This is a little remarks-based size diffing tool I hacked out using the new remarks section stuff. The idea here is to provide insight into function size changes that show up due to compiler changes rather than source code changes.
What this tool does is diffs the instruction counts produced by the asm-printer's remarks. This allows you to quickly see which functions changed in size between two compiles of the same program.
This is just the basic functionality for now.
I can imagine adding, say...
- Detailed information using size-info remarks
- Information from other pass' remarks, e.g the inliner (with remarks, we can directly access this information!)
- Some nice statistical output (e.g. foo contains 25% of the instructions in the program)
Some detailed output for reference:
https://hastebin.com/hucexocuxi.md
Detailed output shows the differences in instruction counts between compiling stepanov_vector for AArch64 at -Os and -O3 with Clang. (-Os count is first, -O3 count is second, delta is third.)
| FileCheck %s ?