ebook img

Th ese Docteur de l'Universit e de Versailles Saint-Quentin Sid-Ahmed-Ali TOUATI Register ... PDF

106 Pages·2008·1.51 MB·English
by  
Save to my drive
Quick download
Download
Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.

Preview Th ese Docteur de l'Universit e de Versailles Saint-Quentin Sid-Ahmed-Ali TOUATI Register ...

(cid:0) UNIVERSITE de VERSAILLES SAINT(cid:1)QUENTIN Th(cid:0)ese pour obtenir le grade de Docteur de l(cid:1)Universit(cid:2)e de Versailles Saint(cid:3)Quentin Discipline(cid:0) INFORMATIQUE Pr(cid:1)esent(cid:1)ee et soutenue publiquement par Sid(cid:3)Ahmed(cid:3)Ali TOUATI Le (cid:2)(cid:3) juin (cid:2)(cid:4)(cid:4)(cid:2) Register Pressure in Instruction Level Parallelism Annexe de Th(cid:0)ese Jury(cid:0) Pr(cid:1) William Jalby Universit(cid:2)e de Versailles Directeur Dr(cid:1) Christine Eisenbeis INRIA Directrice Dr(cid:1) Alain Darte ENS de Lyon Rapporteur Pr(cid:1) Reinhard Wilhelm Universit(cid:2)e de Saarlandes Rapporteur Dr(cid:1) Michael Schlansker HP Labs(cid:1) Rapporteur Pr(cid:1) Dominique Barth Universit(cid:2)e de Versailles Examinateur Pr(cid:1) Fran(cid:3)cois Bodin Universit(cid:2)e de Rennes Examinateur Th(cid:4)ese pr(cid:2)epar(cid:2)ee au sein du laboratoire INRIA de Rocquencourt dans le projet A(cid:5) List of Tables (cid:6)(cid:5)(cid:1)(cid:6) Summary of our Contributions on Register Pressure in DAGs and acyclic CFGs (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:6)(cid:8) (cid:6)(cid:5)(cid:1)(cid:7) Summary of our Contributions on Register Pressure in Innermost Loops (cid:9)without branches(cid:10) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:7)(cid:11) B(cid:1)(cid:6) Operation Opcodes (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:12)(cid:6) C(cid:1)(cid:6) Optimal vs(cid:1) Greedy(cid:13)k in Loop Bodies and Loops Unrolled (cid:7) Times (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:14)(cid:15) C(cid:1)(cid:7) Optimal vs(cid:1) Greedy(cid:13)k in Loops Unrolled (cid:5) and (cid:15) Times (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:14)(cid:16) C(cid:1)(cid:5) Optimal vs(cid:1) Greedy(cid:13)k in Loops Unrolled (cid:16) and (cid:17) Times (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:14)(cid:17) C(cid:1)(cid:15) Optimal vs Approximated RS Reduction in Loop Bodies (cid:9)R (cid:18) (cid:6)(cid:10) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:14)(cid:14) C(cid:1)(cid:16) Optimal vs Approximated RS Reduction in Loop Unrolled (cid:7) Times (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:14)(cid:8) C(cid:1)(cid:17) Optimal vs Approximated RS Reduction in Loop Unrolled (cid:5) Times (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:8)(cid:11) C(cid:1)(cid:12) Optimal vs Approximated RS Reduction in Loop Unrolled (cid:15) Times (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:8)(cid:6) C(cid:1)(cid:14) Optimal vs(cid:1) Approximated Acyclic Su(cid:19)ciency (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:8)(cid:16) C(cid:1)(cid:8) Optimal Cyclic Register Su(cid:19)ciency (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:8)(cid:17) C(cid:1)(cid:6)(cid:11) SIRA Solutions (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:8)(cid:12) C(cid:1)(cid:6)(cid:6) Optimal Solutions (cid:0) Di(cid:20)erence between Hamiltonian SIRA and SIRA (cid:1) (cid:1) (cid:1) (cid:7)(cid:8)(cid:14) C(cid:1)(cid:6)(cid:7) SIRA Solutions using Heuristics (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:1) (cid:7)(cid:8)(cid:14) (cid:7)(cid:15)(cid:16) (cid:7)(cid:15)(cid:17) INDEX Appendix A Proofs A(cid:4)(cid:5) Proofs for DAGs A(cid:0)(cid:1)(cid:0)(cid:1) Lemma (cid:2)(cid:0)(cid:1) Given a DAG G (cid:18) (cid:9)V(cid:0)E(cid:0)(cid:1)(cid:10)(cid:21) then (cid:0)u (cid:1) VR (cid:0)(cid:2) (cid:1) (cid:22)(cid:9)G(cid:10)(cid:0) (cid:2)v (cid:1) pkill(cid:9)u(cid:10) (cid:0) (cid:2)(cid:9)v(cid:10)(cid:23)(cid:1)r(cid:9)v(cid:10) (cid:18) kill(cid:0)(cid:9)u(cid:10) (cid:9)A(cid:1)(cid:6)(cid:10) (cid:0)v (cid:1) pkill(cid:9)u(cid:10)(cid:0) (cid:2)(cid:2) (cid:1) (cid:22)(cid:9)G(cid:10) (cid:0) kill(cid:0)(cid:9)u(cid:10) (cid:18) (cid:2)(cid:9)v(cid:10)(cid:23)(cid:1)r(cid:9)v(cid:10) (cid:9)A(cid:1)(cid:7)(cid:10) Proof(cid:0) First(cid:21) we must recall that(cid:21) initially(cid:21) the delay of each arc e (cid:18) (cid:9)u(cid:0)v(cid:10) is equal to the latency of u(cid:21) i(cid:1)e(cid:1) (cid:1)(cid:9)e(cid:10) (cid:18) lat(cid:9)u(cid:10)(cid:1) The proof of (cid:9)A(cid:1)(cid:6)(cid:10) is derived directly from the de(cid:24)nition of pkill(cid:1) Since (cid:0) (cid:0) v (cid:1) pkill(cid:9)u(cid:10) (cid:18)(cid:3) (cid:0)v (cid:1) Cons(cid:9)u(cid:10) v (cid:3) v then the killing date of u must be the schedule date of some operation in pkill(cid:9)u(cid:10)(cid:1) Let us prove that (cid:0) (cid:0) (cid:0) (cid:0)u (cid:1) VR(cid:0) (cid:0)v (cid:1) Cons(cid:9)u(cid:10)(cid:4)pkill(cid:9)u(cid:10)(cid:0) (cid:2)(cid:2) (cid:1) (cid:22)(cid:9)G(cid:10) (cid:0) kill(cid:0)(cid:9)u(cid:10) (cid:18) (cid:2)(cid:9)v (cid:10)(cid:23)(cid:1)r(cid:9)v (cid:10) Suppose the converse is true(cid:1) (cid:0) (cid:0) (cid:2)v (cid:1) Cons(cid:9)u(cid:10)(cid:4)pkill(cid:9)u(cid:10) (cid:18)(cid:3) (cid:2)v (cid:1) pkill(cid:9)u(cid:10)(cid:4)v (cid:3) v (cid:0) (cid:0) Let lp(cid:9)v (cid:0)v(cid:10) be the longest path from v to v(cid:1) (cid:0) (cid:0) (cid:0) (cid:0) (cid:0) since lp(cid:9)v (cid:0)v(cid:10) (cid:5) lat(cid:9)v (cid:10) (cid:5) (cid:1)r(cid:9)v (cid:10) (cid:18)(cid:3) (cid:2)(cid:9)v(cid:10)(cid:4)(cid:2)(cid:9)v (cid:10) (cid:5) (cid:1)r(cid:9)v (cid:10) Since (cid:1)r(cid:9)v(cid:10) (cid:5) (cid:11)(cid:0) (cid:0) (cid:0) (cid:0) (cid:0) (cid:2)(cid:9)v(cid:10)(cid:23)(cid:1)r(cid:9)v(cid:10)(cid:4)(cid:2)(cid:9)v (cid:10) (cid:5) (cid:1)r(cid:9)v (cid:10) (cid:18)(cid:3) (cid:2)(cid:9)v(cid:10)(cid:23)(cid:1)r(cid:9)v(cid:10) (cid:5) (cid:2)(cid:9)v (cid:10)(cid:23)(cid:1)r(cid:9)v (cid:10) Then (cid:0) (cid:0) kill(cid:0)(cid:9)u(cid:10) (cid:5) (cid:2)(cid:9)v(cid:10)(cid:23)(cid:1)r(cid:9)v(cid:10) (cid:5) (cid:2)(cid:9)v (cid:10)(cid:23)(cid:1)r(cid:9)v (cid:10) (cid:7)(cid:15)(cid:12) (cid:7)(cid:15)(cid:14) APPENDIX A(cid:0) PROOFS (cid:0) u E In order to prove (cid:9)A(cid:1)(cid:7)(cid:10) we create an extended DAG Gv (cid:18) Gn (cid:21) for each (cid:0) v (cid:1) pkill(cid:9)u(cid:10)(cid:21) to enforce v to be the last read of the value u(cid:1) (cid:0)v (cid:1) pkill(cid:9)u(cid:10)(cid:4) (cid:0) (cid:0) fvg(cid:21) we add a serial arc e from v to v with latency (cid:1)(cid:9)e(cid:10) (cid:18) (cid:1)r(cid:9)v (cid:10) (cid:4) (cid:1)r(cid:9)v(cid:10)(cid:1) u (cid:0) (cid:0) Then(cid:21) any schedule (cid:2) (cid:1) (cid:22)(cid:9)Gv(cid:10) ensures (cid:2)(cid:9)v(cid:10) (cid:23) (cid:1)r(cid:9)v(cid:10) (cid:5) (cid:2)(cid:9)v (cid:10) (cid:23) (cid:1)r(cid:9)v (cid:10) which u means kill(cid:0)(cid:9)u(cid:10) (cid:18) (cid:2)(cid:9)v(cid:10)(cid:1) Let(cid:25)s prove that Gv is still a DAG(cid:1) Suppose the u converse is true(cid:21) i(cid:1)e(cid:1)(cid:21) (cid:2)u (cid:1) VR(cid:0) (cid:2)v (cid:1) pkill(cid:9)u(cid:10) such that Gv is cyclic(cid:1) Let (cid:0) (cid:0) C (cid:18) (cid:9)v(cid:0)(cid:6)(cid:6)(cid:6) (cid:0)v (cid:0)v(cid:10) be this circuit where the introduced arc is (cid:9)v (cid:0)v(cid:10)(cid:1) We know that all the potential killing operations pkill(cid:9)u(cid:10) of a value u are parallel in G(cid:1) (cid:0) (cid:0) (cid:0) However(cid:21) before introducing this arc(cid:21) a path P (cid:18) v v means that v (cid:3) v in G which is a contradiction(cid:1) Figure A(cid:1)(cid:6) shows the two extended DAGs associated with e(cid:1) The original DAG is presented in Figure A(cid:1)(cid:6)(cid:1) Here(cid:21) we assume that all read delay are null(cid:1) e has two potential killing operations fh(cid:0)ig(cid:21) so we have two extended DAG(cid:0) e e Gi ensures that i kills e(cid:21) and Gh that ensures that h kills e(cid:1) (cid:2) (cid:2) a b a b c d c d e f e f g h g h 0 0 i i (cid:1) (cid:1) e e (cid:0)a(cid:1)Gi (cid:0)b(cid:1)Gh Figure A(cid:1)(cid:6)(cid:0) Each Potential Killing Operation can Kill the Value y A(cid:0)(cid:1)(cid:0)(cid:3) Theorem (cid:2)(cid:0)(cid:1) Let G (cid:18) (cid:9)V(cid:0)E(cid:0)(cid:1)(cid:10) be a DAG and a schedule (cid:2) (cid:1) (cid:22)(cid:9)G(cid:10)(cid:1) If there is at least one excessive value that has more than one killer according to (cid:2)(cid:21) then there exists another schedule (cid:0) (cid:2) (cid:1) (cid:22)(cid:9)G(cid:10) such that(cid:0) (cid:0) RN(cid:0) (cid:9)G(cid:10) (cid:5) RN(cid:0)(cid:9)G(cid:10) (cid:0) and each excessive value is killed by a unique killer according to (cid:2) (cid:1) Proof(cid:0) A(cid:0)(cid:1)(cid:0) PROOFS FOR DAGS (cid:7)(cid:15)(cid:8) We suppose that there exists a schedule (cid:2) (cid:1) (cid:22)(cid:9)G(cid:10) with at least one excessive value that has more than one killer(cid:0) (cid:0) (cid:2)(cid:2) (cid:1) (cid:22)(cid:9)G(cid:10)(cid:0) (cid:2)u (cid:1) EV (cid:9)G(cid:10) (cid:0) jkillers(cid:0)(cid:9)u(cid:10)j (cid:5) (cid:6) (cid:0) We show in this proof how to build a new schedule (cid:2) (cid:1) (cid:22)(cid:9)G(cid:10) such that u is (cid:0) killed by a unique killer and (cid:2) needs at least as many registers as (cid:2) does(cid:1) Suppose that u has j killers according to (cid:2)(cid:21) and we note them(cid:0) killers(cid:0)(cid:9)u(cid:10) (cid:18) fk(cid:2)(cid:0)(cid:6)(cid:6)(cid:6)(cid:0)kjg with kill(cid:0)(cid:9)u(cid:10) (cid:18) (cid:2)(cid:9)k(cid:2)(cid:10) (cid:23) (cid:1)r(cid:9)k(cid:2)(cid:10) (cid:18) (cid:6)(cid:6)(cid:6) (cid:18) (cid:2)(cid:9)kj(cid:10) (cid:23)(cid:1)r(cid:9)kj(cid:10)(cid:1) We choose one killer (cid:0) within this set to be the only one killer of u according to (cid:2) (cid:21) say k(cid:2)(cid:1) We build (cid:0) (cid:2) by (cid:26)shifting(cid:27) down k(cid:2) and all its descendants with a strictly positive factor(cid:21) say (cid:6)(cid:0) (cid:0) (cid:2)(cid:9)v(cid:10)(cid:23)(cid:6) if v (cid:1)(cid:7) k(cid:2) (cid:0)v (cid:1) V (cid:2) (cid:9)v(cid:10) (cid:18) (cid:0) (cid:2)(cid:9)v(cid:10) otherwise (cid:0) Now(cid:21) we prove that (cid:2) is valid and needs at least as many registers as (cid:2) does(cid:21) (cid:0) and that k(cid:2) is the only killer of u according to (cid:2) (cid:1) (cid:0) (cid:2) is valid(cid:0) we can easily check that any dependence (cid:0)e (cid:18) (cid:9)v(cid:2)(cid:0)v(cid:3)(cid:10) (cid:1) E is (cid:0) satis(cid:24)ed by (cid:2) (cid:0) (cid:6)(cid:1) if both v(cid:2)(cid:0)v(cid:3) (cid:8)(cid:1)(cid:7) k(cid:2)(cid:21) then (cid:0) (cid:0) (cid:2) (cid:9)v(cid:3)(cid:10)(cid:4)(cid:2) (cid:9)v(cid:2)(cid:10) (cid:18) (cid:2)(cid:9)v(cid:3)(cid:10)(cid:4)(cid:2)(cid:9)v(cid:2)(cid:10) (cid:5) (cid:1)(cid:9)e(cid:10) (cid:7)(cid:1) in the case where v(cid:2) (cid:8)(cid:1)(cid:7) k(cid:2) (cid:9) v(cid:3) (cid:1)(cid:7) k(cid:2) (cid:0) (cid:0) (cid:2) (cid:9)v(cid:3)(cid:10)(cid:4)(cid:2) (cid:9)v(cid:2)(cid:10) (cid:18) (cid:2)(cid:9)v(cid:3)(cid:10)(cid:23)(cid:6)(cid:4)(cid:2)(cid:9)v(cid:2)(cid:10) (cid:5) (cid:1)(cid:9)e(cid:10) (cid:5)(cid:1) the case of v(cid:2) (cid:1)(cid:7) k(cid:2) (cid:9) v(cid:3) (cid:8)(cid:1)(cid:7) k(cid:2) is impossible because the arc e (cid:18) (cid:9)v(cid:2)(cid:0)v(cid:3)(cid:10) exists(cid:28) (cid:15)(cid:1) in the case where both v(cid:2)(cid:0)v(cid:3) (cid:1)(cid:7) k(cid:2)(cid:21) then (cid:0) (cid:0) (cid:2) (cid:9)v(cid:3)(cid:10)(cid:4)(cid:2) (cid:9)v(cid:2)(cid:10) (cid:18) (cid:2)(cid:9)v(cid:3)(cid:10)(cid:23)(cid:6)(cid:4)(cid:2)(cid:9)v(cid:2)(cid:10)(cid:4)(cid:6) (cid:5) (cid:1)(cid:9)e(cid:10) (cid:0) RN(cid:0) (cid:5) RN(cid:0)(cid:0) let t be an excessive clock cycle according to (cid:2)(cid:21) then all excessive values are simultaneously alive during t(cid:0) (cid:0) (cid:0)v (cid:1) EV (cid:9)G(cid:10) (cid:0) t (cid:1) LT(cid:0)(cid:9)v(cid:10) (cid:0) (cid:18)(cid:3) (cid:0)v (cid:1) EV (cid:9)G(cid:10) (cid:0) (cid:2)(cid:9)v(cid:10)(cid:23)(cid:1)w(cid:9)v(cid:10) (cid:3) t (cid:10) kill(cid:0)(cid:9)v(cid:10) Here(cid:21) we want to prove thatthese excessive values accordingto (cid:2) are stillalive (cid:0) (cid:0) during t according to (cid:2) (cid:1) Any value v (cid:1) EV (cid:9)G(cid:10) has the same de(cid:24)nition date (cid:0) in (cid:2) as in (cid:2)(cid:21) this is because only (cid:7) k(cid:2) nodes have been shifted down and (cid:0) (cid:0) (cid:0)v (cid:1) EV (cid:9)G(cid:10)(cid:4)fug (cid:0) v (cid:8)(cid:1)(cid:7) k(cid:2) (cid:7)(cid:16)(cid:11) APPENDIX A(cid:0) PROOFS (cid:0) otherwise LT(cid:0)(cid:9)u(cid:10) (cid:11) LT(cid:0)(cid:9)v(cid:10) which is in contradiction with u(cid:0)v (cid:1) EV (cid:9)G(cid:10)(cid:1) Then (cid:0) (cid:0) (cid:0)v (cid:1) EV (cid:9)G(cid:10) (cid:0) (cid:2) (cid:9)v(cid:10) (cid:18) (cid:2)(cid:9)v(cid:10) (cid:0) However(cid:21) thekillingdateofanyexcessivevaluev (cid:1) EV (cid:9)G(cid:10)couldbeincreased by the translation factor (cid:6)(cid:0) (cid:0) (cid:0) (cid:0)v (cid:1) EV (cid:9)G(cid:10) (cid:0) kill(cid:0)(cid:9)v(cid:10) (cid:10) kill(cid:0) (cid:9)v(cid:10) which gives (cid:0) (cid:0) (cid:0) (cid:0)v (cid:1) EV (cid:9)G(cid:10) (cid:0) (cid:2) (cid:9)v(cid:10) (cid:3) t (cid:10) kill(cid:0) (cid:9)v(cid:10) (cid:0) (cid:0) (cid:18)(cid:3) RN(cid:0) (cid:5) jEV (cid:9)G(cid:10)j (cid:18) RN(cid:0)(cid:9)G(cid:10) k(cid:2) is the unique killer of u(cid:0) since k(cid:2) (cid:1) pkillG(cid:9)u(cid:10)(cid:21) there is no other poten(cid:13) tial killer k (cid:1) pkill(cid:9)u(cid:10)(cid:9)k (cid:8)(cid:18) k(cid:2) such that k (cid:1)(cid:7) k(cid:2)(cid:1) Otherwise(cid:21) k(cid:2) cannot kill u (cid:0) (cid:0) (cid:9)pkill operations property(cid:10)(cid:1) In this case (cid:2) (cid:9)k(cid:10) (cid:18) (cid:2)(cid:9)k(cid:10) while (cid:2) (cid:9)k(cid:2)(cid:10) (cid:18) (cid:2)(cid:9)k(cid:10)(cid:23)(cid:6)(cid:1) We conclude (cid:0) (cid:0) (cid:0) (cid:0)k (cid:1) pkillG(cid:9)u(cid:10)(cid:4)fk(cid:2)g (cid:2) (cid:9)k(cid:2)(cid:10)(cid:23)(cid:1)r(cid:9)k(cid:2)(cid:10) (cid:5) (cid:2) (cid:9)k(cid:10)(cid:23)(cid:1)r(cid:9)k(cid:10) (cid:18)(cid:3) killers(cid:0) (cid:9)u(cid:10) (cid:18) fk(cid:2)g Finally(cid:21) generalizing to an arbitrary number of excessive values like u (cid:9)those that have more than one killer and that are simultaneously alive with u(cid:10) (cid:0) is obviously done by iteratively building new (cid:2) schedule for each of these values(cid:1) However(cid:21) we must take a precaution(cid:1) Indeed(cid:21) if we treat an excessive value u(cid:2) by shifting down one of its killers(cid:21) and then we proceed to another excessive value u(cid:3)(cid:21) we cannot guarantee that shifting down u(cid:3)(cid:25)s killer would not shift down other u(cid:2) consumers (cid:9)and hence(cid:21) u(cid:2) becomes killed by multiple consumers(cid:10)(cid:1) To break this recursivity(cid:21) we proceed as follows(cid:1) When we treat an excessive value u by shiftingdown its killerk(cid:9)v(cid:10)(cid:21) we add an arc to the DAG from each potential killer of u (cid:9)except k(cid:9)u(cid:10)(cid:10) to k(cid:9)u(cid:10)(cid:1) Hence(cid:21) when we iterate over the remaining excessive values(cid:21) any shifting down action would always guarantee the existence of a unique killer for the previously treated values(cid:1) The added arcs does not introduce a circuit since they de(cid:24)ne a strict order between the potential killing nodes(cid:1) y Example A(cid:1)(cid:2)(cid:1)(cid:2) The excessive value b in the schedule presented in Figure (cid:0)(cid:1)(cid:2) on page (cid:3)(cid:2) has two killers fe(cid:0)fg (cid:4)DAG in Figure (cid:0)(cid:1)(cid:5) on page (cid:3)(cid:5)(cid:6)(cid:1) Let us choose f to be the only killer of b(cid:1) A new schedule for this aim is presented in Figure A(cid:1)(cid:2) where f and all its descendants are shifted down by one clock cycle(cid:1) The register need of this schedule is still equal to (cid:0)(cid:1) One can remark that the de(cid:7)nition date of each excessive value does not change(cid:8) while the killing date of some excessive values (cid:4)b and d(cid:6) is shifted down by one(cid:1) The new schedule ensures that each excessive value has a unique killer(cid:1) A(cid:0)(cid:1)(cid:0)(cid:4) Lemma (cid:2)(cid:0)(cid:3) (cid:0) (cid:0) E Let G (cid:18) (cid:9)V(cid:0)E(cid:0)(cid:1)(cid:10) be a DAG and k a killing function(cid:1) The extended graph G (cid:18) G(cid:3)kn produced by Algorithm (cid:6) is a DAG(cid:1) Also(cid:21) (cid:0) (cid:0)u(cid:0)v (cid:1) MAk (cid:0)(cid:2) (cid:1) (cid:22)(cid:9)G(cid:10) LT(cid:0)(cid:9)u(cid:10)(cid:12)LT(cid:0)(cid:9)v(cid:10) (cid:8)(cid:18) (cid:7) where MAk is a maximal antichain in DVk(cid:9)G(cid:10)(cid:1) A(cid:0)(cid:1)(cid:0) PROOFS FOR DAGS (cid:7)(cid:16)(cid:6) 0: a ; b ; c LT(a) LT(b) 3: 4: d ; g LT(d) 8: 9: e 10: f LT(e) 11: 12: LT(f) 13: h ; i LT(i) 17: LT(h) 29: time (cid:4)(cid:5)(cid:6) (cid:1) Figure A(cid:1)(cid:7)(cid:0) Example for Theorem (cid:15)(cid:1)(cid:6) Proof Proof(cid:0) (cid:0) We proceed by induction(cid:1) We prove that after exiting Algorithm (cid:6)(cid:21) G is still a DAG(cid:1) We prove also that the algorithm makes all values in MAk satisfying one of the conditions (cid:9)(cid:15)(cid:1)(cid:15)(cid:10)(cid:21) (cid:9)(cid:15)(cid:1)(cid:16)(cid:10) or (cid:9)(cid:15)(cid:1)(cid:17)(cid:10)(cid:1) For this last condition(cid:21) if two (cid:0) values do not satisfy it in the DAG G(cid:3)k(cid:21) they cannot satisfy it in G (cid:0) this is because the killing operations has been (cid:24)xed in G(cid:3)k(cid:1) So(cid:21) if u(cid:0)v do not satisfy Condition (cid:9)(cid:15)(cid:1)(cid:17)(cid:10)(cid:21) Algorithm (cid:6) can only force them to satisfy Condition (cid:9)(cid:15)(cid:1)(cid:15)(cid:10) or Condition (cid:9)(cid:15)(cid:1)(cid:16)(cid:10)(cid:1) We prove also the following property (cid:0) (cid:0)u(cid:0)v (cid:1) MAk (cid:13) k(cid:9)v(cid:10) (cid:3) u(cid:14)k(cid:9)u(cid:10) (cid:3) v in G (cid:1) (cid:2) which is the same as proving that Algorithm (cid:6) guarantees that all values in (cid:0) MAk are forced to be simultaneously alive in G (cid:0) (cid:0) (cid:0)u(cid:0)v (cid:1) MAk(cid:4)u (cid:15) v in DVk(cid:9)G(cid:10) Initially(cid:21) this is correct because u(cid:0)v (cid:1) MAk (cid:18)(cid:3) u (cid:8)(cid:1)(cid:7)R k(cid:9)v(cid:10)(cid:9)v (cid:8)(cid:1)(cid:7)R k(cid:9)u(cid:10)(cid:1) In (cid:0) this proof(cid:21) we note Gi the graph built after exiting iteration i(cid:1) Suppose that (cid:0) after exiting iteration i(cid:4)(cid:6)(cid:21) Gi(cid:4)(cid:2) is still a DAG and (cid:0) (cid:0)u(cid:0)v (cid:1) MAk (cid:13) k(cid:9)v(cid:10) (cid:3) u (cid:14) k(cid:9)u(cid:10) (cid:3) v in Gi(cid:4)(cid:2) (cid:1) (cid:2) Let ui and vi be the two chosen values at iteration i which do not satisfy (cid:0) any of the conditions(cid:1) Let us prove now that Gi is still a DAG and the two chosen values ui(cid:0)vi (cid:1) MAk satisfy one of the conditions after exiting iteration i(cid:1) Furthermore(cid:21) we prove that after exiting this iteration (cid:0) (cid:0)w (cid:1) MAk(cid:4)k(cid:9)ui(cid:10) (cid:3) w (cid:14) k(cid:9)vi(cid:10) (cid:3) w in Gi Our algorithm introduces serial arcs in four cases(cid:0) (cid:7)(cid:16)(cid:7) APPENDIX A(cid:0) PROOFS (cid:0) (cid:6)(cid:1) uijjvi in Gi(cid:4)(cid:2)(cid:21) then (cid:0) (cid:16) if (cid:13)(cid:9)k(cid:9)ui(cid:10) (cid:3) vi(cid:10)(cid:21) the two introduced arcs e (cid:18) (cid:9)ui(cid:0)vi(cid:10)(cid:0)e (cid:18) (cid:9)vi(cid:0)k(cid:9)ui(cid:10)(cid:10) (cid:0) cannotintroducecircuit(cid:21)becauseui (cid:3) k(cid:9)ui(cid:10)inGi(cid:4)(cid:2)(cid:21)seeFigureA(cid:1)(cid:5)(cid:9)a(cid:10)(cid:1) Now they are satisfying Cond(cid:1) (cid:9)(cid:15)(cid:1)(cid:16)(cid:10)(cid:1) Also(cid:21) after introducing these arcs(cid:21) the the following property is satis(cid:24)ed(cid:0) (cid:0) (cid:0)w (cid:1) MAk(cid:4)k(cid:9)ui(cid:10) (cid:3) w (cid:14) k(cid:9)vi(cid:10) (cid:3) w in Gi Suppose the converse is true(cid:21) i(cid:1)e(cid:1)(cid:21) (cid:0) (cid:2)w (cid:1) MAk(cid:4)k(cid:9)ui(cid:10) (cid:3) w (cid:14) k(cid:9)vi(cid:10) (cid:3) w in Gi (cid:0) (cid:0) If k(cid:9)ui(cid:10) (cid:3) w in Gi(cid:21) (cid:18)(cid:3) k(cid:9)ui(cid:10) (cid:3) w in Gi(cid:4)(cid:2) because we have not introduced a serial arc from k(cid:9)ui(cid:10)(cid:21) which is impossible because of induction hypothesis(cid:1) (cid:0) (cid:0) If k(cid:9)vi(cid:10) (cid:3) w in Gi(cid:21) (cid:18)(cid:3) k(cid:9)vi(cid:10) (cid:3) w in Gi(cid:4)(cid:2) because we have not introduced a serial arc from k(cid:9)vi(cid:10)(cid:21) which is also impossible because of induction hypothesis(cid:28) (cid:16) else (cid:13)(cid:9)k(cid:9)vi(cid:10) (cid:3) ui(cid:10) certainly(cid:21) because otherwise (cid:0) vi (cid:3) k(cid:9)vi(cid:10) (cid:3) ui(cid:9)ui (cid:3) k(cid:9)ui(cid:10) (cid:3) vi (cid:18)(cid:3) ui (cid:3) vi(cid:9)vi (cid:3) ui in Gi(cid:4)(cid:2) (cid:9)impossible(cid:10) (cid:0) Then the introduced arcs e (cid:18) (cid:9)vi(cid:0)ui(cid:10)(cid:0)e (cid:18) (cid:9)ui(cid:0)k(cid:9)vi(cid:10)(cid:10) cannot intro(cid:13) (cid:0) duce any circuit because vi (cid:3) k(cid:9)vi(cid:10) in Gi(cid:4)(cid:2)(cid:21) see Figure A(cid:1)(cid:5)(cid:9)b(cid:10)(cid:1) Now they are satisfying Cond(cid:1) (cid:9)(cid:15)(cid:1)(cid:15)(cid:10)(cid:1) Also(cid:21) after introducing these arcs(cid:21) the following property is satis(cid:24)ed(cid:0) (cid:0) (cid:0)w (cid:1) MAk(cid:4)k(cid:9)ui(cid:10) (cid:3) w (cid:14) k(cid:9)vi(cid:10) (cid:3) w in Gi The proof is similar to the above case(cid:28) (cid:0) (cid:0) (cid:7)(cid:1) if vi (cid:3) ui in Gi(cid:4)(cid:2)(cid:21) then by induction hypothesis (cid:13)(cid:9)k(cid:9)vi(cid:10) (cid:3) ui(cid:10) in Gi(cid:4)(cid:2)(cid:1) (cid:0) The two introduced arcs e (cid:18) (cid:9)vi(cid:0)ui(cid:10) and e (cid:18) (cid:9)ui(cid:0)k(cid:9)vi(cid:10)(cid:10) cannot cause any circuit(cid:1) Now they are satisfying Cond(cid:1) (cid:9)(cid:15)(cid:1)(cid:15)(cid:10)(cid:1) Also(cid:21) after introducing these arcs(cid:21) (cid:0) (cid:0)w (cid:1) MAk(cid:4)k(cid:9)ui(cid:10) (cid:3) w (cid:14) k(cid:9)vi(cid:10) (cid:3) w in Gi The proof is similar to the case above(cid:28) (cid:0) (cid:5)(cid:1) ui (cid:3) vi in Gi(cid:4)(cid:2)(cid:21) this case is similar to above(cid:1) Now they are satisfying Cond(cid:1) (cid:9)(cid:15)(cid:1)(cid:16)(cid:10)(cid:1) (cid:3) After n (cid:18) jMAkj iterations(cid:21) we conclude that (cid:0) (cid:0)u(cid:0)v (cid:1) MAk u(cid:0)v satisfy one of the conditions (cid:9)(cid:15)(cid:1)(cid:15)(cid:10)(cid:21) (cid:9)(cid:15)(cid:1)(cid:16)(cid:10) or (cid:9)(cid:15)(cid:1)(cid:17)(cid:10) (cid:0) and then (cid:0)u(cid:0)v (cid:1) MAk (cid:0)(cid:2) (cid:1) (cid:22)(cid:9)G(cid:10) LT(cid:0)(cid:9)u(cid:10)(cid:12)LT(cid:0)(cid:9)v(cid:10) (cid:8)(cid:18) (cid:7) y

Description:
Register Pressure in Instruction Level Parallelism. Annexe de Th ese. Jury : Pr. William Jalby. Universit e de .. Our algorithm introduces serial arcs in four cases : with R+1 registers with a hamiltonian reuse pattern. Hamiltonian
See more

The list of books you might like

Most books are stored in the elastic cloud where traffic is expensive. For this reason, we have a limit on daily download.