This makes oopFactory and deoptimization the only friends of private 
ArrayKlass::allocate_instance.  This is similar to the PR 
https://github.com/openjdk/jdk/pull/27372 in mainline with some extra handling 
for new_refArray (rather than calling RefArrayKlass::allocate_instance() 
directly.
Tested with tier1-4.

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

Commit messages:
 - 8367415: Fully encapsulate array allocation in oopFactory

Changes: https://git.openjdk.org/valhalla/pull/1602/files
  Webrev: https://webrevs.openjdk.org/?repo=valhalla&pr=1602&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8367415
  Stats: 53 lines in 10 files changed: 19 ins; 24 del; 10 mod
  Patch: https://git.openjdk.org/valhalla/pull/1602.diff
  Fetch: git fetch https://git.openjdk.org/valhalla.git pull/1602/head:pull/1602

PR: https://git.openjdk.org/valhalla/pull/1602

Reply via email to