Test Failure: Transforms/InstCombine/add_or_sub.ll

Test source: git

Log:

Source: <stdin>

----------------------------------------
define i32 @add_or_sub_comb_i32_commuted1_nuw(i32 %x) denormal-fp-math=ieee,ieee {
%0:
  %sub = sub i32 0, %x
  %or = or i32 %sub, %x
  %add = add nuw i32 %or, %x
  ret i32 %add
}
=>
define i32 @add_or_sub_comb_i32_commuted1_nuw(i32 %x) denormal-fp-math=ieee,ieee {
%0:
  %1 = add i32 %x, 4294967295
  %add = and i32 %1, %x
  ret i32 %add
}
Transformation seems to be correct!


----------------------------------------
define i8 @add_or_sub_comb_i8_commuted2_nsw(i8 %p) denormal-fp-math=ieee,ieee {
%0:
  %x = mul i8 %p, %p
  %sub = sub i8 0, %x
  %or = or i8 %sub, %x
  %add = add nsw i8 %x, %or
  ret i8 %add
}
=>
define i8 @add_or_sub_comb_i8_commuted2_nsw(i8 %p) denormal-fp-math=ieee,ieee {
%0:
  %x = mul i8 %p, %p
  ret i8 %x
}
Transformation doesn't verify! (unsound)
ERROR: Value mismatch

Example:
i8 %p = #x08 (8)

Source:
i8 %x = #x40 (64)
i8 %sub = #xc0 (192, -64)
i8 %or = #xc0 (192, -64)
i8 %add = #x00 (0)

Target:
i8 %x = #x40 (64)
Source value: #x00 (0)
Target value: #x40 (64)

Pass: ModuleToFunctionPassAdaptor
Command line: '/home/nlopes/llvm/build/bin/opt' '-load=/home/nlopes/alive2/build/tv/tv.so' '-load-pass-plugin=/home/nlopes/alive2/build/tv/tv.so' '-tv-exit-on-error' '-passes=module(tv),function(instcombine),module(tv)' '-S' '-tv-smt-to=20000' '-tv-report-dir=/home/nlopes/alive2/build/logs' '-tv-smt-stats'


------------------- SMT STATS -------------------
Num queries: 12
Num invalid: 0
Num skips:   0
Num trivial: 13 (52.0%)
Num timeout: 0 (0.0%)
Num errors:  0 (0.0%)
Num SAT:     7 (58.3%)
Num UNSAT:   5 (41.7%)
Alive2: Transform doesn't verify; aborting!

stderr:

+ : 'RUN: at line 2'
+ /home/nlopes/alive2/build/opt-alive.sh -passes=instcombine -S
+ /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/add_or_sub.ll

FileCheck error: '<stdin>' is empty.
FileCheck command line:  /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/add_or_sub.ll

 

<-- Back