[PATCH] D124855: [XCOFF][AIX] Use unique section names for LSDA and EH info sections with -ffunction-sections
Hubert Tong via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue May 3 08:57:35 PDT 2022
hubert.reinterpretcast added inline comments.
================
Comment at: llvm/include/llvm/CodeGen/TargetLoweringObjectFileImpl.h:291
+ /// For functions, this will return the LSDA section. If option
+ /// -ffunction-sections is on, this will return a unique cscet with the
+ /// function name appended to .gcc_except_table as a suffix of the LSDA
----------------
Fix typo.
================
Comment at: llvm/lib/CodeGen/AsmPrinter/AIXException.cpp:43
+ cast<MCSectionXCOFF>(Asm->getObjFileLowering().getCompactUnwindSection());
+ if (Asm->TM.getFunctionSections()) {
+ // If option -ffunction-section is on, append the function name to the
----------------
Should we also try to use the explicit section name if the function has one?
================
Comment at: llvm/lib/CodeGen/AsmPrinter/AIXException.cpp:44
+ if (Asm->TM.getFunctionSections()) {
+ // If option -ffunction-section is on, append the function name to the
+ // name of EH Info Table csect so that each function has its own EH Info
----------------
Fix option name.
================
Comment at: llvm/lib/CodeGen/AsmPrinter/AIXException.cpp:53
+ }
+ Asm->OutStreamer->SwitchSection(cast<MCSection>(EHInfo));
MCSymbol *EHInfoLabel =
----------------
I think the cast is not necessary.
================
Comment at: llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp:2571
+ auto *LSDA = cast<MCSectionXCOFF>(LSDASection);
+ if (TM.getFunctionSections()) {
+ // If option -ffunction-section is on, append the function name to the
----------------
Should we also try to use the explicit section name if the function has one?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D124855/new/
https://reviews.llvm.org/D124855
More information about the llvm-commits
mailing list