3.74/1.78 YES 3.74/1.79 proof of /export/starexec/sandbox2/benchmark/theBenchmark.jar 3.74/1.79 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 3.74/1.79 3.74/1.79 3.74/1.79 termination of the given Bare JBC problem could be proven: 3.74/1.79 3.74/1.79 (0) Bare JBC problem 3.74/1.79 (1) BareJBCToJBCProof [EQUIVALENT, 95 ms] 3.74/1.79 (2) JBC problem 3.74/1.79 (3) JBCToGraph [EQUIVALENT, 135 ms] 3.74/1.79 (4) JBCTerminationGraph 3.74/1.79 (5) TerminationGraphToSCCProof [SOUND, 0 ms] 3.74/1.79 (6) TRUE 3.74/1.79 3.74/1.79 3.74/1.79 ---------------------------------------- 3.74/1.79 3.74/1.79 (0) 3.74/1.79 Obligation: 3.74/1.79 need to prove termination of the following program: 3.74/1.79 public class CyclicPair { 3.74/1.79 CyclicPair next; 3.74/1.79 3.74/1.79 public static void main(String[] args) { 3.74/1.79 Random.args = args; 3.74/1.79 CyclicPair one = new CyclicPair(); 3.74/1.79 CyclicPair two = new CyclicPair(); 3.74/1.79 int i = Random.random(); 3.74/1.79 if (i == 0) { //two cyclic 3.74/1.79 two.next = two; 3.74/1.79 } else { //one cyclic 3.74/1.79 one.next = one; 3.74/1.79 } 3.74/1.79 3.74/1.79 while (two.next == two && one.next == one) { 3.74/1.79 one.next = two; //one: o1, two: o2 | o1: (next=o2), o2: (next=o2) 3.74/1.79 two.next = one; //one: o1, two: o2 | o1: (next=o2), o2: (next=o1) 3.74/1.79 one.next = two.next; //one: o2, two: o2 | o1: (next=o1), o2: (next=o1) 3.74/1.79 two.next = two; 3.74/1.79 } 3.74/1.79 } 3.74/1.79 } 3.74/1.79 3.74/1.79 3.74/1.79 public class Random { 3.74/1.79 static String[] args; 3.74/1.79 static int index = 0; 3.74/1.79 3.74/1.79 public static int random() { 3.74/1.79 String string = args[index]; 3.74/1.79 index++; 3.74/1.79 return string.length(); 3.74/1.79 } 3.74/1.79 } 3.74/1.79 3.74/1.79 3.74/1.79 3.74/1.79 ---------------------------------------- 3.74/1.79 3.74/1.79 (1) BareJBCToJBCProof (EQUIVALENT) 3.74/1.79 initialized classpath 3.74/1.79 ---------------------------------------- 3.74/1.79 3.74/1.79 (2) 3.74/1.79 Obligation: 3.74/1.79 need to prove termination of the following program: 3.74/1.79 public class CyclicPair { 3.74/1.79 CyclicPair next; 3.74/1.79 3.74/1.79 public static void main(String[] args) { 3.74/1.79 Random.args = args; 3.74/1.79 CyclicPair one = new CyclicPair(); 3.74/1.79 CyclicPair two = new CyclicPair(); 3.74/1.79 int i = Random.random(); 3.74/1.79 if (i == 0) { //two cyclic 3.74/1.79 two.next = two; 3.74/1.79 } else { //one cyclic 3.74/1.79 one.next = one; 3.74/1.79 } 3.74/1.79 3.74/1.79 while (two.next == two && one.next == one) { 3.74/1.79 one.next = two; //one: o1, two: o2 | o1: (next=o2), o2: (next=o2) 3.74/1.79 two.next = one; //one: o1, two: o2 | o1: (next=o2), o2: (next=o1) 3.74/1.79 one.next = two.next; //one: o2, two: o2 | o1: (next=o1), o2: (next=o1) 3.74/1.79 two.next = two; 3.74/1.79 } 3.74/1.79 } 3.74/1.79 } 3.74/1.79 3.74/1.79 3.74/1.79 public class Random { 3.74/1.79 static String[] args; 3.74/1.79 static int index = 0; 3.74/1.79 3.74/1.79 public static int random() { 3.74/1.79 String string = args[index]; 3.74/1.79 index++; 3.74/1.79 return string.length(); 3.74/1.79 } 3.74/1.79 } 3.74/1.79 3.74/1.79 3.74/1.79 3.74/1.79 ---------------------------------------- 3.74/1.79 3.74/1.79 (3) JBCToGraph (EQUIVALENT) 3.74/1.79 Constructed TerminationGraph. 3.74/1.79 ---------------------------------------- 3.74/1.79 3.74/1.79 (4) 3.74/1.79 Obligation: 3.74/1.79 Termination Graph based on JBC Program: 3.74/1.79 CyclicPair.main([Ljava/lang/String;)V: Graph of 138 nodes with 0 SCCs. 3.74/1.79 3.74/1.79 3.74/1.79 3.74/1.79 3.74/1.79 3.74/1.79 ---------------------------------------- 3.74/1.79 3.74/1.79 (5) TerminationGraphToSCCProof (SOUND) 3.74/1.79 Proven termination by absence of SCCs 3.74/1.79 ---------------------------------------- 3.74/1.79 3.74/1.79 (6) 3.74/1.79 TRUE 3.88/1.81 EOF