[PATCH] D54217: Add total function byte size and inline function byte size to "llvm-dwarfdump --statistics"
David Blaikie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 8 17:15:29 PST 2018
dblaikie added a comment.
In https://reviews.llvm.org/D54217#1292327, @dblaikie wrote:
> In https://reviews.llvm.org/D54217#1292323, @vsk wrote:
>
> > Why not check in a .o? The numbers won't change, so they can meaningfully be compared.
>
>
> An object file or assembly seems fine, yeah.
I should say - I know this can be a bit more of a pain to maintain - modifications to the test case usually involve rerunning the compiler, etc. (though the same is true for LLVM IR debug info metadata usually - we don't generally hand-craft it) - and I wouldn't be averse to an IR test case that was stabilized - there are ways to pretty thoroughly restrict the compiler's ability to optimize anything too far (using function calls (to functions declared but not defined), inline assembly, etc).
But yeah, assembly or object files are probably the right tool here - very few (& I probably would've pushed back on this one going in in the first place if I'd noticed) test case for dwarfdump use IR, the rest use object files or assembly.
https://reviews.llvm.org/D54217
More information about the llvm-commits
mailing list