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
70 lines
2.7 KiB
LLVM
70 lines
2.7 KiB
LLVM
; RUN: llc < %s | FileCheck %s
|
|
|
|
target triple = "aarch64"
|
|
|
|
|
|
define void @dont_rematerialize_cntd(i32 %N) #0 {
|
|
; CHECK-LABEL: dont_rematerialize_cntd:
|
|
; CHECK: cntd
|
|
; CHECK: smstop sm
|
|
; CHECK-NOT: cntd
|
|
; CHECK: bl foo
|
|
; CHECK: smstart sm
|
|
entry:
|
|
%cmp2 = icmp sgt i32 %N, 0
|
|
br i1 %cmp2, label %for.body, label %for.cond.cleanup
|
|
|
|
for.body: ; preds = %entry, %for.body
|
|
%index.03 = phi i32 [ %inc, %for.body ], [ 0, %entry ]
|
|
call void asm sideeffect "", "~{x19},~{x20},~{x21},~{x22},~{x23},~{x24},~{x25},~{x26},~{x27}"() nounwind
|
|
%.tr = call i32 @llvm.vscale.i32()
|
|
%conv = shl nuw nsw i32 %.tr, 4
|
|
call void @foo(i32 %conv)
|
|
%inc = add nuw nsw i32 %index.03, 1
|
|
%exitcond.not = icmp eq i32 %inc, %N
|
|
br i1 %exitcond.not, label %for.cond.cleanup, label %for.body
|
|
|
|
for.cond.cleanup: ; preds = %for.body, %entry
|
|
ret void
|
|
}
|
|
|
|
; This test doesn't strictly make sense, because it passes a scalable predicate
|
|
; to a function, which makes little sense if the VL is not the same in/out of
|
|
; streaming-SVE mode. If the VL is known to be the same, then we could just as
|
|
; well rematerialize the `ptrue` inside the call sequence. However, the purpose
|
|
; of this test is more to ensure that the logic works, which may also trigger
|
|
; when the value is not being passed as argument (e.g. when it is hoisted from
|
|
; a loop and placed inside the call sequence).
|
|
;
|
|
; FIXME: This test also exposes another bug, where the 'mul vl' addressing mode
|
|
; is used before/after the smstop. This will be fixed in a future patch.
|
|
define void @dont_rematerialize_ptrue(i32 %N) #0 {
|
|
; CHECK-LABEL: dont_rematerialize_ptrue:
|
|
; CHECK: ptrue [[PTRUE:p[0-9]+]].b
|
|
; CHECK: str [[PTRUE]], [[[SPILL_ADDR:.*]]]
|
|
; CHECK: smstop sm
|
|
; CHECK: ldr p0, [[[SPILL_ADDR]]]
|
|
; CHECK-NOT: ptrue
|
|
; CHECK: bl bar
|
|
; CHECK: smstart sm
|
|
entry:
|
|
%cmp2 = icmp sgt i32 %N, 0
|
|
br i1 %cmp2, label %for.body, label %for.cond.cleanup
|
|
|
|
for.body: ; preds = %entry, %for.body
|
|
%index.03 = phi i32 [ %inc, %for.body ], [ 0, %entry ]
|
|
call void asm sideeffect "", "~{x19},~{x20},~{x21},~{x22},~{x23},~{x24},~{x25},~{x26},~{x27}"() nounwind
|
|
call void @bar(<vscale x 16 x i1> splat(i1 true))
|
|
%inc = add nuw nsw i32 %index.03, 1
|
|
%exitcond.not = icmp eq i32 %inc, %N
|
|
br i1 %exitcond.not, label %for.cond.cleanup, label %for.body
|
|
|
|
for.cond.cleanup: ; preds = %for.body, %entry
|
|
ret void
|
|
}
|
|
declare void @foo(i32)
|
|
declare void @bar(<vscale x 16 x i1>)
|
|
declare i32 @llvm.vscale.i32()
|
|
|
|
attributes #0 = { "aarch64_pstate_sm_enabled" "frame-pointer"="non-leaf" "target-features"="+sme,+sve" }
|