[aarch64-port-dev ] RFR(XS): 8211320: Aarch64: unsafe.compareAndSetByte() and unsafe.compareAndSetShort() c2 intrinsics broken with negative expected value
    Andrew Haley 
    aph at redhat.com
       
    Mon Oct  1 13:35:52 UTC 2018
    
    
  
Like this:
    bind(retry_load);
    load_exclusive(result, addr, size, acquire);
    if (size == xword) {
      cmp(result, expected);
    } else if (size == word) {
      cmpw(result, expected);
    } else if (size == hword) {
      eorw(rscratch1, result, expected);
      ands(zr, rscratch1, 0xffff);
    } else if (size == byte) {
      eorw(rscratch1, result, expected);
      ands(zr, rscratch1, 0xff);
    } else {
      ShouldNotReachHere();
    }
-- 
Andrew Haley
Java Platform Lead Engineer
Red Hat UK Ltd. <https://www.redhat.com>
EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671
    
    
More information about the hotspot-compiler-dev
mailing list