RFR: 8331404: IGV: Show line numbers for callees in properties
Christian Hagedorn
chagedorn at openjdk.org
Tue Apr 30 15:43:13 UTC 2024
IGV shows the `bci` for a node in the callee, followed by the bci in the caller method and so on until we reach the root method. For the `line` property, we currently only show the line number found in the root method (`first()` is the root method being compiled and `second()` and `third()` are inlined):
Example program:

Properties of the store to `fFld`:

One could read the line number from the `jvms` property above. But you would need to expand that property with the button on the right side which opens a window. But then you cannot click anything else anymore in IGV until you close the window again.
A simpler and easier to read solution is to add the line number information to match the bci numbers (they are printed in callee->root method order which I think is okay - especially if there are a lot of inlinees, it could be easier to have the really interesting numbers at the start on the left side). This would look something like that:

If there is no line number information for a bci, I simply emit a `_`.
Testing:
- Manual testing in IGV
- Sanity testing by running `java -Xcomp -XX:+PrintIdealGraph -XX:PrintIdealGraphLevel=4 -XX:PrintIdealGraphFile=graph.xml HelloWorld.java`.
Thanks,
Christian
-------------
Commit messages:
- 8331404: IGV: Show line numbers for callees in properties
Changes: https://git.openjdk.org/jdk/pull/19025/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=19025&range=00
Issue: https://bugs.openjdk.org/browse/JDK-8331404
Stats: 51 lines in 2 files changed: 31 ins; 16 del; 4 mod
Patch: https://git.openjdk.org/jdk/pull/19025.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/19025/head:pull/19025
PR: https://git.openjdk.org/jdk/pull/19025
More information about the hotspot-compiler-dev
mailing list