[PATCH] D105217: [LLD] Adding support for RELA for CG Profile.

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 8 14:16:17 PDT 2021


MaskRay added a comment.

In D105217#2865533 <https://reviews.llvm.org/D105217#2865533>, @ayermolo wrote:

> In D105217#2863821 <https://reviews.llvm.org/D105217#2863821>, @jhenderson wrote:
>
>> Test case(s) for the LLD portion of this patch?
>
> There doesn't seem to be any tests for LLD, even for old implementation. What would be best way? feed llvm bit code in to llvm-mc, run lld on it and check final binary symbol table for ordering? Add something to LLD to output from internal data structure?

See `test/ELF/cgprofile-obj.s` for `.cg_profile` directives. The old implementation only tested RELA, not REL. The current state is only REL. Now we need `RELA` for GNU objcopy/strip compatibility, we need yaml2obj tests because assemblers don't use REL.

Please mark resolved comments as "done" (press submit).


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D105217/new/

https://reviews.llvm.org/D105217



More information about the llvm-commits mailing list