[foreign-abi] [Rev 01] RFR: 8241017: Enhance AllocationScope to support "unbounded" mode

Maurizio Cimadamore mcimadamore at openjdk.java.net
Fri Mar 13 22:04:22 UTC 2020


> This patch adds support for allocation scopes whose size is not known statically; as such these new unbounded
> allocation scope can be used in more dynamic use cases where e.g. the amount of memory to be allocated depends on the
> result of other native calls.  Internally, the bounded version works as before, and is the more optimized. The
> unbounded version is similar in spirit to the old Panama/foreign scope - where new segments are allocated depending on
> needs.  I've enhanced the existing test covering allocation scopes to also cover the unbounded variants, as well as the
> bounded.

Maurizio Cimadamore has updated the pull request incrementally with three additional commits since the last revision:

 - Update src/jdk.incubator.foreign/share/classes/jdk/incubator/foreign/AllocationScope.java
   
   Co-Authored-By: Jorn Vernee <JornVernee at users.noreply.github.com>
 - Update src/jdk.incubator.foreign/share/classes/jdk/incubator/foreign/AllocationScope.java
   
   Co-Authored-By: Jorn Vernee <JornVernee at users.noreply.github.com>
 - Update src/jdk.incubator.foreign/share/classes/jdk/incubator/foreign/AllocationScope.java
   
   Co-Authored-By: Jorn Vernee <JornVernee at users.noreply.github.com>

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

Changes:
  - all: https://git.openjdk.java.net/panama-foreign/pull/53/files
  - new: https://git.openjdk.java.net/panama-foreign/pull/53/files/fbf5ef77..5cfb84ae

Webrevs:
 - full: https://webrevs.openjdk.java.net/panama-foreign/53/webrev.01
 - incr: https://webrevs.openjdk.java.net/panama-foreign/53/webrev.00-01

  Stats: 3 lines in 1 file changed: 0 ins; 0 del; 3 mod
  Patch: https://git.openjdk.java.net/panama-foreign/pull/53.diff
  Fetch: git fetch https://git.openjdk.java.net/panama-foreign pull/53/head:pull/53

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


More information about the panama-dev mailing list