JDK-8042926 : AdvancedThresholdPolicy::update_rate should use handles for Method*
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 9
  • Priority: P3
  • Status: Resolved
  • Resolution: Not an Issue
  • Submitted: 2014-05-12
  • Updated: 2014-05-13
  • Resolved: 2014-05-13
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.
JDK 9
9Resolved
Related Reports
Relates :  
Description
Raw Method*s are used in AdvancedThresholdPolicy::update_rate, but there are places where safepoint can occur and raw pointers become stale. Method handles should be used instead. 

Also, I filed an RFE to consider completely removing safepoints in ATP::update_rate (see JDK-8042925). 
Comments
Igor, you are right. We discussed that before, but I forgot about it.
13-05-2014

It actually should be ok to use Method* in update_rate() in the post-permgen world. The reference in CompileTask should be enough to keep the method alive. See CompileTask::mark_on_stack().
12-05-2014