JDK-8248549 : Results of execution differ for C2 and C1/Interpreter
  • Type: Bug
  • Component: hotspot
  • Sub-Component: compiler
  • Affected Version: 8,11,15,16
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2020-06-30
  • Updated: 2020-07-13
  • Resolved: 2020-07-13
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 16
16Resolved
Related Reports
Duplicate :  
Description
The attached fuzzer test produces a different result for C2 compared to C1/interpreter.

To reproduce:
$ java -Xint Test.java > Xint.log
$ java -Xmx1G -Xcomp -Xbatch -XX:-TieredCompilation -XX:CompileOnly=Test Test.java > c2.log

$ diff Xint.log c2.log
7c7
< vMeth1_check_sum: 4635247489541481754
---
> vMeth1_check_sum: 4635247489541481753
16c16
< vMeth1_check_sum: -9176249094203243722
---
> vMeth1_check_sum: -9176249094203243723
25c25
< vMeth1_check_sum: -4541001604881528878
---
> vMeth1_check_sum: -4541001604881528879
34c34
< vMeth1_check_sum: 94245884440185966
---
> vMeth1_check_sum: 94245884440185965
43c43
< vMeth1_check_sum: 4729493373761900810
---
> vMeth1_check_sum: 4729493373761900809
52c52
< vMeth1_check_sum: -9082003210625935962
---
> vMeth1_check_sum: -9082003210625935963
61c61
< vMeth1_check_sum: -4446755721304221118
---
> vMeth1_check_sum: -4446755721304221119
70c70
< vMeth1_check_sum: 188491768017493726
---
> vMeth1_check_sum: 188491768017493725
79c79
< vMeth1_check_sum: 4823739257339208570
---
> vMeth1_check_sum: 4823739257339208569
88c88
< vMeth1_check_sum: -8987757327048628202
---
> vMeth1_check_sum: -8987757327048628203

Comments
C2 erroneously schedules a store before a load. This could be traced back to a missing anti-dependency. JDK-8243670 fixed this and also fixes this issue. I will close it as a duplicate.
13-07-2020

ILW = Incorrect execution of C2 compiled code, only with JavaFuzzer generated test (probably edge case) and not a recent regression, disable compilation of affected method = HLM = P3
30-06-2020