[foreign-memaccess+abi] RFR: 8293367: Enable native access for modules not in the boot layer

Athijegannathan Sundararajan sundar at openjdk.org
Tue Sep 20 13:47:42 UTC 2022


Adding a new API ModuleLayer.Controller.enableNativeAccess(Module).
Reworked thread safety of enable native access flag reading and setting.

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

Commit messages:
 - cleaned up locking in Module.java
 - calling address instead of hashCode in LoopOverOfAddress.java
 - added benchmark LoopOverOfAddress.java
 - refactoring to handle all synchronization/checking to Module.java
 - make the public native-access flag getter API synchronized. use unsynchronzied (questionable?)
 - when testing panama_module name clash (b/w boot and other layer), no need to give
 - Made Module.implAddEnableNativeAccess method synchronized
 - missed adding panama_module in module-in-boot-layer test case
 - 8293367: Enable native access for modules not in the boot layer

Changes: https://git.openjdk.org/panama-foreign/pull/729/files
 Webrev: https://webrevs.openjdk.org/?repo=panama-foreign&pr=729&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8293367
  Stats: 478 lines in 8 files changed: 437 ins; 27 del; 14 mod
  Patch: https://git.openjdk.org/panama-foreign/pull/729.diff
  Fetch: git fetch https://git.openjdk.org/panama-foreign pull/729/head:pull/729

PR: https://git.openjdk.org/panama-foreign/pull/729


More information about the panama-dev mailing list