Hicham Mouline wrote: > There is a .so shared dynamic library the main source file of which contains > a global variable. > > In my main funtion, I call dlopen() on the same .so file from 16 different > threads. I do nothing to ensure the call is not done at the same time. > > Very roughly speaking (and please can you provide precision if possible), > the executable code of the .so file is loaded into the main process virtual > memory after the dlopen has succeeded. (Note the main binary is not linked > against the .so file) > > Will there be 16 copies of the executable code from the .so file in the > process? No. > IN particular, will there be 16 copies of the global variable? No. -- Glynn Clements <glynn@xxxxxxxxxxxxxxxxxx> -- To unsubscribe from this list: send the line "unsubscribe linux-c-programming" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html