mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 12:12:47 +01:00
495950222a
First step after e1133179587dd895962a2fe4d6eb0cb1e63b5ee2, in these tests, DomTree is valid afterwards, so mark them as such, so that they don't regress. In further steps, SimplifyCFG transforms shall taught to preserve DomTree, in as small steps as possible.
29 lines
801 B
LLVM
29 lines
801 B
LLVM
; RUN: opt < %s -simplifycfg -simplifycfg-require-and-preserve-domtree=1 -disable-output
|
|
;
|
|
; Test that SimplifyCFG does not cause CallBr instructions to have duplicate
|
|
; destinations, which will cause the verifier to assert.
|
|
|
|
define void @fun0() {
|
|
entry:
|
|
callbr void asm sideeffect "", "X"(i8* blockaddress(@fun0, %bb1))
|
|
to label %bb2 [label %bb1]
|
|
|
|
bb1: ; preds = %bb
|
|
ret void
|
|
|
|
bb2: ; preds = %bb
|
|
ret void
|
|
}
|
|
|
|
define void @fun1() {
|
|
entry:
|
|
callbr void asm sideeffect "", "X"(i8* blockaddress(@fun1, %bb1))
|
|
to label %bb2 [label %bb1]
|
|
|
|
bb2: ; preds = %bb
|
|
ret void
|
|
|
|
bb1: ; preds = %bb
|
|
ret void
|
|
}
|