Hi,
Does anyone know I can internally change KMP_AFFINITY in the sub-process invoked from my program? My experiment shows it does not work with intel compiler but however it is under gcc compiler.
here is the example:
let's say I have KMP_AFFINITY=scatter, which is for my main process. Then inside main process before invoking another executable as the sub-process, putenv is used to modify KMP_AFFINITY=none for the sub-process.
is this supposed to work? my run shows the KMP_AFFINITY=none does not apply to the sub-process if intel compiler is used to compile and link my main program. but it is with gcc compiler.
when I double check the environment, in the sub-process, there is one extra environment variable for my exe with intel compiler
__KMP_REGISTERED_LIB_23907=0xacfa1d0-cafe8af0-libiomp5.a
what does this guy do and how to explain such difference? Thank you
Hongwei