JDK-8350616 : Skip ValidateHazardPtrsClosure in non-debug builds
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 17,21,25
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2025-02-25
  • Updated: 2025-03-07
  • Resolved: 2025-02-26
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 25
25 b12Fixed
Related Reports
Blocks :  
Relates :  
Description
The ValidateHazardPtrsClosure closure is effectively a no-op in a non-debug build, but ThreadsSMRSupport::free_list stills applies it in a linear-scan of all threads, unnecessarily. The assert was originally a guarantee and this optimisation was missed when it was changed over by JDK-8264624
Comments
I've converted to enhancement to make backporting easier.
27-02-2025

Changeset: e43960a0 Branch: master Author: David Holmes <dholmes@openjdk.org> Date: 2025-02-26 20:14:11 +0000 URL: https://git.openjdk.org/jdk/commit/e43960a0170bf29b28ff4733e1c8c927947fb0bb
26-02-2025

Non-critical: any reason for this to be a sub-task? Can we convert it to free-standing issue that relates to JDK-8307970? Should be just a few clicks in JIRA, which does not change bug IDs or anything. I think this fix deserves backports -- as we are seeing some of these issues in prod -- and doing backports of root tasks feels a bit cleaner to avoid overly deep nesting of issues.
26-02-2025

A pull request was submitted for review. Branch: master URL: https://git.openjdk.org/jdk/pull/23762 Date: 2025-02-25 02:33:23 +0000
25-02-2025