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
87 lines
2.1 KiB
LLVM
87 lines
2.1 KiB
LLVM
; RUN: llc -mtriple=i686-- < %s | FileCheck %s
|
|
; RUN: llc -mtriple=i686-- -O0 < %s | FileCheck %s
|
|
; RUN: llc -mtriple=i686-- -disable-tail-calls < %s | FileCheck %s
|
|
|
|
declare void @t1_callee(ptr)
|
|
define void @t1(ptr %a) {
|
|
; CHECK-LABEL: t1:
|
|
; CHECK: jmp {{_?}}t1_callee
|
|
musttail call void @t1_callee(ptr %a)
|
|
ret void
|
|
}
|
|
|
|
declare ptr @t2_callee()
|
|
define ptr @t2() {
|
|
; CHECK-LABEL: t2:
|
|
; CHECK: jmp {{_?}}t2_callee
|
|
%v = musttail call ptr @t2_callee()
|
|
ret ptr %v
|
|
}
|
|
|
|
; Complex frame layout: stack realignment with dynamic alloca.
|
|
define void @t3(i32 %n) alignstack(32) nounwind {
|
|
entry:
|
|
; CHECK: t3:
|
|
; CHECK: pushl %ebp
|
|
; CHECK: pushl %esi
|
|
; CHECK: andl $-32, %esp
|
|
; CHECK: movl %esp, %esi
|
|
; CHECK: popl %esi
|
|
; CHECK: popl %ebp
|
|
; CHECK-NEXT: jmp {{_?}}t3_callee
|
|
%a = alloca i8, i32 %n
|
|
call void @capture(ptr %a)
|
|
musttail call void @t3_callee(i32 %n) nounwind
|
|
ret void
|
|
}
|
|
|
|
declare void @capture(ptr)
|
|
declare void @t3_callee(i32)
|
|
|
|
; Test that we actually copy in and out stack arguments that aren't forwarded
|
|
; without modification.
|
|
define i32 @t4(ptr %fn, i32 %n, i32 %r) {
|
|
; CHECK-LABEL: t4:
|
|
; CHECK: incl %[[r:.*]]
|
|
; CHECK: decl %[[n:.*]]
|
|
; CHECK-DAG: movl %[[r]], {{[0-9]+}}(%esp)
|
|
; CHECK-DAG: movl %[[n]], {{[0-9]+}}(%esp)
|
|
; CHECK: jmpl *%{{.*}}
|
|
|
|
entry:
|
|
%r1 = add i32 %r, 1
|
|
%n1 = sub i32 %n, 1
|
|
%r2 = musttail call i32 %fn(ptr %fn, i32 %n1, i32 %r1)
|
|
ret i32 %r2
|
|
}
|
|
|
|
; Combine the complex stack frame with the parameter modification.
|
|
define i32 @t5(ptr %fn, i32 %n, i32 %r) alignstack(32) {
|
|
; CHECK-LABEL: t5:
|
|
; CHECK: pushl %ebp
|
|
; CHECK: movl %esp, %ebp
|
|
; CHECK: pushl %esi
|
|
; Align the stack.
|
|
; CHECK: andl $-32, %esp
|
|
; CHECK: movl %esp, %esi
|
|
; Modify the args.
|
|
; CHECK: incl %[[r:.*]]
|
|
; CHECK: decl %[[n:.*]]
|
|
; Store them through ebp, since that's the only stable arg pointer.
|
|
; CHECK-DAG: movl %[[r]], {{[0-9]+}}(%ebp)
|
|
; CHECK-DAG: movl %[[n]], {{[0-9]+}}(%ebp)
|
|
; Epilogue.
|
|
; CHECK: leal {{[-0-9]+}}(%ebp), %esp
|
|
; CHECK: popl %esi
|
|
; CHECK: popl %ebp
|
|
; CHECK: jmpl *%{{.*}}
|
|
|
|
entry:
|
|
%a = alloca i8, i32 %n
|
|
call void @capture(ptr %a)
|
|
%r1 = add i32 %r, 1
|
|
%n1 = sub i32 %n, 1
|
|
%r2 = musttail call i32 %fn(ptr %fn, i32 %n1, i32 %r1)
|
|
ret i32 %r2
|
|
}
|