5.09/2.33 YES 5.09/2.33 proof of /export/starexec/sandbox/benchmark/theBenchmark.jar 5.09/2.33 # AProVE Commit ID: 48fb2092695e11cc9f56e44b17a92a5f88ffb256 marcel 20180622 unpublished dirty 5.09/2.33 5.09/2.33 5.09/2.33 termination of the given Bare JBC problem could be proven: 5.09/2.33 5.09/2.33 (0) Bare JBC problem 5.09/2.33 (1) BareJBCToJBCProof [EQUIVALENT, 96 ms] 5.09/2.33 (2) JBC problem 5.09/2.33 (3) JBCToGraph [EQUIVALENT, 302 ms] 5.09/2.33 (4) JBCTerminationGraph 5.09/2.33 (5) TerminationGraphToSCCProof [SOUND, 0 ms] 5.09/2.33 (6) JBCTerminationSCC 5.09/2.33 (7) SCCToIRSProof [SOUND, 72 ms] 5.09/2.33 (8) IRSwT 5.09/2.33 (9) IRSFormatTransformerProof [EQUIVALENT, 0 ms] 5.09/2.33 (10) IRSwT 5.09/2.33 (11) IRSwTTerminationDigraphProof [EQUIVALENT, 0 ms] 5.09/2.33 (12) TRUE 5.09/2.33 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (0) 5.09/2.33 Obligation: 5.09/2.33 need to prove termination of the following program: 5.09/2.33 /** 5.09/2.33 * Example taken from "A Term Rewriting Approach to the Automated Termination 5.09/2.33 * Analysis of Imperative Programs" (http://www.cs.unm.edu/~spf/papers/2009-02.pdf) 5.09/2.33 * and converted to Java. 5.09/2.33 */ 5.09/2.33 5.09/2.33 public class PastaB3 { 5.09/2.33 public static void main(String[] args) { 5.09/2.33 Random.args = args; 5.09/2.33 int x = Random.random(); 5.09/2.33 int y = Random.random(); 5.09/2.33 5.09/2.33 if (x > 0) { 5.09/2.33 while (x > y) { 5.09/2.33 y = x+y; 5.09/2.33 } 5.09/2.33 } 5.09/2.33 } 5.09/2.33 } 5.09/2.33 5.09/2.33 5.09/2.33 public class Random { 5.09/2.33 static String[] args; 5.09/2.33 static int index = 0; 5.09/2.33 5.09/2.33 public static int random() { 5.09/2.33 String string = args[index]; 5.09/2.33 index++; 5.09/2.33 return string.length(); 5.09/2.33 } 5.09/2.33 } 5.09/2.33 5.09/2.33 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (1) BareJBCToJBCProof (EQUIVALENT) 5.09/2.33 initialized classpath 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (2) 5.09/2.33 Obligation: 5.09/2.33 need to prove termination of the following program: 5.09/2.33 /** 5.09/2.33 * Example taken from "A Term Rewriting Approach to the Automated Termination 5.09/2.33 * Analysis of Imperative Programs" (http://www.cs.unm.edu/~spf/papers/2009-02.pdf) 5.09/2.33 * and converted to Java. 5.09/2.33 */ 5.09/2.33 5.09/2.33 public class PastaB3 { 5.09/2.33 public static void main(String[] args) { 5.09/2.33 Random.args = args; 5.09/2.33 int x = Random.random(); 5.09/2.33 int y = Random.random(); 5.09/2.33 5.09/2.33 if (x > 0) { 5.09/2.33 while (x > y) { 5.09/2.33 y = x+y; 5.09/2.33 } 5.09/2.33 } 5.09/2.33 } 5.09/2.33 } 5.09/2.33 5.09/2.33 5.09/2.33 public class Random { 5.09/2.33 static String[] args; 5.09/2.33 static int index = 0; 5.09/2.33 5.09/2.33 public static int random() { 5.09/2.33 String string = args[index]; 5.09/2.33 index++; 5.09/2.33 return string.length(); 5.09/2.33 } 5.09/2.33 } 5.09/2.33 5.09/2.33 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (3) JBCToGraph (EQUIVALENT) 5.09/2.33 Constructed TerminationGraph. 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (4) 5.09/2.33 Obligation: 5.09/2.33 Termination Graph based on JBC Program: 5.09/2.33 PastaB3.main([Ljava/lang/String;)V: Graph of 182 nodes with 1 SCC. 5.09/2.33 5.09/2.33 5.09/2.33 5.09/2.33 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (5) TerminationGraphToSCCProof (SOUND) 5.09/2.33 Splitted TerminationGraph to 1 SCCs. 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (6) 5.09/2.33 Obligation: 5.09/2.33 SCC of termination graph based on JBC Program. 5.09/2.33 SCC contains nodes from the following methods: PastaB3.main([Ljava/lang/String;)V 5.09/2.33 SCC calls the following helper methods: 5.09/2.33 Performed SCC analyses: 5.09/2.33 *Used field analysis yielded the following read fields: 5.09/2.33 5.09/2.33 *Marker field analysis yielded the following relations that could be markers: 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (7) SCCToIRSProof (SOUND) 5.09/2.33 Transformed FIGraph SCCs to intTRSs. Log: 5.09/2.33 Generated rules. Obtained 10 IRulesP rules: 5.09/2.33 f314_0_main_LE(EOS(STATIC_314), i45, i43, i45, i43) -> f329_0_main_Load(EOS(STATIC_329), i45, i43) :|: i45 > i43 5.09/2.33 f329_0_main_Load(EOS(STATIC_329), i45, i43) -> f342_0_main_Load(EOS(STATIC_342), i45, i43, i45) :|: TRUE 5.09/2.33 f342_0_main_Load(EOS(STATIC_342), i45, i43, i45) -> f350_0_main_IntArithmetic(EOS(STATIC_350), i45, i45, i43) :|: TRUE 5.09/2.33 f350_0_main_IntArithmetic(EOS(STATIC_350), i45, i45, i43) -> f356_0_main_Store(EOS(STATIC_356), i45, i45 + i43) :|: i45 > 0 && i43 >= 0 5.09/2.33 f356_0_main_Store(EOS(STATIC_356), i45, i47) -> f360_0_main_JMP(EOS(STATIC_360), i45, i47) :|: TRUE 5.09/2.33 f360_0_main_JMP(EOS(STATIC_360), i45, i47) -> f373_0_main_Load(EOS(STATIC_373), i45, i47) :|: TRUE 5.09/2.33 f373_0_main_Load(EOS(STATIC_373), i45, i47) -> f301_0_main_Load(EOS(STATIC_301), i45, i47) :|: TRUE 5.09/2.33 f301_0_main_Load(EOS(STATIC_301), i45, i43) -> f305_0_main_Load(EOS(STATIC_305), i45, i43, i45) :|: TRUE 5.09/2.33 f305_0_main_Load(EOS(STATIC_305), i45, i43, i45) -> f308_0_main_LE(EOS(STATIC_308), i45, i43, i45, i43) :|: TRUE 5.09/2.33 f308_0_main_LE(EOS(STATIC_308), i45, i43, i45, i43) -> f314_0_main_LE(EOS(STATIC_314), i45, i43, i45, i43) :|: i45 > i43 5.09/2.33 Combined rules. Obtained 1 IRulesP rules: 5.09/2.33 f314_0_main_LE(EOS(STATIC_314), i45:0, i43:0, i45:0, i43:0) -> f314_0_main_LE(EOS(STATIC_314), i45:0, i45:0 + i43:0, i45:0, i45:0 + i43:0) :|: i45:0 > i43:0 && i43:0 > -1 && i45:0 + i43:0 < i45:0 && i45:0 > 0 5.09/2.33 Filtered constant ground arguments: 5.09/2.33 f314_0_main_LE(x1, x2, x3, x4, x5) -> f314_0_main_LE(x2, x3, x4, x5) 5.09/2.33 EOS(x1) -> EOS 5.09/2.33 Filtered duplicate arguments: 5.09/2.33 f314_0_main_LE(x1, x2, x3, x4) -> f314_0_main_LE(x3, x4) 5.09/2.33 Finished conversion. Obtained 1 rules.P rules: 5.09/2.33 f314_0_main_LE(i45:0, i43:0) -> f314_0_main_LE(i45:0, i45:0 + i43:0) :|: i43:0 > -1 && i45:0 > i43:0 && i45:0 > 0 && i45:0 + i43:0 < i45:0 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (8) 5.09/2.33 Obligation: 5.09/2.33 Rules: 5.09/2.33 f314_0_main_LE(i45:0, i43:0) -> f314_0_main_LE(i45:0, i45:0 + i43:0) :|: i43:0 > -1 && i45:0 > i43:0 && i45:0 > 0 && i45:0 + i43:0 < i45:0 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (9) IRSFormatTransformerProof (EQUIVALENT) 5.09/2.33 Reformatted IRS to match normalized format (transformed away non-linear left-hand sides, !=, / and %). 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (10) 5.09/2.33 Obligation: 5.09/2.33 Rules: 5.09/2.33 f314_0_main_LE(i45:0, i43:0) -> f314_0_main_LE(i45:0, arith) :|: i43:0 > -1 && i45:0 > i43:0 && i45:0 > 0 && i45:0 + i43:0 < i45:0 && arith = i45:0 + i43:0 5.09/2.33 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (11) IRSwTTerminationDigraphProof (EQUIVALENT) 5.09/2.33 Constructed termination digraph! 5.09/2.33 Nodes: 5.09/2.33 (1) f314_0_main_LE(i45:0, i43:0) -> f314_0_main_LE(i45:0, arith) :|: i43:0 > -1 && i45:0 > i43:0 && i45:0 > 0 && i45:0 + i43:0 < i45:0 && arith = i45:0 + i43:0 5.09/2.33 5.09/2.33 No arcs! 5.09/2.33 5.09/2.33 This digraph is fully evaluated! 5.09/2.33 ---------------------------------------- 5.09/2.33 5.09/2.33 (12) 5.09/2.33 TRUE 5.33/2.36 EOF