@@ -187,8 +187,7 @@ void runControlFlowTests() {
187
187
}
188
188
189
189
@ Test
190
- // TODO: 8353182
191
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
190
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
192
191
static void testAllocateThenAtomic (Inner i ) {
193
192
Outer o = new Outer ();
194
193
Common .blackhole (o );
@@ -197,42 +196,37 @@ static void testAllocateThenAtomic(Inner i) {
197
196
198
197
@ Test
199
198
@ IR (counts = { IRNode .Z_LOAD_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
200
- // TODO: 8353182
201
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
199
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
202
200
static void testLoadThenAtomic (Outer o , Inner i ) {
203
201
Common .blackhole (o .field1 );
204
202
Common .field1VarHandle .getAndSet (o , i );
205
203
}
206
204
207
205
@ Test
208
- // TODO: 8353182
209
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "2" }, phase = CompilePhase.FINAL_CODE)
206
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "2" }, phase = CompilePhase .FINAL_CODE )
210
207
static void testAtomicThenAtomicAnotherField (Outer o , Inner i ) {
211
208
Common .field1VarHandle .getAndSet (o , i );
212
209
Common .field2VarHandle .getAndSet (o , i );
213
210
}
214
211
215
212
@ Test
216
- // TODO: 8353182
217
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
213
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
218
214
static void testAllocateArrayThenAtomicAtKnownIndex (Outer o ) {
219
215
Outer [] a = new Outer [42 ];
220
216
Common .blackhole (a );
221
217
Common .outerArrayVarHandle .getAndSet (a , 2 , o );
222
218
}
223
219
224
220
@ Test
225
- // TODO: 8353182
226
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
221
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
227
222
static void testAllocateArrayThenAtomicAtUnknownIndex (Outer o , int index ) {
228
223
Outer [] a = new Outer [42 ];
229
224
Common .blackhole (a );
230
225
Common .outerArrayVarHandle .getAndSet (a , index , o );
231
226
}
232
227
233
228
@ Test
234
- // TODO: 8353182
235
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "2" }, phase = CompilePhase.FINAL_CODE)
229
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "2" }, phase = CompilePhase .FINAL_CODE )
236
230
static void testArrayAtomicThenAtomicAtUnknownIndices (Outer [] a , Outer o , int index1 , int index2 ) {
237
231
Common .outerArrayVarHandle .getAndSet (a , index1 , o );
238
232
Common .outerArrayVarHandle .getAndSet (a , index2 , o );
@@ -393,44 +387,39 @@ void runControlFlowTests() {
393
387
394
388
@ Test
395
389
@ IR (counts = { IRNode .Z_STORE_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
396
- // TODO: 8353182
397
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.ELIDED, "1" }, phase = CompilePhase.FINAL_CODE)
390
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .ELIDED , "1" }, phase = CompilePhase .FINAL_CODE )
398
391
static void testStoreThenAtomic (Outer o , Inner i ) {
399
392
o .field1 = i ;
400
393
Common .field1VarHandle .getAndSet (o , i );
401
394
}
402
395
403
396
@ Test
404
- // TODO: 8353182
405
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
397
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
406
398
@ IR (counts = { IRNode .Z_LOAD_P_WITH_BARRIER_FLAG , Common .ELIDED , "1" }, phase = CompilePhase .FINAL_CODE )
407
399
static void testAtomicThenLoad (Outer o , Inner i ) {
408
400
Common .field1VarHandle .getAndSet (o , i );
409
401
Common .blackhole (o .field1 );
410
402
}
411
403
412
404
@ Test
413
- // TODO: 8353182
414
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
405
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
415
406
@ IR (counts = { IRNode .Z_STORE_P_WITH_BARRIER_FLAG , Common .ELIDED , "1" }, phase = CompilePhase .FINAL_CODE )
416
407
static void testAtomicThenStore (Outer o , Inner i ) {
417
408
Common .field1VarHandle .getAndSet (o , i );
418
409
o .field1 = i ;
419
410
}
420
411
421
412
@ Test
422
- // TODO: 8353182
423
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
424
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.ELIDED, "1" }, phase = CompilePhase.FINAL_CODE)
413
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
414
+ //@IR(counts = { IRNode.Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG, Common.ELIDED, "1" }, phase = CompilePhase.FINAL_CODE)
425
415
static void testAtomicThenAtomic (Outer o , Inner i ) {
426
416
Common .field1VarHandle .getAndSet (o , i );
427
417
Common .field1VarHandle .getAndSet (o , i );
428
418
}
429
419
430
420
@ Test
431
- // TODO: 8353182
432
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.REMAINING, "1" }, phase = CompilePhase.FINAL_CODE)
433
- //@IR(counts = { IRNode.Z_GET_AND_SET_P_WITH_BARRIER_FLAG, Common.ELIDED, "1" }, phase = CompilePhase.FINAL_CODE)
421
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .REMAINING , "1" }, phase = CompilePhase .FINAL_CODE )
422
+ @ IR (counts = { IRNode .Z_COMPARE_AND_SWAP_P_WITH_BARRIER_FLAG , Common .ELIDED , "1" }, phase = CompilePhase .FINAL_CODE )
434
423
static void testArrayAtomicThenAtomic (Outer [] a , Outer o ) {
435
424
Common .outerArrayVarHandle .getAndSet (a , 0 , o );
436
425
Common .outerArrayVarHandle .getAndSet (a , 0 , o );
0 commit comments