[llvm] [AIX] In assembly file, create a dummy text renamed to an empty string (PR #73052)

via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 22 08:46:17 PST 2023


================
@@ -928,10 +928,16 @@ void MCObjectFileInfo::initXCOFFMCObjectFileInfo(const Triple &T) {
   // the ABI or object file format, but various tools rely on the section
   // name being empty (considering named symbols to be "user symbol names").
   TextSection = Ctx->getXCOFFSection(
-      "", SectionKind::getText(),
+      "..text..", // Use a non-null name to work around an AIX assembler bug...
+      SectionKind::getText(),
       XCOFF::CsectProperties(XCOFF::StorageMappingClass::XMC_PR, XCOFF::XTY_SD),
       /* MultiSymbolsAllowed*/ true);
 
+  // ... but use a null name when generating the symbol table.
----------------
diggerlin wrote:

delete `...` here.  how about change the comment to 
`Using a null name instead of '..text..' when generating the symbol table.` ?

https://github.com/llvm/llvm-project/pull/73052


More information about the llvm-commits mailing list