RFR: 8254693: Add Panama feature to pass heap segments to native code [v5]

Martin Doerr mdoerr at openjdk.org
Thu Oct 19 13:01:45 UTC 2023


On Wed, 18 Oct 2023 14:47:58 GMT, Jorn Vernee <jvernee at openjdk.org> wrote:

> > I wonder if the native_invoker_size_per_arg thing still works good enough. We may exceed the computed size, now, right?
> 
> Good point. I'll have a look at enhancing the test we have for this.
> 
> Intuitively, I think it will be okay. It's true that we generate more code to add the oops and offsets together, but at the same time, we don't have any code to shuffle the offsets.

Looks like we use 2 input regs per obj, so we reserve 2x native_invoker_size_per_arg. However, the case in which `reg_oop` and `reg_offset` are on stack together with `arg_shuffle` can produce more than this size (depending on platform). If we pass lots of objects on stack, we may exceed the computed size. Correct?

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

PR Comment: https://git.openjdk.org/jdk/pull/16201#issuecomment-1770938705


More information about the core-libs-dev mailing list