Intel® C++ Compiler
Support and discussions for creating C++ code that runs on platforms based on Intel® processors.
The Intel sign-in experience is changing in February to support enhanced security controls. If you sign in, click here for more information.

symbol preemption


The "-mno-symbol-preemption" option is the mechanism that tells the compiler that the ADDRESSES will be known at link time and they will not be changed (preempted) while the binary is
running. This option is no longer used and has been replaced by "-fvisibility=hidden -fminshared".

On doing nm on the object thus generated, I notice that some symbols which were earlier in rodata section(using -mno-symbol-preemption) have been now moved to initialized data section for small objects. Are there any other options to the compiler that can ensure that layout seen when compiling with "-mno-symbol-preemption" is completely replicated. The problem symbols were an array of pointers to implicitly defined strings.

0 Kudos
0 Replies