JDK-8273956 : Add checking for rank values
  • Type: Sub-task
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 18
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2021-09-17
  • Updated: 2021-10-08
  • Resolved: 2021-10-08
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 18
18 masterFixed
Description
Add some checking to maintain sane Mutex rank values.

1. Values can only be subtracted from the enum class rank names
2. Range arithmetic doesn't cause overlap from one range enum value to another
3. Support printing range names and values (rather than numbers in the assert message).
Comments
Changeset: 6364719c Author: Coleen Phillimore <coleenp@openjdk.org> Date: 2021-10-08 12:23:19 +0000 URL: https://git.openjdk.java.net/jdk/commit/6364719cd1c57220769ea580d958da8dc2fdf7f9
08-10-2021