Test source: git
Source: <stdin> -- 1. ModuleToFunctionPassAdaptor -- 1. PassManager<Function> : Skipping NOP -- 2. InstCombinePass ---------------------------------------- define i1 @test_nonzero(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp ne i32 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 3. InstCombinePass ---------------------------------------- define i1 @test_nonzero(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp ne i32 %val_range, 0 ret i1 %rval } => define i1 @test_nonzero(ptr nocapture nowrite %arg) { #0: ret i1 1 } Transformation seems to be correct! -- 4. PassManager<Function> : Skipping NOP -- 5. PassManager<Function> : Skipping NOP -- 6. InstCombinePass ---------------------------------------- define i1 @test_nonzero2(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp eq i32 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 7. InstCombinePass ---------------------------------------- define i1 @test_nonzero2(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp eq i32 %val_range, 0 ret i1 %rval } => define i1 @test_nonzero2(ptr nocapture nowrite %arg) { #0: ret i1 0 } Transformation seems to be correct! -- 8. PassManager<Function> : Skipping NOP -- 9. PassManager<Function> : Skipping NOP -- 10. InstCombinePass ---------------------------------------- define i1 @test_nonzero3(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 0, i32 6 %rval = icmp ne i32 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 11. InstCombinePass ---------------------------------------- define i1 @test_nonzero3(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 0, i32 6 %rval = icmp ne i32 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 12. PassManager<Function> : Skipping NOP -- 13. PassManager<Function> : Skipping NOP -- 14. InstCombinePass ---------------------------------------- define i1 @test_nonzero4(ptr nocapture nowrite %arg) { #0: %val = load i8, ptr nocapture nowrite %arg, align 1 %val_range = !range i8 %val, i8 0, i8 1 %rval = icmp ne i8 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 15. InstCombinePass ---------------------------------------- define i1 @test_nonzero4(ptr nocapture nowrite %arg) { #0: %val = load i8, ptr nocapture nowrite %arg, align 1 %val_range = !range i8 %val, i8 0, i8 1 %rval = icmp ne i8 %val_range, 0 ret i1 %rval } => define i1 @test_nonzero4(ptr nocapture nowrite %arg) { #0: ret i1 0 } Transformation seems to be correct! -- 16. PassManager<Function> : Skipping NOP -- 17. PassManager<Function> : Skipping NOP -- 18. InstCombinePass ---------------------------------------- define i1 @test_nonzero5(ptr nocapture nowrite %arg) { #0: %val = load i8, ptr nocapture nowrite %arg, align 1 %val_range = !range i8 %val, i8 0, i8 1 %rval = icmp ugt i8 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 19. InstCombinePass ---------------------------------------- define i1 @test_nonzero5(ptr nocapture nowrite %arg) { #0: %val = load i8, ptr nocapture nowrite %arg, align 1 %val_range = !range i8 %val, i8 0, i8 1 %rval = icmp ugt i8 %val_range, 0 ret i1 %rval } => define i1 @test_nonzero5(ptr nocapture nowrite %arg) { #0: ret i1 0 } Transformation seems to be correct! -- 20. PassManager<Function> : Skipping NOP -- 21. PassManager<Function> : Skipping NOP -- 22. InstCombinePass ---------------------------------------- define i1 @test_nonzero6(ptr %argw) { #0: %val = load i8, ptr %argw, align 1 %val_range = !range i8 %val, i8 0, i8 6 %rval = icmp sgt i8 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 23. InstCombinePass ---------------------------------------- define i1 @test_nonzero6(ptr %argw) { #0: %val = load i8, ptr %argw, align 1 %val_range = !range i8 %val, i8 0, i8 6 %rval = icmp sgt i8 %val_range, 0 ret i1 %rval } => define i1 @test_nonzero6(ptr %argw) { #0: %val = load i8, ptr %argw, align 1 %val_range = !range i8 %val, i8 0, i8 6 %rval = icmp ne i8 %val_range, 0 ret i1 %rval } Transformation seems to be correct! -- 24. PassManager<Function> : Skipping NOP -- 25. PassManager<Function> : Skipping NOP -- 26. InstCombinePass ---------------------------------------- define i1 @test_not_in_range(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp ne i32 %val_range, 6 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 27. InstCombinePass ---------------------------------------- define i1 @test_not_in_range(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp ne i32 %val_range, 6 ret i1 %rval } => define i1 @test_not_in_range(ptr nocapture nowrite %arg) { #0: ret i1 1 } Transformation seems to be correct! -- 28. PassManager<Function> : Skipping NOP -- 29. PassManager<Function> : Skipping NOP -- 30. InstCombinePass ---------------------------------------- define i1 @test_in_range(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp ne i32 %val_range, 3 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 31. InstCombinePass ---------------------------------------- define i1 @test_in_range(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp ne i32 %val_range, 3 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 32. PassManager<Function> : Skipping NOP -- 33. PassManager<Function> : Skipping NOP -- 34. InstCombinePass ---------------------------------------- define i1 @test_range_sgt_constant(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp sgt i32 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 35. InstCombinePass ---------------------------------------- define i1 @test_range_sgt_constant(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp sgt i32 %val_range, 0 ret i1 %rval } => define i1 @test_range_sgt_constant(ptr nocapture nowrite %arg) { #0: ret i1 1 } Transformation seems to be correct! -- 36. PassManager<Function> : Skipping NOP -- 37. PassManager<Function> : Skipping NOP -- 38. InstCombinePass ---------------------------------------- define i1 @test_range_slt_constant(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp sgt i32 %val_range, 6 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 39. InstCombinePass ---------------------------------------- define i1 @test_range_slt_constant(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6 %rval = icmp sgt i32 %val_range, 6 ret i1 %rval } => define i1 @test_range_slt_constant(ptr nocapture nowrite %arg) { #0: ret i1 0 } Transformation seems to be correct! -- 40. PassManager<Function> : Skipping NOP -- 41. PassManager<Function> : Skipping NOP -- 42. InstCombinePass ---------------------------------------- define i1 @test_multi_range1(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6, i32 8, i32 10 %rval = icmp ne i32 %val_range, 0 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 43. InstCombinePass ---------------------------------------- define i1 @test_multi_range1(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6, i32 8, i32 10 %rval = icmp ne i32 %val_range, 0 ret i1 %rval } => define i1 @test_multi_range1(ptr nocapture nowrite %arg) { #0: ret i1 1 } Transformation seems to be correct! -- 44. PassManager<Function> : Skipping NOP -- 45. PassManager<Function> : Skipping NOP -- 46. InstCombinePass ---------------------------------------- define i1 @test_multi_range2(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6, i32 8, i32 10 %rval = icmp ne i32 %val_range, 7 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 47. InstCombinePass ---------------------------------------- define i1 @test_multi_range2(ptr nocapture nowrite %arg) { #0: %val = load i32, ptr nocapture nowrite %arg, align 4 %val_range = !range i32 %val, i32 1, i32 6, i32 8, i32 10 %rval = icmp ne i32 %val_range, 7 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 48. PassManager<Function> : Skipping NOP -- 49. PassManager<Function> : Skipping NOP -- 50. InstCombinePass ---------------------------------------- define i1 @test_two_ranges(ptr nocapture nowrite %arg1, ptr nocapture nowrite %arg2) { #0: %val1 = load i32, ptr nocapture nowrite %arg1, align 4 %val1_range = !range i32 %val1, i32 5, i32 10 %val2 = load i32, ptr nocapture nowrite %arg2, align 4 %val2_range = !range i32 %val2, i32 8, i32 16 %rval = icmp ult i32 %val2_range, %val1_range ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 51. InstCombinePass ---------------------------------------- define i1 @test_two_ranges(ptr nocapture nowrite %arg1, ptr nocapture nowrite %arg2) { #0: %val1 = load i32, ptr nocapture nowrite %arg1, align 4 %val1_range = !range i32 %val1, i32 5, i32 10 %val2 = load i32, ptr nocapture nowrite %arg2, align 4 %val2_range = !range i32 %val2, i32 8, i32 16 %rval = icmp ult i32 %val2_range, %val1_range ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 52. PassManager<Function> : Skipping NOP -- 53. PassManager<Function> : Skipping NOP -- 54. InstCombinePass ---------------------------------------- define i1 @test_two_attribute_ranges(i32 %arg1, i32 %arg2) { #0: %rval = icmp ult i32 %arg2, %arg1 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 55. InstCombinePass ---------------------------------------- define i1 @test_two_attribute_ranges(i32 %arg1, i32 %arg2) { #0: %rval = icmp ult i32 %arg2, %arg1 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 56. PassManager<Function> : Skipping NOP -- 57. PassManager<Function> : Skipping NOP -- 58. InstCombinePass ---------------------------------------- define i1 @test_two_ranges2(ptr nocapture nowrite %arg1, ptr nocapture nowrite %arg2) { #0: %val1 = load i32, ptr nocapture nowrite %arg1, align 4 %val1_range = !range i32 %val1, i32 1, i32 6 %val2 = load i32, ptr nocapture nowrite %arg2, align 4 %val2_range = !range i32 %val2, i32 8, i32 16 %rval = icmp ult i32 %val2_range, %val1_range ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 59. InstCombinePass ---------------------------------------- define i1 @test_two_ranges2(ptr nocapture nowrite %arg1, ptr nocapture nowrite %arg2) { #0: %val1 = load i32, ptr nocapture nowrite %arg1, align 4 %val1_range = !range i32 %val1, i32 1, i32 6 %val2 = load i32, ptr nocapture nowrite %arg2, align 4 %val2_range = !range i32 %val2, i32 8, i32 16 %rval = icmp ult i32 %val2_range, %val1_range ret i1 %rval } => define i1 @test_two_ranges2(ptr nocapture nowrite %arg1, ptr nocapture nowrite %arg2) { #0: ret i1 0 } Transformation seems to be correct! -- 60. PassManager<Function> : Skipping NOP -- 61. PassManager<Function> : Skipping NOP -- 62. InstCombinePass ---------------------------------------- define i1 @test_two_argument_ranges(i32 %arg1, i32 %arg2) { #0: %rval = icmp ult i32 %arg2, %arg1 ret i1 %rval } Transformation seems to be correct! (syntactically equal) -- 63. InstCombinePass ---------------------------------------- define i1 @test_two_argument_ranges(i32 %arg1, i32 %arg2) { #0: %rval = icmp ult i32 %arg2, %arg1 ret i1 %rval } => define i1 @test_two_argument_ranges(i32 %arg1, i32 %arg2) { #0: ret i1 0 } Transformation doesn't verify! (unsound) ERROR: Value mismatch Example: i32 %arg1 = #x00000001 (1) i32 %arg2 = #x00000000 (0) Source: i1 %rval = #x1 (1) Target: Source value: #x1 (1) Target value: #x0 (0) Pass: InstCombinePass 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=instcombine' '-S' '-tv-smt-to=20000' '-tv-report-dir=/home/nlopes/alive2/build/logs' '-tv-smt-stats' Wrote bitcode to: "/home/nlopes/alive2/build/logs/in_ujCmGiHH_w7lx.bc" ------------------- SMT STATS ------------------- Num queries: 40 Num invalid: 0 Num skips: 0 Num trivial: 59 (59.6%) Num timeout: 0 (0.0%) Num errors: 0 (0.0%) Num SAT: 29 (72.5%) Num UNSAT: 11 (27.5%) Alive2: Transform doesn't verify; aborting!
RUN: at line 2: /home/nlopes/alive2/build/opt-alive.sh < /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/icmp-range.ll -passes=instcombine -S | /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/icmp-range.ll + /home/nlopes/alive2/build/opt-alive.sh -passes=instcombine -S + /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/icmp-range.ll FileCheck error: '<stdin>' is empty. FileCheck command line: /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/icmp-range.ll