Test Failure: Transforms/SimplifyCFG/common-dest-folding.ll

Test source: git

Log:

Source: <stdin>

----------------------------------------
define i32 @foo(i32 %k, i32 %c1, i32 %c2) {
%0:
  %4 = and i32 %c1, %k
  %5 = icmp eq i32 %4, 0
  br i1 %5, label %3, label %1

%1:
  %6 = and i32 %c2, %k
  %7 = icmp eq i32 %6, 0
  br i1 %7, label %3, label %2

%2:
  %8 = call i32 @bar()
  br label %3

%3:
  ret i32 undef
}
=>
define i32 @foo(i32 %k, i32 %c1, i32 %c2) {
%0:
  %3 = and i32 %c1, %k
  %4 = icmp eq i32 %3, 0
  %5 = and i32 %c2, %k
  %6 = icmp eq i32 %5, 0
  %or.cond = or i1 %4, %6
  br i1 %or.cond, label %2, label %1

%1:
  %7 = call i32 @bar()
  br label %2

%2:
  ret i32 undef
}
Transformation doesn't verify!
ERROR: Source is more defined than target

Example:
i32 %k = #xffdfffff (4292870143, -2097153)
i32 %c1 = #x00200000 (2097152)
i32 %c2 = poison

Source:
i32 %4 = #x00000000 (0)
i1 %5 = #x1 (1)
i32 %6 = poison
i1 %7 = poison
i32 %8 = poison

SOURCE MEMORY STATE
===================
NON-LOCAL BLOCKS:
Block 0 >	size: 0	align: 64	alloc type: 0
Block 1 >	size: 0	align: 4	alloc type: 0

Target:
i32 %3 = #x00000000 (0)
i1 %4 = #x1 (1)
i32 %5 = poison
i1 %6 = poison
i1 %or.cond = poison
i32 %7 = poison



------------------- SMT STATS -------------------
Num queries: 2
Num invalid: 0
Num skips:   0
Num trivial: 0 (0.0%)
Num timeout: 0 (0.0%)
Num errors:  0 (0.0%)
Num SAT:     2 (100.0%)
Num UNSAT:   0 (0.0%)

stderr:

+ : 'RUN: at line 1'
+ /home/nlopes/alive2/scripts/opt-alive.sh -simplifycfg -S
+ /home/nlopes/llvm/build/bin/FileCheck /home/nlopes/llvm/llvm/test/Transforms/SimplifyCFG/common-dest-folding.ll

Alive2: Transform doesn't verify; aborting!
FileCheck error: '<stdin>' is empty.
FileCheck command line:  /home/nlopes/llvm/build/bin/FileCheck /home/nlopes/llvm/llvm/test/Transforms/SimplifyCFG/common-dest-folding.ll

 

<-- Back