JDK-8073465 : Protect the memory of G1 regions on the free list
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: gc
  • Affected Version: 9
  • Priority: P4
  • Status: Open
  • Resolution: Unresolved
  • Submitted: 2015-02-19
  • Updated: 2019-02-11
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
tbdUnresolved
Related Reports
Blocks :  
Description
When a G1 heap region is added to the free list (in G1CollectedHeap::free_region), then we should have a way to set the memory protection for the region to PROT_NONE. This can be done with a call to os::protect_memory. The tricky part is to make sure we set the protection back to PROT_RW once the region becomes used again.
Comments
I think this is a nice feature, so imo it should be kept. My remarks were just about that at the moment implementing this may be more difficult than expected; or in other words, it is practically blocked by e.g. JDK-8071913
31-03-2015

Ok, so can we go ahead and close this bug as won't fix?
30-03-2015

I do not think this would work at the moment. The remembered sets may contain stale references to free regions that can be iterated over. In particular, ie. at least one problem is that RSet scrubbing for example does not scrub the sparse remembered sets. It would be a great preparation for allowing uncommit of free regions without a full gc.
26-03-2015

ILW = Low (simplifies debugging but don't affect product), High (always), High (none) = P4
20-02-2015