RFR (L): JDK-8014786: Cleaning up the split code in the register allocator of C2
Niclas Adlertz
niclas.adlertz at oracle.com
Fri May 17 16:37:03 PDT 2013
Hi all.
I've been trying to refactor and cleanup the split code currently located at src/share/vm/opto/reg_split.cpp. Here is the result of that.
This fix also fixes bugs https://jbs.oracle.com/bugs/browse/JDK-8005956 and https://jbs.oracle.com/bugs/browse/JDK-8013830.
The first bug is resolved by removing rematerialization of reaches to phi nodes.
This comes with a slight performance degradation [0]. However, since this rematerialization is causing JVM crashes, I would say it's worth it.
When reviewing this fix, please use the existing reg_split.cpp found at src/share/vm/opto/reg_split.cpp as a reference.
JBS: https://jbs.oracle.com/bugs/browse/JDK-8014786
WEBREV: http://cr.openjdk.java.net/~adlertz/JDK-8014786/webrev00/
Kind Regards,
Niclas Adlertz
[0] Results from refworkload on 1) x64 Linux and 2) SPARCV9 Solaris.
Baseline and fix with 12 iterations each.
1) x64 Linux
============================================================================
refworkload_base: reference_server
Benchmark Samples Mean Stdev
jetstream 12 185.27 0.03
Write 12 71.42 0.04
Parse 12 67.92 0.03
Read 12 17.25 0.10
Copy 12 102.17 0.02
scimark 12 1438.69 0.00
LU 12 3213.92 0.01
FFT 12 211.00 0.02
Monte 12 827.71 0.01
SOR 12 1365.90 0.00
Sparse 12 1574.90 0.01
specjbb2000 12 493245.44 0.00
Last_Warehouse 12 493245.44 0.00
First_Warehouse 12 118938.86 0.00
specjbb2005 12 179117.61 0.00
last 12 179117.61 0.00
interval_average 12 10536.25 0.00
peak 12 184040.52 0.01
overall_average 12 164733.22 0.01
last_warehouse 12 8.00 0.00
peak_warehouse 12 4.25 0.11
first 12 63494.80 0.00
specjvm98 12 1020.02 0.01
compress 12 817.54 0.00
javac 12 598.70 0.01
db 12 407.37 0.02
jack 12 1299.66 0.03
mtrt 12 2904.37 0.02
jess 12 1089.06 0.02
mpegaudio 12 1402.48 0.00
volano25 12 183768.67 0.04
time 12 4.36 0.04
connections 12 400.00 0.00
--------------------------------------------------------------------------
Weighted Geomean 23543.18
============================================================================
refworkload_new: reference_server
Benchmark Samples Mean Stdev %Diff P Significant
jetstream 12 185.36 0.04 0.05 0.972 *
Write 12 71.50 0.04 -0.12 0.939 *
Parse 12 68.25 0.03 -0.49 0.720 *
Read 12 17.42 0.16 -0.97 0.858 *
Copy 12 101.25 0.01 0.90 0.173 *
scimark 12 1439.00 0.00 0.02 0.883 *
LU 12 3219.37 0.01 0.17 0.573 *
FFT 12 210.42 0.02 -0.28 0.731 *
Monte 12 822.82 0.02 -0.59 0.308 *
SOR 12 1366.46 0.00 0.04 0.727 *
Sparse 12 1575.92 0.01 0.06 0.827 *
specjbb2000 12 494080.03 0.00 0.17 0.390 *
Last_Warehouse 12 494080.04 0.00 0.17 0.390 *
First_Warehouse 12 118958.56 0.01 0.02 0.929 *
specjbb2005 12 177183.33 0.00 -1.08 0.000 Yes
last 12 177183.33 0.00 -1.08 0.000 Yes
interval_average 12 10422.67 0.00 -1.08 0.000 Yes
peak 12 181694.28 0.01 -1.27 0.002 Yes
overall_average 12 162698.56 0.00 -1.24 0.000 Yes
last_warehouse 12 8.00 0.00 -0.00 0.000 *
peak_warehouse 12 4.25 0.15 -0.00 1.000 *
first 12 62434.46 0.01 -1.67 0.000 Yes
specjvm98 12 1023.79 0.00 0.37 0.066 *
compress 12 815.74 0.00 -0.22 0.066 *
javac 12 601.44 0.02 0.46 0.488 *
db 12 406.33 0.01 -0.26 0.610 *
jack 12 1315.79 0.01 1.24 0.162 *
mtrt 12 2892.01 0.01 -0.43 0.472 *
jess 12 1107.66 0.01 1.71 0.003 Yes
mpegaudio 12 1403.36 0.00 0.06 0.560 *
volano25 12 180872.25 0.04 -1.58 0.333 *
time 12 4.43 0.04 -1.63 0.312 *
connections 12 400.00 0.00 0.00 0.000 *
--------------------------------------------------------------------------
Weighted Geomean 23425.71 -0.50
============================================================================
2) SPARCV9 Solaris
============================================================================
refworkload_base: reference_server
Benchmark Samples Mean Stdev
jetstream 12 36.03 0.01
Copy 12 258.08 0.00
Parse 12 337.08 0.00
Read 12 126.67 0.04
Write 12 538.83 0.00
scimark 12 44.36 0.01
Sparse 12 27.44 0.01
LU 12 51.53 0.02
SOR 12 80.13 0.01
FFT 12 14.28 0.00
Monte 12 48.44 0.00
specjbb2000 12 80257.23 0.00
First_Warehouse 12 10756.41 0.01
Last_Warehouse 12 80257.24 0.00
specjbb2005 12 274794.56 0.02
peak 12 274794.56 0.02
peak_warehouse 12 8.00 0.00
last 12 274794.56 0.02
interval_average 12 535.58 0.02
first 12 5079.05 0.02
overall_average 12 121172.61 0.07
last_warehouse 12 8.00 0.00
specjvm98 12 81.51 0.01
javac 12 58.26 0.01
db 12 54.68 0.03
jess 12 88.80 0.00
jack 12 41.98 0.01
compress 12 87.66 0.00
mtrt 12 228.86 0.01
mpegaudio 12 100.37 0.00
volano25 12 114566.00 0.15
connections 12 400.00 0.00
time 12 7.15 0.17
--------------------------------------------------------------------------
Weighted Geomean 6260.91
============================================================================
refworkload_new: reference_server
Benchmark Samples Mean Stdev %Diff P Significant
jetstream 12 35.94 0.01 -0.26 0.419 *
Copy 12 257.00 0.00 0.42 0.000 Yes
Parse 12 345.33 0.02 -2.45 0.001 Yes
Read 12 126.08 0.00 0.46 0.686 *
Write 12 535.92 0.00 0.54 0.000 Yes
scimark 12 44.47 0.01 0.25 0.340 *
Sparse 12 27.37 0.01 -0.24 0.301 *
LU 12 51.27 0.01 -0.50 0.525 *
SOR 12 81.10 0.01 1.21 0.002 Yes
FFT 12 14.24 0.00 -0.27 0.118 *
Monte 12 48.37 0.00 -0.14 0.392 *
specjbb2000 12 80158.49 0.01 -0.12 0.497 *
First_Warehouse 12 10859.44 0.02 0.96 0.169 *
Last_Warehouse 12 80158.49 0.01 -0.12 0.497 *
specjbb2005 12 271115.25 0.02 -1.34 0.093 *
peak 12 271115.24 0.02 -1.34 0.093 *
peak_warehouse 12 8.00 0.00 -0.00 0.000 *
last 12 271115.24 0.02 -1.34 0.093 *
interval_average 12 528.42 0.02 -1.34 0.091 *
first 12 5138.08 0.01 1.16 0.074 *
overall_average 12 122254.45 0.07 0.89 0.764 *
last_warehouse 12 8.00 0.00 -0.00 0.000 *
specjvm98 12 81.52 0.01 0.01 0.956 *
javac 12 58.16 0.01 -0.16 0.715 *
db 12 54.62 0.03 -0.11 0.921 *
jess 12 89.43 0.01 0.72 0.005 Yes
jack 12 42.04 0.01 0.13 0.619 *
compress 12 87.62 0.00 -0.04 0.739 *
mtrt 12 228.18 0.02 -0.30 0.608 *
mpegaudio 12 100.24 0.00 -0.13 0.383 *
volano25 12 116908.34 0.12 2.04 0.713 *
connections 12 400.00 0.00 0.00 0.000 *
time 12 6.93 0.12 3.02 0.617 *
--------------------------------------------------------------------------
Weighted Geomean 6264.78 0.06
============================================================================
More information about the hotspot-compiler-dev
mailing list