Bjorn Pettersson eda6ff3472 [test][Transform/Utils] Update tests to opaque pointer syntax. NFC
This patch converts test cases that simly could be rewritten
using the script at
https://gist.github.com/nikic/98357b71fd67756b0f064c9517b62a34
2022-10-03 23:01:43 +02:00

26 lines
464 B
LLVM

; RUN: opt -passes=print-predicateinfo < %s 2>&1 | FileCheck %s
declare void @foo()
declare void @llvm.assume(i1)
define void @bar(ptr %p) {
entry:
; CHECK-LABEL: @bar
br label %end
unreachable1:
%v1 = load i32, ptr %p, align 4
%c1 = icmp eq i32 %v1, 0
call void @llvm.assume(i1 %c1)
br label %unreachable2
unreachable2:
%v2 = load i32, ptr %p, align 4
%c2 = icmp eq i32 %v2, 0
call void @llvm.assume(i1 %c2)
br label %end
end:
ret void
}