The script we now have is nice, and incredibly useful already, but lacking in many important respects.
We need:
1) Ability to easily diff LLVM output as well as WASM output.
This should be relatively straightforward to implement: save the base obj directory, use llvm-dis to find and disassemble functions with diffs, dump those functions into diff files (alongside WASM or separately - open question).
Fixed in #2496.
2) Ability to compile single functions. There are two "levels" to this feature:
Ability to construct a --singlemethod-based ILC command line given a diff index.
Ability to diff the resulting object file - this would enable single-function WASM diffs.
The latter feature is critical for debugging, as right now you can only guess what caused the diffs. Now, single-method diffing can never be 100% faithful of the final compilation and in fact often isn't due to ILC's and LLVM's global analyses, but it is not really possible to do much about it short of replaying the whole compilation for one method, which is very slow.
The script we now have is nice, and incredibly useful already, but lacking in many important respects.
We need: 1) Ability to easily diff LLVM output as well as WASM output.
obj
directory, usellvm-dis
to find and disassemble functions with diffs, dump those functions into diff files (alongside WASM or separately - open question).--singlemethod
-based ILC command line given a diff index.The latter feature is critical for debugging, as right now you can only guess what caused the diffs. Now, single-method diffing can never be 100% faithful of the final compilation and in fact often isn't due to ILC's and LLVM's global analyses, but it is not really possible to do much about it short of replaying the whole compilation for one method, which is very slow.