Revision e39f5319
Added by Xavier Thirioux almost 10 years ago
src/clocks.ml | ||
---|---|---|
98 | 98 |
let rec print_ck_long fmt ck = |
99 | 99 |
match ck.cdesc with |
100 | 100 |
| Carrow (ck1,ck2) -> |
101 |
fprintf fmt "%a->%a" print_ck_long ck1 print_ck_long ck2
|
|
101 |
fprintf fmt "%a -> %a" print_ck_long ck1 print_ck_long ck2
|
|
102 | 102 |
| Ctuple cklist -> |
103 | 103 |
fprintf fmt "(%a)" |
104 | 104 |
(fprintf_list ~sep:" * " print_ck_long) cklist |
... | ... | |
529 | 529 |
let ck = simplify ck in |
530 | 530 |
match ck.cdesc with |
531 | 531 |
| Carrow (ck1,ck2) -> |
532 |
fprintf fmt "%a->%a" aux ck1 aux ck2
|
|
532 |
fprintf fmt "%a -> %a" aux ck1 aux ck2
|
|
533 | 533 |
| Ctuple cklist -> |
534 | 534 |
fprintf fmt "(%a)" |
535 | 535 |
(fprintf_list ~sep:" * " aux) cklist |
src/liveness.ml | ||
---|---|---|
192 | 192 |
try |
193 | 193 |
let disjoint_live = Disjunction.CISet.inter disjoint live in |
194 | 194 |
let reuse = Disjunction.CISet.max_elt disjoint_live in |
195 |
let reuse' = Hashtbl.find ctx.policy reuse.var_id in |
|
195 | 196 |
begin |
196 | 197 |
IdentDepGraph.add_edge ctx.dep_graph var.var_id reuse.var_id; |
197 |
Hashtbl.add ctx.policy var.var_id (Hashtbl.find ctx.policy reuse.var_id); |
|
198 |
if reuse != reuse' then IdentDepGraph.add_edge ctx.dep_graph reuse.var_id reuse'.var_id; |
|
199 |
Hashtbl.add ctx.policy var.var_id reuse'; |
|
198 | 200 |
ctx.evaluated <- Disjunction.CISet.add var ctx.evaluated; |
199 | 201 |
(*Format.eprintf "%s reused by live@." var.var_id;*) |
200 | 202 |
end |
... | ... | |
202 | 204 |
try |
203 | 205 |
let dead = Disjunction.CISet.filter (fun v -> is_graph_root v.var_id ctx.dep_graph) quasi_dead in |
204 | 206 |
let reuse = Disjunction.CISet.choose dead in |
207 |
let reuse' = Hashtbl.find ctx.policy reuse.var_id in |
|
205 | 208 |
begin |
206 | 209 |
IdentDepGraph.add_edge ctx.dep_graph var.var_id reuse.var_id; |
207 |
Hashtbl.add ctx.policy var.var_id (Hashtbl.find ctx.policy reuse.var_id); |
|
210 |
if reuse != reuse' then IdentDepGraph.add_edge ctx.dep_graph reuse.var_id reuse'.var_id; |
|
211 |
Hashtbl.add ctx.policy var.var_id reuse'; |
|
208 | 212 |
ctx.evaluated <- Disjunction.CISet.add var ctx.evaluated; |
209 | 213 |
(*Format.eprintf "%s reused by dead %a@." var.var_id Disjunction.pp_ciset dead;*) |
210 | 214 |
end |
src/modules.ml | ||
---|---|---|
129 | 129 |
(*Format.eprintf "Error: %s@." msg;*) |
130 | 130 |
raise (Error (loc, Unknown_library basename)) |
131 | 131 |
end |
132 |
| Corelang.Error (_, msg) as exc -> raise (Corelang.Error (loc, msg))
|
|
132 |
| Corelang.Error (_, msg) -> raise (Corelang.Error (loc, msg)) |
|
133 | 133 |
|
134 | 134 |
let import_dependency loc (local, dep) = |
135 | 135 |
try |
src/types.ml | ||
---|---|---|
83 | 83 |
fprintf fmt "%a -> %a" print_ty ty1 print_ty ty2 |
84 | 84 |
| Ttuple tylist -> |
85 | 85 |
fprintf fmt "(%a)" |
86 |
(Utils.fprintf_list ~sep:"*" print_ty) tylist
|
|
86 |
(Utils.fprintf_list ~sep:" * " print_ty) tylist
|
|
87 | 87 |
| Tenum taglist -> |
88 | 88 |
fprintf fmt "enum {%a }" |
89 | 89 |
(Utils.fprintf_list ~sep:", " pp_print_string) taglist |
Also available in: Unified diff
corrected a bug when activating optimization (-O 3) (edge missing in a dep graph)
git-svn-id: https://cavale.enseeiht.fr/svn/lustrec/lustre_compiler/trunk@448 041b043f-8d7c-46b2-b46e-ef0dd855326e