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
110 lines
3.9 KiB
LLVM
110 lines
3.9 KiB
LLVM
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
|
|
; RUN: opt -S -passes=simplifycfg -simplifycfg-require-and-preserve-domtree=1 < %s | FileCheck %s
|
|
|
|
declare i8 @next_char();
|
|
|
|
define void @test_no_msan() {
|
|
; CHECK-LABEL: @test_no_msan(
|
|
; CHECK-NEXT: entry:
|
|
; CHECK-NEXT: br label [[WHILE_BODY:%.*]]
|
|
; CHECK: while.body:
|
|
; CHECK-NEXT: br label [[WHILE_BODY_I:%.*]]
|
|
; CHECK: while.body.i:
|
|
; CHECK-NEXT: [[MAYBE_UNDEF:%.*]] = phi i1 [ undef, [[WHILE_BODY]] ], [ [[NEXT_MAYBE_UNDEF:%.*]], [[WHILE_BODY_I]] ]
|
|
; CHECK-NEXT: [[C:%.*]] = call fastcc signext i8 @next_char()
|
|
; CHECK-NEXT: [[C_10:%.*]] = icmp eq i8 [[C]], 10
|
|
; CHECK-NEXT: [[C_13:%.*]] = icmp eq i8 [[C]], 13
|
|
; CHECK-NEXT: [[C_10_OR_13:%.*]] = or i1 [[C_10]], [[C_13]]
|
|
; CHECK-NEXT: [[NEXT_MAYBE_UNDEF]] = or i1 [[MAYBE_UNDEF]], [[C_10_OR_13]]
|
|
; CHECK-NEXT: [[C_NOT_10_OR_13:%.*]] = xor i1 [[C_10_OR_13]], true
|
|
; CHECK-NEXT: br i1 [[C_NOT_10_OR_13]], label [[WHILE_BODY_I]], label [[WHILE_BODY_I_BREAK:%.*]]
|
|
; CHECK: while.body.i.break:
|
|
; CHECK-NEXT: [[TMP0:%.*]] = freeze i1 [[MAYBE_UNDEF]]
|
|
; CHECK-NEXT: br i1 [[TMP0]], label [[WHILE_BODY]], label [[SWITCH_EARLY_TEST:%.*]]
|
|
; CHECK: switch.early.test:
|
|
; CHECK-NEXT: switch i8 [[C]], label [[RETURN:%.*]] [
|
|
; CHECK-NEXT: i8 13, label [[WHILE_BODY]]
|
|
; CHECK-NEXT: i8 10, label [[WHILE_BODY]]
|
|
; CHECK-NEXT: ]
|
|
; CHECK: return:
|
|
; CHECK-NEXT: ret void
|
|
;
|
|
|
|
entry:
|
|
br label %while.body
|
|
|
|
while.body:
|
|
br label %while.body.i
|
|
|
|
while.body.i:
|
|
%maybe_undef = phi i1 [ undef, %while.body ], [ %next_maybe_undef, %while.body.i ]
|
|
%c = call fastcc signext i8 @next_char()
|
|
%c_10 = icmp eq i8 %c, 10
|
|
%c_13 = icmp eq i8 %c, 13
|
|
%c_10_or_13 = or i1 %c_10, %c_13
|
|
%next_maybe_undef = or i1 %maybe_undef, %c_10_or_13
|
|
%c_not_10_or_13 = xor i1 %c_10_or_13, true
|
|
br i1 %c_not_10_or_13, label %while.body.i, label %while.body.i.break
|
|
|
|
while.body.i.break:
|
|
; NEXT_MAYBE_UNDEF is never undef if here
|
|
br i1 %next_maybe_undef, label %while.body, label %return
|
|
|
|
|
|
return:
|
|
ret void
|
|
}
|
|
|
|
|
|
define void @test_msan() sanitize_memory {
|
|
; CHECK-LABEL: @test_msan(
|
|
; CHECK-NEXT: entry:
|
|
; CHECK-NEXT: br label [[WHILE_BODY:%.*]]
|
|
; CHECK: while.body:
|
|
; CHECK-NEXT: br label [[WHILE_BODY_I:%.*]]
|
|
; CHECK: while.body.i:
|
|
; CHECK-NEXT: [[MAYBE_UNDEF:%.*]] = phi i1 [ undef, [[WHILE_BODY]] ], [ [[NEXT_MAYBE_UNDEF:%.*]], [[WHILE_BODY_I]] ]
|
|
; CHECK-NEXT: [[C:%.*]] = call fastcc signext i8 @next_char()
|
|
; CHECK-NEXT: [[C_10:%.*]] = icmp eq i8 [[C]], 10
|
|
; CHECK-NEXT: [[C_13:%.*]] = icmp eq i8 [[C]], 13
|
|
; CHECK-NEXT: [[C_10_OR_13:%.*]] = or i1 [[C_10]], [[C_13]]
|
|
; CHECK-NEXT: [[NEXT_MAYBE_UNDEF]] = or i1 [[MAYBE_UNDEF]], [[C_10_OR_13]]
|
|
; CHECK-NEXT: [[C_NOT_10_OR_13:%.*]] = xor i1 [[C_10_OR_13]], true
|
|
; CHECK-NEXT: br i1 [[C_NOT_10_OR_13]], label [[WHILE_BODY_I]], label [[WHILE_BODY_I_BREAK:%.*]]
|
|
; CHECK: while.body.i.break:
|
|
; CHECK-NEXT: [[TMP0:%.*]] = freeze i1 [[MAYBE_UNDEF]]
|
|
; CHECK-NEXT: br i1 [[TMP0]], label [[WHILE_BODY]], label [[SWITCH_EARLY_TEST:%.*]]
|
|
; CHECK: switch.early.test:
|
|
; CHECK-NEXT: switch i8 [[C]], label [[RETURN:%.*]] [
|
|
; CHECK-NEXT: i8 13, label [[WHILE_BODY]]
|
|
; CHECK-NEXT: i8 10, label [[WHILE_BODY]]
|
|
; CHECK-NEXT: ]
|
|
; CHECK: return:
|
|
; CHECK-NEXT: ret void
|
|
;
|
|
|
|
entry:
|
|
br label %while.body
|
|
|
|
while.body:
|
|
br label %while.body.i
|
|
|
|
while.body.i:
|
|
%maybe_undef = phi i1 [ undef, %while.body ], [ %next_maybe_undef, %while.body.i ]
|
|
%c = call fastcc signext i8 @next_char()
|
|
%c_10 = icmp eq i8 %c, 10
|
|
%c_13 = icmp eq i8 %c, 13
|
|
%c_10_or_13 = or i1 %c_10, %c_13
|
|
%next_maybe_undef = or i1 %maybe_undef, %c_10_or_13
|
|
%c_not_10_or_13 = xor i1 %c_10_or_13, true
|
|
br i1 %c_not_10_or_13, label %while.body.i, label %while.body.i.break
|
|
|
|
while.body.i.break:
|
|
; NEXT_MAYBE_UNDEF is never undef if here
|
|
br i1 %next_maybe_undef, label %while.body, label %return
|
|
|
|
|
|
return:
|
|
ret void
|
|
}
|