RFR: 8366815: C2: Delay Mod/Div by constant transformation
    Vladimir Ivanov 
    vlivanov at openjdk.org
       
    Thu Oct 23 19:29:58 UTC 2025
    
    
  
On Sun, 19 Oct 2025 15:46:06 GMT, Hannes Greule <hgreule at openjdk.org> wrote:
> The test cases show examples of code where `Value()` previously wasn't run because idealization took place before, resulting in less precise type analysis.
> 
> Please let me know what you think.
It seems the root cause is a divergence in functionality in GVN between different representations of Div/Mod nodes.
How hard would it be to align the implementation and improve GVN handling for other representations, so the same type is constructed irrespective of the IR shape?
Alternatively, as part of the expansion, new representation can be wrapped in CastII/CastLL with the narrower type of original Div/Mod node.
-------------
PR Comment: https://git.openjdk.org/jdk/pull/27886#issuecomment-3438763340
    
    
More information about the hotspot-compiler-dev
mailing list