Files
TheRock/compiler/amd-llvm/llvm/test/CodeGen/AArch64/arm64ec-reservedregs.ll
T
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

98 lines
4.5 KiB
LLVM

; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
; RUN: llc -mtriple=arm64ec-pc-windows-msvc -arm64ec-generate-thunks=false < %s | FileCheck %s
; Make sure we're reserving all the registers that are supposed to be
; reserved. Integer regs x13, x15, x23, x24, x28. Float regs v16-v31.
; We confirm this by ensuring that we spill if and only if none of the
; unreserved registers are available.
define i32 @no_int_regs(i32 %x) nounwind {
; CHECK-LABEL: no_int_regs:
; CHECK: // %bb.0: // %entry
; CHECK-NEXT: stp x19, x20, [sp, #-80]! // 16-byte Folded Spill
; CHECK-NEXT: stp x21, x22, [sp, #16] // 16-byte Folded Spill
; CHECK-NEXT: stp x25, x26, [sp, #32] // 16-byte Folded Spill
; CHECK-NEXT: str x27, [sp, #48] // 8-byte Spill
; CHECK-NEXT: stp x29, x30, [sp, #56] // 16-byte Folded Spill
; CHECK-NEXT: str w0, [sp, #76] // 4-byte Spill
; CHECK-NEXT: //APP
; CHECK-NEXT: //NO_APP
; CHECK-NEXT: ldp x29, x30, [sp, #56] // 16-byte Folded Reload
; CHECK-NEXT: ldr w0, [sp, #76] // 4-byte Reload
; CHECK-NEXT: ldp x25, x26, [sp, #32] // 16-byte Folded Reload
; CHECK-NEXT: ldr x27, [sp, #48] // 8-byte Reload
; CHECK-NEXT: ldp x21, x22, [sp, #16] // 16-byte Folded Reload
; CHECK-NEXT: ldp x19, x20, [sp], #80 // 16-byte Folded Reload
; CHECK-NEXT: ret
entry:
tail call void asm sideeffect "", "~{x0},~{x1},~{x2},~{x3},~{x4},~{x5},~{x6},~{x7},~{x8},~{x9},~{x10},~{x11},~{x12},~{x15},~{x16},~{x17},~{x19},~{x20},~{x21},~{x22},~{x25},~{x26},~{x27},~{fp},~{lr}"()
ret i32 %x
}
define i32 @one_int_reg(i32 %x) nounwind {
; CHECK-LABEL: one_int_reg:
; CHECK: // %bb.0: // %entry
; CHECK-NEXT: stp x19, x20, [sp, #-80]! // 16-byte Folded Spill
; CHECK-NEXT: stp x21, x22, [sp, #16] // 16-byte Folded Spill
; CHECK-NEXT: stp x25, x26, [sp, #32] // 16-byte Folded Spill
; CHECK-NEXT: str x27, [sp, #48] // 8-byte Spill
; CHECK-NEXT: stp x29, x30, [sp, #56] // 16-byte Folded Spill
; CHECK-NEXT: mov w30, w0
; CHECK-NEXT: //APP
; CHECK-NEXT: //NO_APP
; CHECK-NEXT: mov w0, w30
; CHECK-NEXT: ldp x29, x30, [sp, #56] // 16-byte Folded Reload
; CHECK-NEXT: ldp x25, x26, [sp, #32] // 16-byte Folded Reload
; CHECK-NEXT: ldr x27, [sp, #48] // 8-byte Reload
; CHECK-NEXT: ldp x21, x22, [sp, #16] // 16-byte Folded Reload
; CHECK-NEXT: ldp x19, x20, [sp], #80 // 16-byte Folded Reload
; CHECK-NEXT: ret
entry:
tail call void asm sideeffect "", "~{x0},~{x1},~{x2},~{x3},~{x4},~{x5},~{x6},~{x7},~{x8},~{x9},~{x10},~{x11},~{x12},~{x15},~{x16},~{x17},~{x19},~{x20},~{x21},~{x22},~{x25},~{x26},~{x27},~{fp}"()
ret i32 %x
}
define float @no_float_regs(float %x) nounwind {
; CHECK-LABEL: no_float_regs:
; CHECK: // %bb.0: // %entry
; CHECK-NEXT: sub sp, sp, #80
; CHECK-NEXT: stp d8, d9, [sp, #16] // 16-byte Folded Spill
; CHECK-NEXT: stp d10, d11, [sp, #32] // 16-byte Folded Spill
; CHECK-NEXT: stp d12, d13, [sp, #48] // 16-byte Folded Spill
; CHECK-NEXT: stp d14, d15, [sp, #64] // 16-byte Folded Spill
; CHECK-NEXT: str s0, [sp, #12] // 4-byte Spill
; CHECK-NEXT: //APP
; CHECK-NEXT: //NO_APP
; CHECK-NEXT: ldp d14, d15, [sp, #64] // 16-byte Folded Reload
; CHECK-NEXT: ldr s0, [sp, #12] // 4-byte Reload
; CHECK-NEXT: ldp d12, d13, [sp, #48] // 16-byte Folded Reload
; CHECK-NEXT: ldp d10, d11, [sp, #32] // 16-byte Folded Reload
; CHECK-NEXT: ldp d8, d9, [sp, #16] // 16-byte Folded Reload
; CHECK-NEXT: add sp, sp, #80
; CHECK-NEXT: ret
entry:
tail call void asm sideeffect "", "~{v0},~{v1},~{v2},~{v3},~{v4},~{v5},~{v6},~{v7},~{v8},~{v9},~{v10},~{v11},~{v12},~{v13},~{v14},~{v15}"()
ret float %x
}
define float @one_float_reg(float %x) nounwind {
; CHECK-LABEL: one_float_reg:
; CHECK: // %bb.0: // %entry
; CHECK-NEXT: stp d8, d9, [sp, #-64]! // 16-byte Folded Spill
; CHECK-NEXT: stp d14, d15, [sp, #48] // 16-byte Folded Spill
; CHECK-NEXT: fmov s15, s0
; CHECK-NEXT: stp d10, d11, [sp, #16] // 16-byte Folded Spill
; CHECK-NEXT: stp d12, d13, [sp, #32] // 16-byte Folded Spill
; CHECK-NEXT: //APP
; CHECK-NEXT: //NO_APP
; CHECK-NEXT: ldp d12, d13, [sp, #32] // 16-byte Folded Reload
; CHECK-NEXT: fmov s0, s15
; CHECK-NEXT: ldp d14, d15, [sp, #48] // 16-byte Folded Reload
; CHECK-NEXT: ldp d10, d11, [sp, #16] // 16-byte Folded Reload
; CHECK-NEXT: ldp d8, d9, [sp], #64 // 16-byte Folded Reload
; CHECK-NEXT: ret
entry:
tail call void asm sideeffect "", "~{v0},~{v1},~{v2},~{v3},~{v4},~{v5},~{v6},~{v7},~{v8},~{v9},~{v10},~{v11},~{v12},~{v13},~{v14}"()
ret float %x
}