Skip to content

Commit 67b3b65

Browse files
Update test
Signed-off-by: Mikhail R. Gadelha <[email protected]>
1 parent 99e11ae commit 67b3b65

File tree

1 file changed

+36
-42
lines changed

1 file changed

+36
-42
lines changed

llvm/test/CodeGen/RISCV/stores-of-loads-merging.ll

Lines changed: 36 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -363,28 +363,26 @@ define void @two_half(ptr %p, ptr %q) {
363363
; ZVFH-NEXT: .cfi_def_cfa_offset 32
364364
; ZVFH-NEXT: sd ra, 24(sp) # 8-byte Folded Spill
365365
; ZVFH-NEXT: sd s0, 16(sp) # 8-byte Folded Spill
366+
; ZVFH-NEXT: fsd fs0, 8(sp) # 8-byte Folded Spill
367+
; ZVFH-NEXT: fsd fs1, 0(sp) # 8-byte Folded Spill
366368
; ZVFH-NEXT: .cfi_offset ra, -8
367369
; ZVFH-NEXT: .cfi_offset s0, -16
368-
; ZVFH-NEXT: csrr a2, vlenb
369-
; ZVFH-NEXT: sub sp, sp, a2
370-
; ZVFH-NEXT: .cfi_escape 0x0f, 0x0d, 0x72, 0x00, 0x11, 0x20, 0x22, 0x11, 0x01, 0x92, 0xa2, 0x38, 0x00, 0x1e, 0x22 # sp + 32 + 1 * vlenb
371-
; ZVFH-NEXT: vsetivli zero, 2, e16, mf4, ta, ma
372-
; ZVFH-NEXT: vle16.v v8, (a0)
373-
; ZVFH-NEXT: addi a0, sp, 16
374-
; ZVFH-NEXT: vs1r.v v8, (a0) # Unknown-size Folded Spill
370+
; ZVFH-NEXT: .cfi_offset fs0, -24
371+
; ZVFH-NEXT: .cfi_offset fs1, -32
372+
; ZVFH-NEXT: flh fs0, 0(a0)
373+
; ZVFH-NEXT: flh fs1, 2(a0)
375374
; ZVFH-NEXT: mv s0, a1
376375
; ZVFH-NEXT: call g
377-
; ZVFH-NEXT: addi a0, sp, 16
378-
; ZVFH-NEXT: vl1r.v v8, (a0) # Unknown-size Folded Reload
379-
; ZVFH-NEXT: vsetivli zero, 2, e16, mf4, ta, ma
380-
; ZVFH-NEXT: vse16.v v8, (s0)
381-
; ZVFH-NEXT: csrr a0, vlenb
382-
; ZVFH-NEXT: add sp, sp, a0
383-
; ZVFH-NEXT: .cfi_def_cfa sp, 32
376+
; ZVFH-NEXT: fsh fs0, 0(s0)
377+
; ZVFH-NEXT: fsh fs1, 2(s0)
384378
; ZVFH-NEXT: ld ra, 24(sp) # 8-byte Folded Reload
385379
; ZVFH-NEXT: ld s0, 16(sp) # 8-byte Folded Reload
380+
; ZVFH-NEXT: fld fs0, 8(sp) # 8-byte Folded Reload
381+
; ZVFH-NEXT: fld fs1, 0(sp) # 8-byte Folded Reload
386382
; ZVFH-NEXT: .cfi_restore ra
387383
; ZVFH-NEXT: .cfi_restore s0
384+
; ZVFH-NEXT: .cfi_restore fs0
385+
; ZVFH-NEXT: .cfi_restore fs1
388386
; ZVFH-NEXT: addi sp, sp, 32
389387
; ZVFH-NEXT: .cfi_def_cfa_offset 0
390388
; ZVFH-NEXT: ret
@@ -409,28 +407,26 @@ define void @two_float(ptr %p, ptr %q) {
409407
; CHECK-NEXT: .cfi_def_cfa_offset 32
410408
; CHECK-NEXT: sd ra, 24(sp) # 8-byte Folded Spill
411409
; CHECK-NEXT: sd s0, 16(sp) # 8-byte Folded Spill
410+
; CHECK-NEXT: fsd fs0, 8(sp) # 8-byte Folded Spill
411+
; CHECK-NEXT: fsd fs1, 0(sp) # 8-byte Folded Spill
412412
; CHECK-NEXT: .cfi_offset ra, -8
413413
; CHECK-NEXT: .cfi_offset s0, -16
414-
; CHECK-NEXT: csrr a2, vlenb
415-
; CHECK-NEXT: sub sp, sp, a2
416-
; CHECK-NEXT: .cfi_escape 0x0f, 0x0d, 0x72, 0x00, 0x11, 0x20, 0x22, 0x11, 0x01, 0x92, 0xa2, 0x38, 0x00, 0x1e, 0x22 # sp + 32 + 1 * vlenb
417-
; CHECK-NEXT: vsetivli zero, 2, e32, mf2, ta, ma
418-
; CHECK-NEXT: vle32.v v8, (a0)
419-
; CHECK-NEXT: addi a0, sp, 16
420-
; CHECK-NEXT: vs1r.v v8, (a0) # Unknown-size Folded Spill
414+
; CHECK-NEXT: .cfi_offset fs0, -24
415+
; CHECK-NEXT: .cfi_offset fs1, -32
416+
; CHECK-NEXT: flw fs0, 0(a0)
417+
; CHECK-NEXT: flw fs1, 4(a0)
421418
; CHECK-NEXT: mv s0, a1
422419
; CHECK-NEXT: call g
423-
; CHECK-NEXT: addi a0, sp, 16
424-
; CHECK-NEXT: vl1r.v v8, (a0) # Unknown-size Folded Reload
425-
; CHECK-NEXT: vsetivli zero, 2, e32, mf2, ta, ma
426-
; CHECK-NEXT: vse32.v v8, (s0)
427-
; CHECK-NEXT: csrr a0, vlenb
428-
; CHECK-NEXT: add sp, sp, a0
429-
; CHECK-NEXT: .cfi_def_cfa sp, 32
420+
; CHECK-NEXT: fsw fs0, 0(s0)
421+
; CHECK-NEXT: fsw fs1, 4(s0)
430422
; CHECK-NEXT: ld ra, 24(sp) # 8-byte Folded Reload
431423
; CHECK-NEXT: ld s0, 16(sp) # 8-byte Folded Reload
424+
; CHECK-NEXT: fld fs0, 8(sp) # 8-byte Folded Reload
425+
; CHECK-NEXT: fld fs1, 0(sp) # 8-byte Folded Reload
432426
; CHECK-NEXT: .cfi_restore ra
433427
; CHECK-NEXT: .cfi_restore s0
428+
; CHECK-NEXT: .cfi_restore fs0
429+
; CHECK-NEXT: .cfi_restore fs1
434430
; CHECK-NEXT: addi sp, sp, 32
435431
; CHECK-NEXT: .cfi_def_cfa_offset 0
436432
; CHECK-NEXT: ret
@@ -453,28 +449,26 @@ define void @two_double(ptr %p, ptr %q) {
453449
; CHECK-NEXT: .cfi_def_cfa_offset 32
454450
; CHECK-NEXT: sd ra, 24(sp) # 8-byte Folded Spill
455451
; CHECK-NEXT: sd s0, 16(sp) # 8-byte Folded Spill
452+
; CHECK-NEXT: fsd fs0, 8(sp) # 8-byte Folded Spill
453+
; CHECK-NEXT: fsd fs1, 0(sp) # 8-byte Folded Spill
456454
; CHECK-NEXT: .cfi_offset ra, -8
457455
; CHECK-NEXT: .cfi_offset s0, -16
458-
; CHECK-NEXT: csrr a2, vlenb
459-
; CHECK-NEXT: sub sp, sp, a2
460-
; CHECK-NEXT: .cfi_escape 0x0f, 0x0d, 0x72, 0x00, 0x11, 0x20, 0x22, 0x11, 0x01, 0x92, 0xa2, 0x38, 0x00, 0x1e, 0x22 # sp + 32 + 1 * vlenb
461-
; CHECK-NEXT: vsetivli zero, 2, e64, m1, ta, ma
462-
; CHECK-NEXT: vle64.v v8, (a0)
463-
; CHECK-NEXT: addi a0, sp, 16
464-
; CHECK-NEXT: vs1r.v v8, (a0) # Unknown-size Folded Spill
456+
; CHECK-NEXT: .cfi_offset fs0, -24
457+
; CHECK-NEXT: .cfi_offset fs1, -32
458+
; CHECK-NEXT: fld fs0, 0(a0)
459+
; CHECK-NEXT: fld fs1, 8(a0)
465460
; CHECK-NEXT: mv s0, a1
466461
; CHECK-NEXT: call g
467-
; CHECK-NEXT: addi a0, sp, 16
468-
; CHECK-NEXT: vl1r.v v8, (a0) # Unknown-size Folded Reload
469-
; CHECK-NEXT: vsetivli zero, 2, e64, m1, ta, ma
470-
; CHECK-NEXT: vse64.v v8, (s0)
471-
; CHECK-NEXT: csrr a0, vlenb
472-
; CHECK-NEXT: add sp, sp, a0
473-
; CHECK-NEXT: .cfi_def_cfa sp, 32
462+
; CHECK-NEXT: fsd fs0, 0(s0)
463+
; CHECK-NEXT: fsd fs1, 8(s0)
474464
; CHECK-NEXT: ld ra, 24(sp) # 8-byte Folded Reload
475465
; CHECK-NEXT: ld s0, 16(sp) # 8-byte Folded Reload
466+
; CHECK-NEXT: fld fs0, 8(sp) # 8-byte Folded Reload
467+
; CHECK-NEXT: fld fs1, 0(sp) # 8-byte Folded Reload
476468
; CHECK-NEXT: .cfi_restore ra
477469
; CHECK-NEXT: .cfi_restore s0
470+
; CHECK-NEXT: .cfi_restore fs0
471+
; CHECK-NEXT: .cfi_restore fs1
478472
; CHECK-NEXT: addi sp, sp, 32
479473
; CHECK-NEXT: .cfi_def_cfa_offset 0
480474
; CHECK-NEXT: ret

0 commit comments

Comments
 (0)