Bjorn Pettersson 57bd67abfc [NewPM][test] Use -passes syntax in SpeculativeExecution lit tests
The legacy PM is deprecated, so use the new PM syntax in lit tests
running the speculative-execution pass.
2021-10-20 15:16:17 +02:00

32 lines
538 B
LLVM

; RUN: opt < %s -S -passes=speculative-execution \
; RUN: -spec-exec-max-speculation-cost 4 -spec-exec-max-not-hoisted 3 \
; RUN: | FileCheck %s
; CHECK-LABEL: @ifThen_icmp(
; CHECK: icmp
; CHECK: br i1 true
define void @ifThen_icmp() {
br i1 true, label %a, label %b
a:
%x = icmp eq i32 undef, undef
br label %b
b:
ret void
}
; CHECK-LABEL: @ifThen_fcmp(
; CHECK: fcmp
; CHECK: br i1 true
define void @ifThen_fcmp() {
br i1 true, label %a, label %b
a:
%x = fcmp oeq float undef, undef
br label %b
b:
ret void
}