[foreign-abi] RFR: Copy stubs from Compile arena to nmethod stub array

Jorn Vernee jvernee at openjdk.java.net
Thu Jul 2 15:58:34 UTC 2020


Hi,

This is a small followup on the intrinsics patch (https://github.com/openjdk/panama-foreign/pull/219).

@slowhog was seeing a crash when native invoker stubs were being freed, and it turned out that this was due to not
copying the stubs properly from the compile arena to the nmethod stub array when creating the nmethod. This patch fixes
that.

I had wrongly assumed that this code path would be exercised by the current tests, but this is evidently not the case.
I'll think of a way to add a test for this specific case, but in the mean time this is a stop-gap fix to resolve the
crash.

Thanks,
Jorn

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

Commit messages:
 - Fix bug

Changes: https://git.openjdk.java.net/panama-foreign/pull/227/files
 Webrev: https://webrevs.openjdk.java.net/panama-foreign/227/webrev.00
  Stats: 3 lines in 1 file changed: 3 ins; 0 del; 0 mod
  Patch: https://git.openjdk.java.net/panama-foreign/pull/227.diff
  Fetch: git fetch https://git.openjdk.java.net/panama-foreign pull/227/head:pull/227

PR: https://git.openjdk.java.net/panama-foreign/pull/227


More information about the panama-dev mailing list