[PATCH] D62596: [AARCH64][ELF][llvm-readobj] Add support for BTI and PAC dynamic tags

Peter Smith via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu May 30 02:31:22 PDT 2019

peter.smith marked an inline comment as done.
peter.smith added inline comments.

Comment at: test/tools/llvm-readobj/aarch64-bti-pac-dynamic.test:1
+# Check DT_MIPS_OPTIONS .dynamic section tag reading
grimar wrote:
> ostannard wrote:
> > Copy-pasted comment?
> It is becoming common to start comments from `##` in LLVM tools.
> (see dynamic-section-arch-tags.test below, for example).
Yes will fix, thanks for the spot.

Comment at: test/tools/llvm-readobj/aarch64-bti-pac-dynamic.test:15
+CHECK-NEXT:   0x0000000070000001 AARCH64_BTI_PLT      0
+CHECK-NEXT:   0x0000000070000003 AARCH64_PAC_PLT      0x0
+CHECK-NEXT:   0x0000000000000006 SYMTAB               0x200258
grimar wrote:
> ostannard wrote:
> > Why is the value for PAC printed as "0x0", but BTI is just "0"?
> FWIW it is not an issue of this patch it seems.
That is interesting, in many places in llvm-readelf the architecture specific tags are separated from each other, but in the case of printDynamicEntry they are not. So the AArch64 tags overlap with MIPS_RLD_VERSION and MIPS_ICHECKSUM. In this particular case this doesn't really matter as the value of the tag isn't important, but it may do in the future. To fix this properly will need some similar logic to isolate the cases by processor. I'll have a think.



More information about the llvm-commits mailing list