[lworld] RFR: 8262863: [lworld] C2 should keep track of the oop even if an inline type is returned as fields [v2]

Tobias Hartmann thartmann at openjdk.java.net
Tue Mar 2 16:29:23 UTC 2021


> If an inline type is returned, its fields are passed in registers if possible. The first register (rax) either contains a pointer to the InlineKlass to allow buffering in interpreted or C1 compiled callers or an oop if the inline type has already been buffered. Currently, a C2 compiled caller completely ignores the first register and just uses the field values returned in the other registers.
> 
> With this patch, C2 checks if an oop is returned and keeps track of it to avoid unnecessary re-buffering. This significantly boosts performance of cases were inlining fails and the callee is interpreted, C1 compiled or had to buffer the inline type for another reason (for example, due a store to a non-flattened field/array).
> 
> Thanks,
> Tobias

Tobias Hartmann has updated the pull request incrementally with one additional commit since the last revision:

  Handle incremental inlining

-------------

Changes:
  - all: https://git.openjdk.java.net/valhalla/pull/357/files
  - new: https://git.openjdk.java.net/valhalla/pull/357/files/64a82a25..ed85fab9

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=valhalla&pr=357&range=01
 - incr: https://webrevs.openjdk.java.net/?repo=valhalla&pr=357&range=00-01

  Stats: 7 lines in 1 file changed: 5 ins; 0 del; 2 mod
  Patch: https://git.openjdk.java.net/valhalla/pull/357.diff
  Fetch: git fetch https://git.openjdk.java.net/valhalla pull/357/head:pull/357

PR: https://git.openjdk.java.net/valhalla/pull/357



More information about the valhalla-dev mailing list