[PATCH] D81894: [llvm-readobj][COFF] add .llvm.call-graph-profile section dump
Zequan Wu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 18 11:27:04 PDT 2020
zequanwu marked an inline comment as done.
zequanwu added inline comments.
================
Comment at: llvm/test/tools/llvm-readobj/COFF/call-graph-profile.test:33
+ Alignment: 1
+ SectionData: 0400000008000000200000000000000009000000040000000B0000000000000005000000060000001400000000000000
+symbols:
----------------
grimar wrote:
> zequanwu wrote:
> > grimar wrote:
> > > You should probably put a comment about how to recreate this bytes.
> > > (e.g. a piece of asm)
> > This is generated from a child patch (D81775) and I reduced it by only keeping symbols referred in `SectionData`. Those bytes represent the symbol indexes (which are not stable) and weight.
> >
> > Or I could use the previous version of the test, which includes all symbols and sections generated.
> >
> > I don't if there is a better way to write the test. In `tools/llvm-readobj/ELF/call-graph-profile.test`, `yaml2obj` could generate the `SectionData` from `Entryies` for ELF. For COFF, it lacks the functionalities.
> Ok. Lets leave it as is for now then. I am not sure it is reasonable to reference the functionality of D81775 until it is not landed.
Actually, D81775 depends on this patch. Because the test case `cgprofile.s` in D81775 replies on the functionality of `llvm-readobj` to dump `CGProfile`.
Before, these two patch were in one patch. I split it into two.
================
Comment at: llvm/test/tools/llvm-readobj/COFF/malformed-call-graph-profile.test:16
+ Alignment: 1
+ SectionData: 00
+symbols:
----------------
grimar wrote:
> Isn't it a truncated section for which llvm-readobj should report a warning/error?
Yes.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D81894/new/
https://reviews.llvm.org/D81894
More information about the llvm-commits
mailing list