Skip to content

Commit

Permalink
Address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kovdan01 committed Apr 3, 2024
1 parent f5e0db1 commit 3beb910
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# RUN: rm -rf %t && split-file %s %t && cd %t

#--- gnu-42-1.s

.section ".note.gnu.property", "a"
.long 4 // Name length is always 4 ("GNU")
.long end - begin // Data length
Expand Down Expand Up @@ -45,7 +44,6 @@ end:
# OBJ-NEXT: ]

#--- gnu-0-0.s

.section ".note.gnu.property", "a"
.long 4 // Name length is always 4 ("GNU")
.long end - begin // Data length
Expand All @@ -68,7 +66,6 @@ end:
# RUN: FileCheck --check-prefix=OBJ -DPLATFORM="0x0 (invalid)" -DVERSION=0x0 %s

#--- gnu-1-0.s

.section ".note.gnu.property", "a"
.long 4 // Name length is always 4 ("GNU")
.long end - begin // Data length
Expand All @@ -91,7 +88,6 @@ end:
# RUN: FileCheck --check-prefix=OBJ -DPLATFORM="0x1 (baremetal)" -DVERSION=0x0 %s

#--- gnu-0x10000002-85.s

.section ".note.gnu.property", "a"
.long 4 // Name length is always 4 ("GNU")
.long end - begin // Data length
Expand All @@ -116,7 +112,6 @@ end:
# RUN: -DVERSION="0x55 (PointerAuthIntrinsics, !PointerAuthCalls, PointerAuthReturns, !PointerAuthAuthTraps, PointerAuthVTPtrAddressDiscrimination, !PointerAuthVTPtrTypeDiscrimination, PointerAuthInitFini)" %s

#--- gnu-0x10000002-128.s

.section ".note.gnu.property", "a"
.long 4 // Name length is always 4 ("GNU")
.long end - begin // Data length
Expand All @@ -139,7 +134,6 @@ end:
# RUN: FileCheck --check-prefix=OBJ -DPLATFORM="0x10000002 (llvm_linux)" -DVERSION="0x80 (unknown)" %s

#--- gnu-short.s

.section ".note.gnu.property", "a"
.long 4 // Name length is always 4 ("GNU")
.long end - begin // Data length
Expand Down Expand Up @@ -185,7 +179,6 @@ end:
# OBJ-ERR-NEXT: ]

#--- gnu-long.s

.section ".note.gnu.property", "a"
.long 4 // Name length is always 4 ("GNU")
.long end - begin // Data length
Expand Down
6 changes: 3 additions & 3 deletions llvm/tools/llvm-readobj/ELFDumper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5156,12 +5156,12 @@ static bool printAArch64PAuthABICoreInfo(raw_ostream &OS, uint32_t DataSize,
"Update when new enum items are defined");

std::string Desc;
for (uint32_t I = 0; I < Flags.size(); ++I) {
for (uint32_t I = 0, End = Flags.size(); I < End; ++I) {
if (!(Version & (1 << I)))
Desc += '!';
Desc += Twine("PointerAuth" + Flags[I] + ", ").str();
Desc +=
Twine("PointerAuth" + Flags[I] + (I == End - 1 ? "" : ", ")).str();
}
Desc.resize(Desc.size() - 2); // Trim last ", "
return Desc;
}();

Expand Down

0 comments on commit 3beb910

Please sign in to comment.