0.03/0.18 WORST_CASE(?,O(n^1)) 0.03/0.18 0.03/0.18 Preprocessing Cost Relations 0.03/0.18 ===================================== 0.03/0.18 0.03/0.18 #### Computed strongly connected components 0.03/0.18 0. recursive : [eval1/4,eval2/4] 0.03/0.18 1. non_recursive : [exit_location/1] 0.03/0.18 2. non_recursive : [eval1_loop_cont/2] 0.03/0.18 3. non_recursive : [start/4] 0.03/0.18 0.03/0.18 #### Obtained direct recursion through partial evaluation 0.03/0.18 0. SCC is partially evaluated into eval1/4 0.03/0.18 1. SCC is completely evaluated into other SCCs 0.03/0.18 2. SCC is completely evaluated into other SCCs 0.03/0.18 3. SCC is partially evaluated into start/4 0.03/0.18 0.03/0.18 Control-Flow Refinement of Cost Relations 0.03/0.18 ===================================== 0.03/0.18 0.03/0.18 ### Specialization of cost equations eval1/4 0.03/0.18 * CE 5 is refined into CE [6] 0.03/0.18 * CE 2 is refined into CE [7] 0.03/0.18 * CE 3 is refined into CE [8] 0.03/0.18 * CE 4 is refined into CE [9] 0.03/0.18 0.03/0.18 0.03/0.18 ### Cost equations --> "Loop" of eval1/4 0.03/0.18 * CEs [7] --> Loop 6 0.03/0.18 * CEs [8] --> Loop 7 0.03/0.18 * CEs [9] --> Loop 8 0.03/0.18 * CEs [6] --> Loop 9 0.03/0.18 0.03/0.18 ### Ranking functions of CR eval1(A,B,C,D) 0.03/0.18 * RF of phase [6]: [A-B] 0.03/0.18 * RF of phase [7,8]: [2*A-B-C-1] 0.03/0.18 0.03/0.18 #### Partial ranking functions of CR eval1(A,B,C,D) 0.03/0.18 * Partial RF of phase [6]: 0.03/0.18 - RF of loop [6:1]: 0.03/0.18 A-B 0.03/0.18 * Partial RF of phase [7,8]: 0.03/0.18 - RF of loop [7:1]: 0.03/0.18 A-C 0.03/0.18 - RF of loop [8:1]: 0.03/0.18 A-B 0.03/0.18 0.03/0.18 0.03/0.18 ### Specialization of cost equations start/4 0.03/0.18 * CE 1 is refined into CE [10,11,12] 0.03/0.18 0.03/0.18 0.03/0.18 ### Cost equations --> "Loop" of start/4 0.03/0.18 * CEs [12] --> Loop 10 0.03/0.18 * CEs [11] --> Loop 11 0.03/0.18 * CEs [10] --> Loop 12 0.03/0.18 0.03/0.18 ### Ranking functions of CR start(A,B,C,D) 0.03/0.18 0.03/0.18 #### Partial ranking functions of CR start(A,B,C,D) 0.03/0.18 0.03/0.18 0.03/0.18 Computing Bounds 0.03/0.18 ===================================== 0.03/0.18 0.03/0.18 #### Cost of chains of eval1(A,B,C,D): 0.03/0.18 * Chain [[7,8],[6],9]: 2*it(6)+1*it(7)+0 0.03/0.18 Such that:it(7) =< A-C 0.03/0.18 aux(3) =< A-B 0.03/0.18 aux(4) =< 2*A-B-C 0.03/0.18 it(6) =< aux(3) 0.03/0.18 it(6) =< aux(4) 0.03/0.18 it(7) =< aux(4) 0.03/0.18 0.03/0.18 with precondition: [D=2,A>=B+1,A>=C+1] 0.03/0.18 0.03/0.18 * Chain [[7,8],9]: 1*it(7)+1*it(8)+0 0.03/0.18 Such that:it(8) =< A-B 0.03/0.18 it(7) =< A-C 0.03/0.18 aux(5) =< 2*A-B-C 0.03/0.18 it(7) =< aux(5) 0.03/0.18 it(8) =< aux(5) 0.03/0.18 0.03/0.18 with precondition: [D=2,A>=B+1,A>=C+1] 0.03/0.18 0.03/0.18 * Chain [[6],9]: 1*it(6)+0 0.03/0.18 Such that:it(6) =< A-B 0.03/0.18 0.03/0.18 with precondition: [D=2,C>=A,A>=B+1] 0.03/0.18 0.03/0.18 * Chain [9]: 0 0.03/0.18 with precondition: [D=2] 0.03/0.18 0.03/0.18 0.03/0.18 #### Cost of chains of start(A,B,C,D): 0.03/0.18 * Chain [12]: 0 0.03/0.18 with precondition: [] 0.03/0.18 0.03/0.18 * Chain [11]: 1*s(8)+0 0.03/0.18 Such that:s(8) =< A-B 0.03/0.18 0.03/0.18 with precondition: [C>=A,A>=B+1] 0.03/0.18 0.03/0.18 * Chain [10]: 3*s(12)+2*s(13)+0 0.03/0.18 Such that:s(9) =< A-B 0.03/0.18 s(10) =< A-C 0.03/0.18 s(11) =< 2*A-B-C 0.03/0.18 s(12) =< s(9) 0.03/0.18 s(13) =< s(10) 0.03/0.18 s(13) =< s(11) 0.03/0.18 s(12) =< s(11) 0.03/0.18 0.03/0.18 with precondition: [A>=B+1,A>=C+1] 0.03/0.18 0.03/0.18 0.03/0.18 Closed-form bounds of start(A,B,C,D): 0.03/0.18 ------------------------------------- 0.03/0.18 * Chain [12] with precondition: [] 0.03/0.18 - Upper bound: 0 0.03/0.18 - Complexity: constant 0.03/0.18 * Chain [11] with precondition: [C>=A,A>=B+1] 0.03/0.18 - Upper bound: A-B 0.03/0.18 - Complexity: n 0.03/0.18 * Chain [10] with precondition: [A>=B+1,A>=C+1] 0.03/0.18 - Upper bound: 5*A-3*B-2*C 0.03/0.18 - Complexity: n 0.03/0.18 0.03/0.18 ### Maximum cost of start(A,B,C,D): nat(A-C)*2+nat(A-B)*2+nat(A-B) 0.03/0.18 Asymptotic class: n 0.03/0.18 * Total analysis performed in 118 ms. 0.03/0.18 0.03/0.28 EOF