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
74 lines
2.6 KiB
LLVM
74 lines
2.6 KiB
LLVM
; RUN: opt < %s -mtriple=aarch64-linux-gnu -passes=simplifycfg -simplifycfg-require-and-preserve-domtree=1 -hoist-common-insts=true -S >%t
|
|
; RUN: FileCheck %s < %t
|
|
; ModuleID = 't.cc'
|
|
|
|
; Function Attrs: nounwind
|
|
define double @_Z3fooRdS_S_S_(ptr dereferenceable(8) %x, ptr dereferenceable(8) %y, ptr dereferenceable(8) %a) #0 {
|
|
entry:
|
|
%0 = load double, ptr %y, align 8
|
|
%cmp = fcmp oeq double %0, 0.000000e+00
|
|
%1 = load double, ptr %x, align 8
|
|
br i1 %cmp, label %if.then, label %if.else
|
|
|
|
; fadd (const, (fmul x, y))
|
|
if.then: ; preds = %entry
|
|
; CHECK-LABEL: if.then:
|
|
; CHECK: %3 = fmul fast double %1, %2
|
|
; CHECK-NEXT: %mul = fadd fast double 1.000000e+00, %3
|
|
%2 = load double, ptr %a, align 8
|
|
%3 = fmul fast double %1, %2
|
|
%mul = fadd fast double 1.000000e+00, %3
|
|
store double %mul, ptr %y, align 8
|
|
br label %if.end
|
|
|
|
; fsub ((fmul x, y), z)
|
|
if.else: ; preds = %entry
|
|
; CHECK-LABEL: if.else:
|
|
; CHECK: %mul1 = fmul fast double %1, %2
|
|
; CHECK-NEXT: %sub1 = fsub fast double %mul1, %0
|
|
%4 = load double, ptr %a, align 8
|
|
%mul1 = fmul fast double %1, %4
|
|
%sub1 = fsub fast double %mul1, %0
|
|
%gep1 = getelementptr double, ptr %y, i32 1
|
|
store double %sub1, ptr %gep1, align 8
|
|
br label %if.end
|
|
|
|
if.end: ; preds = %if.else, %if.then
|
|
%5 = load double, ptr %y, align 8
|
|
%cmp2 = fcmp oeq double %5, 2.000000e+00
|
|
%6 = load double, ptr %x, align 8
|
|
br i1 %cmp2, label %if.then2, label %if.else2
|
|
|
|
; fsub (x, (fmul y, z))
|
|
if.then2: ; preds = %entry
|
|
; CHECK-LABEL: if.then2:
|
|
; CHECK: %7 = fmul fast double %5, 3.000000e+00
|
|
; CHECK-NEXT: %mul2 = fsub fast double %6, %7
|
|
%7 = load double, ptr %a, align 8
|
|
%8 = fmul fast double %6, 3.0000000e+00
|
|
%mul2 = fsub fast double %7, %8
|
|
store double %mul2, ptr %y, align 8
|
|
br label %if.end2
|
|
|
|
; fsub (fneg((fmul x, y)), const)
|
|
if.else2: ; preds = %entry
|
|
; CHECK-LABEL: if.else2:
|
|
; CHECK: %mul3 = fmul fast double %5, 3.000000e+00
|
|
; CHECK-NEXT: %neg = fsub fast double 0.000000e+00, %mul3
|
|
; CHECK-NEXT: %sub2 = fsub fast double %neg, 3.000000e+00
|
|
%mul3 = fmul fast double %6, 3.0000000e+00
|
|
%neg = fsub fast double 0.0000000e+00, %mul3
|
|
%sub2 = fsub fast double %neg, 3.0000000e+00
|
|
store double %sub2, ptr %y, align 8
|
|
br label %if.end2
|
|
|
|
if.end2: ; preds = %if.else, %if.then
|
|
%9 = load double, ptr %x, align 8
|
|
%10 = load double, ptr %y, align 8
|
|
%add = fadd fast double %9, %10
|
|
%11 = load double, ptr %a, align 8
|
|
%add2 = fadd fast double %add, %11
|
|
ret double %add2
|
|
}
|
|
|