Request for reviews (S): 6892186: 6896084: VM does not reserve protected page below heap for compressed oops implicit null checks
John.Coomes at sun.com
Thu Oct 29 13:21:10 PDT 2009
Vladimir Kozlov (Vladimir.Kozlov at Sun.COM) wrote:
> Fixed 6896084: VM does not reserve protected page below heap for compressed oops implicit null checks
> VM should reserve protected page below heap for compressed oops
> implicit null checks in compiled code (see 6716785).
> After zero based compressed oops changes (6791178) the page is
> not reserved because undefined narrow_oop_base (NULL by default)
> is used in ReservedHeapSpace() to determine if the page is needed.
> Set narrow_oop_base and narrow_oop_use_implicit_null_checks
> values according to compressed oops encoding mode in
> Universe::preferred_heap_base() which is called before
> ReservedHeapSpace() constructors.
Your changes look good to me. Some comment typos/nits:
788 // Set not NULL value to indicate the need of narrow_oop_base.
The comment didn't help me understand why it had to be non-null.
Maybe "Set to a non-NULL value so the ReservedSpace ctor computes the
correct no-access prefix."
Not your change, but the conditional expression in ReservedHeapSpace
ctor that uses this should be made into a static function, e.g.,
no_access_prefix_size(...). I'll add it to my cleanups list.
794 // addressing mode, when large pages are specified on windows.
FWIW, the comma isn't necessary.
More information about the hotspot-runtime-dev