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

84 lines
2.3 KiB
LLVM

; RUN: llc -verify-machineinstrs -O2 -mcpu=pwr8 -mtriple=powerpc64le-unknown-unknown < %s | FileCheck %s
; Function Attrs: norecurse nounwind
define void @test1(ptr noalias nocapture %a, ptr noalias nocapture readonly %b, ptr nocapture readnone %c, i32 signext %n) #0 {
; CHECK-LABEL: test1
entry:
%idxprom = sext i32 %n to i64
%arrayidx = getelementptr inbounds i32, ptr %b, i64 %idxprom
%0 = load i32, ptr %arrayidx, align 4, !tbaa !1
%conv = sitofp i32 %0 to float
%mul = fmul float %conv, 0x4002916880000000
%arrayidx2 = getelementptr inbounds float, ptr %a, i64 %idxprom
store float %mul, ptr %arrayidx2, align 4, !tbaa !5
ret void
; CHECK-NOT: mtvsrwa
; CHECK-NOT: mtfprwa
; CHECK: lfiwax [[REG:[0-9]+]], {{.*}}
; CHECK-NOT: mtvsrwa
; CHECK-NOT: mtfprwa
; CHECK: xscvsxdsp {{.*}}, [[REG]]
; CHECK-NOT: mtvsrwa
; CHECK-NOT: mtfprwa
; CHECK: blr
}
; Function Attrs: norecurse nounwind readonly
define float @test2(ptr nocapture readonly %b) #0 {
; CHECK-LABEL: test2
entry:
%0 = load i32, ptr %b, align 4, !tbaa !1
%conv = sitofp i32 %0 to float
%mul = fmul float %conv, 0x40030A3D80000000
ret float %mul
; CHECK-NOT: mtvsrwa
; CHECK-NOT: mtfprwa
; CHECK: lfiwax [[REG:[0-9]+]], {{.*}}
; CHECK-NOT: mtvsrwa
; CHECK-NOT: mtfprwa
; CHECK: xscvsxdsp {{.*}}, [[REG]]
; CHECK-NOT: mtvsrwa
; CHECK-NOT: mtfprwa
; CHECK: blr
}
; Function Attrs: norecurse nounwind
define void @test3(ptr noalias nocapture %a, ptr noalias nocapture readonly %b, ptr noalias nocapture %c, i32 signext %n) #0 {
; CHECK-LABEL: test3
entry:
%idxprom = sext i32 %n to i64
%arrayidx = getelementptr inbounds i32, ptr %b, i64 %idxprom
%0 = load i32, ptr %arrayidx, align 4, !tbaa !1
%conv = sitofp i32 %0 to float
%mul = fmul float %conv, 0x4002916880000000
%arrayidx2 = getelementptr inbounds float, ptr %a, i64 %idxprom
store float %mul, ptr %arrayidx2, align 4, !tbaa !5
%arrayidx6 = getelementptr inbounds i32, ptr %c, i64 %idxprom
%1 = load i32, ptr %arrayidx6, align 4, !tbaa !1
%add = add nsw i32 %1, %0
store i32 %add, ptr %arrayidx6, align 4, !tbaa !1
ret void
; CHECK: mtfprwa
; CHECK: blr
}
!0 = !{!"clang version 3.9.0"}
!1 = !{!2, !2, i64 0}
!2 = !{!"int", !3, i64 0}
!3 = !{!"omnipotent char", !4, i64 0}
!4 = !{!"Simple C++ TBAA"}
!5 = !{!6, !6, i64 0}
!6 = !{!"float", !3, i64 0}