Define a Section with __section Macro in GCC
This is a preprocessor macro that defines a section named 'prog' using the GNU compiler attribute syntax. The section is marked as 'used', which means that the linker should include it in the final executable or shared library, even if there are no references to symbols defined in that section. This macro is often used to specify sections for code or data that need to be located at specific addresses in memory, or to group related functions or variables together for better organization and optimization.
原文地址: http://www.cveoy.top/t/topic/n3Ia 著作权归作者所有。请勿转载和采集!