JDK-8324655 : Identify integer minimum and maximum patterns created with if statements
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 23
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2024-01-24
  • Updated: 2024-11-11
  • Resolved: 2024-03-25
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 23
23 b16Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Description
The code patterns "a > b ? a : b" and "if (a > b) b = a" are fairly common in Java code. Currently, the compiler doesn't transform these patterns into minimum and maximum nodes, but such a transformation would compact the IR and allow for other optimizations, such as vectorization.
Comments
Changeset: 9f920b9b Author: Jasmine Karthikeyan <jkarthikeyan@openjdk.org> Committer: Emanuel Peter <epeter@openjdk.org> Date: 2024-03-25 06:23:11 +0000 URL: https://git.openjdk.org/jdk/commit/9f920b9bbf8a64e2c2db085cf3da30db37c0d1bc
25-03-2024

A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/17574 Date: 2024-01-25 18:15:21 +0000
25-01-2024