Files
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

78 lines
2.5 KiB
LLVM

; RUN: llc -verify-machineinstrs -enable-machine-outliner %s -o - | FileCheck %s
; RUN: llc -verify-machineinstrs -enable-machine-outliner -aarch64-redzone %s -o - | FileCheck %s -check-prefix=REDZONE
; Ensure that the MachineOutliner does not fire on functions which use a
; redzone. We don't care about what's actually outlined here. We just want to
; force behaviour in the outliner to make sure that it never acts on anything
; that might have a redzone.
target triple = "arm64----"
@x = common global i32 0, align 4
declare void @baz() #0
; In AArch64FrameLowering, there are a couple special early exit cases where we
; *know* we don't use a redzone. The GHC calling convention is one of these
; cases. Make sure that we know we don't have a redzone even in these cases.
define cc 10 void @bar() #0 {
; CHECK-LABEL: bar
; CHECK: bl OUTLINED_FUNCTION
; REDZONE-LABEL: bar
; REDZONE: bl OUTLINED_FUNCTION
%1 = load i32, ptr @x, align 4
%2 = add nsw i32 %1, 1
store i32 %2, ptr @x, align 4
call void @baz()
%3 = load i32, ptr @x, align 4
%4 = add nsw i32 %3, 1
store i32 %4, ptr @x, align 4
call void @baz()
%5 = load i32, ptr @x, align 4
%6 = add nsw i32 %5, 1
store i32 %6, ptr @x, align 4
ret void
}
; foo() should have a redzone when compiled with -aarch64-redzone, and no
; redzone otherwise.
define void @foo() #0 {
; CHECK-LABEL: foo
; CHECK: bl OUTLINED_FUNCTION
; REDZONE-LABEL: foo
; REDZONE-NOT: bl OUTLINED_FUNCTION
%1 = alloca i32, align 4
%2 = alloca i32, align 4
%3 = alloca i32, align 4
%4 = alloca i32, align 4
store i32 0, ptr %1, align 4
store i32 0, ptr %2, align 4
store i32 0, ptr %3, align 4
store i32 0, ptr %4, align 4
%5 = load i32, ptr %1, align 4
%6 = add nsw i32 %5, 1
store i32 %6, ptr %1, align 4
%7 = load i32, ptr %3, align 4
%8 = add nsw i32 %7, 1
store i32 %8, ptr %3, align 4
%9 = load i32, ptr %4, align 4
%10 = add nsw i32 %9, 1
store i32 %10, ptr %4, align 4
%11 = load i32, ptr %2, align 4
%12 = add nsw i32 %11, 1
store i32 %12, ptr %2, align 4
%13 = load i32, ptr %1, align 4
%14 = add nsw i32 %13, 1
store i32 %14, ptr %1, align 4
%15 = load i32, ptr %3, align 4
%16 = add nsw i32 %15, 1
store i32 %16, ptr %3, align 4
%17 = load i32, ptr %4, align 4
%18 = add nsw i32 %17, 1
store i32 %18, ptr %4, align 4
%19 = load i32, ptr %2, align 4
%20 = add nsw i32 %19, -1
store i32 %20, ptr %2, align 4
ret void
}
attributes #0 = { noinline nounwind optnone }