Skip to content

Commit b3ae9b9

Browse files
committed
Remove br i1 undef in InstSimplify directory
1 parent 4559b4e commit b3ae9b9

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

llvm/test/Transforms/InstSimplify/dead-code-removal.ll

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py
22
; RUN: opt -passes=instsimplify -S < %s | FileCheck %s
33

4-
define void @foo() nounwind {
4+
define void @foo(i1 %arg) nounwind {
55
; CHECK-LABEL: @foo(
6-
; CHECK-NEXT: br i1 undef, label [[TMP1:%.*]], label [[TMP2:%.*]]
6+
; CHECK-NEXT: br i1 %arg, label [[TMP1:%.*]], label [[TMP2:%.*]]
77
; CHECK: 1:
88
; CHECK-NEXT: br label [[TMP1]]
99
; CHECK: 2:
1010
; CHECK-NEXT: ret void
1111
;
12-
br i1 undef, label %1, label %4
12+
br i1 %arg, label %1, label %4
1313

1414
; <label>:1 ; preds = %1, %0
1515
%2 = phi i32 [ %3, %1 ], [ undef, %0 ]

llvm/test/Transforms/InstSimplify/require-dominator.ll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@
77
target triple = "x86_64-grtev4-linux-gnu"
88

99
; Function Attrs: nounwind uwtable
10-
define void @foo(ptr) #1 align 2 {
11-
br i1 undef, label %exit, label %2
10+
define void @foo(ptr, i1 %arg) #1 align 2 {
11+
br i1 %arg, label %exit, label %2
1212

1313
; <label>:2:
1414
%3 = tail call ptr @_Znwm(i64 56) #10

0 commit comments

Comments
 (0)