JIT function insertion/creation in multithreaded setting

I have been looking at the possibility of writing a multithreaded server with the LLVM JIT acting as a key part of the runtime system. In this kind of setting it may entirely be possible for the compiler to be active on to separate threads. I am curious in this sort of situation which entities I would have to protect with a mutex. Is it just certain functions in the Module class?

Thanks in advance.

I believe you have to protect the whole module (at least for now).