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
88 lines
2.4 KiB
LLVM
88 lines
2.4 KiB
LLVM
; RUN: llc < %s -mtriple=i686-windows | FileCheck %s
|
|
; RUN: llc < %s -mtriple=x86_64-linux | FileCheck %s -check-prefix=LINUX64
|
|
|
|
declare void @param1(i32 %a)
|
|
declare i32 @param2_ret(i32 %a, i32 %b)
|
|
declare i64 @param2_ret64(i32 %a, i32 %b)
|
|
declare void @param2(i32 %a, i32 %b)
|
|
declare void @param3(i32 %a, i32 %b, i32 %c)
|
|
declare void @param8(i64, i64, i64, i64, i64, i64, i64, i64)
|
|
declare i32 @param8_ret(i64, i64, i64, i64, i64, i64, i64, i64)
|
|
|
|
|
|
define void @test() minsize nounwind {
|
|
; CHECK-LABEL: test:
|
|
; CHECK: calll _param1
|
|
; CHECK-NEXT: popl %eax
|
|
; CHECK: calll _param2
|
|
; CHECK-NEXT: popl %eax
|
|
; CHECK-NEXT: popl %ecx
|
|
; CHECK: calll _param2_ret
|
|
; CHECK-NEXT: popl %ecx
|
|
; CHECK-NEXT: popl %edx
|
|
; CHECK-NEXT: pushl %eax
|
|
; CHECK: calll _param3
|
|
; CHECK-NEXT: addl $12, %esp
|
|
; CHECK: calll _param2_ret64
|
|
; CHECK-NEXT: popl %ecx
|
|
; CHECK-NEXT: popl %ecx
|
|
call void @param1(i32 1)
|
|
call void @param2(i32 1, i32 2)
|
|
%ret = call i32 @param2_ret(i32 1, i32 2)
|
|
call void @param3(i32 1, i32 2, i32 %ret)
|
|
%ret64 = call i64 @param2_ret64(i32 1, i32 2)
|
|
ret void
|
|
}
|
|
|
|
define void @negative(i32 %k) {
|
|
; CHECK-LABEL: negative:
|
|
; CHECK: calll _param1
|
|
; CHECK-NEXT: addl $4, %esp
|
|
; CHECK: calll _param2
|
|
; CHECK-NEXT: addl $8, %esp
|
|
; CHECK: calll _param3
|
|
; CHECK-NEXT: movl %ebp, %esp
|
|
%v = alloca i32, i32 %k
|
|
call void @param1(i32 1)
|
|
call void @param2(i32 1, i32 2)
|
|
call void @param3(i32 1, i32 2, i32 3)
|
|
ret void
|
|
}
|
|
|
|
define void @spill(i32 inreg %a, i32 inreg %b, i32 inreg %c) minsize nounwind {
|
|
; CHECK-LABEL: spill:
|
|
; CHECK-DAG: movl %ecx,
|
|
; CHECK-DAG: movl %edx,
|
|
; CHECK: calll _param2_ret
|
|
; CHECK-NEXT: popl %ecx
|
|
; CHECK-NEXT: popl %edx
|
|
; CHECK-DAG: movl {{.*}}, %ecx
|
|
; CHECK-DAG: movl {{.*}}, %edx
|
|
; CHECK: calll _spill
|
|
%i = call i32 @param2_ret(i32 1, i32 2)
|
|
call void @spill(i32 inreg %a, i32 inreg %b, i32 inreg %c)
|
|
ret void
|
|
}
|
|
|
|
define void @test_linux64(i32 %size) minsize nounwind {
|
|
; LINUX64-LABEL: test_linux64:
|
|
; LINUX64: pushq %rbp
|
|
; LINUX64: callq param8
|
|
; LINUX64-NEXT: popq %rax
|
|
; LINUX64-NEXT: popq %rcx
|
|
|
|
%a = alloca i64, i32 %size, align 8
|
|
call void @param8(i64 1, i64 2, i64 3, i64 4, i64 5, i64 6, i64 7, i64 8)
|
|
ret void
|
|
}
|
|
|
|
define i32 @test_linux64_i32(i32 %size) minsize nounwind {
|
|
; LINUX64-LABEL: test_linux64_i32:
|
|
; LINUX64: callq param8_ret
|
|
; LINUX64-NOT: popq %rax
|
|
; LINUX64: retq
|
|
%a = alloca i64, i32 %size, align 8
|
|
%r = call i32 @param8_ret(i64 1, i64 2, i64 3, i64 4, i64 5, i64 6, i64 7, i64 8)
|
|
ret i32 %r
|
|
}
|