[llvm] r191824 - Add Support For .bss Named Section Directive For Darwin Targets.
Rafael Espindola
rafael.espindola at gmail.com
Wed Oct 2 07:09:29 PDT 2013
Author: rafael
Date: Wed Oct 2 09:09:29 2013
New Revision: 191824
URL: http://llvm.org/viewvc/llvm-project?rev=191824&view=rev
Log:
Add Support For .bss Named Section Directive For Darwin Targets.
Patch by Nicholas White.
Modified:
llvm/trunk/lib/MC/MCParser/DarwinAsmParser.cpp
Modified: llvm/trunk/lib/MC/MCParser/DarwinAsmParser.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/MC/MCParser/DarwinAsmParser.cpp?rev=191824&r1=191823&r2=191824&view=diff
==============================================================================
--- llvm/trunk/lib/MC/MCParser/DarwinAsmParser.cpp (original)
+++ llvm/trunk/lib/MC/MCParser/DarwinAsmParser.cpp Wed Oct 2 09:09:29 2013
@@ -71,6 +71,7 @@ public:
".end_data_region");
// Special section directives.
+ addDirectiveHandler<&DarwinAsmParser::ParseSectionDirectiveBss>(".bss");
addDirectiveHandler<&DarwinAsmParser::ParseSectionDirectiveConst>(".const");
addDirectiveHandler<&DarwinAsmParser::ParseSectionDirectiveConstData>(
".const_data");
@@ -182,6 +183,10 @@ public:
bool ParseDirectiveDataRegionEnd(StringRef, SMLoc);
// Named Section Directive
+ bool ParseSectionDirectiveBss(StringRef, SMLoc) {
+ return ParseSectionSwitch("__DATA", "__bss");
+ }
+
bool ParseSectionDirectiveConst(StringRef, SMLoc) {
return ParseSectionSwitch("__TEXT", "__const");
}
More information about the llvm-commits
mailing list