Test source: git
Source: <stdin> -- 1. ModuleToFunctionPassAdaptor -- 1. PassManager<Function> : Skipping NOP -- 2. InstCombinePass ---------------------------------------- define ptr @test(ptr %P) { #0: %V = ptrtoint ptr %P to i32 %P2 = inttoptr i32 %V to ptr ret ptr %P2 } Transformation seems to be correct! (syntactically equal) -- 3. InstCombinePass ---------------------------------------- define ptr @test(ptr %P) { #0: %V = ptrtoint ptr %P to i32 %P2 = inttoptr i32 %V to ptr ret ptr %P2 } => define ptr @test(ptr %P) { #0: ret ptr %P } Transformation doesn't verify! (unsound) ERROR: Value mismatch Example: ptr %P = pointer(non-local, block_id=0, offset=8) / Address=#x00000008 Source: i32 %V = #x00000008 (8) ptr %P2 = phy-ptr(addr=8) / Address=#x00000008 SOURCE MEMORY STATE =================== NON-LOCAL BLOCKS: Block 0 > size: 0 align: 1 alloc type: 0 alive: false address: 0 Block 1 > size: 1548353536 align: 1 alloc type: 0 alive: true address: 2 Block 2 > size: 0 align: 2 alloc type: 0 alive: true address: 2 Target: Source value: phy-ptr(addr=8) / Address=#x00000008 Target value: pointer(non-local, block_id=0, offset=8) / Address=#x00000008 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_GcrHEDO6_WyW0.bc" ------------------- SMT STATS ------------------- Num queries: 14 Num invalid: 0 Num skips: 0 Num trivial: 8 (36.4%) Num timeout: 0 (0.0%) Num errors: 0 (0.0%) Num SAT: 10 (71.4%) Num UNSAT: 4 (28.6%) Alive2: Transform doesn't verify; aborting!
/home/nlopes/alive2/build/opt-alive.sh < /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/IntPtrCast.ll -passes=instcombine -S | /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/IntPtrCast.ll # RUN: at line 1 + /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/IntPtrCast.ll + /home/nlopes/alive2/build/opt-alive.sh -passes=instcombine -S FileCheck error: '<stdin>' is empty. FileCheck command line: /bitbucket/nlopes/llvm/build/bin/FileCheck /bitbucket/nlopes/llvm/llvm/test/Transforms/InstCombine/IntPtrCast.ll