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
65 lines
2.3 KiB
LLVM
65 lines
2.3 KiB
LLVM
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 4
|
|
; PR32952: Don't erroneously consider congruent two phi nodes which
|
|
; have the same arguments but different incoming edges.
|
|
; RUN: opt -passes=newgvn -S %s | FileCheck %s
|
|
|
|
@a = common global i16 0, align 2
|
|
@.str = private unnamed_addr constant [4 x i8] c"%d\0A\00", align 1
|
|
|
|
define i32 @tinkywinky() {
|
|
; CHECK-LABEL: define i32 @tinkywinky() {
|
|
; CHECK-NEXT: entry:
|
|
; CHECK-NEXT: [[TMP0:%.*]] = load i16, ptr @a, align 2
|
|
; CHECK-NEXT: [[CONV:%.*]] = sext i16 [[TMP0]] to i32
|
|
; CHECK-NEXT: [[NEG:%.*]] = xor i32 [[CONV]], -1
|
|
; CHECK-NEXT: [[CONV1:%.*]] = trunc i32 [[NEG]] to i16
|
|
; CHECK-NEXT: [[CONV3:%.*]] = zext i16 [[CONV1]] to i32
|
|
; CHECK-NEXT: [[CMP:%.*]] = icmp slt i32 [[CONV]], [[CONV3]]
|
|
; CHECK-NEXT: br i1 [[CMP]], label [[TINKY:%.*]], label [[WINKY:%.*]]
|
|
; CHECK: tinky:
|
|
; CHECK-NEXT: store i16 2, ptr @a, align 2
|
|
; CHECK-NEXT: br label [[PATATINO:%.*]]
|
|
; CHECK: winky:
|
|
; CHECK-NEXT: br label [[PATATINO]]
|
|
; CHECK: patatino:
|
|
; CHECK-NEXT: [[MEH:%.*]] = phi i16 [ [[TMP0]], [[WINKY]] ], [ [[CONV1]], [[TINKY]] ]
|
|
; CHECK-NEXT: [[BANANA:%.*]] = phi i16 [ [[TMP0]], [[TINKY]] ], [ [[CONV1]], [[WINKY]] ]
|
|
; CHECK-NEXT: br label [[END:%.*]]
|
|
; CHECK: end:
|
|
; CHECK-NEXT: [[PROMOTED:%.*]] = zext i16 [[BANANA]] to i32
|
|
; CHECK-NEXT: [[OTHER:%.*]] = zext i16 [[MEH]] to i32
|
|
; CHECK-NEXT: [[FIRST:%.*]] = tail call i32 (ptr, ...) @printf(ptr @.str, i32 [[PROMOTED]])
|
|
; CHECK-NEXT: [[SECOND:%.*]] = tail call i32 (ptr, ...) @printf(ptr @.str, i32 [[OTHER]])
|
|
; CHECK-NEXT: ret i32 0
|
|
;
|
|
entry:
|
|
%0 = load i16, ptr @a, align 2
|
|
%conv = sext i16 %0 to i32
|
|
%neg = xor i32 %conv, -1
|
|
%conv1 = trunc i32 %neg to i16
|
|
%conv3 = zext i16 %conv1 to i32
|
|
%cmp = icmp slt i32 %conv, %conv3
|
|
br i1 %cmp, label %tinky, label %winky
|
|
|
|
tinky:
|
|
store i16 2, ptr @a, align 2
|
|
br label %patatino
|
|
|
|
winky:
|
|
br label %patatino
|
|
|
|
patatino:
|
|
%meh = phi i16 [ %0, %winky ], [ %conv1, %tinky ]
|
|
%banana = phi i16 [ %0, %tinky ], [ %conv1, %winky ]
|
|
br label %end
|
|
|
|
end:
|
|
%promoted = zext i16 %banana to i32
|
|
%other = zext i16 %meh to i32
|
|
%first = tail call i32 (ptr, ...) @printf(ptr @.str, i32 %promoted)
|
|
%second = tail call i32 (ptr, ...) @printf(ptr @.str, i32 %other)
|
|
ret i32 0
|
|
}
|
|
|
|
declare i32 @printf(ptr, ...)
|