12.07.2015 Views

Calcul des etats atteignables de programmes Esterel partitionne ...

Calcul des etats atteignables de programmes Esterel partitionne ...

Calcul des etats atteignables de programmes Esterel partitionne ...

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

62 CHAPITRE 5. CALCUL DES ETATS ATTEIGNABLES PARTITIONNÉ1 reachable ← ι2 pending ← ι3 −− <strong>Calcul</strong> <strong>de</strong> area 0 voir algorithme 5.24 area ← area 05 tantque ( pending ≠ ∅ ) faire6 si ( (pending ∩ area) = ∅ ) alors7 −− <strong>Calcul</strong> <strong>de</strong> area ′ tel que area ′ ⊃ area voir algorithme 5.38 area ← area ′9 fin si10 domain ← pending ∩ area11 new ← Image ∆ (Υ, domain) reachable12 pending ← (pending area) ∪ new13 reachable ← reachable ∪ new14 fin tantqueAlgorithme 5.1 – Algorithme partitionnéLa valeur initiale area 0 <strong>de</strong> l’ensemble area (ligne 4) est calculée à partir du graphe <strong>de</strong> flot <strong>de</strong>contrôle comme nous le verrons par la suite. Nous pouvons remarquer que si area 0 désignel’ensemble B K alors cet algorithme est i<strong>de</strong>ntique à l’algorithme 2.1 présenté à la section 2.3.Tant que <strong><strong>de</strong>s</strong> nouveaux états sont découverts à l’intérieur <strong>de</strong> l’ensemble area, aucune frontièren’a besoin d’être ouverte (ligne 6). Dans le cas contraire, certaines frontières du graphe sontouvertes. Un nouvel ensemble area ′ contenant strictement l’ancien ensemble area est alors calculéà partir du graphe (ligne 8).5.1.1 Initialisations dans le graphe <strong>de</strong> contrôle (calcul <strong>de</strong> area 0 )Nous supposons que l’arbre syntaxique du programme est donné dans T. La phase d’initialisationconsiste à construire le graphe <strong>de</strong> flot <strong>de</strong> contrôle afin d’obtenir un ensemble d’arcsfrontièrefermés initial. A partir <strong>de</strong> ces conditions initiales, l’ensemble area 0 est initialisé.1 (I , O , N , E , F) ← G(T)2 R ← Register〈N〉3 inner ← Closure (N,E) (I)4 R + ← Register〈inner〉5 area 0 ← NOr(R R + )Algorithme 5.2 – <strong>Calcul</strong> <strong>de</strong> area 0La première étape consiste à construire le graphe (ligne 1). A partir du graphe, nous construisonsl’ensemble inner contenant l’ensemble <strong><strong>de</strong>s</strong> noeuds situés à l’intérieur <strong>de</strong> la frontière. Cetensemble est construit par fermeture transitive en partant <strong><strong>de</strong>s</strong> noeuds initiaux I et en passantpar les arcs <strong>de</strong> E (ligne 3). L’ensemble R contient la totalité <strong><strong>de</strong>s</strong> registres du graphe (ligne 2).Seuls les registres situés à l’intérieur <strong>de</strong> la frontière peuvent être actifs. L’ensemble R + <strong><strong>de</strong>s</strong> registresactifs est construit à partir <strong>de</strong> l’ensemble inner à la ligne 4. Finalement, area 0 est définicomme l’ensemble <strong><strong>de</strong>s</strong> états tels qu’aucun registre exceptés ceux <strong>de</strong> R + n’est actif (ligne 5).

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!