data_seg
#pragma data_seg( ["section-name"[, "section-class"] ] )
Specifies the default section for initialized data. For example:
#pragma data_seg( "MY_DATA" )
causes data allocated following the #pragma statement to be placed in a section called MY_DATA.
Data allocated using the data_seg pragma does not retain any information about its location.
The second parameter, section-class, is included for compatibilty with versions of Visual C++ prior to version 2.0, and is now ignored.
See /SECTION for a list of names you should not use when creating a section.
博客介绍了C++里data_seg的作用,它用于指定初始化数据的默认段。如使用该编译指令后分配的数据会被放在指定段中,且用其分配的数据不保留位置信息,第二个参数现被忽略,还提到创建段时的命名注意事项。
1405

被折叠的 条评论
为什么被折叠?



