File tree Expand file tree Collapse file tree 1 file changed +20
-1
lines changed
test/hotspot/jtreg/compiler/macronodes Expand file tree Collapse file tree 1 file changed +20
-1
lines changed Original file line number Diff line number Diff line change 2626 * @bug 8327012
2727 * @summary Test that initializing store gets captured, i.e. moved before the InitializeNode
2828 * and made into a raw-store.
29- *
29+ * @library /test/lib /
3030 * @run driver compiler.macronodes.TestInitializingStoreCapturing
3131 */
3232
3333package compiler .macronodes ;
3434
35+ import compiler .lib .ir_framework .*;
36+
3537public class TestInitializingStoreCapturing {
3638
39+ static class A {
40+ float value ;
41+ A (float v ) { value = v ; }
42+ };
43+
3744 static public void main (String [] args ) {
45+ TestFramework .run ();
3846 }
3947
48+ @ Test
49+ @ IR (counts = {IRNode .STE , "= 0" })
50+ static A testInitializeField () {
51+ return new A (4.2f );
52+ }
53+
54+ @ Test
55+ @ IR (counts = {IRNode .STORE , "= 0" })
56+ static float [] testInitializeArray () {
57+ return new float [] {4.2f };
58+ }
4059}
4160
You can’t perform that action at this time.
0 commit comments