/export/starexec/sandbox/solver/bin/starexec_run_standard /export/starexec/sandbox/benchmark/theBenchmark.jar /export/starexec/sandbox/output/output_files -------------------------------------------------------------------------------- NO proof of /export/starexec/sandbox/benchmark/theBenchmark.jar # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty termination of the given Bare JBC problem could be disproven: (0) Bare JBC problem (1) BareJBCToJBCProof [EQUIVALENT, 97 ms] (2) JBC problem (3) JBCToGraph [EQUIVALENT, 202 ms] (4) JBCTerminationGraph (5) JBCNonTerm [COMPLETE, 140 ms] (6) NO ---------------------------------------- (0) Obligation: need to prove termination of the following program: package simple.alternDiv; public class AlternDiv { public static void loop(int i) { while (i != 0) { if (i < 0) { i--; i = i*(-1); } else { i++; i = i*(-1); } } } } package simple.alternDiv; public class Main { /** * @param args */ public static void main(String[] args) { AlternDiv.loop(args.length); } } ---------------------------------------- (1) BareJBCToJBCProof (EQUIVALENT) initialized classpath ---------------------------------------- (2) Obligation: need to prove termination of the following program: package simple.alternDiv; public class AlternDiv { public static void loop(int i) { while (i != 0) { if (i < 0) { i--; i = i*(-1); } else { i++; i = i*(-1); } } } } package simple.alternDiv; public class Main { /** * @param args */ public static void main(String[] args) { AlternDiv.loop(args.length); } } ---------------------------------------- (3) JBCToGraph (EQUIVALENT) Constructed TerminationGraph. ---------------------------------------- (4) Obligation: Termination Graph based on JBC Program: simple.alternDiv.Main.main([Ljava/lang/String;)V: Graph of 31 nodes with 1 SCC. ---------------------------------------- (5) JBCNonTerm (COMPLETE) Reached a loop using the following run: 0: a16([java.lang.String...]): length 1 -->{java.lang.Object...} YES: (JL1) 1: a16([java.lang.String...]): length 1 -->{java.lang.Object...} YES: (JL1) 2: YES: (JL1) 3: YES: (JL1) Start state of loop: [a6(lv_0_0)] i122: # i16: [0,+inf)(l1) a6([java.lang.String...]): length i16 -->{java.lang.Object...} YES: (JL1) In the loop head node, references [i122] were interesting. All methods calls in the loop body are side-effect free, hence they can be ignored. By SMT, we could prove (0 <= initial_i16 and ((((path1_i122 = path1_i131 and path1_i131 = path1_i134 and path1_i136 = (path1_i134 + -1) and path1_i140 = (path1_i136 * -1) and path1_i140 = res_i122 and path1_i122 = initial_i122) and (path1_i131 != 0 and path1_i134 < 0)) or ((path2_i122 = path2_i131 and path2_i131 = path2_i135 and path2_i138 = (path2_i135 + 1) and path2_i142 = (path2_i138 * -1) and path2_i142 = res_i122 and path2_i122 = initial_i122) and (path2_i131 != 0 and path2_i135 >= 0)) or ((path1_i122 = path1_i131 and path1_i131 = path1_i134 and path1_i136 = (path1_i134 + -1) and path1_i140 = (path1_i136 * -1) and path1_i140 = res_i122 and path1_i122 = initial_i122) and (path1_i134 < 0 and path1_i131 < 0)) or ((path1_i122 = path1_i131 and path1_i131 = path1_i134 and path1_i136 = (path1_i134 + -1) and path1_i140 = (path1_i136 * -1) and path1_i140 = res_i122 and path1_i122 = initial_i122) and (path1_i134 < 0 and path1_i131 > 0)) or ((path2_i122 = path2_i131 and path2_i131 = path2_i135 and path2_i138 = (path2_i135 + 1) and path2_i142 = (path2_i138 * -1) and path2_i142 = res_i122 and path2_i122 = initial_i122) and (path2_i135 >= 0 and path2_i131 < 0)) or ((path2_i122 = path2_i131 and path2_i131 = path2_i135 and path2_i138 = (path2_i135 + 1) and path2_i142 = (path2_i138 * -1) and path2_i142 = res_i122 and path2_i122 = initial_i122) and (path2_i135 >= 0 and path2_i131 > 0))) and (((res1_i122 = res1_i131 and res1_i131 = res1_i134 and res1_i136 = (res1_i134 + -1) and res1_i140 = (res1_i136 * -1) and res_i122 = res1_i122) and !(res1_i131 != 0 and res1_i134 < 0)) and ((res2_i122 = res2_i131 and res2_i131 = res2_i135 and res2_i138 = (res2_i135 + 1) and res2_i142 = (res2_i138 * -1) and res_i122 = res2_i122) and !(res2_i131 != 0 and res2_i135 >= 0)) and ((res1_i122 = res1_i131 and res1_i131 = res1_i134 and res1_i136 = (res1_i134 + -1) and res1_i140 = (res1_i136 * -1) and res_i122 = res1_i122) and !(res1_i134 < 0 and res1_i131 < 0)) and ((res1_i122 = res1_i131 and res1_i131 = res1_i134 and res1_i136 = (res1_i134 + -1) and res1_i140 = (res1_i136 * -1) and res_i122 = res1_i122) and !(res1_i134 < 0 and res1_i131 > 0)) and ((res2_i122 = res2_i131 and res2_i131 = res2_i135 and res2_i138 = (res2_i135 + 1) and res2_i142 = (res2_i138 * -1) and res_i122 = res2_i122) and !(res2_i135 >= 0 and res2_i131 < 0)) and ((res2_i122 = res2_i131 and res2_i131 = res2_i135 and res2_i138 = (res2_i135 + 1) and res2_i142 = (res2_i138 * -1) and res_i122 = res2_i122) and !(res2_i135 >= 0 and res2_i131 > 0))))) to be UNSAT. Consequently, the loop will not terminate. ---------------------------------------- (6) NO