1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
2 ; RUN: llc -mtriple=riscv64 -mattr=+reserve-x24 < %s | FileCheck %s
4 define noundef signext i32 @foo() {
7 ; CHECK-NEXT: li s8, 321
10 tail call void @llvm.write_register.i64(metadata !0, i64 321)
14 declare void @llvm.write_register.i64(metadata, i64)
16 define noundef signext i32 @bar() nounwind {
19 ; CHECK-NEXT: addi sp, sp, -16
20 ; CHECK-NEXT: sd s9, 8(sp) # 8-byte Folded Spill
23 ; CHECK-NEXT: li s8, 321
24 ; CHECK-NEXT: li a0, 0
25 ; CHECK-NEXT: ld s9, 8(sp) # 8-byte Folded Reload
26 ; CHECK-NEXT: addi sp, sp, 16
28 tail call void asm sideeffect "", "~{x25}"() #3
29 tail call void @llvm.write_register.i64(metadata !0, i64 321)
33 !llvm.named.register.x24 = !{!0}