[PATCH] D101272: [llvm-objdump][XCOFF][AIX] Enable the -l (--line-numbers) option.
Xing GUO via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Apr 29 20:00:45 PDT 2021
Higuoxing accepted this revision.
Higuoxing added a comment.
This revision is now accepted and ready to land.
Only minor suggestions, otherwise LGTM. But please give somebody else a chance to review this change :)
================
Comment at: llvm/lib/Object/XCOFFObjectFile.cpp:858-859
+bool XCOFFSymbolRef::isCommon() const {
+ return ((getStorageClass() == XCOFF::C_EXT &&
+ getSectionNumber() == XCOFF::N_UNDEF && getSymbolType() != 0));
+}
----------------
================
Comment at: llvm/lib/Object/XCOFFObjectFile.cpp:871-876
+ bool isAppdomainGlobal =
+ getStorageClass() == XCOFF::C_EXT && getSectionNumber() == XCOFF::N_ABS;
+ bool isOrdinarySection = getStorageClass() == XCOFF::C_STAT;
+ if (!getNumberOfAuxEntries())
+ return false;
+ return isAppdomainGlobal || isOrdinarySection;
----------------
I would suggest putting the code block
```
if (!getNumberOfAuxEntries())
return false;
```
in the front to avoid potential useless computation.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D101272/new/
https://reviews.llvm.org/D101272
More information about the llvm-commits
mailing list