diff --git a/Makefile.version b/Makefile.version index 8110a3b180419f2598ad13f26e18ba327f801fbf..d851694973061edebe5466bcdc33b0cd8e838e81 100644 --- a/Makefile.version +++ b/Makefile.version @@ -21,4 +21,4 @@ src/lv6version.ml: Makefile echo "let commit = \"$(shell utils/get_commit_number)\"" >> $@ echo "let sha_1 = \"$(shell utils/get_sha_1)"\">> $@ echo "let str = (branch ^ \".\" ^ commit ^ \" (\" ^ sha_1 ^ \")\")">> $@ - echo "let maintainer = \"jahier@imag.fr\"">> $@ + echo "let maintainer = \"erwan.jahier@univ-grenoble-alpes.fr\"">> $@ diff --git a/_oasis b/_oasis index 3670dbe49a053c3f9cc503dfc912095f237ec259..38347cb859978842a0d73fa9522eda7ca82da4da 100644 --- a/_oasis +++ b/_oasis @@ -1,6 +1,6 @@ OASISFormat: 0.4 Name: lustre-v6 -Version: 1.709 +Version: 1.710 Synopsis: The Lustre V6 Verimag compiler Description: This package contains: (1) lus2lic: the (current) name of the compiler (and interpreter via -exec). diff --git a/src/assertion2lutin.ml b/src/assertion2lutin.ml index 46a97f73c03bbfcc2c1905ae312167e5c734d089..3b39428b76f3fa200903a9ad1754063a70a993a9 100644 --- a/src/assertion2lutin.ml +++ b/src/assertion2lutin.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 26/02/2015 (at 11:18) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:26) by Erwan Jahier> *) open Lxm @@ -35,7 +35,7 @@ and (string_of_by_pos_op_eff: Lic.by_pos_op srcflagged -> Lic.val_exp list -> st let tuple_par vel = "(" ^ (tuple vel) ^ ")" in let str = match posop.it,vel with - | CONST c,_ -> LicDump.string_of_const_eff c + | CONST c,_ -> LicDump.string_of_const_eff true c | CALL ({it=("Lustre","not"),[]}), [ve1] | PREDEF_CALL ({it=("Lustre","not"),[]}), [ve1] -> ((AstPredef.op2string AstPredef.NOT_n) ^ " " ^ @@ -78,7 +78,7 @@ and (string_of_by_pos_op_eff: Lic.by_pos_op srcflagged -> Lic.val_exp list -> st ((string_of_node_key nk) ^ (tuple_par vel)) ) - | CONST_REF idl, _ -> LicDump.dump_long idl + | CONST_REF idl, _ -> LicDump.dump_long true idl | VAR_REF id, _ -> id | PRE, [ve] -> if is_not_atomic ve.ve_core then raise Not_handled else diff --git a/src/ast2lic.ml b/src/ast2lic.ml index 12a10601835bd13ea828316625f82de1b30825a5..734c697593b8fe75daf57b726b11e9fb8a420c62 100644 --- a/src/ast2lic.ml +++ b/src/ast2lic.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 21/06/2017 (at 16:25) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 16:45) by Erwan Jahier> *) open Lxm @@ -41,7 +41,7 @@ let (add_pack_name : IdSolver.t -> Lxm.t -> Lv6Id.idref -> Lv6Id.idref) = match Lv6Id.pack_of_idref cc with | Some _ -> cc | None -> - let id = Lv6Id.of_idref cc in + let id = Lv6Id.of_idref false cc in let pn = AstTabSymbol.find_pack_of_const id_solver.global_symbols id lxm in @@ -74,10 +74,11 @@ and (type_check_equation: IdSolver.t -> Lxm.t -> Lic.left list -> " for the left-hand-side, and \n***\t" ^ (string_of_int (List.length right_part)) ^ " for the right-hand-side (in " ^ - (String.concat "," - (List.map LicDump.string_of_leff lpl_eff)) ^ " = " ^ - (LicDump.string_of_val_exp_eff ve_eff) ^ - ")\n" + (String.concat + "," + (List.map (LicDump.string_of_leff false) lpl_eff)) + ^ " = " ^ + (LicDump.string_of_val_exp_eff false ve_eff) ^ ")\n" )) else List.iter2 @@ -555,7 +556,7 @@ and translate_by_name_op id_solver op s = let to_long idref = match Lv6Id.pack_of_idref idref with | None -> (* If no pack name is provided, we lookup it in the symbol table *) - let id = Lv6Id.of_idref idref in + let id = Lv6Id.of_idref false idref in let pn = AstTabSymbol.find_pack_of_type id_solver.global_symbols id op.src in Lv6Id.make_long pn idref.id_id | Some pn -> Lv6Id.make_long pn idref.id_id diff --git a/src/astCore.ml b/src/astCore.ml index 84a5ba5ebdae56955916e28f7d01140de3f5e2da..8eb48a426c28ba17bb9f69f548f68326fdb12ddf 100644 --- a/src/astCore.ml +++ b/src/astCore.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 26/02/2015 (at 11:19) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:45) by Erwan Jahier> *) (** (Raw) Abstract syntax tree of source Lustre Core programs. *) @@ -201,7 +201,7 @@ let rec string_of_type_exp x = | Bool_type_exp -> "bool" | Int_type_exp -> "int" | Real_type_exp -> "real" - | Named_type_exp id -> (Lv6Id.string_of_idref id) + | Named_type_exp id -> (Lv6Id.string_of_idref false id) | Array_type_exp (te, sz) -> (string_of_type_exp te) ^ "^ ..." diff --git a/src/astV6Dump.ml b/src/astV6Dump.ml index c4d7dde455a5143567fb06b03b9c766be68ee405..2f755c701563c9c9a8cae8a56cac94ade4b3723b 100644 --- a/src/astV6Dump.ml +++ b/src/astV6Dump.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 25/02/2016 (at 17:29) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 16:52) by Erwan Jahier> *) open Lxm @@ -23,7 +23,7 @@ let rec (op2string : AstCore.by_pos_op -> string) = | (WHEN_n _ce) -> "when" | (HAT_n ) -> "^" | (CONCAT_n ) -> "|" - | (IDENT_n idref) -> Lv6Id.string_of_idref idref + | (IDENT_n idref) -> Lv6Id.string_of_idref false idref | (FBY_n ) -> "fby" | (WITH_n(_,_,_)) -> "with" | (TUPLE_n ) -> assert false @@ -285,7 +285,7 @@ and dump_var_decl (os: Format.formatter) (vinfo: var_info ) = ( match vinfo.var_clock with Base -> () | NamedClock({it=cc,id;src=lxm}) -> - let cc_str = Lv6Id.long_to_string cc in + let cc_str = Lv6Id.string_of_long false cc in let id_str = Lv6Id.to_string id in let clk_str = if cc_str = "true" then id_str @@ -303,7 +303,7 @@ and dump_type_exp (os: Format.formatter) (x: type_exp) = ( Bool_type_exp -> fprintf os "bool" | Int_type_exp -> fprintf os "int" | Real_type_exp -> fprintf os "real" - | Named_type_exp id -> fprintf os "%s" (Lv6Id.string_of_idref id) + | Named_type_exp id -> fprintf os "%s" (Lv6Id.string_of_idref false id) | Array_type_exp (te, sz) -> ( dump_type_exp os te ; fprintf os "^" ; @@ -377,7 +377,7 @@ and dump_val_exp_list (os : formatter) (xl: val_exp list) = ( and dump_by_pos_exp (os: Format.formatter) (oper: by_pos_op) (pars: operands) = ( match (oper, pars) with - | (IDENT_n id,Oper []) -> dump_leaf_exp os (Lv6Id.string_of_idref id) + | (IDENT_n id,Oper []) -> dump_leaf_exp os (Lv6Id.string_of_idref false id) | (PRE_n, Oper [p0]) -> dump_unary_exp os "pre" p0 | (CURRENT_n, Oper [p0]) -> dump_unary_exp os "current" p0 | (ARROW_n, Oper [p0;p1]) -> dump_binary_exp os "->" p0 p1 @@ -498,13 +498,13 @@ and dump_nary_exp ) and string_of_node_exp (id, sal) = - (Lv6Id.string_of_idref id) ^ + (Lv6Id.string_of_idref false id) ^ (if sal = [] then "" else "<<" ^ (String.concat ", " (List.map static_arg_to_string sal)) ^ ">>") and static_arg_to_string arg = match arg.it with - | StaticArgLv6Id id -> Lv6Id.string_of_idref id + | StaticArgLv6Id id -> Lv6Id.string_of_idref false id | StaticArgConst ve -> "const xxx" | StaticArgType te -> "type xxx" | StaticArgNode op -> "node "^(op2string op) @@ -527,7 +527,7 @@ and dump_static_sarg (sa: static_arg) = match sa with - | StaticArgLv6Id id -> fprintf os "%s" (Lv6Id.string_of_idref id) + | StaticArgLv6Id id -> fprintf os "%s" (Lv6Id.string_of_idref false id) | StaticArgConst ve -> fprintf os "const %a" dump_val_exp ve | StaticArgType te -> fprintf os "type %a" dump_type_exp te | StaticArgNode op -> fprintf os "node %s" (op2string op) @@ -548,7 +548,7 @@ and dump_static_arg = fprintf os "%s = " (Lv6Id.to_string id); match sa.it with - | StaticArgLv6Id id -> fprintf os "%s" (Lv6Id.string_of_idref id) + | StaticArgLv6Id id -> fprintf os "%s" (Lv6Id.string_of_idref false id) | StaticArgConst ve -> fprintf os "const %a" dump_val_exp ve | StaticArgType te -> fprintf os "type %a" dump_type_exp te | StaticArgNode op -> fprintf os "node %s" (op2string op) @@ -573,11 +573,11 @@ and dump_by_name_exp ( match (oper, pars) with | (STRUCT_n id, pl) -> ( - fprintf os "%s{@,%a@,}" (Lv6Id.string_of_idref id) dump_named_pars pl + fprintf os "%s{@,%a@,}" (Lv6Id.string_of_idref false id) dump_named_pars pl ) | (STRUCT_WITH_n (id1,id2), pl) -> ( - fprintf os "%s{ %s with @,%a@,}" (Lv6Id.string_of_idref id1) - (Lv6Id.string_of_idref id2) dump_named_pars pl + fprintf os "%s{ %s with @,%a@,}" (Lv6Id.string_of_idref false id1) + (Lv6Id.string_of_idref false id2) dump_named_pars pl ) | (STRUCT_anonymous_n, pl) -> ( fprintf os "{@,%a@,}" dump_named_pars pl diff --git a/src/evalClock.ml b/src/evalClock.ml index 29d0a6b1c670cd69e54f5dd314c3ced8b9bd2bb9..24dcb58dd989de4f302f327617799ed40e4517de 100644 --- a/src/evalClock.ml +++ b/src/evalClock.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 05/07/2017 (at 17:23) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 16:44) by Erwan Jahier> *) open AstPredef @@ -94,7 +94,8 @@ let (check_args : Lxm.t -> Lxm.t list -> subst -> Lic.id_clock list -> ~flag:dbg ( fun () -> let pos = Lxm.position lxm in - let id_clock2str (id,c) = Printf.sprintf "[%s,%s]" id (LicDump.string_of_clock2 c) in + let id_clock2str (id,c) = Printf.sprintf "[%s,%s]" id + (LicDump.string_of_clock2 c) in let par = String.concat "," (List.map id_clock2str cil_par) in let arg = String.concat "," (List.map id_clock2str cil_arg) in Printf.printf @@ -164,7 +165,8 @@ let rec (var_info_eff_of_left_eff: Lic.left -> Lic.var_info) = | LeftSliceLic (l,si,_) -> let v = var_info_eff_of_left_eff l in - let new_name = (Lv6Id.to_string v.var_name_eff) ^ (LicDump.string_of_slice_info_eff si) + let new_name = (Lv6Id.to_string v.var_name_eff) ^ + (LicDump.string_of_slice_info_eff si) in { v with var_name_eff = Lv6Id.of_string new_name } @@ -295,7 +297,7 @@ let rec (f : IdSolver.t -> subst -> Lic.val_exp -> Lxm.t list -> Lic.clock list let ve = apply_subst_val_exp s ve in if Lv6Verbose.level() > 2 then print_string ( - "Clocking the expression '" ^ (LicDump.string_of_val_exp_eff ve) ^"': "^ + "Clocking the expression '" ^ (LicDump.string_of_val_exp_eff false ve) ^"': "^ (LicDump.string_of_clock2 (List.hd clks)) ^"\n"); assert(ve.ve_clk <> []); ve, inf_clks, s diff --git a/src/evalConst.ml b/src/evalConst.ml index 874f279b2c3ed27bd0ce8e2641fe3becd6d81bb7..5c027e027d481de90ae66e933bf5db163836def9 100644 --- a/src/evalConst.ml +++ b/src/evalConst.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 22/06/2017 (at 09:01) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:50) by Erwan Jahier> *) open Printf @@ -110,7 +110,7 @@ let make_struct_const (teff : Lic.type_) (id_opt : Lv6Id.idref option) else raise (Compile_error( lxm , sprintf "\n*** type error in struct %s, %s instead of %s" - (Lv6Id.string_of_long tnm) + (Lv6Id.string_of_long false tnm) (Lic.string_of_type vt) (Lic.string_of_type ft) )) with Not_found -> @@ -342,7 +342,7 @@ let rec f then raise(EvalConst_error( sprintf "multiple definition of param %s in %s call" - (Lv6Id.to_string pid.it) (Lv6Id.string_of_idref opid))) + (Lv6Id.to_string pid.it) (Lv6Id.string_of_idref false opid))) else let v = rec_eval_const pexp in match v with @@ -350,7 +350,7 @@ let rec f | _ -> raise(EvalConst_error( sprintf "unexpected tuple value for param %s in %s call" - (Lv6Id.to_string pid.it) (Lv6Id.string_of_idref opid))) + (Lv6Id.to_string pid.it) (Lv6Id.string_of_idref false opid))) in match namop with | STRUCT_anonymous_n -> finish_me "anonymous struct"; assert false @@ -427,10 +427,10 @@ and eval_array_index | [Int_const_eff i] | [Abstract_const_eff(_,_, (Int_const_eff i), true)] -> int_of_string i | [Abstract_const_eff(id,_,_,false)] -> - raise(EvalArray_error("The const " ^ (Lv6Id.string_of_long id) ^ + raise(EvalArray_error("The const " ^ (Lv6Id.string_of_long false id) ^ " is abstract")) | [Extern_const_eff(id,_)] -> - raise(EvalArray_error("The const " ^ (Lv6Id.string_of_long id) ^ + raise(EvalArray_error("The const " ^ (Lv6Id.string_of_long false id) ^ " is extern")) | [x] -> raise(EvalArray_error(sprintf "bad array index, int expected but get %s" diff --git a/src/evalType.ml b/src/evalType.ml index 38fd48da3878b304ba00b2bbdbc13b98af68763c..127362f29b4147e38d3e1477a5e7733851dfcada 100644 --- a/src/evalType.ml +++ b/src/evalType.ml @@ -1,4 +1,4 @@ -(** Time-stamp: <modified the 22/06/2017 (at 08:43) by Erwan Jahier> *) +(** Time-stamp: <modified the 21/07/2017 (at 15:35) by Erwan Jahier> *) open AstPredef @@ -335,7 +335,7 @@ and eval_by_name_type (id_solver: IdSolver.t) (namop: Lic.by_name_op) (lxm: Lxm with Not_found -> let msg = Printf.sprintf "Error: the field '%s' of structure '%s' is undefined" - (id) (Lv6Id.string_of_long opid) + (id) (Lv6Id.string_of_long false opid) in raise (Compile_error(lxm, msg)) ) diff --git a/src/idSolver.ml b/src/idSolver.ml index 9d548afb137d16b0c9992ff81e27eec0d4d2959b..e2d497d4cd34d5d87f70a382c83ca1f4d65f0551 100644 --- a/src/idSolver.ml +++ b/src/idSolver.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 26/02/2015 (at 11:21) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:49) by Erwan Jahier> *) (** Utilities for managing node environements (items tables) *) @@ -93,15 +93,15 @@ type node_env = { let (lookup_type: local_env -> Lv6Id.idref -> Lxm.t -> Lic.type_) = fun env id lxm -> - Hashtbl.find env.lenv_types (Lv6Id.of_idref id) + Hashtbl.find env.lenv_types (Lv6Id.of_idref false id) let (lookup_node : local_env -> Lv6Id.idref -> Lxm.t -> Lic.node_key) = fun env id lxm -> - Hashtbl.find env.lenv_nodes (Lv6Id.of_idref id) + Hashtbl.find env.lenv_nodes (Lv6Id.of_idref false id) let (lookup_const: local_env -> Lv6Id.idref -> Lxm.t -> Lic.const) = fun env id lmx -> - Hashtbl.find env.lenv_const (Lv6Id.of_idref id) + Hashtbl.find env.lenv_const (Lv6Id.of_idref false id) let (lookup_var: local_env -> Lv6Id.t -> Lxm.t -> Lic.var_info) = fun env id lmx -> diff --git a/src/l2lCheckLoops.mli b/src/l2lCheckLoops.mli index ae919c353717d03b41fd722973e72e835c906751..069d2c06540e09c92073b05fcbe929d479e56e80 100644 --- a/src/l2lCheckLoops.mli +++ b/src/l2lCheckLoops.mli @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 11/07/2017 (at 10:31) by Erwan Jahier> *) +(* Time-stamp: <modified the 18/08/2017 (at 11:00) by Erwan Jahier> *) (** Check that there is no dependancy loop between equations. @@ -9,7 +9,11 @@ is done by ec tools either (exexe, ec2c, etc.). Hence it is necessary to duplicate the work (done in ActionsDeps) here. Note that in ec mode, structs and arrays have been expanded, which makes things easier. - *) + +XXX : Should I rather use Lic2soc.f to check loops? + +Yes. So this module is not used anymore. +*) exception Error of (Lxm.t * string * LicPrg.t) diff --git a/src/l2lExpandArrays.ml b/src/l2lExpandArrays.ml index cc63b7fee520e853938cd260bd3e1f371def0806..d109f5e85f58580d82c85910a68c01a906e83158 100644 --- a/src/l2lExpandArrays.ml +++ b/src/l2lExpandArrays.ml @@ -1,4 +1,4 @@ -(** Time-stamp: <modified the 10/07/2017 (at 10:45) by Erwan Jahier> *) +(** Time-stamp: <modified the 21/07/2017 (at 15:18) by Erwan Jahier> *) (* Replace structures and arrays by as many variables as necessary. Since structures can be nested, it migth be a lot of new variables... @@ -322,7 +322,7 @@ and (var_trees_of_val_exp : do_const acc lctx lxm const with _ -> let msg = - "\n*** during Array expansion: '"^ (Lv6Id.string_of_long idl)^ + "\n*** during Array expansion: '"^ (Lv6Id.string_of_long false idl)^ "': Unknown constant.\n*** Current constants are: "^ (LicPrg.fold_consts (fun k c acc -> @@ -416,12 +416,12 @@ and (break_tuple : Lxm.t -> left list -> val_exp -> Lic.eq_info srcflagged list) let l1,l2= List.length ve1l, List.length ve2l in if (l1 <> l2) then let vel2str vel = - (String.concat ", " (List.map LicDump.string_of_val_exp_eff vel)) + (String.concat ", " (List.map (LicDump.string_of_val_exp_eff false) vel)) in let msg = Printf.sprintf "error: expression \n %s\n cannot be broken \n %s (%d) should have the same arity as\n%s(%d)" - (LicDump.string_of_val_exp_eff ve) + (LicDump.string_of_val_exp_eff false ve) (vel2str ve1l) l1 (vel2str ve2l) l2 in raise (Lv6errors.Compile_error(lxm, msg)) diff --git a/src/l2lExpandArrays.mli b/src/l2lExpandArrays.mli index 9db54361d0b895756acf7b6a3494d4e5160dea45..c8cafa592037535a635ccbddb122c94ffedbd216 100644 --- a/src/l2lExpandArrays.mli +++ b/src/l2lExpandArrays.mli @@ -1,11 +1,12 @@ -(* Time-stamp: <modified the 22/08/2014 (at 15:56) by Erwan Jahier> *) +(* Time-stamp: <modified the 18/08/2017 (at 11:04) by Erwan Jahier> *) -(** Expand strutures and arrays. - - Needed to generate ec and lv4 code. +(** Expand structures and arrays. Necessary to generate ec code. - Quite buggy. + Quite buggy :( + + Requires that nodes are expanded (should not be necessary, but it makes + things simpler and this pass is only used for generating ec code anyway) *) val doit : LicPrg.t -> LicPrg.t diff --git a/src/l2lExpandNodes.ml b/src/l2lExpandNodes.ml index 84b17028ce014027ea272494bee0deb76fe00dcf..cc221844a9469b1be44a8e52315d8a6b7dafc549 100644 --- a/src/l2lExpandNodes.ml +++ b/src/l2lExpandNodes.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 20/06/2017 (at 11:38) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:00) by Erwan Jahier> *) open Lxm @@ -264,11 +264,11 @@ and (expand_eq_aux: local_ctx -> Lic.eq_info -> local_ctx * acc option)= | Some n -> n | None -> prerr_string ( - "*** "^ (LicDump.string_of_node_key_rec false node_key.it) ^ + "*** "^ (LicDump.string_of_node_key_rec false false node_key.it) ^ " not defined.\n*** Defined nodes are:"^ (String.concat ",\n" (List.map (fun (nk,_) -> "\""^ - LicDump.string_of_node_key_rec false nk^"\"") + LicDump.string_of_node_key_rec false false nk^"\"") (LicPrg.list_nodes lctx.init_prg))) ); flush stderr; diff --git a/src/l2lRemoveAlias.ml b/src/l2lRemoveAlias.ml index ca6a27715de40840f00ab8436ef9963a034cd041..eba605267ac8b932fe5b1efffa8a49bd21a59682 100644 --- a/src/l2lRemoveAlias.ml +++ b/src/l2lRemoveAlias.ml @@ -1,6 +1,5 @@ -(* Time-stamp: <modified the 21/04/2017 (at 17:34) by Erwan Jahier> *) +(* Time-stamp: <modified the 18/07/2017 (at 16:22) by Erwan Jahier> *) -(** Remove useless aliases created by various l2l passes of the compiler *) open Lxm open Lic @@ -11,9 +10,6 @@ let profile_info = Lv6Verbose.profile_info module StringMap = Map.Make(String) type subst = Lic.var_info StringMap.t - - - type acc = subst * Lic.eq_info srcflagged list (* equations *) let (apply_subst : string -> subst -> string) = @@ -40,8 +36,6 @@ let (do_var_info : subst -> Lic.var_info -> Lic.var_info) = let id,clk = v.var_clock_eff in let clk = do_clock s clk in { v with var_clock_eff = apply_subst id s ,clk } - - let add_subst (x:Lv6Id.t) (nv:Lic.var_info) (s:subst) = let nv = do_var_info s nv in @@ -50,7 +44,6 @@ let add_subst (x:Lv6Id.t) (nv:Lic.var_info) (s:subst) = ~flag:dbg (fun() -> Printf.printf "#DBG: L2lRemoveAlias.add_subst '%s->%s'\n" x nv.var_name_eff); StringMap.add x nv s - let rec (do_eq_pass1 : Lic.node_exp -> Lic.eq_info srcflagged -> acc -> acc) = fun node_exp { src = lxm_eq ; it = (left_list, ve) } acc -> @@ -70,8 +63,6 @@ let rec (do_eq_pass1 : Lic.node_exp -> Lic.eq_info srcflagged -> acc -> acc) = s, { src = lxm_eq ; it = (left_list, ve) } :: eqs else add_subst vi.var_name_eff v_id s, eqs - - | _,_ -> let s, eqs = acc in (* let ve = do_val_exp licprg ve s in *) @@ -82,7 +73,6 @@ and (do_eq_pass2 : subst -> Lic.eq_info srcflagged -> Lic.eq_info srcflagged ) = let ve = do_val_exp ve s in { src = lxm_eq ; it = (left_list, ve) } - and (do_val_exp: val_exp -> subst -> val_exp) = fun ve s -> let ve_core = diff --git a/src/l2lRemoveAlias.mli b/src/l2lRemoveAlias.mli index aa510e3f978761e7cd8ebf127fc6756291e6654d..be2fd2ec97ab5165b3e2fe20ff869c17a3699217 100644 --- a/src/l2lRemoveAlias.mli +++ b/src/l2lRemoveAlias.mli @@ -1,3 +1,8 @@ -(* Time-stamp: <modified the 21/04/2017 (at 10:07) by Erwan Jahier> *) +(* Time-stamp: <modified the 18/08/2017 (at 11:05) by Erwan Jahier> *) + +(** Remove useless aliases created by various l2l passes of the compiler + + Watch out: if the program contains combinatory loops, bad things happen. +*) val doit : LicPrg.t -> LicPrg.t diff --git a/src/l2lSplit.ml b/src/l2lSplit.ml index 15dda919359f7d8e132e031746a00146b602298c..6f854163b129c4dd619696f3a85deef6d1f20e76 100644 --- a/src/l2lSplit.ml +++ b/src/l2lSplit.ml @@ -358,7 +358,7 @@ and split_node (lic_prg:LicPrg.t) (opt:Lv6MainArgs.t) (n: Lic.node_exp) : Lic.no Lv6Verbose.exe ~flag:dbg (fun () -> Printf.eprintf "*** Splitting node %s\n" - (LicDump.string_of_node_key_iter n.node_key_eff); + (LicDump.string_of_node_key_iter false n.node_key_eff); flush stderr); let res = match n.def_eff with | ExternLic diff --git a/src/lic.ml b/src/lic.ml index 6902f3dd2fe93084592674521d52f497951a50d2..832bcbfd667b04ad250bedd552779a8568a191b0 100644 --- a/src/lic.ml +++ b/src/lic.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 05/07/2017 (at 09:14) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:28) by Erwan Jahier> *) (** Define the Data Structure representing Compiled programs. By compiled we mean that constant are propagated, packages are @@ -627,7 +627,7 @@ let (clock_of_left: left -> clock) = snd (var_info_of_left left).var_clock_eff -let string_of_ident = Lv6Id.string_of_long_bis +let string_of_ident = Lv6Id.string_of_long_bis false let rec string_of_type = function | Bool_type_eff -> "bool" @@ -654,7 +654,8 @@ and string_of_clock = function | BaseLic -> " on base" | ClockVar i -> " on 'CV"^(string_of_int i) | On ( (cc,cv,ct), ck) -> - " on "^(Lv6Id.long_to_string cc) ^ "(" ^ (Lv6Id.to_string cv) ^ ")" ^(string_of_clock ck) + " on "^(Lv6Id.string_of_long false cc) ^ "(" + ^ (Lv6Id.to_string cv) ^ ")" ^(string_of_clock ck) and enum_to_string s ll = match Lv6MainArgs.global_opt.Lv6MainArgs.expand_enums with diff --git a/src/lic2soc.ml b/src/lic2soc.ml index b5619f0ebea5df96ae0a99cc6e5f11848f20711a..2446fb49b13e759d6113a18051ba121df907bd0c 100644 --- a/src/lic2soc.ml +++ b/src/lic2soc.ml @@ -1,4 +1,4 @@ -(** Time-stamp: <modified the 10/07/2017 (at 10:47) by Erwan Jahier> *) +(** Time-stamp: <modified the 17/08/2017 (at 18:24) by Erwan Jahier> *) (* XXX ce module est mal écrit. A reprendre. (R1) *) @@ -38,20 +38,20 @@ let rec lic_to_data_type: (Lic.type_ -> Data.t) = | Lic.Bool_type_eff -> Data.Bool | Lic.Int_type_eff -> Data.Int | Lic.Real_type_eff -> Data.Real - | Lic.External_type_eff s -> Data.Extern (Lv6Id.string_of_long s) + | Lic.External_type_eff s -> Data.Extern (Lv6Id.string_of_long false s) | Lic.Enum_type_eff (id, l) -> ( - Data.Enum(Lv6Id.string_of_long id, List.map Lv6Id.string_of_long l) + Data.Enum(Lv6Id.string_of_long false id, List.map (Lv6Id.string_of_long false) l) ) | Lic.Struct_type_eff (id, fl) -> ( let trans_field (id,(t,_)) = (* fde_value is ignored. Good idea? *) Lv6Id.to_string id, lic_to_data_type t in - let id = Lv6Id.string_of_long id in + let id = Lv6Id.string_of_long false id in Data.Struct(id, List.map trans_field fl) ) | Lic.Array_type_eff(ty,i) -> Data.Array(lic_to_data_type ty,i) | Lic.Abstract_type_eff (id, t) -> lic_to_data_type t - (* Data.Alias(Lv6Id.string_of_long id,lic_to_data_type t) *) + (* Data.Alias(Lv6Id.string_of_long false id,lic_to_data_type t) *) | Lic.TypeVar Lic.Any -> Data.Alpha 0 | Lic.TypeVar Lic.AnyNum -> @@ -115,9 +115,9 @@ let rec (lic2soc_const : Lic.const -> Soc.var_expr list) = | Bool_const_eff false -> [Soc.Const("false", Data.Bool)] | Int_const_eff i -> [Soc.Const(i, Data.Int)] | Real_const_eff r -> [Soc.Const(r, Data.Real)] - | Extern_const_eff (s, teff) -> [Soc.Const(Lv6Id.string_of_long s, + | Extern_const_eff (s, teff) -> [Soc.Const(Lv6Id.string_of_long false s, lic_to_data_type teff)] - | Abstract_const_eff (s, teff,_,_) -> [Soc.Const(Lv6Id.string_of_long s, + | Abstract_const_eff (s, teff,_,_) -> [Soc.Const(Lv6Id.string_of_long false s, lic_to_data_type teff)] | Enum_const_eff (s, teff) -> let ll = match teff with Enum_type_eff(_,ll) -> ll | _ -> assert false in @@ -149,7 +149,7 @@ let rec get_leaf: (LicPrg.t -> Lic.val_exp -> Soc.var_expr list option) = Some [translation] | Lic.CONST_REF l -> ( let type_ = lic_to_data_type (List.hd type_) in - Some [Soc.Const(Lv6Id.string_of_long l, type_)] + Some [Soc.Const(Lv6Id.string_of_long false l, type_)] ) | Lic.CONST c -> Some(lic2soc_const c) | Lic.STRUCT_ACCESS(field) -> ( @@ -276,7 +276,7 @@ let (lic_val_exp_to_soc_var : LicPrg.t -> Lic.val_exp Lxm.srcflagged -> | Some [Soc.Var v] -> ve.src, v | Some _ -> assert false | None -> - failwith ("Should be a var: "^(LicDump.string_of_val_exp_eff ve.it)) + failwith ("Should be a var: "^(LicDump.string_of_val_exp_eff false ve.it)) let (lic_to_soc_var : Lic.var_info -> Soc.var) = fun vi -> @@ -304,7 +304,7 @@ let (make_soc_key_of_node_key : key_opt ) in - LicDump.string_of_node_key_rec false nk, vl, key_opt + LicDump.string_of_node_key_rec false false nk, vl, key_opt let (soc_key_of_node_exp : Lic.node_exp -> Soc.key) = @@ -340,7 +340,7 @@ let rec (val_exp_to_filter: LicPrg.t -> Lic.val_exp -> Soc.var_expr list) = [translation] | CONST_REF l -> ( let type_ = lic_to_data_type (List.hd type_) in - [Soc.Const(Lv6Id.string_of_long l, type_)] + [Soc.Const(Lv6Id.string_of_long false l, type_)] ) | CONST (Bool_const_eff true) -> [Soc.Const("true", Data.Bool)] | CONST (Bool_const_eff false) -> [Soc.Const("false", Data.Bool)] @@ -386,7 +386,7 @@ let rec (val_exp_to_filter: LicPrg.t -> Lic.val_exp -> Soc.var_expr list) = let lxm = by_pos_op_flg.src in let msg = (Lxm.details lxm) ^ ": only one operator per equation is allowed ("^ - (LicDump.string_of_val_exp_eff val_exp)^").\n" + (LicDump.string_of_val_exp_eff false val_exp)^").\n" in raise (Lv6errors.Global_error msg) ) @@ -726,13 +726,13 @@ let rec f: (LicPrg.t -> Lic.node_key -> Soc.key * Soc.tbl) = match LicPrg.find_node prog nk with | None -> prerr_string ( - "*** "^ (LicDump.string_of_node_key_rec false nk) ^ + "*** "^ (LicDump.string_of_node_key_rec false false nk) ^ " not defined (as lic).\n" ^ "*** Defined nodes are:"^ (String.concat ",\n" (List.map (fun (nk,_) -> - "\""^LicDump.string_of_node_key_rec false nk ^"\"") + "\""^LicDump.string_of_node_key_rec false false nk ^"\"") (LicPrg.list_nodes prog))) ); assert false @@ -754,13 +754,16 @@ let rec f: (LicPrg.t -> Lic.node_key -> Soc.key * Soc.tbl) = ) ) with + | Undef_soc (sk,lxm,Lic.CALL { it = nk2 }, types,_) -> (* Il manque une dépendance, on essaie de la - traduire puis de retraduire le noeud courant. *) - | Undef_soc (sk,lxm,Lic.CALL { it = nk2 }, types,_) -> + traduire puis de retraduire le noeud courant. + ZZZ ca part facilement en vrille ici si une erreur + a été faite en amont... + *) let soc_tbl = snd (process_node nk2 soc_tbl) in snd (process_node nk soc_tbl) - - | Undef_soc (sk,lxm,pos_op, types, fby_init_opt) -> ( + + | Undef_soc (sk,lxm,pos_op, types, fby_init_opt) -> ( let soc = SocPredef.soc_interface_of_pos_op lxm pos_op types fby_init_opt in diff --git a/src/licDump.ml b/src/licDump.ml index 469123039d7f4b8b4c50163d897570d6d4c163af..b0d220dbbee8cfac2f930f1a9e644a614421b171 100644 --- a/src/licDump.ml +++ b/src/licDump.ml @@ -1,5 +1,19 @@ -(* Time-stamp: <modified the 04/07/2017 (at 17:17) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 16:43) by Erwan Jahier> *) +(* +This module is used both for +(1) dealing with internal ident names +(2) generating lustre files +(3) building error messages + +Because of (2), ident names may depend on the ec or the v4 option. But for (1) +and (3), we don't want to depend that those options. + +Hence, I've added a boolean flag to all "to_string" functions that +states whether the function is used for internal purposes, or for +generating lustre files. + + *) open Lv6errors open Printf open Lxm @@ -8,7 +22,7 @@ open List open Lv6MainArgs (* XXX changer le nom de cette fonction *) -let (dump_long : Lv6Id.long -> string) = Lv6Id.string_of_long_bis +let (dump_long : bool -> Lv6Id.long -> string) = Lv6Id.string_of_long_bis (* fun id -> *) @@ -44,49 +58,51 @@ let rec is_a_tuple (e:Lic.val_exp) : bool = (******************************************************************************) -let string_of_ident x = +let string_of_ident forprint x = if global_opt.kcg then Lv6Id.no_pack_string_of_long x else if global_opt.no_prefix then Lv6Id.no_pack_string_of_long x - else Lv6Id.string_of_long x + else Lv6Id.string_of_long forprint x - -let rec string_of_const_eff = +(* the flag forprint controls whether those functions are used for printing + into a file or not (i.e. for internal use) *) + +let rec string_of_const_eff forprint = function | Bool_const_eff true -> "true" | Bool_const_eff false -> "false" | Int_const_eff i -> (sprintf "%s" i) | Real_const_eff r -> r - | Extern_const_eff (s,t) -> (dump_long s) + | Extern_const_eff (s,t) -> (dump_long forprint s) | Abstract_const_eff (s,t,v,_) -> - (dump_long s) ^ (* XXX ? *) - (string_of_const_eff v) - (* | Abstract_const_eff (s,t,v,false) -> (dump_long s) *) + (dump_long forprint s) ^ (* XXX ? *) + (string_of_const_eff forprint v) + (* | Abstract_const_eff (s,t,v,false) -> (dump_long forprint s) *) | Enum_const_eff (s,Enum_type_eff(_,ll)) -> Lic.enum_to_string s ll | Enum_const_eff (_) -> assert false | Struct_const_eff (fl, t) -> ( let string_of_field = function (id, veff) -> - (Lv6Id.to_string id)^" = "^ (string_of_const_eff veff) + (Lv6Id.to_string id)^" = "^ (string_of_const_eff forprint veff) in let flst = List.map string_of_field fl in - (string_of_type_eff t)^"{"^(String.concat "; " flst)^"}" + (string_of_type_eff forprint t)^"{"^(String.concat "; " flst)^"}" ) | Array_const_eff (ctab, _t) -> ( - let vl = List.map string_of_const_eff ctab in + let vl = List.map (string_of_const_eff forprint) ctab in "["^(String.concat ", " vl)^"]" ) | Tuple_const_eff cl -> ( - string_of_const_eff_list cl + string_of_const_eff_list forprint cl ) -and string_of_const_eff_list = +and string_of_const_eff_list forprint = function - | [c] -> string_of_const_eff c - | cl -> "(" ^ (String.concat ", " (List.map string_of_const_eff cl)) ^ ")" + | [c] -> string_of_const_eff forprint c + | cl -> "(" ^ (String.concat ", " (List.map (string_of_const_eff forprint) cl)) ^ ")" (* modify numbers notations in such a way that they become "valid" identifiers. Policy: @@ -109,55 +125,55 @@ and correct_num_string s = Bytes.iter f s; Bytes.to_string res -and string_ident_of_const_eff c = +and string_ident_of_const_eff forprint c = (* that version generates a string that is a valid lic ident, in order to use it to generate a node name using static parameters *) match c with | Int_const_eff _ | Real_const_eff _ -> - correct_num_string(string_of_const_eff c) + correct_num_string(string_of_const_eff forprint c) | Bool_const_eff _ | Extern_const_eff _ | Abstract_const_eff _ - | Enum_const_eff _ -> string_of_const_eff c + | Enum_const_eff _ -> string_of_const_eff forprint c | Struct_const_eff (_, t) -> ( match t with | Struct_type_eff (sn,_) -> Lv6Id.no_pack_string_of_long sn | _ -> assert false ) | Array_const_eff (ctab, t) -> - (string_of_type_eff t) ^ "_" ^(string_of_int (List.length ctab)) - | Tuple_const_eff cl -> string_ident_of_const_eff_list cl + (string_of_type_eff forprint t) ^ "_" ^(string_of_int (List.length ctab)) + | Tuple_const_eff cl -> string_ident_of_const_eff_list forprint cl -and string_ident_of_const_eff_list cl = +and string_ident_of_const_eff_list forprint cl = match cl with - | [c] -> string_ident_of_const_eff c - | _ -> "" ^ (String.concat "_" (List.map string_ident_of_const_eff cl)) ^ "" + | [c] -> string_ident_of_const_eff forprint c + | _ -> "" ^ (String.concat "_" (List.map (string_ident_of_const_eff forprint) cl)) ^ "" -and string_of_const_eff_opt = function +and string_of_const_eff_opt forprint = function | None -> "" - | Some val_exp_eff -> string_of_const_eff val_exp_eff + | Some val_exp_eff -> string_of_const_eff forprint val_exp_eff -and string_def_of_type_eff = function +and string_def_of_type_eff forprint = function | Bool_type_eff -> "bool" | Int_type_eff -> "int" | Real_type_eff -> "real" - | External_type_eff (i) -> dump_long i - | Abstract_type_eff (i, t) -> string_def_of_type_eff t + | External_type_eff (i) -> dump_long forprint i + | Abstract_type_eff (i, t) -> string_def_of_type_eff forprint t | Enum_type_eff (i, sl) -> assert (sl <>[]); - let f sep acc s = acc ^ sep ^ (dump_long s) in + let f sep acc s = acc ^ sep ^ (dump_long forprint s) in (List.fold_left (f ", ") (f "" "enum {" (List.hd sl)) (List.tl sl)) ^ "}" - | Array_type_eff (ty, sz) -> sprintf "%s^%d" (string_of_type_eff ty) sz + | Array_type_eff (ty, sz) -> sprintf "%s^%d" (string_of_type_eff forprint ty) sz | Struct_type_eff (name, fl) -> assert (fl <>[]); let f sep acc (id, (type_eff, const_eff_opt)) = acc ^ sep ^ (Lv6Id.to_string id) ^ " : " ^ - (string_of_type_eff type_eff) ^ + (string_of_type_eff forprint type_eff) ^ match const_eff_opt with None -> "" - | Some ce -> " = " ^ (string_of_const_eff ce) + | Some ce -> " = " ^ (string_of_const_eff forprint ce) in if global_opt.kcg then (List.fold_left (f ", ") (f "" " {" (List.hd fl)) (List.tl fl)) ^ "}" @@ -172,17 +188,17 @@ and string_def_of_type_eff = function (* exported *) (* On prend le meme que Lic *) -and string_of_type_eff = function +and string_of_type_eff forprint = function | Bool_type_eff -> "bool" | Int_type_eff -> "int" | Real_type_eff -> "real" - | External_type_eff (name) -> (string_of_ident name) - | Abstract_type_eff (name, t) -> (string_of_ident name) + | External_type_eff (name) -> (string_of_ident forprint name) + | Abstract_type_eff (name, t) -> (string_of_ident forprint name) | Enum_type_eff (name, el) -> (match global_opt.Lv6MainArgs.expand_enums with - | AsEnum | AsConst -> string_of_ident name - | AsInt -> if global_opt.kcg then dump_long name else "int" - | AsBool -> if global_opt.kcg then dump_long name else + | AsEnum | AsConst -> string_of_ident forprint name + | AsInt -> if global_opt.kcg then dump_long forprint name else "int" + | AsBool -> if global_opt.kcg then dump_long forprint name else (* let get_n x = (* returns the n s.t., 2^(n-1) < x <= 2^n *) assert(x>0); @@ -199,79 +215,85 @@ and string_of_type_eff = function ("bool^"^(string_of_int size)) ) | Array_type_eff (ty, sz) -> - Printf.sprintf "%s^%d" (string_of_type_eff ty) sz - | Struct_type_eff (name, _) -> (if global_opt.kcg then dump_long name else string_of_ident name) + Printf.sprintf "%s^%d" (string_of_type_eff forprint ty) sz + | Struct_type_eff (name, _) -> (if global_opt.kcg then dump_long forprint name else string_of_ident forprint name) | TypeVar Any -> "any" | (TypeVar AnyNum) -> "anynum" -and string_of_type_list = function +and string_of_type_list forprint = function | [] -> "" - | [x] -> string_of_type_eff x - | l -> String.concat " * " (List.map string_of_type_eff l) + | [x] -> string_of_type_eff forprint x + | l -> String.concat " * " (List.map (string_of_type_eff forprint) l) -and string_of_type_profile (i, o) = - (string_of_type_list i)^" -> "^(string_of_type_list o) +and string_of_type_profile forprint (i, o) = + (string_of_type_list forprint i)^" -> "^(string_of_type_list forprint o) -and string_of_const = function +and string_of_const forprint = function | Bool_const_eff true -> "true" | Bool_const_eff false -> "false" | Int_const_eff i -> (sprintf "%s" i) | Real_const_eff r -> r - | Extern_const_eff (s,_) -> (string_of_ident s) - | Abstract_const_eff (s,t,v,_) -> (string_of_ident s) + | Extern_const_eff (s,_) -> (string_of_ident forprint s) + | Abstract_const_eff (s,t,v,_) -> (string_of_ident forprint s) | Enum_const_eff (s,Enum_type_eff(_,ll)) -> (string_of_int (Lv6util.pos_in_list 0 s ll)) | Enum_const_eff _ -> assert false | Struct_const_eff (fl, t) -> let string_of_field (id, veff) = - (Lv6Id.to_string id)^" = "^ (string_of_const veff) + (Lv6Id.to_string id)^" = "^ (string_of_const forprint veff) in Printf.sprintf "%s{%s}" - (string_of_type_eff t) + (string_of_type_eff forprint t) (String.concat "; " (List.map string_of_field fl)) | Array_const_eff (ctab, t) -> Printf.sprintf "[%s]" - (String.concat ", " (List.map string_of_const ctab)) + (String.concat ", " (List.map (string_of_const forprint) ctab)) | Tuple_const_eff cl -> Printf.sprintf "(%s)" - (String.concat ", " (List.map string_of_const cl)) + (String.concat ", " (List.map (string_of_const forprint)cl)) -and string_of_var_info x = +and string_of_var_info forprint x = (AstCore.string_of_var_nature x.var_nature_eff) ^ " " ^ - (Lv6Id.to_string x.var_name_eff) ^ ":"^(string_of_type_eff x.var_type_eff)^ + (Lv6Id.to_string x.var_name_eff) ^ ":"^(string_of_type_eff forprint x.var_type_eff)^ (string_of_clock (snd x.var_clock_eff)^"("^ (Lv6Id.to_string (fst x.var_clock_eff)) ^","^ (string_of_int x.var_number_eff)^")") -and string_of_var_list vl = String.concat " ; " (List.map string_of_var_info vl) +and string_of_var_list forprint vl = + String.concat " ; " (List.map (string_of_var_info forprint) vl) -and string_of_node_key = function +and string_of_node_key forprint = function | (ik, []) -> - (string_of_ident ik) - | (ik, sargs) -> Printf.sprintf "%s<<%s>>" - (string_of_ident ik) - (String.concat ", " (List.map string_of_static_arg sargs)) - -and string_of_static_arg = function - | ConstStaticArgLic(id, ceff) -> Printf.sprintf "const %s = %s" id (string_of_const ceff) - | TypeStaticArgLic (id, teff) -> Printf.sprintf "type %s = %s" id (string_of_type_eff teff) + (string_of_ident forprint ik) + | (ik, sargs) -> + Printf.sprintf "%s<<%s>>" + (string_of_ident forprint ik) + (String.concat ", " + (List.map (string_of_static_arg forprint) sargs)) + +and string_of_static_arg forprint = function + | ConstStaticArgLic(id, ceff) -> + Printf.sprintf "const %s = %s" id (string_of_const forprint ceff) + | TypeStaticArgLic (id, teff) -> + Printf.sprintf "type %s = %s" id (string_of_type_eff forprint teff) (* | NodeStaticArgLic (id, ((long,sargs), _, _), _) -> *) | NodeStaticArgLic (id, nk) -> - Printf.sprintf "node %s = %s" id (string_of_node_key nk) + Printf.sprintf "node %s = %s" id (string_of_node_key forprint nk) -and string_of_type_var tv = string_of_type_eff (TypeVar tv) -and string_of_type_matches pm = +and string_of_type_var forprint tv = string_of_type_eff forprint (TypeVar tv) +and string_of_type_matches forprint pm = let sotm (tv,t) = Printf.sprintf "%s <- %s" - (string_of_type_var tv) (string_of_type_eff t) + (string_of_type_var forprint tv) + (string_of_type_eff forprint t) in String.concat ", " (List.map sotm pm) (* for printing recursive node *) -and string_of_node_key_rec (no_prefix:bool) (nkey: node_key) = +and string_of_node_key_rec forprint (no_prefix:bool) (nkey: node_key) = match nkey with | (ik, []) -> if global_opt.kcg then Lv6Id.no_pack_string_of_long ik else if no_prefix then Lv6Id.no_pack_string_of_long ik - else Lv6Id.string_of_long ik + else Lv6Id.string_of_long forprint ik | (ik, salst) -> if global_opt.kcg then ((* recursive nodes have been unfold *) (*assert (List.mem ik ["map"]);*) @@ -291,83 +313,87 @@ and string_of_node_key_rec (no_prefix:bool) (nkey: node_key) = ) in let nk, salst = get_node salst in - let astrings = List.map static_arg2string_kcg salst in + let astrings = List.map (static_arg2string_kcg forprint) salst in let name = sprintf "(%s %s <<%s>>)" (Lv6Id.no_pack_string_of_long ik) - (string_of_node_key_rec no_prefix nk) (String.concat "," astrings) + (string_of_node_key_rec forprint no_prefix nk) + (String.concat "," astrings) in (FreshName.node_key nkey name) ) else - let astrings = List.map static_arg2string_bis salst in - let name = sprintf "%s_%s" (Lv6Id.no_pack_string_of_long ik) (String.concat "_" astrings) in + let astrings = List.map (static_arg2string_bis forprint) salst in + let name = sprintf "%s_%s" (Lv6Id.no_pack_string_of_long ik) + (String.concat "_" astrings) in (FreshName.node_key nkey name) (* for printing iterators *) -and string_of_node_key_iter (nkey: node_key) = +and string_of_node_key_iter forprint (nkey: node_key) = match nkey with - | (ik, []) -> dump_long ik + | (ik, []) -> dump_long forprint ik | (ik, salst) -> - let astrings = List.map (static_arg2string) salst in - sprintf "%s<<%s>>" (Lv6Id.string_of_long ik) (String.concat ", " astrings) - + let astrings = List.map (static_arg2string forprint) salst in + if forprint then + sprintf "%s<<%s>>" (Lv6Id.string_of_long forprint ik) (String.concat ", " astrings) + else + sprintf "%s<<%s>>" (Lv6Id.string_of_long forprint ik) (String.concat ", " astrings) (* pour ecrire UN NIVEAU d'arg statique (cf. LicMetaOp *) -and string_of_node_key_def (nkey: node_key) = +and string_of_node_key_def forprint (nkey: node_key) = match nkey with - | (ik, []) -> dump_long ik + | (ik, []) -> dump_long forprint ik | (ik, salst) -> - let astrings = List.map (string_of_static_arg) salst in + let astrings = List.map (string_of_static_arg forprint) salst in sprintf "%s<<%s>>" (Lv6Id.no_pack_string_of_long ik) (String.concat ", " astrings) (* for inventing a name to parametrized nodes *) -and static_arg2string_bis (sa : Lic.static_arg) = +and static_arg2string_bis forprint (sa : Lic.static_arg) = match sa with - | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff ceff) - | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff teff) + | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff forprint ceff) + | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff forprint teff) (* | NodeStaticArgLic (id, ((long, _sargs), _, _), _) -> *) | NodeStaticArgLic (id, (long,_)) -> sprintf "%s" (Lv6Id.no_pack_string_of_long long) -and static_arg2string_kcg (sa : Lic.static_arg) = +and static_arg2string_kcg forprint (sa : Lic.static_arg) = match sa with - | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff ceff) - | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff teff) + | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff forprint ceff) + | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff forprint teff) (* | NodeStaticArgLic (id, ((long, _sargs), _, _), _) -> *) | NodeStaticArgLic (id, (long,_)) -> assert false (* should not occur *) (* for printing recursive node and iterators *) -and static_arg2string (sa : Lic.static_arg) = +and static_arg2string forprint (sa : Lic.static_arg) = match sa with - | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff ceff) - | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff teff) + | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff forprint ceff) + | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff forprint teff) (* | NodeStaticArgLic (id, ((long,sargs), _, _), _) -> *) | NodeStaticArgLic (id, (long,sargs)) -> - string_of_node_key_iter (long,sargs) -(* sprintf "%s" (dump_long long) *) + string_of_node_key_iter forprint (long,sargs) +(* sprintf "%s" (dump_long forprint long) *) -and static_arg2string_rec (sa : Lic.static_arg) = +and static_arg2string_rec forprint (sa : Lic.static_arg) = match sa with - | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff ceff) - | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff teff) + | ConstStaticArgLic (id, ceff) -> sprintf "%s" (string_ident_of_const_eff forprint ceff) + | TypeStaticArgLic (id, teff) -> sprintf "%s" (string_of_type_eff forprint teff) (* | NodeStaticArgLic (id, ((long,sargs), _, _), _) -> *) | NodeStaticArgLic (id, (long,sargs)) -> - string_of_node_key_rec global_opt.no_prefix (long,sargs) -(* sprintf "%s" (dump_long long) *) + string_of_node_key_rec forprint global_opt.no_prefix (long,sargs) +(* sprintf "%s" (dump_long forprint long) *) -and (string_of_var_info_eff: Lic.var_info -> string) = - fun x -> - (Lv6Id.to_string x.var_name_eff) ^ ":"^(string_of_type_eff x.var_type_eff) +and (string_of_var_info_eff: bool -> Lic.var_info -> string) = + fun forprint x -> + (Lv6Id.to_string x.var_name_eff) ^ ":"^(string_of_type_eff forprint x.var_type_eff) -and (type_string_of_var_info_eff: Lic.var_info -> string) = - fun x -> (string_of_type_eff x.var_type_eff) ^ +and (type_string_of_var_info_eff: bool -> Lic.var_info -> string) = + fun forprint x -> (string_of_type_eff forprint x.var_type_eff) ^ (string_of_clock2 (snd x.var_clock_eff)) -and string_of_decl var_info_eff = +and string_of_decl forprint var_info_eff = let vt_str = (Lv6Id.to_string var_info_eff.var_name_eff) ^ ":" ^ - (string_of_type_eff var_info_eff.var_type_eff) + (string_of_type_eff forprint var_info_eff.var_type_eff) in let clk_str = (string_of_clock (snd var_info_eff.var_clock_eff)) in if global_opt.ec then @@ -375,9 +401,9 @@ and string_of_decl var_info_eff = else "("^vt_str ^")"^ clk_str else vt_str ^ clk_str -and (string_of_type_decl_list : Lic.var_info list -> string -> string) = - fun tel sep -> - let str = String.concat sep (List.map string_of_decl tel) in +and (string_of_type_decl_list : bool -> Lic.var_info list -> string -> string) = + fun forprint tel sep -> + let str = String.concat sep (List.map (string_of_decl forprint) tel) in str and string_of_slice_info_eff si_eff = @@ -385,20 +411,23 @@ and string_of_slice_info_eff si_eff = (if si_eff.se_step = 1 then "" else " step " ^ (string_of_int si_eff.se_step)) ^ "]" -and (string_of_leff : Lic.left -> string) = +and (string_of_leff : bool -> Lic.left -> string) = fun forprint -> function | LeftVarLic (vi_eff,_) -> Lv6Id.to_string vi_eff.var_name_eff - | LeftFieldLic(leff,id,_) -> (string_of_leff leff) ^ "." ^ (Lv6Id.to_string id) - | LeftArrayLic(leff,i,_) -> (string_of_leff leff) ^ "[" ^ (string_of_int i) ^ "]" - | LeftSliceLic(leff,si,_) -> (string_of_leff leff) ^ (string_of_slice_info_eff si) + | LeftFieldLic(leff,id,_) -> + (string_of_leff forprint leff) ^ "." ^ (Lv6Id.to_string id) + | LeftArrayLic(leff,i,_) -> + (string_of_leff forprint leff) ^ "[" ^ (string_of_int i) ^ "]" + | LeftSliceLic(leff,si,_) -> (string_of_leff forprint leff) ^ + (string_of_slice_info_eff si) -and (string_of_leff_list : Lic.left list -> string) = - fun l -> if global_opt.kcg then - String.concat ", " (List.map string_of_leff l) +and (string_of_leff_list : bool -> Lic.left list -> string) = + fun forprint l -> if global_opt.kcg then + String.concat ", " (List.map (string_of_leff forprint) l) else (if List.length l = 1 then "" else "(") ^ - (String.concat ", " (List.map string_of_leff l)) ^ + (String.concat ", " (List.map (string_of_leff forprint) l)) ^ (if List.length l = 1 then "" else ")") and (array_of_size_one : Lic.val_exp -> bool) = @@ -406,26 +435,26 @@ and (array_of_size_one : Lic.val_exp -> bool) = | {ve_typ= [Array_type_eff(Bool_type_eff, size)] } -> size = 1 | {ve_typ= [_] } -> true | _ -> false -and sov ve = string_of_val_exp_eff ve -and (string_of_by_pos_op_eff: Lic.by_pos_op srcflagged -> Lic.val_exp list -> string) = - fun posop vel -> - let tuple vel = (String.concat ", " (List.map string_of_val_exp_eff vel)) in +and sov forprint ve = string_of_val_exp_eff forprint ve +and (string_of_by_pos_op_eff: bool -> Lic.by_pos_op srcflagged -> Lic.val_exp list -> string) = + fun forprint posop vel -> + let tuple vel = (String.concat ", " (List.map (string_of_val_exp_eff forprint) vel)) in let tuple_par vel = "(" ^ (tuple vel) ^ ")" in let tuple_square vel = - "[" ^ (String.concat ", " (List.map string_of_val_exp_eff vel)) ^ "]" + "[" ^ (String.concat ", " (List.map (string_of_val_exp_eff forprint) vel)) ^ "]" in let str = match posop.it,vel with - | CONST c,_ -> string_of_const_eff c + | CONST c,_ -> string_of_const_eff forprint c | CALL ({it=("Lustre","not"),[]}), [ve1] | PREDEF_CALL ({it=("Lustre","not"),[]}), [ve1] -> ((op2string AstPredef.NOT_n) ^ " " ^ - (if is_a_tuple ve1 then (tuple_par [ve1]) else sov ve1)) + (if is_a_tuple ve1 then (tuple_par [ve1]) else sov forprint ve1)) | CALL ({it=("Lustre","diese"),[]}), [ve1] | PREDEF_CALL ({it=("Lustre","diese"),[]}), [ve1] -> if (global_opt.lv4) && array_of_size_one ve1 - then sov ve1 (* lv4 does no accept to apply # on One var only! *) + then sov forprint ve1 (* lv4 does no accept to apply # on One var only! *) (*else if global_opt.kcg then ("#" ^ (dump_array_no_square ve1)) *) (* do later *) @@ -438,11 +467,11 @@ and (string_of_by_pos_op_eff: Lic.by_pos_op srcflagged -> Lic.val_exp list -> st | CALL ({it=("Lustre","if"),[]}), [ve1; ve2; ve3] | PREDEF_CALL ({it=("Lustre","if"),[]}), [ve1; ve2; ve3] -> - let ve2str = string_of_val_exp_eff ve2 in + let ve2str = string_of_val_exp_eff forprint ve2 in let ve2str = if is_a_tuple ve2 then "("^ve2str^")" else ve2str in - let ve3str = string_of_val_exp_eff ve3 in + let ve3str = string_of_val_exp_eff forprint ve3 in let ve3str = if is_a_tuple ve3 then "("^ve3str^")" else ve3str in - " if " ^ (string_of_val_exp_eff ve1) ^ + " if " ^ (string_of_val_exp_eff forprint ve1) ^ " then " ^ ve2str ^ " else " ^ ve3str | CALL(op), vel @@ -452,8 +481,8 @@ and (string_of_by_pos_op_eff: Lic.by_pos_op srcflagged -> Lic.val_exp list -> st let op_short_str = op2string (AstPredef.string_to_op op_str) in if AstPredef.is_infix (AstPredef.string_to_op op_str) then ( let ve1, ve2 = cut_list vel in - (string_of_val_exp_eff ve1) ^ " " ^ op_short_str ^ - " " ^ (string_of_val_exp_eff ve2) ) + (string_of_val_exp_eff forprint ve1) ^ " " ^ op_short_str ^ + " " ^ (string_of_val_exp_eff forprint ve2) ) else (op_short_str ^ (match op_str with @@ -464,44 +493,44 @@ and (string_of_by_pos_op_eff: Lic.by_pos_op srcflagged -> Lic.val_exp list -> st else let nk = op.it in if not global_opt.lv4 then - ((string_of_node_key nk) ^ (tuple_par vel)) + ((string_of_node_key forprint nk) ^ (tuple_par vel)) else - ((string_of_node_key_rec global_opt.no_prefix nk) ^ (tuple_par vel)) + ((string_of_node_key_rec forprint global_opt.no_prefix nk) ^ (tuple_par vel)) ) - | CONST_REF idl, _ -> dump_long idl + | CONST_REF idl, _ -> dump_long forprint idl | VAR_REF id, _ -> id | PRE, _ -> "pre " ^ (tuple_par vel) | ARROW, [ve1; ve2] -> (* if global_opt.kcg then ( "fby(" ^ - (if is_a_tuple ve2 then tuple_par [ve2] else string_of_val_exp_eff ve2) + (if is_a_tuple ve2 then tuple_par [ve2] else string_of_val_exp_eff forprint ve2) ^ ";1;" ^ - (if is_a_tuple ve2 then tuple_par [ve1] else string_of_val_exp_eff ve1) ^ ")" + (if is_a_tuple ve2 then tuple_par [ve1] else string_of_val_exp_eff forprint ve1) ^ ")" ) else( *) - (if is_a_tuple ve1 then tuple_par [ve1] else string_of_val_exp_eff ve1) ^ + (if is_a_tuple ve1 then tuple_par [ve1] else string_of_val_exp_eff forprint ve1) ^ " -> " ^ - (if is_a_tuple ve1 then tuple_par [ve2] else string_of_val_exp_eff ve2) + (if is_a_tuple ve1 then tuple_par [ve2] else string_of_val_exp_eff forprint ve2) | FBY, [ve1; ve2] -> (* dead code ? *) if global_opt.lv4 then - (if is_a_tuple ve1 then tuple_par [ve1] else string_of_val_exp_eff ve1) + (if is_a_tuple ve1 then tuple_par [ve1] else string_of_val_exp_eff forprint ve1) ^ " -> pre " ^ - (if is_a_tuple ve1 then tuple_par [ve2] else string_of_val_exp_eff ve2) + (if is_a_tuple ve1 then tuple_par [ve2] else string_of_val_exp_eff forprint ve2) else if global_opt.kcg then ( "fby(" ^ - (if is_a_tuple ve2 then tuple_par [ve2] else string_of_val_exp_eff ve2) + (if is_a_tuple ve2 then tuple_par [ve2] else string_of_val_exp_eff forprint ve2) ^ ";1;" ^ - (if is_a_tuple ve2 then tuple_par [ve1] else string_of_val_exp_eff ve1) ^ ")" + (if is_a_tuple ve2 then tuple_par [ve1] else string_of_val_exp_eff forprint ve1) ^ ")" ) else( - (if is_a_tuple ve1 then tuple_par [ve1] else string_of_val_exp_eff ve1) + (if is_a_tuple ve1 then tuple_par [ve1] else string_of_val_exp_eff forprint ve1) ^ " fby " ^ - (if is_a_tuple ve1 then tuple_par [ve2] else string_of_val_exp_eff ve2) + (if is_a_tuple ve1 then tuple_par [ve2] else string_of_val_exp_eff forprint ve2) ) | WHEN clk, vel -> (tuple vel) ^ (string_of_clock clk) @@ -513,18 +542,18 @@ and (string_of_by_pos_op_eff: Lic.by_pos_op srcflagged -> Lic.val_exp list -> st | CURRENT None,_ -> "current " ^ tuple_par vel | TUPLE,_ -> (tuple vel) | CONCAT, [ve1; ve2] -> - (string_of_val_exp_eff ve1) ^ " | " ^ (string_of_val_exp_eff ve2) - | HAT (i), [ve] -> (string_of_val_exp_eff ve) ^ "^" ^ (string_of_int i) + (string_of_val_exp_eff forprint ve1) ^ " | " ^ (string_of_val_exp_eff forprint ve2) + | HAT (i), [ve] -> (string_of_val_exp_eff forprint ve) ^ "^" ^ (string_of_int i) | HAT (i), _ -> assert false | ARRAY, vel -> tuple_square vel | STRUCT_ACCESS(id), [ve1] -> - (string_of_val_exp_eff ve1) ^ "." ^ (Lv6Id.to_string id) + (string_of_val_exp_eff forprint ve1) ^ "." ^ (Lv6Id.to_string id) | ARRAY_ACCES(i), [ve1] -> - (string_of_val_exp_eff ve1) ^ "[" ^ (string_of_int i) ^ "]" + (string_of_val_exp_eff forprint ve1) ^ "[" ^ (string_of_int i) ^ "]" | ARRAY_SLICE(si_eff), [ve1] -> - (string_of_val_exp_eff ve1) ^ (string_of_slice_info_eff si_eff) + (string_of_val_exp_eff forprint ve1) ^ (string_of_slice_info_eff si_eff) | ARRAY_SLICE(_), _ -> assert false (* todo *) @@ -579,27 +608,27 @@ and (cut_list : val_exp list -> val_exp * val_exp) = for printing purpose *) ve1,ve2 -and string_of_val_exp_eff ve = string_of_val_exp_eff_core ve.ve_core -and string_of_val_exp_eff_core ve_core = +and string_of_val_exp_eff forprint ve = string_of_val_exp_eff_core forprint ve.ve_core +and string_of_val_exp_eff_core forprint ve_core = match ve_core with | CallByPosLic (by_pos_op_eff, vel) -> (* ICI : on pourrait afficher en commentaire l'éventuel type_matches ? *) - (string_of_by_pos_op_eff by_pos_op_eff vel) + (string_of_by_pos_op_eff forprint by_pos_op_eff vel) | Merge (ve, [({it=Bool_const_eff true }, ct); ({it=Bool_const_eff false}, cf)]) | Merge (ve, [({it=Bool_const_eff false}, cf); ({it=Bool_const_eff true}, ct)]) -> if global_opt.lv4 then ( - "if " ^ (string_of_val_exp_eff ve) ^ " then current (" ^ - (string_of_val_exp_eff ct) ^ ") else current (" ^ - (string_of_val_exp_eff cf) ^")" + "if " ^ (string_of_val_exp_eff forprint ve) ^ " then current (" ^ + (string_of_val_exp_eff forprint ct) ^ ") else current (" ^ + (string_of_val_exp_eff forprint cf) ^")" ) else ( if global_opt.kcg then ( - "merge ( " ^ (string_of_val_exp_eff ve) ^ ";" ^ - (string_of_val_exp_eff ct) ^ "when " ^(string_of_val_exp_eff ve) ^ ";" ^ - (string_of_val_exp_eff cf) ^ "when not " ^ (string_of_val_exp_eff ve) ^ ")" + "merge ( " ^ (string_of_val_exp_eff forprint ve) ^ ";" ^ + (string_of_val_exp_eff forprint ct) ^ "when " ^(string_of_val_exp_eff forprint ve) ^ ";" ^ + (string_of_val_exp_eff forprint cf) ^ "when not " ^ (string_of_val_exp_eff forprint ve) ^ ")" ) else ( - "merge " ^ (string_of_val_exp_eff ve) ^ " (true -> " ^ - (string_of_val_exp_eff ct) ^ ") (false -> "^ (string_of_val_exp_eff cf) ^")" + "merge " ^ (string_of_val_exp_eff forprint ve) ^ " (true -> " ^ + (string_of_val_exp_eff forprint ct) ^ ") (false -> "^ (string_of_val_exp_eff forprint cf) ^")" ) ) | Merge (ve, cl) -> ( @@ -610,7 +639,7 @@ and string_of_val_exp_eff_core ve_core = | [On((cc,cv,Bool_type_eff),_)] -> cv | _ -> assert false (* SNO *) in - let expr = string_of_val_exp_eff ve in + let expr = string_of_val_exp_eff forprint ve in clk, expr in let print_case c = @@ -623,25 +652,25 @@ and string_of_val_exp_eff_core ve_core = let str = (String.concat "" cl_str) ^ last_case in str ) else ( - "merge " ^ (string_of_val_exp_eff ve) ^ " " ^ + "merge " ^ (string_of_val_exp_eff forprint ve) ^ " " ^ (String.concat " " (List.map - (fun (id,ve) -> "( "^(string_of_const_eff id.it) ^ " -> " ^ - (string_of_val_exp_eff ve)^" )") + (fun (id,ve) -> "( "^(string_of_const_eff forprint id.it) ^ " -> " ^ + (string_of_val_exp_eff forprint ve)^" )") cl) ) ) ) | CallByNameLic(by_name_op_eff, fl) -> (match by_name_op_eff.it with - | STRUCT (long) -> (Lv6Id.string_of_long long) - | STRUCT_with (long, _dft) -> (Lv6Id.string_of_long long) + | STRUCT (long) -> (Lv6Id.string_of_long forprint long) + | STRUCT_with (long, _dft) -> (Lv6Id.string_of_long forprint long) | STRUCT_anonymous -> "" ) ^ ( "{" ^ (String.concat ";" (List.map (fun (id,veff) -> - let str = string_of_val_exp_eff veff in + let str = string_of_val_exp_eff forprint veff in (Lv6Id.to_string id.it) ^ "=" ^ (if is_a_tuple veff then ("("^ str^")") else str) ) @@ -669,79 +698,80 @@ and wrap_long_line str = new_str ^ " " ^ reste -and string_of_eq_info_eff (leff_list, vee) = - let str = string_of_val_exp_eff vee in +and string_of_eq_info_eff forprint (leff_list, vee) = + let str = string_of_val_exp_eff forprint vee in wrap_long_line ( - (string_of_leff_list leff_list) ^ " = " ^ + (string_of_leff_list forprint leff_list) ^ " = " ^ (if is_a_tuple vee then ("("^ str^")") else str) ^ ";") -and (string_of_assert : Lic.val_exp srcflagged -> string ) = - fun eq_eff -> +and (string_of_assert : bool -> Lic.val_exp srcflagged -> string ) = + fun forprint eq_eff -> wrap_long_line ( - if global_opt.kcg then "assume " ^ FreshName.local_var "A" ^ ": " ^ string_of_val_exp_eff eq_eff.it ^ ";" + if global_opt.kcg then "assume " ^ FreshName.local_var "A" ^ ": " + ^ string_of_val_exp_eff forprint eq_eff.it ^ ";" else - "assert(" ^ string_of_val_exp_eff eq_eff.it ^ ");") + "assert(" ^ string_of_val_exp_eff forprint eq_eff.it ^ ");") -and (string_of_eq : Lic.eq_info srcflagged -> string) = - fun eq_eff -> - string_of_eq_info_eff eq_eff.it +and (string_of_eq : bool -> Lic.eq_info srcflagged -> string) = + fun forprint eq_eff -> + string_of_eq_info_eff forprint eq_eff.it and wrap_long_profile str = if String.length str < 75 then str else "\n"^(Str.global_replace (Str.regexp "returns") "\nreturns" str) -and (profile_of_node_exp_eff: Lic.node_exp -> string) = - fun neff -> - ("(" ^ (string_of_type_decl_list neff.inlist_eff "; ") ^ ") returns (" ^ - (string_of_type_decl_list neff.outlist_eff "; ") ^ ")") +and (profile_of_node_exp_eff: bool -> Lic.node_exp -> string) = + fun forprint neff -> + ("(" ^ (string_of_type_decl_list forprint neff.inlist_eff "; ") ^ ") returns (" ^ + (string_of_type_decl_list forprint neff.outlist_eff "; ") ^ ")") -and (string_of_node_def : Lic.node_def -> string list) = +and (string_of_node_def : bool -> Lic.node_def -> string list) = fun forprint -> function | ExternLic | MetaOpLic | AbstractLic _ -> [] | BodyLic node_body_eff -> List.append - (List.map string_of_assert node_body_eff.asserts_eff) - (List.map string_of_eq node_body_eff.eqs_eff) + (List.map (string_of_assert forprint) node_body_eff.asserts_eff) + (List.map (string_of_eq forprint)node_body_eff.eqs_eff) (* exported *) -and (type_decl: Lv6Id.long -> Lic.type_ -> string) = - fun tname teff -> +and (type_decl: bool -> Lv6Id.long -> Lic.type_ -> string) = + fun forprint tname teff -> if global_opt.kcg then match teff with | Enum_type_eff (_) -> - "type " ^ (dump_long tname) ^ " = " ^ (string_def_of_type_eff teff) ^ ";\n" + "type " ^ (dump_long forprint tname) ^ " = " ^ (string_def_of_type_eff forprint teff) ^ ";\n" | External_type_eff (_) | Abstract_type_eff(_,External_type_eff (_)) -> - "type imported " ^ (dump_long tname) ^ ";\n" - | _ -> "type " ^ (dump_long tname) ^ " = " ^ (string_def_of_type_eff teff) ^ ";\n" + "type imported " ^ (dump_long forprint tname) ^ ";\n" + | _ -> "type " ^ (dump_long forprint tname) ^ " = " ^ (string_def_of_type_eff forprint teff) ^ ";\n" else - "type " ^ (dump_long tname) ^ + "type " ^ (dump_long forprint tname) ^ (match teff with | Enum_type_eff (_) -> - " = " ^ (string_def_of_type_eff teff) ^ ";\n" + " = " ^ (string_def_of_type_eff forprint teff) ^ ";\n" | External_type_eff (_) | Abstract_type_eff(_,External_type_eff (_)) -> ";\n" - | _ -> " = " ^ (string_def_of_type_eff teff) ^ ";\n" + | _ -> " = " ^ (string_def_of_type_eff forprint teff) ^ ";\n" ) (* exported *) -and (const_decl: Lv6Id.long -> Lic.const -> string) = - fun tname ceff -> - let begin_str = ("const " ^ (dump_long tname)) in - let end_str = (string_of_const_eff ceff) ^ ";\n" in +and (const_decl: bool -> Lv6Id.long -> Lic.const -> string) = + fun forprint tname ceff -> + let begin_str = ("const " ^ (dump_long forprint tname)) in + let end_str = (string_of_const_eff forprint ceff) ^ ";\n" in (match ceff with | Enum_const_eff(id, t) -> "" | Extern_const_eff _ | Abstract_const_eff _ -> if global_opt.kcg then - "const imported " ^ (dump_long tname) ^ " : " ^ - (string_of_type_eff (Lic.type_of_const ceff)) ^ (";\n") + "const imported " ^ (dump_long forprint tname) ^ " : " ^ + (string_of_type_eff forprint (Lic.type_of_const ceff)) ^ (";\n") else - begin_str ^ " : " ^ (string_of_type_eff (Lic.type_of_const ceff)) ^ + begin_str ^ " : " ^ (string_of_type_eff forprint (Lic.type_of_const ceff)) ^ (* (if global_opt.ec then ".\n" else *) (";\n") | Struct_const_eff _ @@ -750,8 +780,8 @@ and (const_decl: Lv6Id.long -> Lic.const -> string) = | Int_const_eff _ | Real_const_eff _ -> if global_opt.kcg then - begin_str ^ ":" ^ (string_of_type_eff (Lic.type_of_const ceff)) ^ " = " ^ end_str - else begin_str ^ " = " ^ end_str + begin_str ^ ":" ^ (string_of_type_eff forprint (Lic.type_of_const ceff)) ^ + " = " ^ end_str else begin_str ^ " = " ^ end_str | Tuple_const_eff _ -> print_internal_error "LicDump.const_decl" "should not have been called for a tuple"; assert false @@ -759,7 +789,7 @@ and (const_decl: Lv6Id.long -> Lic.const -> string) = (* exported *) -and node_of_node_exp_eff (neff: Lic.node_exp): string = +and node_of_node_exp_eff forprint (neff: Lic.node_exp): string = wrap_long_profile ( ( if neff.is_safe_eff then "" else "unsafe " @@ -777,8 +807,8 @@ and node_of_node_exp_eff (neff: Lic.node_exp): string = )^(if global_opt.kcg then if neff.def_eff = ExternLic then "imported " else "" else "") - ^(string_of_node_key_rec global_opt.no_prefix neff.node_key_eff)^( - profile_of_node_exp_eff neff + ^(string_of_node_key_rec forprint global_opt.no_prefix neff.node_key_eff)^( + profile_of_node_exp_eff forprint neff ) ^ (match neff.def_eff with @@ -786,7 +816,7 @@ and node_of_node_exp_eff (neff: Lic.node_exp): string = | MetaOpLic -> ( (* on écrit juste un alias *) - " = " ^(string_of_node_key_def neff.node_key_eff)^ ";\n" + " = " ^(string_of_node_key_def forprint neff.node_key_eff)^ ";\n" ) | AbstractLic _ -> "; \n" | BodyLic _ -> ( @@ -796,13 +826,14 @@ and node_of_node_exp_eff (neff: Lic.node_exp): string = | Some [] -> "" | Some l -> let l = Lic.sort_var_info l in - ("var\n " ^ (string_of_type_decl_list l ";\n ") ^ ";\n" + ("var\n " ^ (string_of_type_decl_list forprint l ";\n ") ^ ";\n" ) ) ^ "let\n " ^ - (String.concat "\n " (string_of_node_def neff.def_eff)) ^ + (String.concat "\n " (string_of_node_def forprint neff.def_eff)) ^ "\ntel\n-- end of node " ^ - (string_of_node_key_rec (not global_opt.no_prefix) neff.node_key_eff) ^ "\n") + (string_of_node_key_rec forprint + (not global_opt.no_prefix) neff.node_key_eff) ^ "\n") ) ) @@ -819,7 +850,7 @@ and (string_of_ident_clk : Lv6Id.clk -> string) = match cc with | "Lustre","true" -> (Lv6Id.to_string v) | "Lustre","false" -> "not " ^ (Lv6Id.to_string v) - | _ -> + | _ -> (* if global_opt.lv4 || global_opt.ec then *) (* raise (Lv6errors.Global_error *) (* ("Cannot generate V4 style Lustre for programs with enumerated "^ *) @@ -862,7 +893,7 @@ and op2string op = Formatage standard des erreurs de compil ----------------------------------------------------------------------*) let node_error_string lxm nkey = ( - Printf.sprintf "While checking %s" (string_of_node_key_iter nkey) + Printf.sprintf "While checking %s" (string_of_node_key_iter false nkey) ) (*--------------------------------------------------------------------- diff --git a/src/licEvalType.ml b/src/licEvalType.ml index 1d39be53f6f337a1eaef72c6f7c869d6c56951ae..935d8fec1258c72c13356c35b4ceb2628de99730 100644 --- a/src/licEvalType.ml +++ b/src/licEvalType.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 22/06/2017 (at 08:40) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:33) by Erwan Jahier> *) open AstPredef open Lxm @@ -101,7 +101,7 @@ let get_node_and_int_const | (_, Abstract_const_eff(_,_,Int_const_eff c, true)) -> c | (_, zcl) -> let msg = "immediate integer expected, but get \"" - ^ (LicDump.string_of_const_eff zcl) + ^ (LicDump.string_of_const_eff false zcl) ^ "\"\n" in raise (Compile_error(lxm, msg)) in @@ -147,7 +147,8 @@ let condact_profile let dl = List.length dflt_types in let ol = List.length outlist in Lv6Verbose.exe ~flag:dbg ~level:3 (fun () -> - Lv6Verbose.printf " condact_profile: dflt=%s\n" (string_of_const_eff dflt)); + Lv6Verbose.printf " condact_profile: dflt=%s\n" + (string_of_const_eff false dflt)); let _ = if (dl <> ol) then raise_arity_error "in condact default arg" dl ol in let out_types = List.map (fun x -> x.var_type_eff) outlist in diff --git a/src/licMetaOp.ml b/src/licMetaOp.ml index 1af5930a7f98bf40e4fcea610d51090bac8a931a..50c4d080aba4b7f516b626b21a39409774af10b8 100644 --- a/src/licMetaOp.ml +++ b/src/licMetaOp.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 20/02/2017 (at 11:26) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:02) by Erwan Jahier> *) (* *) @@ -15,7 +15,7 @@ let get_node_and_int_const (lxm: Lxm.t) (sargs: Lic.static_arg list) | (_, Abstract_const_eff(_,_,Int_const_eff c, true)) -> c | (_, zcl) -> let msg = "immediate integer expected, but get \"" - ^ (LicDump.string_of_const_eff zcl) + ^ (LicDump.string_of_const_eff false zcl) ^ "\"\n" in raise (Compile_error(lxm, msg)) in @@ -104,8 +104,8 @@ and do_fillred nk2nd nk lxm = if t1 <> t2 then let msg = Printf.sprintf "node can't be used in iterator, first input type '%s' differs from first output type '%s'" - (LicDump.string_of_type_eff t1) - (LicDump.string_of_type_eff t2) + (LicDump.string_of_type_eff false t1) + (LicDump.string_of_type_eff false t2) in raise (Compile_error(lxm, msg)) else diff --git a/src/licPrg.ml b/src/licPrg.ml index 11013a317c20ec5aa9f23e5b60031cd5c14d478a..708e7ab36849a7b39a051494438f6ca95e70db8c 100644 --- a/src/licPrg.ml +++ b/src/licPrg.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 28/06/2017 (at 17:21) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:06) by Erwan Jahier> *) open Lv6MainArgs module ItemKeyMap = struct @@ -107,12 +107,14 @@ let add_const (k:Lic.item_key) (v:Lic.const) (prg:t) : t = let add_node (k:Lic.node_key) (v:Lic.node_exp) (prg:t) : t = Lv6Verbose.exe ~level:3 (fun () -> - Printf.printf "## LicPrg.add_node %s\n" (LicDump.string_of_node_key_rec false k)); - { prg with nodes = NodeKeyMap.add k v prg.nodes } + Printf.printf "## LicPrg.add_node %s\n" + (LicDump.string_of_node_key_rec false false k)); + { prg with nodes = NodeKeyMap.add k v prg.nodes } let del_node (k:Lic.node_key) (prg:t) : t = Lv6Verbose.exe ~level:3 (fun () -> - Printf.printf "## LicPrg.del_node %s\n" (LicDump.string_of_node_key_rec false k)); + Printf.printf "## LicPrg.del_node %s\n" + (LicDump.string_of_node_key_rec false false k)); { prg with nodes = NodeKeyMap.remove k prg.nodes } @@ -153,7 +155,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = (* global_opt.Lv6MainArgs.kcg || *) (* Lv6MainArgs.global_opt.Lv6MainArgs.expand_enums = AsEnum) *) (* then *) - output_string opt.Lv6MainArgs.oc (LicDump.type_decl tn te) + output_string opt.Lv6MainArgs.oc (LicDump.type_decl true tn te) (* else *) (* () *) ) @@ -202,7 +204,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = match te with | Lic.Enum_type_eff(long, longl) -> output_string opt.Lv6MainArgs.oc - (LicDump.type_decl long (Lic.External_type_eff long)); + (LicDump.type_decl true long (Lic.External_type_eff long)); List.rev_append (List.map (fun x -> long,x) longl) acc | _ -> acc ) @@ -212,7 +214,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = List.iter (fun (t,elt) -> let const = Lic.Extern_const_eff (elt, Lic.External_type_eff t) in - output_string opt.Lv6MainArgs.oc (LicDump.const_decl elt const)) + output_string opt.Lv6MainArgs.oc (LicDump.const_decl true elt const)) const_list; ) | Lv6MainArgs.AsInt -> @@ -222,7 +224,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = (List.iteri (fun i (t,elt) -> let const = Lic.Int_const_eff (string_of_int i) in - output_string opt.Lv6MainArgs.oc (LicDump.const_decl elt const)) + output_string opt.Lv6MainArgs.oc (LicDump.const_decl true elt const)) ) const_list; ) @@ -249,7 +251,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = (List.map (fun b -> Lic.Bool_const_eff(b)) bool_list, Lic.Bool_type_eff) in - output_string opt.Lv6MainArgs.oc (LicDump.const_decl elt const)) + output_string opt.Lv6MainArgs.oc (LicDump.const_decl true elt const)) ) l) const_list; @@ -260,7 +262,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = ItemKeyMap.iter (fun cn ce -> if (not Lv6MainArgs.global_opt.Lv6MainArgs.ec || Lic.is_extern_const ce) then - output_string opt.Lv6MainArgs.oc (LicDump.const_decl cn ce) + output_string opt.Lv6MainArgs.oc (LicDump.const_decl true cn ce) ) this.consts ; if Lv6MainArgs.global_opt.Lv6MainArgs.ec then ( @@ -269,7 +271,8 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = (fun (key,_) nexp -> ( if nexp.Lic.def_eff = Lic.ExternLic && Lv6Id.pack_of_long key <> "Lustre" then ( let str = (if nexp.Lic.has_mem_eff then "extern node " else "function ") ^ - (Lv6Id.of_long key)^(LicDump.profile_of_node_exp_eff nexp)^".\n" + (Lv6Id.of_long key)^ + (LicDump.profile_of_node_exp_eff true nexp)^".\n" in output_string opt.Lv6MainArgs.oc (str); flush opt.Lv6MainArgs.oc; @@ -300,7 +303,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = ) this.nodes with Print_me nexp -> - output_string opt.Lv6MainArgs.oc (LicDump.node_of_node_exp_eff nexp); + output_string opt.Lv6MainArgs.oc (LicDump.node_of_node_exp_eff true nexp); flush opt.Lv6MainArgs.oc; ) else ( (* Pour les noeuds, pas sur que ça marche tant qu'on n'a @@ -318,7 +321,7 @@ let to_file (opt: Lv6MainArgs.t) (this:t) (main_node: Lv6Id.idref option) = match nexp.Lic.node_key_eff with (* inutile d'écrire les noeuds predefs *) | (("Lustre",_),[]) -> () - | _ -> output_string opt.Lv6MainArgs.oc (LicDump.node_of_node_exp_eff nexp) + | _ -> output_string opt.Lv6MainArgs.oc (LicDump.node_of_node_exp_eff true nexp) ) this.nodes ) diff --git a/src/licTab.ml b/src/licTab.ml index 356deb7c21eaef509f5df174ba93a4279e853d9c..19f3a13268ee662d482e13992347f6853e45c197 100644 --- a/src/licTab.ml +++ b/src/licTab.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 02/01/2017 (at 11:45) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:53) by Erwan Jahier> *) open Lxm @@ -193,7 +193,7 @@ let x_check let x_def = match find_x x_pack_symbols xn lxm with | AstTabSymbol.Local x_def -> x_def | AstTabSymbol.Imported (lid,_) -> - print_string ("*** " ^ (Lv6Id.string_of_long lid) ^ "???\n" ^ + print_string ("*** " ^ (Lv6Id.string_of_long false lid) ^ "???\n" ^ (Lxm.details lxm)); assert false (* should not occur *) in @@ -427,7 +427,7 @@ let rec type_check (lxm: Lxm.t) : Lic.type_ = Lv6Verbose.exe ~flag:dbg (fun () -> - Printf.printf "#DBG: licTab.type_check '%s'\n" (Lv6Id.string_of_long key)); + Printf.printf "#DBG: licTab.type_check '%s'\n" (Lv6Id.string_of_long false key)); x_check this.types AstTabSymbol.find_type type_check_do type_builtin lookup_type_eff Lv6Id.pack_of_long Lv6Id.of_long this key lxm @@ -439,7 +439,7 @@ and const_check (lxm: Lxm.t) : Lic.const = Lv6Verbose.exe ~flag:dbg (fun() -> Printf.printf - "#DBG: licTab.const_check '%s'\n" (Lv6Id.string_of_long key)); + "#DBG: licTab.const_check '%s'\n" (Lv6Id.string_of_long false key)); x_check this.consts AstTabSymbol.find_const const_check_do const_builtin lookup_const_eff Lv6Id.pack_of_long Lv6Id.of_long this @@ -452,7 +452,7 @@ and type_check_interface (lxm: Lxm.t) : Lic.type_ = Lv6Verbose.exe ~flag:dbg (fun() -> Printf.printf - "#DBG: licTab.type_check_interface '%s'\n" (Lv6Id.string_of_long key)); + "#DBG: licTab.type_check_interface '%s'\n" (Lv6Id.string_of_long false key)); x_check_interface this.prov_types AstTabSymbol.find_type type_check type_check_interface_do type_builtin lookup_type_eff Lv6Id.pack_of_long Lv6Id.of_long this @@ -465,7 +465,7 @@ and const_check_interface (lxm: Lxm.t) : Lic.const = Lv6Verbose.exe ~flag:dbg (fun () -> Printf.printf - "#DBG: licTab.const_check_interface '%s'\n" (Lv6Id.string_of_long key)); + "#DBG: licTab.const_check_interface '%s'\n" (Lv6Id.string_of_long false key)); x_check_interface this.prov_consts AstTabSymbol.find_const const_check const_check_interface_do const_builtin lookup_const_eff Lv6Id.pack_of_long Lv6Id.of_long this @@ -748,7 +748,7 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> if t1 = t2 or t1 is abstract and and t2. *) let msg_prefix = - ("provided node for " ^ (Lv6Id.string_of_long (fst nk)) ^ + ("provided node for " ^ (Lv6Id.string_of_long false (fst nk)) ^ " is not compatible with its implementation: ") in let str_of_var = Lic.string_of_var_info in @@ -870,7 +870,7 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> Lv6Verbose.exe ~level:3 ( fun () -> Printf.printf "*** Dont find type %s in local_env\n" - (Lv6Id.string_of_idref id); + (Lv6Id.string_of_idref false id); Printf.printf "*** local_env.lenv_types contain def for: "; Hashtbl.iter (fun id t -> @@ -946,9 +946,10 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> let id_key = ("", id) in try ( let ce = lookup_const_eff temp_const_eff_tab id_key lxm in - Lv6Verbose.exe ~level:3 (fun() -> Printf.printf - " * const %s already treated = %s\n" - id (LicDump.string_of_const_eff ce)); + Lv6Verbose.exe + ~level:3 (fun() -> Printf.printf + " * const %s already treated = %s\n" + id (LicDump.string_of_const_eff false ce)); ce ) with Not_found -> ( let (lxmdef, toptdef, vedef) = Hashtbl.find temp_const_def_tab id in @@ -973,8 +974,9 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> | [] -> assert false (* should not occur *) | _::_ -> raise (Compile_error(lxmdef, "bad constant value: tuple not allowed")) in - Lv6Verbose.exe ~level:3 (fun() -> Printf.printf " * const %s evaluated to %s\n" - id (LicDump.string_of_const_eff ce)); + Lv6Verbose.exe + ~level:3 (fun() -> Printf.printf " * const %s evaluated to %s\n" + id (LicDump.string_of_const_eff false ce)); Hashtbl.replace temp_const_eff_tab id_key (Checked ce) ; ce ) @@ -993,10 +995,10 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> (* not a local constant -> search in global env *) Lv6Verbose.printf ~level:3 " * %s not a local const, should be global ?" - (Lv6Id.string_of_idref idrf); + (Lv6Id.string_of_idref false idrf); let ce = node_id_solver.id2const idrf lxm in Lv6Verbose.exe ~level:3 (fun() -> Printf.printf - " YES -> %s\n" (LicDump.string_of_const_eff ce)); + " YES -> %s\n" (LicDump.string_of_const_eff false ce)); ce ) ) in @@ -1005,15 +1007,15 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> temp_const_def_tab ; (* Finally, adds each local const to ICI *) let add_local_const idref ceck = ( - Lv6Verbose.exe ~level:3 - (fun() -> Printf.printf - " * add_local_const %s = %s\n" - (snd idref) - (match ceck with - | Checking -> "Checking" - | Checked ce -> (LicDump.string_of_const_eff ce) - | Incorrect -> "Incorrect" - )); + Lv6Verbose.exe + ~level:3 + (fun() -> Printf.printf + " * add_local_const %s = %s\n" (snd idref) + (match ceck with + | Checking -> "Checking" + | Checked ce -> (LicDump.string_of_const_eff false ce) + | Incorrect -> "Incorrect" + )); match ceck with | Checked ce -> Hashtbl.add local_env.lenv_const (snd idref) ce | _ -> assert false @@ -1208,7 +1210,7 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> : node_exp = Lv6Verbose.printf ~level:3 - "*** Lic.make_alias_node %s \n" (Lv6Id.long_to_string (fst alias_nk)); + "*** Lic.make_alias_node %s \n" (Lv6Id.string_of_long false (fst alias_nk)); flush stdout; let (outs:left list) = List.map (fun vi -> LeftVarLic (vi, lxm)) vol in @@ -1301,9 +1303,9 @@ and (node_check_interface_do: t -> Lic.node_key -> Lxm.t -> ) with Recursion_error (n, stack) -> let msg = "Recursion loop detected in node " ^ - (Lv6Id.string_of_long (fst nk)) in - let msg = msg ^ "\n*** "^ (Lv6Id.string_of_long n) ^ " depends on itself\n " - ^ (String.concat "\n*****" stack) in + (Lv6Id.string_of_long false (fst nk)) in + let msg = msg ^ "\n*** "^ (Lv6Id.string_of_long false n) ^ + " depends on itself\n " ^ (String.concat "\n*****" stack) in raise (Compile_error (lxm, msg)) and node_check_interface @@ -1340,12 +1342,12 @@ let compile_all_item this label x_check_interface string_of_x_key let compile_all_types pack_name this = - compile_all_item this "type" type_check_interface Lv6Id.string_of_long + compile_all_item this "type" type_check_interface (Lv6Id.string_of_long false) Lic.string_of_type (fun id -> Lv6Id.make_long pack_name id) let compile_all_constants pack_name this = - compile_all_item this "const" const_check_interface Lv6Id.string_of_long - LicDump.string_of_const_eff (fun id -> Lv6Id.make_long pack_name id) + compile_all_item this "const" const_check_interface (Lv6Id.string_of_long false) + (LicDump.string_of_const_eff true) (fun id -> Lv6Id.make_long pack_name id) let (get_static_params : (node_info Lxm.srcflagged) AstTabSymbol.elt -> @@ -1360,7 +1362,7 @@ let compile_all_nodes pack_name this id ni_f = if sp <> [] then () (* we need static arg to compile such kind of things *) else compile_all_item this "node" node_check_interface - (LicDump.string_of_node_key_rec false ) + (LicDump.string_of_node_key_rec true false) Lic.profile_of_node_exp (fun id -> (Lv6Id.make_long pack_name id, [])) id ni_f @@ -1421,7 +1423,7 @@ let compile_all (this:t) : t = this with Recursion_error (n, stack) -> - let msg = "Recursion loop detected in node " ^ (Lv6Id.string_of_long n) in + let msg = "Recursion loop detected in node " ^ (Lv6Id.string_of_long false n) in let msg = msg ^ "\n*****" ^ (String.concat "\n*****" stack) in raise (Compile_error (Lxm.dummy "", msg)) @@ -1431,7 +1433,7 @@ let compile_node (this:t) (main_node:Lv6Id.idref) : t = profile_info "LicTab.compile_node\n"; Lv6Verbose.printf "-- MAIN NODE: \"%s\"\n" - (LicDump.string_of_node_key_rec false main_node_key); + (LicDump.string_of_node_key_rec true false main_node_key); let lxm = match Lv6Id.pack_of_idref main_node with | None -> Lxm.dummy "" diff --git a/src/lv6Compile.ml b/src/lv6Compile.ml index 32078660a04bf98aaafaadc9a56cc77f46919164..f7f79a27d39cfbe73db48c70cb638e97bec0b2ea 100644 --- a/src/lv6Compile.ml +++ b/src/lv6Compile.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 04/07/2017 (at 15:55) by Erwan Jahier> *) +(* Time-stamp: <modified the 17/08/2017 (at 16:12) by Erwan Jahier> *) open Lxm open Lv6errors @@ -63,7 +63,7 @@ let expand_nodes opt main_node zelic = in assert (nodes_to_keep <> []); profile_info ("Expanding the following node calls: " - ^(String.concat "," (List.map Lv6Id.string_of_idref ids_to_expand))^"\n"); + ^(String.concat "," (List.map (Lv6Id.string_of_idref false) ids_to_expand))^"\n"); profile_info ("Keeping the following node calls: " ^(String.concat "," (List.map Lic.string_of_node_key nodes_to_keep))^"\n"); L2lExpandNodes.doit nodes_to_keep zelic @@ -128,17 +128,28 @@ let when_on_idents opt zelic = (* should be done after L2lOptimIte, as it introduces some 'when' *) if not Lv6MainArgs.global_opt.Lv6MainArgs.when_on_ident then zelic else ( profile_info "Creating ident on when statements if necessary...\n"; - L2lWhenOnId.doit zelic) + L2lWhenOnId.doit zelic) + let no_when_not opt zelic = if not Lv6MainArgs.global_opt.Lv6MainArgs.no_when_not then zelic else ( profile_info "Replace 'when not' statements by new variables...\n"; L2lNoWhenNot.doit zelic) -let check_loops opt zelic = - if Lv6MainArgs.global_opt.Lv6MainArgs.ec then ( +let check_loops opt zelic main_node = profile_info "Check loops...\n"; - L2lCheckLoops.doit zelic - ) + (* let zelic = if opt.Lv6MainArgs.expand_arrays then zelic else + (* L2lCheckLoops only works if struct and array are expanded *) + L2lExpandArrays.doit zelic + in + L2lCheckLoops.doit zelic *) + (* The dep loop check is done by Lic2soc.f + nb : we need to do this check before removing aliases. + because if there is a loop, the remove alias pass is wrong + *) + match main_node with + | None -> () + (* LicPrg.iter_nodes (fun n _ -> ignore(Lic2soc.f zelic n)) zelic *) + | Some mn -> ignore(Lic2soc.f zelic (Lic.node_key_of_idref mn)) let check_decl opt zelic = profile_info "Check safety and memory declarations...\n"; @@ -195,10 +206,10 @@ let (doit : Lv6MainArgs.t -> AstV6.pack_or_model list -> Lv6Id.idref option -> let zelic = expand_nodes opt main_node zelic in (* after split *) let zelic = no_when_not opt zelic in let zelic = expand_arrays opt zelic in (* after expand_nodes - and remove_polymorphism *) - let zelic = remove_aliases opt zelic in + and remove_polymorphism *) + check_loops opt zelic main_node; + let zelic = remove_aliases opt zelic in (* after check_loops *) (* let zelic = alias_arrays opt zelic in *) - check_loops opt zelic; check_outputs opt zelic; profile_info "Lic Compilation done!\n"; zelic diff --git a/src/lv6Id.ml b/src/lv6Id.ml index bb72704f61802447c5aae7865fe1d3dfeacb4c78..770907f6bb4a5f9f02945dd1684333422fe751d8 100644 --- a/src/lv6Id.ml +++ b/src/lv6Id.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 20/09/2016 (at 14:31) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:59) by Erwan Jahier> *) (* J'ai appele ca symbol (mais ca remplace le ident) : c'est juste une couche qui garantit l'unicite en memoire @@ -63,8 +63,9 @@ let (pack_name_of_string : string -> pack_name) = let (pack_name_to_string : pack_name -> string) = fun x -> x -let (string_of_long : long -> string) = - fun (pn, id) -> +let (string_of_long: bool -> long -> string) = + fun forprint (pn, id) -> + if forprint then let sep = if Lv6MainArgs.global_opt.Lv6MainArgs.ec || Lv6MainArgs.global_opt.Lv6MainArgs.lv4 then "__" else "::" @@ -74,29 +75,25 @@ let (string_of_long : long -> string) = | "Lustre","true" -> "true" | "Lustre","false" -> "false" | _,_ -> - (* if Lv6MainArgs.global_opt.Lv6MainArgs.no_prefix then id else *) + (* if Lv6MainArgs.global_opt.Lv6MainArgs.no_prefix then id else *) Printf.sprintf "%s%s%s" pn sep id - -let (string_of_long2 : long -> string) = - fun (pn, id) -> - Printf.sprintf "%s::%s" pn id + else if pn = "" then id else + Printf.sprintf "%s::%s" pn id let (no_pack_string_of_long : long -> string) = fun (pn, id) -> id -let (long_to_string : long -> string) = - string_of_long - -let (string_of_long_bis : long -> string) = fun x -> +let (string_of_long_bis : bool -> long -> string) = + fun forprint x -> if Lv6MainArgs.global_opt.Lv6MainArgs.kcg then no_pack_string_of_long x else if Lv6MainArgs.global_opt.Lv6MainArgs.no_prefix then no_pack_string_of_long x else - string_of_long x + string_of_long forprint x let (make_long : pack_name -> t -> long) = @@ -143,20 +140,16 @@ let (long_of_string : string -> long) = | [p;i]-> p, i | _ -> raise (Failure ("idref_of_string: \""^s^"\" not a proper ident")) -let string_of_idref i = ( +let string_of_idref forprint i = ( match i.id_pack with - Some p -> - if Lv6MainArgs.global_opt.Lv6MainArgs.no_prefix then i.id_id else + Some p -> + if not forprint then (p^"::"^i.id_id) else + if Lv6MainArgs.global_opt.Lv6MainArgs.no_prefix then i.id_id else if Lv6MainArgs.global_opt.Lv6MainArgs.ec then p^"__"^i.id_id else - if Lv6MainArgs.global_opt.Lv6MainArgs.lv4 then (p^"__"^i.id_id) else + if Lv6MainArgs.global_opt.Lv6MainArgs.lv4 then (p^"__"^i.id_id) else (p^"::"^i.id_id) | None -> i.id_id ) -let string_of_idref_bis i = ( - match i.id_pack with - Some p -> (p^"::"^i.id_id) - | None -> i.id_id -) let raw_string_of_idref i = ( let p = match i.id_pack with | Some p -> "Some \""^p^"\"" @@ -170,9 +163,9 @@ let (wrap_idref : idref -> string -> string -> idref) = fun { id_pack = p ; id_id = id } pref suff -> { id_pack = p ; id_id = of_string (pref ^ (to_string id)^suff) } -let (of_idref : idref -> t) = - fun idref -> - of_string (string_of_idref idref) +let (of_idref : bool -> idref -> t) = + fun forprint idref -> + of_string (string_of_idref forprint idref) let (to_idref : t -> idref) = fun id -> idref_of_string (to_string id) @@ -199,8 +192,8 @@ let (make_idref : pack_name -> t -> idref) = type clk = long * t -let (string_of_clk : clk -> string) = +let (string_of_clk :clk -> string) = fun (cc,cv) -> - (string_of_long cc) ^ "(" ^ (to_string cv) ^ ")" + (string_of_long false cc) ^ "(" ^ (to_string cv) ^ ")" (*************************************************************************) diff --git a/src/lv6Id.mli b/src/lv6Id.mli index 8cdc1bb18f504ca246c2025d86f49e6a8f5d5eac..498b323b03863558959df80f14f4c31f3fb19a4c 100644 --- a/src/lv6Id.mli +++ b/src/lv6Id.mli @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 20/09/2016 (at 14:15) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:48) by Erwan Jahier> *) (** *) @@ -14,14 +14,12 @@ val pack_name_of_string : string -> pack_name val pack_name_to_string : pack_name -> string val pack_of_long : long -> pack_name -val string_of_long : long -> string -val string_of_long_bis : long -> string -val string_of_long2 : long -> string +val string_of_long : bool -> long -> string +val string_of_long_bis : bool -> long -> string val long_of_string : string -> long (** To ignore pack name (meaningful when generating ec code for exemple *) val no_pack_string_of_long : long -> string -val long_to_string : long -> string val make_long : pack_name -> t -> long @@ -52,10 +50,9 @@ val idref_of_string : string -> idref val make_idref : pack_name -> t -> idref -val string_of_idref : idref -> string -val string_of_idref_bis : idref -> string +val string_of_idref : bool -> idref -> string val raw_string_of_idref : idref -> string -val of_idref : idref -> t +val of_idref : bool -> idref -> t val to_idref : t -> idref val name_of_idref : idref -> t diff --git a/src/lv6MainArgs.ml b/src/lv6MainArgs.ml index 608d2ca4e52ee220469663cec201215d824defc0..298f7415e6eb4e0f031fdee763ceb7d93af8fe92 100644 --- a/src/lv6MainArgs.ml +++ b/src/lv6MainArgs.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 10/07/2017 (at 13:36) by Erwan Jahier> *) +(* Time-stamp: <modified the 17/08/2017 (at 18:18) by Erwan Jahier> *) (* Le manager d'argument adapté de celui de lutin, plus joli N.B. solution un peu batarde : les options sont stockées, comme avant, dans Global, @@ -37,7 +37,7 @@ type t = { mutable oc : Pervasives.out_channel; mutable tlex : bool; mutable exec : bool; - mutable gen_c : bool; + mutable gen_c: bool; mutable rif : bool; mutable gen_ocaml : bool; mutable launch_cc : bool; @@ -352,8 +352,9 @@ let mkoptab (opt:t) : unit = ( ["-esa"; "--expand-structs-and-arrays"] (Arg.Unit (fun _ -> opt.expand_arrays <- true; + opt.expand_nodes <- true; opt.inline_iterator <- true)) - ["Expand structures and arrays (forces '-ei')"] + ["Expand structures and arrays (forces '-ei' and '-en')"] ; mkopt opt ~doc_level:Advanced ["-en"; "--expand-nodes"] diff --git a/src/lv6version.ml b/src/lv6version.ml index 34892f45901cc68ea51357913e9a7c5a2ef24b0d..464d8451eb6e94c5a3448890a1c23ea8a0980767 100644 --- a/src/lv6version.ml +++ b/src/lv6version.ml @@ -1,7 +1,7 @@ (** Automatically generated from Makefile *) let tool = "lus2lic" let branch = "master" -let commit = "709" -let sha_1 = "fdd977a6a66cd5c069e3efffa039de0880522887" +let commit = "710" +let sha_1 = "70354a0738db94a4a5c9494ff378b49750a8388f" let str = (branch ^ "." ^ commit ^ " (" ^ sha_1 ^ ")") let maintainer = "jahier@imag.fr" diff --git a/src/main.ml b/src/main.ml index 44799a59192979a1692281fd247949eb66e9293c..930db8aeda7e52cfa5f8242a8b7bb24c4098aa01 100644 --- a/src/main.ml +++ b/src/main.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 03/07/2017 (at 10:22) by Erwan Jahier> *) +(* Time-stamp: <modified the 20/07/2017 (at 17:09) by Erwan Jahier> *) open Lv6Verbose open AstV6 diff --git a/src/soc2cIdent.ml b/src/soc2cIdent.ml index e852593c880bdf446d4c08396cca840d52dc8942..3ef1d78acb5c159a4fbf06bf042c62545b006b2b 100644 --- a/src/soc2cIdent.ml +++ b/src/soc2cIdent.ml @@ -1,10 +1,12 @@ -(* Time-stamp: <modified the 07/10/2016 (at 10:48) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 17:04) by Erwan Jahier> *) open Soc let colcol = Str.regexp "::" let id2s id = (* XXX Refuser les noms de module à la con plutot *) let str = match Str.split colcol id with + | ["Lustre";"true"] -> "_true" (* a good idea to do that here ? *) + | ["Lustre";"false"] -> "_false" | ["true"] -> "_true" (* a good idea to do that here ? *) | ["false"] -> "_false" | [s] -> s @@ -14,7 +16,7 @@ let id2s id = (* XXX Refuser les noms de module à la con plutot *) let str = Str.global_replace colcol "_" str in str -let long2s l = id2s (Lv6Id.string_of_long l) +let long2s l = id2s (Lv6Id.string_of_long false l) let rec (type_to_short_string : Data.t -> string) = fun v -> diff --git a/src/soc2cUtil.ml b/src/soc2cUtil.ml index 0064d6ae0cfe4f26b78a85993d99ab839aa16646..815982e34cd03b76ba6284daf1ed1371453b270a 100644 --- a/src/soc2cUtil.ml +++ b/src/soc2cUtil.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 26/06/2017 (at 17:00) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 16:55) by Erwan Jahier> *) open Soc2cIdent open Data @@ -262,15 +262,16 @@ let (gen_c_switch : string -> (string * string) list -> string) = fun cond_var cases -> if Lv6MainArgs.global_opt.Lv6MainArgs.soc2c_no_switch then let l = List.map - (fun (v,code) -> Printf.sprintf " if (%s == %s) {\n%s\n } else {\n" cond_var v code) - cases + (fun (v,code) -> + Printf.sprintf " if (%s == %s) {\n%s\n } else {\n" cond_var v code) + cases in let switch = String.concat "" l in let closing_curly = String.concat "" (List.map (fun _ -> "}") cases) in Printf.sprintf "%s %s" switch closing_curly else let case_list = List.map - (fun (v, code) -> Printf.sprintf " case %s:\n%s break;\n" v code) cases + (fun (v, code) -> Printf.sprintf " case %s:\n%s break;\n" v code) cases in let cases = String.concat "" case_list in Printf.sprintf " switch (%s){\n%s}\n" cond_var cases diff --git a/src/socExecEvalPredef.ml b/src/socExecEvalPredef.ml index c0d5d56b05dacc2826e10977f0654463c5bfd03c..5ba06b2ba1a63e643a131ffb207647240b26c64b 100644 --- a/src/socExecEvalPredef.ml +++ b/src/socExecEvalPredef.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 25/11/2016 (at 18:11) by Erwan Jahier> *) +(* Time-stamp: <modified the 16/08/2017 (at 16:07) by Erwan Jahier> *) open SocExecValue open Data @@ -9,17 +9,20 @@ open Soc let type_error v1 v2 = Printf.eprintf "Runtime error: '%s' and '%s' have different types.\n" (Data.val_to_string string_of_float v1) (Data.val_to_string string_of_float v2); - flush stderr + flush stderr; + exit 2 let type_error1 v1 str = Printf.eprintf "Runtime error: '%s' is not a '%s'\n" (Data.val_to_string string_of_float v1) str; - flush stderr + flush stderr; + exit 2 let type_error2 v1 v2 str = Printf.eprintf "Runtime error: '%s' and/or '%s' are/is not a %s\n" (Data.val_to_string string_of_float v1) (Data.val_to_string string_of_float v2) str; - flush stderr + flush stderr; + exit 2 let (lustre_plus : ctx -> ctx) = fun ctx -> diff --git a/src/socExecValue.ml b/src/socExecValue.ml index 7e1800f3d336a405c8288908b8e92ca9ce90e890..fcc82c7ca7a56c7164622443dc8315fb50fd05ac 100644 --- a/src/socExecValue.ml +++ b/src/socExecValue.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 25/11/2016 (at 16:45) by Erwan Jahier> *) +(* Time-stamp: <modified the 16/08/2017 (at 17:13) by Erwan Jahier> *) let dbg = (Lv6Verbose.get_flag "exec") @@ -255,8 +255,8 @@ let (get_enum : ident -> ctx -> ident) = fun id ctx -> match get_val id ctx with | E(e,_) -> e - | B true -> "true" - | B false -> "false" + | B true -> "Lustre::true" + | B false -> "Lustre::false" | U -> (* print_string (id ^ " undefined\n"); flush stdout; *) raise Not_found diff --git a/src/socPredef.ml b/src/socPredef.ml index 4d180b318b03c9066bac81c0eaad0b76ed5a44fa..2efbdf76b54f4df13c5f592de59f4ea253ddc31e 100644 --- a/src/socPredef.ml +++ b/src/socPredef.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 20/02/2017 (at 11:28) by Erwan Jahier> *) +(* Time-stamp: <modified the 17/08/2017 (at 18:39) by Erwan Jahier> *) (** Synchronous Object Code for Predefined operators. *) @@ -33,7 +33,9 @@ let (soc_profile_of_types_nary : Data.t list -> var list * var list) = fun vl -> match vl with | ta::Bool::[] -> ["i1", ta], ["out",Bool] - | _ -> assert false (* sno *) + | _ -> + let inputs = List.mapi (fun i t -> assert(t=Bool); "i"^(string_of_int i),t) vl in + List.tl inputs, ["out",Bool] let step11 str = { (* a useful alias again *) @@ -196,7 +198,7 @@ let of_soc_key : Soc.key -> Soc.t = impl = Gaol([], [Case((fst cv),[ - (Lv6Id.string_of_long cc, [Call([Var(mem)], + (Lv6Id.string_of_long false cc, [Call([Var(mem)], Assign, [Var(vin)], dummy)])], dummy); @@ -281,7 +283,11 @@ let of_soc_key : Soc.key -> Soc.t = | "Lustre::nor" -> let size = match sk with | _,[Array(Bool,size);_],_ -> size - | _ -> failwith "-esa in not compatible with -2c nor -exec when using nor, sorry" + | _,bools,_ -> + if List.exists (fun t -> t<>Bool) bools then + failwith "type error in nor" + else + List.length bools in { Soc.key = sk; @@ -303,7 +309,11 @@ let of_soc_key : Soc.key -> Soc.t = | "Lustre::diese" -> let size = match sk with | _,[Array(Bool,size);_],_ -> size - | _ -> failwith "-esa in not compatible with -2c nor -exec when using #, sorry" + | _,bools,_ -> + if List.exists (fun t -> t<>Bool) bools then + failwith "type error in #" + else + List.length bools in { Soc.key = sk; @@ -482,20 +492,29 @@ let make_hat_soc: int -> Data.t -> Soc.t = } let output_type_of_op op tl = - match op with + match op with (* beurk, pas bô *) | "Lustre::eq" | "Lustre::neq" - | "Lustre::lt" - | "Lustre::gt" - | "Lustre::lte" - | "Lustre::gte" + | "Lustre::lt" | "Lustre::rlt" | "Lustre::ilt" + | "Lustre::gt" | "Lustre::rgt" | "Lustre::igt" + | "Lustre::lte"| "Lustre::rlte" | "Lustre::ilte" + | "Lustre::gte"| "Lustre::rgte" | "Lustre::igte" | "Lustre::nor" | "Lustre::diese" -> Bool | "Lustre::real2int" -> Int | "Lustre::int2real" -> Real | "Lustre::if" -> assert(tl<>[]);List.hd (List.tl tl) - | _ -> List.hd tl + | "Lustre::hat" -> assert false (* sno? *) + | "Lustre::array" -> assert false (* sno? *) + | "Lustre::concat" -> assert false (* sno? *) + | "Lustre::arrow" -> assert false (* sno? *) + | "Lustre::current" -> assert false + | "Lustre::array_slice" -> assert false (* sno? *) + + | _ -> + (* in all other cases, the outpout type is the same as the first input (really?)*) + List.hd tl let (soc_interface_of_pos_op: Lxm.t -> Lic.by_pos_op -> Data.t list -> Soc.var_expr option -> Soc.t) = @@ -508,7 +527,7 @@ let (soc_interface_of_pos_op: instanciate_soc soc concrete_type | Lic.PREDEF_CALL {Lxm.it=(op,sargs)}, _, _ -> assert (sargs=[]); - let soc_name = Lv6Id.string_of_long op in + let soc_name = Lv6Id.string_of_long false op in let out_type = output_type_of_op soc_name types in let soc = of_soc_key (soc_name, types@[out_type], Nomore) in soc diff --git a/src/socUtils.ml b/src/socUtils.ml index 033edf0be263b204e6d5e7d8ced69ad0e1fe5e2b..a2404578783b363a1d2472f474fc75fc03dfb3bc 100644 --- a/src/socUtils.ml +++ b/src/socUtils.ml @@ -1,4 +1,4 @@ -(** Time-stamp: <modified the 11/07/2017 (at 17:02) by Erwan Jahier> *) +(** Time-stamp: <modified the 21/07/2017 (at 15:30) by Erwan Jahier> *) open Soc @@ -80,7 +80,7 @@ let string_of_soc_key_ff: (Soc.key -> Format.formatter -> unit) = (String.concat " -> " (List.map string_of_type_ref types))); (match si_opt with | Nomore -> () - | Curr(cc) -> fprintf ff "%s" (Lv6Id.string_of_long cc) + | Curr(cc) -> fprintf ff "%s" (Lv6Id.string_of_long false cc) | Slic(f,l,step) -> fprintf ff "[%d .. %d step %d]" f l step | MemInit ve -> string_of_filter_ff ve ff ) diff --git a/src/sortActions.ml b/src/sortActions.ml index 238957fc721b0671efb9af64e0dccbda109feced..00d93ca9bd48e12f7f7641df504783f09b57c0eb 100644 --- a/src/sortActions.ml +++ b/src/sortActions.ml @@ -1,4 +1,4 @@ -(** Time-stamp: <modified the 18/07/2017 (at 11:01) by Erwan Jahier> *) +(** Time-stamp: <modified the 21/07/2017 (at 15:31) by Erwan Jahier> *) (** topological sort of actions (that may optimize test openning) *) @@ -34,7 +34,7 @@ let rec (gao_of_action: Action.t -> Soc.gao) = | Lic.BaseLic -> acc | Lic.ClockVar i -> acc (* should not occur? *) | Lic.On((value, cvar, _ctyp), outter_clock) -> - let cc = Lv6Id.string_of_long value in + let cc = Lv6Id.string_of_long false value in let acc = Soc.Case (cvar, [cc, [acc]], lxm) in unpack_clock acc outter_clock in diff --git a/src/unifyClock.ml b/src/unifyClock.ml index 9de8b1ba6dd8be5e045cb0d344b46ad3425f2618..9eb49a1ed59bd482487e53525ca5678fac24fd82 100644 --- a/src/unifyClock.ml +++ b/src/unifyClock.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 20/02/2017 (at 11:32) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 16:44) by Erwan Jahier> *) (* XXX a revoir et faire comme expliqué ici : http://www.cs.cornell.edu/courses/cs3110/2011sp/lectures/lec26-type-inference/type-inference.htm diff --git a/src/unifyType.ml b/src/unifyType.ml index 5065c1d9d36e2c82e4388cf625cae2a76839c6ec..191afa1bfb1021dada668755bdb3615ebc0db0d2 100644 --- a/src/unifyType.ml +++ b/src/unifyType.ml @@ -1,4 +1,4 @@ -(* Time-stamp: <modified the 27/05/2016 (at 16:02) by Erwan Jahier> *) +(* Time-stamp: <modified the 21/07/2017 (at 15:31) by Erwan Jahier> *) (* 12/07. Premier pas vers une méthode un peu plus standard : @@ -269,7 +269,7 @@ let (profile_is_compatible: node_key -> Lxm.t -> Lic.type_ list * Lic.type_ list | Abstract_type_eff(name, _) -> (TypeVar Any) | t -> t in - let msg_prefix = ("provided node for " ^ (Lv6Id.string_of_long (fst nk)) ^ + let msg_prefix = ("provided node for " ^ (Lv6Id.string_of_long false (fst nk)) ^ " is not compatible with its implementation: ") in let apply_subst s t = try List.assoc t s with Not_found -> t in diff --git a/test/lus2lic.sum b/test/lus2lic.sum index 6ee598b03a14b7001b2e0a72aae0b05cbec4806b..411ee23aea23fb370bc839a051b756606a8cb019 100644 --- a/test/lus2lic.sum +++ b/test/lus2lic.sum @@ -1,5 +1,5 @@ ==> lus2lic0.sum <== -Test Run By jahier on Tue Jul 18 11:26:32 +Test Run By jahier on Thu Aug 17 18:43:14 Native configuration is x86_64-unknown-linux-gnu === lus2lic0 tests === @@ -66,7 +66,7 @@ XFAIL: Test bad programs (assert): test_lus2lic_no_node should_fail/assert/lecte XFAIL: Test bad programs (assert): test_lus2lic_no_node should_fail/assert/s.lus ==> lus2lic1.sum <== -Test Run By jahier on Tue Jul 18 11:26:33 +Test Run By jahier on Thu Aug 17 18:43:15 Native configuration is x86_64-unknown-linux-gnu === lus2lic1 tests === @@ -412,7 +412,7 @@ PASS: sh multipar.sh PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c multipar.lus {} ==> lus2lic2.sum <== -Test Run By jahier on Tue Jul 18 11:27:29 +Test Run By jahier on Thu Aug 17 18:44:08 Native configuration is x86_64-unknown-linux-gnu === lus2lic2 tests === @@ -546,7 +546,7 @@ PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c param_node4.lus {} PASS: ./lus2lic {-2c param_struct.lus -n param_struct} PASS: sh param_struct.sh PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c param_struct.lus {} -PASS: ./lus2lic --expand-nodes {-2c pilote.lus -n pilote} +FAIL: Generate c code : ./lus2lic --expand-nodes {-2c pilote.lus -n pilote} PASS: ./lus2lic {-2c pipeline.lus -n pipeline} PASS: sh pipeline.sh PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c pipeline.lus {} @@ -749,9 +749,10 @@ PASS: sh zzz.sh PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c zzz.lus {} PASS: ./lus2lic {-2c zzz2.lus -n zzz2} PASS: sh zzz2.sh +PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c zzz2.lus {} ==> lus2lic3.sum <== -Test Run By jahier on Tue Jul 18 11:28:29 +Test Run By jahier on Thu Aug 17 18:45:05 Native configuration is x86_64-unknown-linux-gnu === lus2lic3 tests === @@ -761,511 +762,511 @@ Schedule of variations: Running target unix Running ./lus2lic.tests/test3.exp ... -PASS: ./lus2lic {-o COUNTER.lic COUNTER.lus} +PASS: ./lus2lic {} {-o COUNTER.lic COUNTER.lus} PASS: ./lus2lic {-ec -o COUNTER.ec COUNTER.lus} PASS: ./myec2c {-o COUNTER.c COUNTER.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node COUNTER.lus {} -PASS: ./lus2lic {-o CURRENT.lic CURRENT.lus} +PASS: ./lus2lic {} {-o CURRENT.lic CURRENT.lus} PASS: ./lus2lic {-ec -o CURRENT.ec CURRENT.lus} PASS: ./myec2c {-o CURRENT.c CURRENT.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node CURRENT.lus {} -PASS: ./lus2lic {-o Condact.lic Condact.lus} +PASS: ./lus2lic {} {-o Condact.lic Condact.lus} PASS: ./lus2lic {-ec -o Condact.ec Condact.lus} PASS: ./myec2c {-o Condact.c Condact.ec} -PASS: ./lus2lic {-o EDGE.lic EDGE.lus} +PASS: ./lus2lic {} {-o EDGE.lic EDGE.lus} PASS: ./lus2lic {-ec -o EDGE.ec EDGE.lus} PASS: ./myec2c {-o EDGE.c EDGE.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node EDGE.lus {} -PASS: ./lus2lic {-o ELMU.lic ELMU.lus} +PASS: ./lus2lic {} {-o ELMU.lic ELMU.lus} PASS: ./lus2lic {-ec -o ELMU.ec ELMU.lus} PASS: ./myec2c {-o ELMU.c ELMU.ec} -PASS: ./lus2lic {-o FALLING_EDGE.lic FALLING_EDGE.lus} +PASS: ./lus2lic {} {-o FALLING_EDGE.lic FALLING_EDGE.lus} PASS: ./lus2lic {-ec -o FALLING_EDGE.ec FALLING_EDGE.lus} PASS: ./myec2c {-o FALLING_EDGE.c FALLING_EDGE.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node FALLING_EDGE.lus {} -PASS: ./lus2lic {-o FillFollowedByRed.lic FillFollowedByRed.lus} +PASS: ./lus2lic {} {-o FillFollowedByRed.lic FillFollowedByRed.lus} PASS: ./lus2lic {-ec -o FillFollowedByRed.ec FillFollowedByRed.lus} PASS: ./myec2c {-o FillFollowedByRed.c FillFollowedByRed.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node FillFollowedByRed.lus {} -PASS: ./lus2lic {-o Gyroscope.lic Gyroscope.lus} +PASS: ./lus2lic {} {-o Gyroscope.lic Gyroscope.lus} PASS: ./lus2lic {-ec -o Gyroscope.ec Gyroscope.lus} PASS: ./myec2c {-o Gyroscope.c Gyroscope.ec} UNRESOLVED: Time out: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node Gyroscope.lus {} -PASS: ./lus2lic {-o Gyroscope2.lic Gyroscope2.lus} +PASS: ./lus2lic {} {-o Gyroscope2.lic Gyroscope2.lus} PASS: ./lus2lic {-ec -o Gyroscope2.ec Gyroscope2.lus} PASS: ./myec2c {-o Gyroscope2.c Gyroscope2.ec} UNRESOLVED: Time out: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node Gyroscope2.lus {} -PASS: ./lus2lic {-o aa.lic aa.lus} +PASS: ./lus2lic {} {-o aa.lic aa.lus} PASS: ./lus2lic {-ec -o aa.ec aa.lus} PASS: ./myec2c {-o aa.c aa.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node aa.lus {} -PASS: ./lus2lic {-o access.lic access.lus} +PASS: ./lus2lic {} {-o access.lic access.lus} PASS: ./lus2lic {-ec -o access.ec access.lus} PASS: ./myec2c {-o access.c access.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node access.lus {} -PASS: ./lus2lic {-o activation1.lic activation1.lus} +PASS: ./lus2lic { --expand-nodes} {-o activation1.lic activation1.lus} PASS: ./lus2lic {-ec -o activation1.ec activation1.lus} PASS: ./myec2c {-o activation1.c activation1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node activation1.lus { --expand-nodes} -PASS: ./lus2lic {-o activation2.lic activation2.lus} +PASS: ./lus2lic { --expand-nodes} {-o activation2.lic activation2.lus} PASS: ./lus2lic {-ec -o activation2.ec activation2.lus} PASS: ./myec2c {-o activation2.c activation2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node activation2.lus { --expand-nodes} -PASS: ./lus2lic {-o activation_ec.lic activation_ec.lus} +PASS: ./lus2lic {} {-o activation_ec.lic activation_ec.lus} PASS: ./lus2lic {-ec -o activation_ec.ec activation_ec.lus} PASS: ./myec2c {-o activation_ec.c activation_ec.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node activation_ec.lus {} -PASS: ./lus2lic {-o after.lic after.lus} +PASS: ./lus2lic {} {-o after.lic after.lus} PASS: ./lus2lic {-ec -o after.ec after.lus} PASS: ./myec2c {-o after.c after.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node after.lus {} -PASS: ./lus2lic {-o alias.lic alias.lus} +PASS: ./lus2lic {} {-o alias.lic alias.lus} PASS: ./lus2lic {-ec -o alias.ec alias.lus} PASS: ./myec2c {-o alias.c alias.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node alias.lus {} -PASS: ./lus2lic {-o amaury.lic amaury.lus} +PASS: ./lus2lic {} {-o amaury.lic amaury.lus} PASS: ./lus2lic {-ec -o amaury.ec amaury.lus} PASS: ./myec2c {-o amaury.c amaury.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node amaury.lus {} -PASS: ./lus2lic {-o arbitre.lic arbitre.lus} +PASS: ./lus2lic {} {-o arbitre.lic arbitre.lus} PASS: ./lus2lic {-ec -o arbitre.ec arbitre.lus} PASS: ./myec2c {-o arbitre.c arbitre.ec} -PASS: ./lus2lic {-o argos.lic argos.lus} +PASS: ./lus2lic {} {-o argos.lic argos.lus} PASS: ./lus2lic {-ec -o argos.ec argos.lus} PASS: ./myec2c {-o argos.c argos.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node argos.lus {} -PASS: ./lus2lic {-o array_concat.lic array_concat.lus} +PASS: ./lus2lic {} {-o array_concat.lic array_concat.lus} PASS: ./lus2lic {-ec -o array_concat.ec array_concat.lus} PASS: ./myec2c {-o array_concat.c array_concat.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node array_concat.lus {} -PASS: ./lus2lic {-o array_concat2.lic array_concat2.lus} +PASS: ./lus2lic {} {-o array_concat2.lic array_concat2.lus} PASS: ./lus2lic {-ec -o array_concat2.ec array_concat2.lus} PASS: ./myec2c {-o array_concat2.c array_concat2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node array_concat2.lus {} -PASS: ./lus2lic {-o array_equals.lic array_equals.lus} +PASS: ./lus2lic {} {-o array_equals.lic array_equals.lus} PASS: ./lus2lic {-ec -o array_equals.ec array_equals.lus} PASS: ./myec2c {-o array_equals.c array_equals.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node array_equals.lus {} -PASS: ./lus2lic {-o arrays.lic arrays.lus} +PASS: ./lus2lic {} {-o arrays.lic arrays.lus} PASS: ./lus2lic {-ec -o arrays.ec arrays.lus} PASS: ./myec2c {-o arrays.c arrays.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node arrays.lus {} -PASS: ./lus2lic {-o asservi.lic asservi.lus} +PASS: ./lus2lic { --expand-nodes} {-o asservi.lic asservi.lus} PASS: ./lus2lic {-ec -o asservi.ec asservi.lus} PASS: ./myec2c {-o asservi.c asservi.ec} -PASS: ./lus2lic {-o bad_call03.lic bad_call03.lus} +PASS: ./lus2lic {} {-o bad_call03.lic bad_call03.lus} PASS: ./lus2lic {-ec -o bad_call03.ec bad_call03.lus} PASS: ./myec2c {-o bad_call03.c bad_call03.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node bad_call03.lus {} -PASS: ./lus2lic {-o bascule.lic bascule.lus} +PASS: ./lus2lic {} {-o bascule.lic bascule.lus} PASS: ./lus2lic {-ec -o bascule.ec bascule.lus} PASS: ./myec2c {-o bascule.c bascule.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node bascule.lus {} -PASS: ./lus2lic {-o bob.lic bob.lus} +PASS: ./lus2lic {} {-o bob.lic bob.lus} PASS: ./lus2lic {-ec -o bob.ec bob.lus} PASS: ./myec2c {-o bob.c bob.ec} UNRESOLVED: Time out: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node bob.lus {} -PASS: ./lus2lic {-o bred.lic bred.lus} +PASS: ./lus2lic {} {-o bred.lic bred.lus} PASS: ./lus2lic {-ec -o bred.ec bred.lus} PASS: ./myec2c {-o bred.c bred.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node bred.lus {} -PASS: ./lus2lic {-o bred_lv4.lic bred_lv4.lus} +PASS: ./lus2lic {} {-o bred_lv4.lic bred_lv4.lus} PASS: ./lus2lic {-ec -o bred_lv4.ec bred_lv4.lus} PASS: ./myec2c {-o bred_lv4.c bred_lv4.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node bred_lv4.lus {} -PASS: ./lus2lic {-o bug.lic bug.lus} +PASS: ./lus2lic {} {-o bug.lic bug.lus} PASS: ./lus2lic {-ec -o bug.ec bug.lus} PASS: ./myec2c {-o bug.c bug.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node bug.lus {} -PASS: ./lus2lic {-o bug2.lic bug2.lus} +PASS: ./lus2lic {} {-o bug2.lic bug2.lus} PASS: ./lus2lic {-ec -o bug2.ec bug2.lus} PASS: ./myec2c {-o bug2.c bug2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node bug2.lus {} -FAIL: without any option: ./lus2lic {-o bug_map_fby.lic bug_map_fby.lus} -PASS: ./lus2lic {-o calculs_max.lic calculs_max.lus} +FAIL: without any option: ./lus2lic {} {-o bug_map_fby.lic bug_map_fby.lus} +PASS: ./lus2lic {} {-o calculs_max.lic calculs_max.lus} PASS: ./lus2lic {-ec -o calculs_max.ec calculs_max.lus} PASS: ./myec2c {-o calculs_max.c calculs_max.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node calculs_max.lus {} -PASS: ./lus2lic {-o call.lic call.lus} +PASS: ./lus2lic {} {-o call.lic call.lus} PASS: ./lus2lic {-ec -o call.ec call.lus} PASS: ./myec2c {-o call.c call.ec} -PASS: ./lus2lic {-o call01.lic call01.lus} +PASS: ./lus2lic {} {-o call01.lic call01.lus} PASS: ./lus2lic {-ec -o call01.ec call01.lus} PASS: ./myec2c {-o call01.c call01.ec} -PASS: ./lus2lic {-o call02.lic call02.lus} +PASS: ./lus2lic {} {-o call02.lic call02.lus} PASS: ./lus2lic {-ec -o call02.ec call02.lus} PASS: ./myec2c {-o call02.c call02.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node call02.lus {} -PASS: ./lus2lic {-o call03.lic call03.lus} +PASS: ./lus2lic {} {-o call03.lic call03.lus} PASS: ./lus2lic {-ec -o call03.ec call03.lus} PASS: ./myec2c {-o call03.c call03.ec} -PASS: ./lus2lic {-o call04.lic call04.lus} +PASS: ./lus2lic {} {-o call04.lic call04.lus} PASS: ./lus2lic {-ec -o call04.ec call04.lus} PASS: ./myec2c {-o call04.c call04.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node call04.lus {} -PASS: ./lus2lic {-o call05.lic call05.lus} +PASS: ./lus2lic {} {-o call05.lic call05.lus} PASS: ./lus2lic {-ec -o call05.ec call05.lus} PASS: ./myec2c {-o call05.c call05.ec} -PASS: ./lus2lic {-o call06.lic call06.lus} +PASS: ./lus2lic {} {-o call06.lic call06.lus} PASS: ./lus2lic {-ec -o call06.ec call06.lus} PASS: ./myec2c {-o call06.c call06.ec} -PASS: ./lus2lic {-o call07.lic call07.lus} +PASS: ./lus2lic {} {-o call07.lic call07.lus} PASS: ./lus2lic {-ec -o call07.ec call07.lus} PASS: ./myec2c {-o call07.c call07.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node call07.lus {} -PASS: ./lus2lic {-o carV2.lic carV2.lus} +PASS: ./lus2lic {} {-o carV2.lic carV2.lus} PASS: ./lus2lic {-ec -o carV2.ec carV2.lus} PASS: ./myec2c {-o carV2.c carV2.ec} -PASS: ./lus2lic {-o carligths.lic carligths.lus} +PASS: ./lus2lic {} {-o carligths.lic carligths.lus} PASS: ./lus2lic {-ec -o carligths.ec carligths.lus} PASS: ./myec2c {-o carligths.c carligths.ec} -PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node carligths.lus {} -PASS: ./lus2lic {-o ck2.lic ck2.lus} +UNRESOLVED: Time out: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node carligths.lus {} +PASS: ./lus2lic {} {-o ck2.lic ck2.lus} PASS: ./lus2lic {-ec -o ck2.ec ck2.lus} PASS: ./myec2c {-o ck2.c ck2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ck2.lus {} -PASS: ./lus2lic {-o ck3.lic ck3.lus} +PASS: ./lus2lic {} {-o ck3.lic ck3.lus} PASS: ./lus2lic {-ec -o ck3.ec ck3.lus} PASS: ./myec2c {-o ck3.c ck3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ck3.lus {} -PASS: ./lus2lic {-o ck4.lic ck4.lus} +PASS: ./lus2lic {} {-o ck4.lic ck4.lus} PASS: ./lus2lic {-ec -o ck4.ec ck4.lus} PASS: ./myec2c {-o ck4.c ck4.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ck4.lus {} -PASS: ./lus2lic {-o ck5.lic ck5.lus} +PASS: ./lus2lic {} {-o ck5.lic ck5.lus} PASS: ./lus2lic {-ec -o ck5.ec ck5.lus} PASS: ./myec2c {-o ck5.c ck5.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ck5.lus {} -FAIL: without any option: ./lus2lic {-o ck6.lic ck6.lus} -PASS: ./lus2lic {-o ck7.lic ck7.lus} +FAIL: without any option: ./lus2lic {} {-o ck6.lic ck6.lus} +PASS: ./lus2lic {} {-o ck7.lic ck7.lus} PASS: ./lus2lic {-ec -o ck7.ec ck7.lus} PASS: ./myec2c {-o ck7.c ck7.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ck7.lus {} -PASS: ./lus2lic {-o clock1_2ms.lic clock1_2ms.lus} +PASS: ./lus2lic {} {-o clock1_2ms.lic clock1_2ms.lus} PASS: ./lus2lic {-ec -o clock1_2ms.ec clock1_2ms.lus} PASS: ./myec2c {-o clock1_2ms.c clock1_2ms.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node clock1_2ms.lus {} -PASS: ./lus2lic {-o clock_ite.lic clock_ite.lus} +PASS: ./lus2lic {} {-o clock_ite.lic clock_ite.lus} PASS: ./lus2lic {-ec -o clock_ite.ec clock_ite.lus} PASS: ./myec2c {-o clock_ite.c clock_ite.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node clock_ite.lus {} -PASS: ./lus2lic {-o cminus.lic cminus.lus} +PASS: ./lus2lic {} {-o cminus.lic cminus.lus} PASS: ./lus2lic {-ec -o cminus.ec cminus.lus} PASS: ./myec2c {-o cminus.c cminus.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node cminus.lus {} -PASS: ./lus2lic {-o complex.lic complex.lus} +PASS: ./lus2lic {} {-o complex.lic complex.lus} PASS: ./lus2lic {-ec -o complex.ec complex.lus} PASS: ./myec2c {-o complex.c complex.ec} -PASS: ./lus2lic {-o compteur.lic compteur.lus} +PASS: ./lus2lic {} {-o compteur.lic compteur.lus} PASS: ./lus2lic {-ec -o compteur.ec compteur.lus} PASS: ./myec2c {-o compteur.c compteur.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node compteur.lus {} -PASS: ./lus2lic {-o cond01.lic cond01.lus} +PASS: ./lus2lic {} {-o cond01.lic cond01.lus} PASS: ./lus2lic {-ec -o cond01.ec cond01.lus} PASS: ./myec2c {-o cond01.c cond01.ec} FAIL: Try to compare lus2lic -exec and ecexe: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node cond01.lus {} -PASS: ./lus2lic {-o consensus.lic consensus.lus} +PASS: ./lus2lic {} {-o consensus.lic consensus.lus} PASS: ./lus2lic {-ec -o consensus.ec consensus.lus} PASS: ./myec2c {-o consensus.c consensus.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node consensus.lus {} -PASS: ./lus2lic {-o consensus2.lic consensus2.lus} +PASS: ./lus2lic {} {-o consensus2.lic consensus2.lus} PASS: ./lus2lic {-ec -o consensus2.ec consensus2.lus} PASS: ./myec2c {-o consensus2.c consensus2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node consensus2.lus {} -PASS: ./lus2lic {-o contractForElementSelectionInArray.lic contractForElementSelectionInArray.lus} +PASS: ./lus2lic {} {-o contractForElementSelectionInArray.lic contractForElementSelectionInArray.lus} PASS: ./lus2lic {-ec -o contractForElementSelectionInArray.ec contractForElementSelectionInArray.lus} PASS: ./myec2c {-o contractForElementSelectionInArray.c contractForElementSelectionInArray.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node contractForElementSelectionInArray.lus {} -PASS: ./lus2lic {-o convert.lic convert.lus} +PASS: ./lus2lic {} {-o convert.lic convert.lus} PASS: ./lus2lic {-ec -o convert.ec convert.lus} PASS: ./myec2c {-o convert.c convert.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node convert.lus {} -PASS: ./lus2lic {-o count.lic count.lus} +PASS: ./lus2lic {} {-o count.lic count.lus} PASS: ./lus2lic {-ec -o count.ec count.lus} PASS: ./myec2c {-o count.c count.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node count.lus {} -PASS: ./lus2lic {-o cpt.lic cpt.lus} +PASS: ./lus2lic {} {-o cpt.lic cpt.lus} PASS: ./lus2lic {-ec -o cpt.ec cpt.lus} PASS: ./myec2c {-o cpt.c cpt.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node cpt.lus {} -PASS: ./lus2lic {-o cst.lic cst.lus} +PASS: ./lus2lic {} {-o cst.lic cst.lus} PASS: ./lus2lic {-ec -o cst.ec cst.lus} PASS: ./myec2c {-o cst.c cst.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node cst.lus {} -FAIL: without any option: ./lus2lic {-o dadic_x5_a.lic dadic_x5_a.lus} -FAIL: without any option: ./lus2lic {-o dadic_x5_b.lic dadic_x5_b.lus} -FAIL: without any option: ./lus2lic {-o dadic_x5_c.lic dadic_x5_c.lus} -PASS: ./lus2lic {-o deSimone.lic deSimone.lus} +PASS: ./lus2lic { dadic.lv6} {-o dadic_x5_a.lic dadic_x5_a.lus} +PASS: ./lus2lic { dadic.lv6} {-o dadic_x5_b.lic dadic_x5_b.lus} +FAIL: without any option: ./lus2lic {} {-o dadic_x5_c.lic dadic_x5_c.lus} +PASS: ./lus2lic {} {-o deSimone.lic deSimone.lus} PASS: ./lus2lic {-ec -o deSimone.ec deSimone.lus} PASS: ./myec2c {-o deSimone.c deSimone.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node deSimone.lus {} -PASS: ./lus2lic {-o decl.lic decl.lus} +PASS: ./lus2lic {} {-o decl.lic decl.lus} PASS: ./lus2lic {-ec -o decl.ec decl.lus} PASS: ./myec2c {-o decl.c decl.ec} -PASS: ./lus2lic {-o declaration.lic declaration.lus} +PASS: ./lus2lic {} {-o declaration.lic declaration.lus} PASS: ./lus2lic {-ec -o declaration.ec declaration.lus} PASS: ./myec2c {-o declaration.c declaration.ec} -PASS: ./lus2lic {-o deconne.lic deconne.lus} +PASS: ./lus2lic {} {-o deconne.lic deconne.lus} PASS: ./lus2lic {-ec -o deconne.ec deconne.lus} PASS: ./myec2c {-o deconne.c deconne.ec} -PASS: ./lus2lic {-o dep.lic dep.lus} +PASS: ./lus2lic {} {-o dep.lic dep.lus} PASS: ./lus2lic {-ec -o dep.ec dep.lus} PASS: ./myec2c {-o dep.c dep.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node dep.lus {} -PASS: ./lus2lic {-o depend.lic depend.lus} +PASS: ./lus2lic {} {-o depend.lic depend.lus} PASS: ./lus2lic {-ec -o depend.ec depend.lus} PASS: ./myec2c {-o depend.c depend.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node depend.lus {} -PASS: ./lus2lic {-o dependeur.lic dependeur.lus} +PASS: ./lus2lic {} {-o dependeur.lic dependeur.lus} PASS: ./lus2lic {-ec -o dependeur.ec dependeur.lus} PASS: ./myec2c {-o dependeur.c dependeur.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node dependeur.lus {} -PASS: ./lus2lic {-o dependeur_struct.lic dependeur_struct.lus} +PASS: ./lus2lic {} {-o dependeur_struct.lic dependeur_struct.lus} PASS: ./lus2lic {-ec -o dependeur_struct.ec dependeur_struct.lus} PASS: ./myec2c {-o dependeur_struct.c dependeur_struct.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node dependeur_struct.lus {} -PASS: ./lus2lic {-o double_delay.lic double_delay.lus} +PASS: ./lus2lic {} {-o double_delay.lic double_delay.lus} PASS: ./lus2lic {-ec -o double_delay.ec double_delay.lus} PASS: ./myec2c {-o double_delay.c double_delay.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node double_delay.lus {} -PASS: ./lus2lic {-o ec.lic ec.lus} +PASS: ./lus2lic {} {-o ec.lic ec.lus} PASS: ./lus2lic {-ec -o ec.ec ec.lus} PASS: ./myec2c {-o ec.c ec.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ec.lus {} -PASS: ./lus2lic {-o enum0.lic enum0.lus} +PASS: ./lus2lic {} {-o enum0.lic enum0.lus} PASS: ./lus2lic {-ec -o enum0.ec enum0.lus} PASS: ./myec2c {-o enum0.c enum0.ec} -PASS: ./lus2lic {-o enum0_lv4.lic enum0_lv4.lus} +PASS: ./lus2lic {} {-o enum0_lv4.lic enum0_lv4.lus} PASS: ./lus2lic {-ec -o enum0_lv4.ec enum0_lv4.lus} PASS: ./myec2c {-o enum0_lv4.c enum0_lv4.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node enum0_lv4.lus {} -PASS: ./lus2lic {-o ex.lic ex.lus} +PASS: ./lus2lic {} {-o ex.lic ex.lus} PASS: ./lus2lic {-ec -o ex.ec ex.lus} PASS: ./myec2c {-o ex.c ex.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ex.lus {} -PASS: ./lus2lic {-o exclusion.lic exclusion.lus} +PASS: ./lus2lic {} {-o exclusion.lic exclusion.lus} PASS: ./lus2lic {-ec -o exclusion.ec exclusion.lus} PASS: ./myec2c {-o exclusion.c exclusion.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node exclusion.lus {} -PASS: ./lus2lic {-o filliter.lic filliter.lus} +PASS: ./lus2lic {} {-o filliter.lic filliter.lus} PASS: ./lus2lic {-ec -o filliter.ec filliter.lus} PASS: ./myec2c {-o filliter.c filliter.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node filliter.lus {} -PASS: ./lus2lic {-o filter.lic filter.lus} +PASS: ./lus2lic {} {-o filter.lic filter.lus} PASS: ./lus2lic {-ec -o filter.ec filter.lus} PASS: ./myec2c {-o filter.c filter.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node filter.lus {} -PASS: ./lus2lic {-o flo.lic flo.lus} +PASS: ./lus2lic {} {-o flo.lic flo.lus} PASS: ./lus2lic {-ec -o flo.ec flo.lus} PASS: ./myec2c {-o flo.c flo.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node flo.lus {} -PASS: ./lus2lic {-o followed_by.lic followed_by.lus} +PASS: ./lus2lic {} {-o followed_by.lic followed_by.lus} PASS: ./lus2lic {-ec -o followed_by.ec followed_by.lus} PASS: ./myec2c {-o followed_by.c followed_by.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node followed_by.lus {} -PASS: ./lus2lic {-o fresh_name.lic fresh_name.lus} +PASS: ./lus2lic {} {-o fresh_name.lic fresh_name.lus} PASS: ./lus2lic {-ec -o fresh_name.ec fresh_name.lus} PASS: ./myec2c {-o fresh_name.c fresh_name.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node fresh_name.lus {} -PASS: ./lus2lic {-o func_with_body.lic func_with_body.lus} +PASS: ./lus2lic {} {-o func_with_body.lic func_with_body.lus} PASS: ./lus2lic {-ec -o func_with_body.ec func_with_body.lus} PASS: ./myec2c {-o func_with_body.c func_with_body.ec} -PASS: ./lus2lic {-o hanane.lic hanane.lus} +PASS: ./lus2lic {} {-o hanane.lic hanane.lus} PASS: ./lus2lic {-ec -o hanane.ec hanane.lus} PASS: ./myec2c {-o hanane.c hanane.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node hanane.lus {} -PASS: ./lus2lic {-o heater_control.lic heater_control.lus} +PASS: ./lus2lic {} {-o heater_control.lic heater_control.lus} PASS: ./lus2lic {-ec -o heater_control.ec heater_control.lus} PASS: ./myec2c {-o heater_control.c heater_control.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node heater_control.lus {} -PASS: ./lus2lic {-o impl_priority.lic impl_priority.lus} +PASS: ./lus2lic {} {-o impl_priority.lic impl_priority.lus} PASS: ./lus2lic {-ec -o impl_priority.ec impl_priority.lus} PASS: ./myec2c {-o impl_priority.c impl_priority.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node impl_priority.lus {} -PASS: ./lus2lic {-o import1.lic import1.lus} +PASS: ./lus2lic {} {-o import1.lic import1.lus} PASS: ./lus2lic {-ec -o import1.ec import1.lus} PASS: ./myec2c {-o import1.c import1.ec} -PASS: ./lus2lic {-o initial.lic initial.lus} +PASS: ./lus2lic {} {-o initial.lic initial.lus} PASS: ./lus2lic {-ec -o initial.ec initial.lus} PASS: ./myec2c {-o initial.c initial.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node initial.lus {} -PASS: ./lus2lic {-o integrator.lic integrator.lus} +PASS: ./lus2lic {} {-o integrator.lic integrator.lus} PASS: ./lus2lic {-ec -o integrator.ec integrator.lus} PASS: ./myec2c {-o integrator.c integrator.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node integrator.lus {} -PASS: ./lus2lic {-o is_stable.lic is_stable.lus} +PASS: ./lus2lic {} {-o is_stable.lic is_stable.lus} PASS: ./lus2lic {-ec -o is_stable.ec is_stable.lus} PASS: ./myec2c {-o is_stable.c is_stable.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node is_stable.lus {} -PASS: ./lus2lic {-o iter.lic iter.lus} +PASS: ./lus2lic {} {-o iter.lic iter.lus} PASS: ./lus2lic {-ec -o iter.ec iter.lus} PASS: ./myec2c {-o iter.c iter.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node iter.lus {} -PASS: ./lus2lic {-o iterFibo.lic iterFibo.lus} +PASS: ./lus2lic {} {-o iterFibo.lic iterFibo.lus} PASS: ./lus2lic {-ec -o iterFibo.ec iterFibo.lus} PASS: ./myec2c {-o iterFibo.c iterFibo.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node iterFibo.lus {} -PASS: ./lus2lic {-o iterate.lic iterate.lus} +PASS: ./lus2lic {} {-o iterate.lic iterate.lus} PASS: ./lus2lic {-ec -o iterate.ec iterate.lus} PASS: ./myec2c {-o iterate.c iterate.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node iterate.lus {} -PASS: ./lus2lic {-o left.lic left.lus} +PASS: ./lus2lic {} {-o left.lic left.lus} PASS: ./lus2lic {-ec -o left.ec left.lus} PASS: ./myec2c {-o left.c left.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node left.lus {} -PASS: ./lus2lic {-o long_et_stupide_nom_de_noeud.lic long_et_stupide_nom_de_noeud.lus} +PASS: ./lus2lic {} {-o long_et_stupide_nom_de_noeud.lic long_et_stupide_nom_de_noeud.lus} PASS: ./lus2lic {-ec -o long_et_stupide_nom_de_noeud.ec long_et_stupide_nom_de_noeud.lus} PASS: ./myec2c {-o long_et_stupide_nom_de_noeud.c long_et_stupide_nom_de_noeud.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node long_et_stupide_nom_de_noeud.lus {} -PASS: ./lus2lic {-o lucky.lic lucky.lus} +PASS: ./lus2lic {} {-o lucky.lic lucky.lus} PASS: ./lus2lic {-ec -o lucky.ec lucky.lus} PASS: ./myec2c {-o lucky.c lucky.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node lucky.lus {} -PASS: ./lus2lic {-o lustre_test1_ok.lic lustre_test1_ok.lus} +PASS: ./lus2lic {} {-o lustre_test1_ok.lic lustre_test1_ok.lus} PASS: ./lus2lic {-ec -o lustre_test1_ok.ec lustre_test1_ok.lus} PASS: ./myec2c {-o lustre_test1_ok.c lustre_test1_ok.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node lustre_test1_ok.lus {} -PASS: ./lus2lic {-o map_red_iter.lic map_red_iter.lus} +PASS: ./lus2lic {} {-o map_red_iter.lic map_red_iter.lus} PASS: ./lus2lic {-ec -o map_red_iter.ec map_red_iter.lus} PASS: ./myec2c {-o map_red_iter.c map_red_iter.ec} -PASS: ./lus2lic {-o mapdeRed.lic mapdeRed.lus} +PASS: ./lus2lic {} {-o mapdeRed.lic mapdeRed.lus} PASS: ./lus2lic {-ec -o mapdeRed.ec mapdeRed.lus} PASS: ./myec2c {-o mapdeRed.c mapdeRed.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mapdeRed.lus {} -PASS: ./lus2lic {-o mapinf.lic mapinf.lus} +PASS: ./lus2lic {} {-o mapinf.lic mapinf.lus} PASS: ./lus2lic {-ec -o mapinf.ec mapinf.lus} PASS: ./myec2c {-o mapinf.c mapinf.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mapinf.lus {} -PASS: ./lus2lic {-o mapiter.lic mapiter.lus} +PASS: ./lus2lic {} {-o mapiter.lic mapiter.lus} PASS: ./lus2lic {-ec -o mapiter.ec mapiter.lus} PASS: ./myec2c {-o mapiter.c mapiter.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mapiter.lus {} -PASS: ./lus2lic {-o mappredef.lic mappredef.lus} +PASS: ./lus2lic {} {-o mappredef.lic mappredef.lus} PASS: ./lus2lic {-ec -o mappredef.ec mappredef.lus} PASS: ./myec2c {-o mappredef.c mappredef.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mappredef.lus {} -PASS: ./lus2lic {-o matrice.lic matrice.lus} +PASS: ./lus2lic {} {-o matrice.lic matrice.lus} PASS: ./lus2lic {-ec -o matrice.ec matrice.lus} PASS: ./myec2c {-o matrice.c matrice.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node matrice.lus {} -PASS: ./lus2lic {-o matrice2.lic matrice2.lus} +PASS: ./lus2lic {} {-o matrice2.lic matrice2.lus} PASS: ./lus2lic {-ec -o matrice2.ec matrice2.lus} PASS: ./myec2c {-o matrice2.c matrice2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node matrice2.lus {} -PASS: ./lus2lic {-o minmax1.lic minmax1.lus} +PASS: ./lus2lic {} {-o minmax1.lic minmax1.lus} PASS: ./lus2lic {-ec -o minmax1.ec minmax1.lus} PASS: ./myec2c {-o minmax1.c minmax1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node minmax1.lus {} -PASS: ./lus2lic {-o minmax2.lic minmax2.lus} +PASS: ./lus2lic {} {-o minmax2.lic minmax2.lus} PASS: ./lus2lic {-ec -o minmax2.ec minmax2.lus} PASS: ./myec2c {-o minmax2.c minmax2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node minmax2.lus {} -PASS: ./lus2lic {-o minmax3.lic minmax3.lus} +PASS: ./lus2lic {} {-o minmax3.lic minmax3.lus} PASS: ./lus2lic {-ec -o minmax3.ec minmax3.lus} PASS: ./myec2c {-o minmax3.c minmax3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node minmax3.lus {} -PASS: ./lus2lic {-o minmax4.lic minmax4.lus} +PASS: ./lus2lic {} {-o minmax4.lic minmax4.lus} PASS: ./lus2lic {-ec -o minmax4.ec minmax4.lus} PASS: ./myec2c {-o minmax4.c minmax4.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node minmax4.lus {} -PASS: ./lus2lic {-o minmax4_bis.lic minmax4_bis.lus} +PASS: ./lus2lic {} {-o minmax4_bis.lic minmax4_bis.lus} PASS: ./lus2lic {-ec -o minmax4_bis.ec minmax4_bis.lus} PASS: ./myec2c {-o minmax4_bis.c minmax4_bis.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node minmax4_bis.lus {} -PASS: ./lus2lic {-o minmax5.lic minmax5.lus} +PASS: ./lus2lic {} {-o minmax5.lic minmax5.lus} PASS: ./lus2lic {-ec -o minmax5.ec minmax5.lus} PASS: ./myec2c {-o minmax5.c minmax5.ec} -PASS: ./lus2lic {-o minmax5_random.lic minmax5_random.lus} +PASS: ./lus2lic {} {-o minmax5_random.lic minmax5_random.lus} PASS: ./lus2lic {-ec -o minmax5_random.ec minmax5_random.lus} PASS: ./myec2c {-o minmax5_random.c minmax5_random.ec} -PASS: ./lus2lic {-o minmax6.lic minmax6.lus} +PASS: ./lus2lic {} {-o minmax6.lic minmax6.lus} PASS: ./lus2lic {-ec -o minmax6.ec minmax6.lus} PASS: ./myec2c {-o minmax6.c minmax6.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node minmax6.lus {} -PASS: ./lus2lic {-o minus.lic minus.lus} +PASS: ./lus2lic {} {-o minus.lic minus.lus} PASS: ./lus2lic {-ec -o minus.ec minus.lus} PASS: ./myec2c {-o minus.c minus.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node minus.lus {} -PASS: ./lus2lic {-o mm.lic mm.lus} +PASS: ./lus2lic {} {-o mm.lic mm.lus} PASS: ./lus2lic {-ec -o mm.ec mm.lus} PASS: ./myec2c {-o mm.c mm.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mm.lus {} -PASS: ./lus2lic {-o mm1.lic mm1.lus} +PASS: ./lus2lic {} {-o mm1.lic mm1.lus} PASS: ./lus2lic {-ec -o mm1.ec mm1.lus} PASS: ./myec2c {-o mm1.c mm1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mm1.lus {} -PASS: ./lus2lic {-o mm22.lic mm22.lus} +PASS: ./lus2lic {} {-o mm22.lic mm22.lus} PASS: ./lus2lic {-ec -o mm22.ec mm22.lus} PASS: ./myec2c {-o mm22.c mm22.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mm22.lus {} -PASS: ./lus2lic {-o mm3.lic mm3.lus} +PASS: ./lus2lic {} {-o mm3.lic mm3.lus} PASS: ./lus2lic {-ec -o mm3.ec mm3.lus} PASS: ./myec2c {-o mm3.c mm3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mm3.lus {} -PASS: ./lus2lic {-o modelInst.lic modelInst.lus} +PASS: ./lus2lic {} {-o modelInst.lic modelInst.lus} PASS: ./lus2lic {-ec -o modelInst.ec modelInst.lus} PASS: ./myec2c {-o modelInst.c modelInst.ec} -PASS: ./lus2lic {-o modes3x2_v2.lic modes3x2_v2.lus} +PASS: ./lus2lic {} {-o modes3x2_v2.lic modes3x2_v2.lus} PASS: ./lus2lic {-ec -o modes3x2_v2.ec modes3x2_v2.lus} PASS: ./myec2c {-o modes3x2_v2.c modes3x2_v2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node modes3x2_v2.lus {} -PASS: ./lus2lic {-o modes3x2_v3.lic modes3x2_v3.lus} +PASS: ./lus2lic {} {-o modes3x2_v3.lic modes3x2_v3.lus} PASS: ./lus2lic {-ec -o modes3x2_v3.ec modes3x2_v3.lus} -PASS: ./lus2lic {-o modes3x2_v4.lic modes3x2_v4.lus} +PASS: ./lus2lic {} {-o modes3x2_v4.lic modes3x2_v4.lus} PASS: ./lus2lic {-ec -o modes3x2_v4.ec modes3x2_v4.lus} -FAIL: without any option: ./lus2lic {-o modes3x2_v4.lv4.lic modes3x2_v4.lv4.lus} -PASS: ./lus2lic {-o morel.lic morel.lus} +FAIL: without any option: ./lus2lic {} {-o modes3x2_v4.lv4.lic modes3x2_v4.lv4.lus} +PASS: ./lus2lic {} {-o morel.lic morel.lus} PASS: ./lus2lic {-ec -o morel.ec morel.lus} PASS: ./myec2c {-o morel.c morel.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node morel.lus {} -PASS: ./lus2lic {-o morel2.lic morel2.lus} +PASS: ./lus2lic {} {-o morel2.lic morel2.lus} PASS: ./lus2lic {-ec -o morel2.ec morel2.lus} PASS: ./myec2c {-o morel2.c morel2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node morel2.lus {} -PASS: ./lus2lic {-o morel3.lic morel3.lus} +PASS: ./lus2lic {} {-o morel3.lic morel3.lus} PASS: ./lus2lic {-ec -o morel3.ec morel3.lus} PASS: ./myec2c {-o morel3.c morel3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node morel3.lus {} -PASS: ./lus2lic {-o morel4.lic morel4.lus} +PASS: ./lus2lic {} {-o morel4.lic morel4.lus} PASS: ./lus2lic {-ec -o morel4.ec morel4.lus} PASS: ./myec2c {-o morel4.c morel4.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node morel4.lus {} -PASS: ./lus2lic {-o morel5.lic morel5.lus} +PASS: ./lus2lic {} {-o morel5.lic morel5.lus} PASS: ./lus2lic {-ec -o morel5.ec morel5.lus} PASS: ./myec2c {-o morel5.c morel5.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node morel5.lus {} -PASS: ./lus2lic {-o mouse.lic mouse.lus} +PASS: ./lus2lic {} {-o mouse.lic mouse.lus} PASS: ./lus2lic {-ec -o mouse.ec mouse.lus} PASS: ./myec2c {-o mouse.c mouse.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mouse.lus {} -PASS: ./lus2lic {-o mouse1.lic mouse1.lus} +PASS: ./lus2lic {} {-o mouse1.lic mouse1.lus} PASS: ./lus2lic {-ec -o mouse1.ec mouse1.lus} PASS: ./myec2c {-o mouse1.c mouse1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mouse1.lus {} -PASS: ./lus2lic {-o mouse2.lic mouse2.lus} +PASS: ./lus2lic {} {-o mouse2.lic mouse2.lus} PASS: ./lus2lic {-ec -o mouse2.ec mouse2.lus} PASS: ./myec2c {-o mouse2.c mouse2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mouse2.lus {} -PASS: ./lus2lic {-o mouse3.lic mouse3.lus} +PASS: ./lus2lic {} {-o mouse3.lic mouse3.lus} PASS: ./lus2lic {-ec -o mouse3.ec mouse3.lus} PASS: ./myec2c {-o mouse3.c mouse3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node mouse3.lus {} -PASS: ./lus2lic {-o moyenne.lic moyenne.lus} +PASS: ./lus2lic {} {-o moyenne.lic moyenne.lus} PASS: ./lus2lic {-ec -o moyenne.ec moyenne.lus} PASS: ./myec2c {-o moyenne.c moyenne.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node moyenne.lus {} -PASS: ./lus2lic {-o multiclock.lic multiclock.lus} +PASS: ./lus2lic {} {-o multiclock.lic multiclock.lus} PASS: ./lus2lic {-ec -o multiclock.ec multiclock.lus} PASS: ./myec2c {-o multiclock.c multiclock.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node multiclock.lus {} -PASS: ./lus2lic {-o multipar.lic multipar.lus} +PASS: ./lus2lic {} {-o multipar.lic multipar.lus} PASS: ./lus2lic {-ec -o multipar.ec multipar.lus} PASS: ./myec2c {-o multipar.c multipar.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node multipar.lus {} ==> lus2lic4.sum <== -Test Run By jahier on Tue Jul 18 11:30:43 +Test Run By jahier on Thu Aug 17 18:47:50 Native configuration is x86_64-unknown-linux-gnu === lus2lic4 tests === @@ -1275,474 +1276,474 @@ Schedule of variations: Running target unix Running ./lus2lic.tests/test4.exp ... -FAIL: without any option: ./lus2lic {-o PCOND.lic PCOND.lus} -FAIL: without any option: ./lus2lic {-o PCOND1.lic PCOND1.lus} -PASS: ./lus2lic {-o SOURIS.lic SOURIS.lus} +FAIL: without any option: ./lus2lic {} {-o PCOND.lic PCOND.lus} +FAIL: without any option: ./lus2lic {} {-o PCOND1.lic PCOND1.lus} +PASS: ./lus2lic {} {-o SOURIS.lic SOURIS.lus} PASS: ./lus2lic {-ec -o SOURIS.ec SOURIS.lus} PASS: ./myec2c {-o SOURIS.c SOURIS.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node SOURIS.lus {} -PASS: ./lus2lic {-o STABLE.lic STABLE.lus} +PASS: ./lus2lic {} {-o STABLE.lic STABLE.lus} PASS: ./lus2lic {-ec -o STABLE.ec STABLE.lus} PASS: ./myec2c {-o STABLE.c STABLE.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node STABLE.lus {} -PASS: ./lus2lic {-o SWITCH.lic SWITCH.lus} +PASS: ./lus2lic {} {-o SWITCH.lic SWITCH.lus} PASS: ./lus2lic {-ec -o SWITCH.ec SWITCH.lus} PASS: ./myec2c {-o SWITCH.c SWITCH.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node SWITCH.lus {} -PASS: ./lus2lic {-o SWITCH1.lic SWITCH1.lus} +PASS: ./lus2lic {} {-o SWITCH1.lic SWITCH1.lus} PASS: ./lus2lic {-ec -o SWITCH1.ec SWITCH1.lus} PASS: ./myec2c {-o SWITCH1.c SWITCH1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node SWITCH1.lus {} -PASS: ./lus2lic {-o TIME_STABLE.lic TIME_STABLE.lus} +PASS: ./lus2lic {} {-o TIME_STABLE.lic TIME_STABLE.lus} PASS: ./lus2lic {-ec -o TIME_STABLE.ec TIME_STABLE.lus} PASS: ./myec2c {-o TIME_STABLE.c TIME_STABLE.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node TIME_STABLE.lus {} -PASS: ./lus2lic {-o TIME_STABLE1.lic TIME_STABLE1.lus} +PASS: ./lus2lic {} {-o TIME_STABLE1.lic TIME_STABLE1.lus} PASS: ./lus2lic {-ec -o TIME_STABLE1.ec TIME_STABLE1.lus} PASS: ./myec2c {-o TIME_STABLE1.c TIME_STABLE1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node TIME_STABLE1.lus {} -PASS: ./lus2lic {-o Watch.lic Watch.lus} +PASS: ./lus2lic {} {-o Watch.lic Watch.lus} PASS: ./lus2lic {-ec -o Watch.ec Watch.lus} PASS: ./myec2c {-o Watch.c Watch.ec} -PASS: ./lus2lic {-o X.lic X.lus} +PASS: ./lus2lic {} {-o X.lic X.lus} PASS: ./lus2lic {-ec -o X.ec X.lus} PASS: ./myec2c {-o X.c X.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node X.lus {} -PASS: ./lus2lic {-o X2.lic X2.lus} +PASS: ./lus2lic {} {-o X2.lic X2.lus} PASS: ./lus2lic {-ec -o X2.ec X2.lus} PASS: ./myec2c {-o X2.c X2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node X2.lus {} -FAIL: without any option: ./lus2lic {-o X6.lic X6.lus} -PASS: ./lus2lic {-o Xr.lic Xr.lus} +FAIL: without any option: ./lus2lic {} {-o X6.lic X6.lus} +PASS: ./lus2lic {} {-o Xr.lic Xr.lus} PASS: ./lus2lic {-ec -o Xr.ec Xr.lus} PASS: ./myec2c {-o Xr.c Xr.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node Xr.lus {} -PASS: ./lus2lic {-o nc1.lic nc1.lus} +PASS: ./lus2lic {} {-o nc1.lic nc1.lus} PASS: ./lus2lic {-ec -o nc1.ec nc1.lus} PASS: ./myec2c {-o nc1.c nc1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc1.lus {} -PASS: ./lus2lic {-o nc10.lic nc10.lus} +PASS: ./lus2lic {} {-o nc10.lic nc10.lus} PASS: ./lus2lic {-ec -o nc10.ec nc10.lus} PASS: ./myec2c {-o nc10.c nc10.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc10.lus {} -PASS: ./lus2lic {-o nc2.lic nc2.lus} +PASS: ./lus2lic {} {-o nc2.lic nc2.lus} PASS: ./lus2lic {-ec -o nc2.ec nc2.lus} PASS: ./myec2c {-o nc2.c nc2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc2.lus {} -PASS: ./lus2lic {-o nc3.lic nc3.lus} +PASS: ./lus2lic {} {-o nc3.lic nc3.lus} PASS: ./lus2lic {-ec -o nc3.ec nc3.lus} PASS: ./myec2c {-o nc3.c nc3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc3.lus {} -PASS: ./lus2lic {-o nc4.lic nc4.lus} +PASS: ./lus2lic {} {-o nc4.lic nc4.lus} PASS: ./lus2lic {-ec -o nc4.ec nc4.lus} PASS: ./myec2c {-o nc4.c nc4.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc4.lus {} -PASS: ./lus2lic {-o nc5.lic nc5.lus} +PASS: ./lus2lic {} {-o nc5.lic nc5.lus} PASS: ./lus2lic {-ec -o nc5.ec nc5.lus} PASS: ./myec2c {-o nc5.c nc5.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc5.lus {} -PASS: ./lus2lic {-o nc6.lic nc6.lus} +PASS: ./lus2lic {} {-o nc6.lic nc6.lus} PASS: ./lus2lic {-ec -o nc6.ec nc6.lus} PASS: ./myec2c {-o nc6.c nc6.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc6.lus {} -PASS: ./lus2lic {-o nc7.lic nc7.lus} +PASS: ./lus2lic {} {-o nc7.lic nc7.lus} PASS: ./lus2lic {-ec -o nc7.ec nc7.lus} PASS: ./myec2c {-o nc7.c nc7.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc7.lus {} -PASS: ./lus2lic {-o nc8.lic nc8.lus} +PASS: ./lus2lic {} {-o nc8.lic nc8.lus} PASS: ./lus2lic {-ec -o nc8.ec nc8.lus} PASS: ./myec2c {-o nc8.c nc8.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc8.lus {} -PASS: ./lus2lic {-o nc9.lic nc9.lus} +PASS: ./lus2lic {} {-o nc9.lic nc9.lus} PASS: ./lus2lic {-ec -o nc9.ec nc9.lus} PASS: ./myec2c {-o nc9.c nc9.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nc9.lus {} -PASS: ./lus2lic {-o nested.lic nested.lus} +PASS: ./lus2lic {} {-o nested.lic nested.lus} PASS: ./lus2lic {-ec -o nested.ec nested.lus} PASS: ./myec2c {-o nested.c nested.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nested.lus {} -PASS: ./lus2lic {-o newpacks.lic newpacks.lus} +PASS: ./lus2lic {} {-o newpacks.lic newpacks.lus} PASS: ./lus2lic {-ec -o newpacks.ec newpacks.lus} PASS: ./myec2c {-o newpacks.c newpacks.ec} -PASS: ./lus2lic {-o noAlarm.lic noAlarm.lus} +PASS: ./lus2lic {} {-o noAlarm.lic noAlarm.lus} PASS: ./lus2lic {-ec -o noAlarm.ec noAlarm.lus} PASS: ./myec2c {-o noAlarm.c noAlarm.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node noAlarm.lus {} -PASS: ./lus2lic {-o node_caller1.lic node_caller1.lus} +PASS: ./lus2lic {} {-o node_caller1.lic node_caller1.lus} PASS: ./lus2lic {-ec -o node_caller1.ec node_caller1.lus} PASS: ./myec2c {-o node_caller1.c node_caller1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node node_caller1.lus {} -PASS: ./lus2lic {-o nodeparam.lic nodeparam.lus} +PASS: ./lus2lic {} {-o nodeparam.lic nodeparam.lus} PASS: ./lus2lic {-ec -o nodeparam.ec nodeparam.lus} PASS: ./myec2c {-o nodeparam.c nodeparam.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node nodeparam.lus {} -PASS: ./lus2lic {-o noeudsIndependants.lic noeudsIndependants.lus} +PASS: ./lus2lic {} {-o noeudsIndependants.lic noeudsIndependants.lus} PASS: ./lus2lic {-ec -o noeudsIndependants.ec noeudsIndependants.lus} PASS: ./myec2c {-o noeudsIndependants.c noeudsIndependants.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node noeudsIndependants.lus {} -PASS: ./lus2lic {-o noinput.lic noinput.lus} +PASS: ./lus2lic {} {-o noinput.lic noinput.lus} FAIL: Generate ec code : ./lus2lic {-ec -o noinput.ec noinput.lus} -PASS: ./lus2lic {-o normal.lic normal.lus} +PASS: ./lus2lic {} {-o normal.lic normal.lus} PASS: ./lus2lic {-ec -o normal.ec normal.lus} PASS: ./myec2c {-o normal.c normal.ec} -PASS: ./lus2lic {-o notTwo.lic notTwo.lus} +PASS: ./lus2lic {} {-o notTwo.lic notTwo.lus} PASS: ./lus2lic {-ec -o notTwo.ec notTwo.lus} PASS: ./myec2c {-o notTwo.c notTwo.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node notTwo.lus {} -PASS: ./lus2lic {-o o2l_feux_compl.lic o2l_feux_compl.lus} +PASS: ./lus2lic {} {-o o2l_feux_compl.lic o2l_feux_compl.lus} PASS: ./lus2lic {-ec -o o2l_feux_compl.ec o2l_feux_compl.lus} PASS: ./myec2c {-o o2l_feux_compl.c o2l_feux_compl.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node o2l_feux_compl.lus {} -PASS: ./lus2lic {-o oneq.lic oneq.lus} +PASS: ./lus2lic {} {-o oneq.lic oneq.lus} PASS: ./lus2lic {-ec -o oneq.ec oneq.lus} PASS: ./myec2c {-o oneq.c oneq.ec} -PASS: ./lus2lic {-o onlyroll.lic onlyroll.lus} +PASS: ./lus2lic {} {-o onlyroll.lic onlyroll.lus} PASS: ./lus2lic {-ec -o onlyroll.ec onlyroll.lus} PASS: ./myec2c {-o onlyroll.c onlyroll.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node onlyroll.lus {} -PASS: ./lus2lic {-o onlyroll2.lic onlyroll2.lus} +PASS: ./lus2lic {} {-o onlyroll2.lic onlyroll2.lus} PASS: ./lus2lic {-ec -o onlyroll2.ec onlyroll2.lus} PASS: ./myec2c {-o onlyroll2.c onlyroll2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node onlyroll2.lus {} -PASS: ./lus2lic {-o over2.lic over2.lus} +PASS: ./lus2lic {} {-o over2.lic over2.lus} PASS: ./lus2lic {-ec -o over2.ec over2.lus} PASS: ./myec2c {-o over2.c over2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node over2.lus {} -PASS: ./lus2lic {-o over3.lic over3.lus} +PASS: ./lus2lic {} {-o over3.lic over3.lus} PASS: ./lus2lic {-ec -o over3.ec over3.lus} PASS: ./myec2c {-o over3.c over3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node over3.lus {} -PASS: ./lus2lic {-o overload.lic overload.lus} +PASS: ./lus2lic {} {-o overload.lic overload.lus} PASS: ./lus2lic {-ec -o overload.ec overload.lus} PASS: ./myec2c {-o overload.c overload.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node overload.lus {} -PASS: ./lus2lic {-o p.lic p.lus} +PASS: ./lus2lic {} {-o p.lic p.lus} PASS: ./lus2lic {-ec -o p.ec p.lus} PASS: ./myec2c {-o p.c p.ec} -PASS: ./lus2lic {-o pack1.lic pack1.lus} +PASS: ./lus2lic {} {-o pack1.lic pack1.lus} PASS: ./lus2lic {-ec -o pack1.ec pack1.lus} PASS: ./myec2c {-o pack1.c pack1.ec} -PASS: ./lus2lic {-o packageTableau.lic packageTableau.lus} +PASS: ./lus2lic {} {-o packageTableau.lic packageTableau.lus} PASS: ./lus2lic {-ec -o packageTableau.ec packageTableau.lus} PASS: ./myec2c {-o packageTableau.c packageTableau.ec} -PASS: ./lus2lic {-o packed_cst.lic packed_cst.lus} +PASS: ./lus2lic {} {-o packed_cst.lic packed_cst.lus} PASS: ./lus2lic {-ec -o packed_cst.ec packed_cst.lus} PASS: ./myec2c {-o packed_cst.c packed_cst.ec} -PASS: ./lus2lic {-o packs.lic packs.lus} +PASS: ./lus2lic {} {-o packs.lic packs.lus} PASS: ./lus2lic {-ec -o packs.ec packs.lus} PASS: ./myec2c {-o packs.c packs.ec} -PASS: ./lus2lic {-o param_node.lic param_node.lus} +PASS: ./lus2lic {} {-o param_node.lic param_node.lus} PASS: ./lus2lic {-ec -o param_node.ec param_node.lus} PASS: ./myec2c {-o param_node.c param_node.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node param_node.lus {} -PASS: ./lus2lic {-o param_node2.lic param_node2.lus} +PASS: ./lus2lic {} {-o param_node2.lic param_node2.lus} PASS: ./lus2lic {-ec -o param_node2.ec param_node2.lus} PASS: ./myec2c {-o param_node2.c param_node2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node param_node2.lus {} -PASS: ./lus2lic {-o param_node3.lic param_node3.lus} +PASS: ./lus2lic {} {-o param_node3.lic param_node3.lus} PASS: ./lus2lic {-ec -o param_node3.ec param_node3.lus} PASS: ./myec2c {-o param_node3.c param_node3.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node param_node3.lus {} -PASS: ./lus2lic {-o param_node4.lic param_node4.lus} +PASS: ./lus2lic {} {-o param_node4.lic param_node4.lus} PASS: ./lus2lic {-ec -o param_node4.ec param_node4.lus} PASS: ./myec2c {-o param_node4.c param_node4.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node param_node4.lus {} -PASS: ./lus2lic {-o param_struct.lic param_struct.lus} +PASS: ./lus2lic {} {-o param_struct.lic param_struct.lus} PASS: ./lus2lic {-ec -o param_struct.ec param_struct.lus} PASS: ./myec2c {-o param_struct.c param_struct.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node param_struct.lus {} -PASS: ./lus2lic {-o pilote.lic pilote.lus} +PASS: ./lus2lic { --expand-nodes} {-o pilote.lic pilote.lus} PASS: ./lus2lic {-ec -o pilote.ec pilote.lus} PASS: ./myec2c {-o pilote.c pilote.ec} -PASS: ./lus2lic {-o pipeline.lic pipeline.lus} +PASS: ./lus2lic {} {-o pipeline.lic pipeline.lus} PASS: ./lus2lic {-ec -o pipeline.ec pipeline.lus} PASS: ./myec2c {-o pipeline.c pipeline.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node pipeline.lus {} -PASS: ./lus2lic {-o plus.lic plus.lus} +PASS: ./lus2lic {} {-o plus.lic plus.lus} PASS: ./lus2lic {-ec -o plus.ec plus.lus} PASS: ./myec2c {-o plus.c plus.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node plus.lus {} -PASS: ./lus2lic {-o ply01.lic ply01.lus} +PASS: ./lus2lic {} {-o ply01.lic ply01.lus} PASS: ./lus2lic {-ec -o ply01.ec ply01.lus} PASS: ./myec2c {-o ply01.c ply01.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ply01.lus {} -PASS: ./lus2lic {-o ply02.lic ply02.lus} +PASS: ./lus2lic {} {-o ply02.lic ply02.lus} PASS: ./lus2lic {-ec -o ply02.ec ply02.lus} PASS: ./myec2c {-o ply02.c ply02.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ply02.lus {} -PASS: ./lus2lic {-o ply03.lic ply03.lus} +PASS: ./lus2lic {} {-o ply03.lic ply03.lus} PASS: ./lus2lic {-ec -o ply03.ec ply03.lus} PASS: ./myec2c {-o ply03.c ply03.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ply03.lus {} -PASS: ./lus2lic {-o polymorphic_pack.lic polymorphic_pack.lus} +PASS: ./lus2lic {} {-o polymorphic_pack.lic polymorphic_pack.lus} PASS: ./lus2lic {-ec -o polymorphic_pack.ec polymorphic_pack.lus} PASS: ./myec2c {-o polymorphic_pack.c polymorphic_pack.ec} -PASS: ./lus2lic {-o poussoir.lic poussoir.lus} +PASS: ./lus2lic {} {-o poussoir.lic poussoir.lus} PASS: ./lus2lic {-ec -o poussoir.ec poussoir.lus} PASS: ./myec2c {-o poussoir.c poussoir.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node poussoir.lus {} -PASS: ./lus2lic {-o pplus.lic pplus.lus} +PASS: ./lus2lic {} {-o pplus.lic pplus.lus} PASS: ./lus2lic {-ec -o pplus.ec pplus.lus} PASS: ./myec2c {-o pplus.c pplus.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node pplus.lus {} -PASS: ./lus2lic {-o pre_x.lic pre_x.lus} +PASS: ./lus2lic {} {-o pre_x.lic pre_x.lus} PASS: ./lus2lic {-ec -o pre_x.ec pre_x.lus} PASS: ./myec2c {-o pre_x.c pre_x.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node pre_x.lus {} -PASS: ./lus2lic {-o predef01.lic predef01.lus} +PASS: ./lus2lic {} {-o predef01.lic predef01.lus} PASS: ./lus2lic {-ec -o predef01.ec predef01.lus} PASS: ./myec2c {-o predef01.c predef01.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node predef01.lus {} -PASS: ./lus2lic {-o predef02.lic predef02.lus} +PASS: ./lus2lic {} {-o predef02.lic predef02.lus} PASS: ./lus2lic {-ec -o predef02.ec predef02.lus} PASS: ./myec2c {-o predef02.c predef02.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node predef02.lus {} -PASS: ./lus2lic {-o predef03.lic predef03.lus} +PASS: ./lus2lic {} {-o predef03.lic predef03.lus} PASS: ./lus2lic {-ec -o predef03.ec predef03.lus} PASS: ./myec2c {-o predef03.c predef03.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node predef03.lus {} -PASS: ./lus2lic {-o predefOp.lic predefOp.lus} +PASS: ./lus2lic {} {-o predefOp.lic predefOp.lus} PASS: ./lus2lic {-ec -o predefOp.ec predefOp.lus} PASS: ./myec2c {-o predefOp.c predefOp.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node predefOp.lus {} -PASS: ./lus2lic {-o produitBool.lic produitBool.lus} +PASS: ./lus2lic {} {-o produitBool.lic produitBool.lus} PASS: ./lus2lic {-ec -o produitBool.ec produitBool.lus} PASS: ./myec2c {-o produitBool.c produitBool.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node produitBool.lus {} -PASS: ./lus2lic {-o real_ex.lic real_ex.lus} +PASS: ./lus2lic {} {-o real_ex.lic real_ex.lus} PASS: ./lus2lic {-ec -o real_ex.ec real_ex.lus} PASS: ./myec2c {-o real_ex.c real_ex.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node real_ex.lus {} -PASS: ./lus2lic {-o redIf.lic redIf.lus} +PASS: ./lus2lic {} {-o redIf.lic redIf.lus} PASS: ./lus2lic {-ec -o redIf.ec redIf.lus} PASS: ./myec2c {-o redIf.c redIf.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node redIf.lus {} -PASS: ./lus2lic {-o rediter.lic rediter.lus} +PASS: ./lus2lic {} {-o rediter.lic rediter.lus} PASS: ./lus2lic {-ec -o rediter.ec rediter.lus} PASS: ./myec2c {-o rediter.c rediter.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node rediter.lus {} -PASS: ./lus2lic {-o redoptest.lic redoptest.lus} +PASS: ./lus2lic {} {-o redoptest.lic redoptest.lus} PASS: ./lus2lic {-ec -o redoptest.ec redoptest.lus} PASS: ./myec2c {-o redoptest.c redoptest.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node redoptest.lus {} -PASS: ./lus2lic {-o remplissage.lic remplissage.lus} +PASS: ./lus2lic {} {-o remplissage.lic remplissage.lus} PASS: ./lus2lic {-ec -o remplissage.ec remplissage.lus} PASS: ./myec2c {-o remplissage.c remplissage.ec} -PASS: ./lus2lic {-o rs.lic rs.lus} +PASS: ./lus2lic {} {-o rs.lic rs.lus} PASS: ./lus2lic {-ec -o rs.ec rs.lus} PASS: ./myec2c {-o rs.c rs.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node rs.lus {} -PASS: ./lus2lic {-o sample_time_change.lic sample_time_change.lus} +PASS: ./lus2lic {} {-o sample_time_change.lic sample_time_change.lus} PASS: ./lus2lic {-ec -o sample_time_change.ec sample_time_change.lus} PASS: ./myec2c {-o sample_time_change.c sample_time_change.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node sample_time_change.lus {} -PASS: ./lus2lic {-o sample_time_change_MainNode.lic sample_time_change_MainNode.lus} +PASS: ./lus2lic {} {-o sample_time_change_MainNode.lic sample_time_change_MainNode.lus} PASS: ./lus2lic {-ec -o sample_time_change_MainNode.ec sample_time_change_MainNode.lus} PASS: ./myec2c {-o sample_time_change_MainNode.c sample_time_change_MainNode.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node sample_time_change_MainNode.lus {} -PASS: ./lus2lic {-o shiftFill_ludic.lic shiftFill_ludic.lus} +PASS: ./lus2lic {} {-o shiftFill_ludic.lic shiftFill_ludic.lus} PASS: ./lus2lic {-ec -o shiftFill_ludic.ec shiftFill_ludic.lus} PASS: ./myec2c {-o shiftFill_ludic.c shiftFill_ludic.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node shiftFill_ludic.lus {} -PASS: ./lus2lic {-o shift_ludic.lic shift_ludic.lus} +PASS: ./lus2lic {} {-o shift_ludic.lic shift_ludic.lus} PASS: ./lus2lic {-ec -o shift_ludic.ec shift_ludic.lus} PASS: ./myec2c {-o shift_ludic.c shift_ludic.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node shift_ludic.lus {} -PASS: ./lus2lic {-o simple.lic simple.lus} +PASS: ./lus2lic {} {-o simple.lic simple.lus} PASS: ./lus2lic {-ec -o simple.ec simple.lus} PASS: ./myec2c {-o simple.c simple.ec} -PASS: ./lus2lic {-o simpleRed.lic simpleRed.lus} +PASS: ./lus2lic {} {-o simpleRed.lic simpleRed.lus} PASS: ./lus2lic {-ec -o simpleRed.ec simpleRed.lus} PASS: ./myec2c {-o simpleRed.c simpleRed.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node simpleRed.lus {} -PASS: ./lus2lic {-o sincos.lic sincos.lus} +PASS: ./lus2lic {} {-o sincos.lic sincos.lus} PASS: ./lus2lic {-ec -o sincos.ec sincos.lus} PASS: ./myec2c {-o sincos.c sincos.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node sincos.lus {} -PASS: ./lus2lic {-o speedcontrol.lic speedcontrol.lus} +PASS: ./lus2lic { --expand-nodes} {-o speedcontrol.lic speedcontrol.lus} PASS: ./lus2lic {-ec -o speedcontrol.ec speedcontrol.lus} PASS: ./myec2c {-o speedcontrol.c speedcontrol.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node speedcontrol.lus { --expand-nodes} -PASS: ./lus2lic {-o sqrt.lic sqrt.lus} +PASS: ./lus2lic {} {-o sqrt.lic sqrt.lus} PASS: ./lus2lic {-ec -o sqrt.ec sqrt.lus} PASS: ./myec2c {-o sqrt.c sqrt.ec} -PASS: ./lus2lic {-o stopwatch.lic stopwatch.lus} +PASS: ./lus2lic {} {-o stopwatch.lic stopwatch.lus} PASS: ./lus2lic {-ec -o stopwatch.ec stopwatch.lus} PASS: ./myec2c {-o stopwatch.c stopwatch.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node stopwatch.lus {} -PASS: ./lus2lic {-o struct0.lic struct0.lus} +PASS: ./lus2lic {} {-o struct0.lic struct0.lus} PASS: ./lus2lic {-ec -o struct0.ec struct0.lus} PASS: ./myec2c {-o struct0.c struct0.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node struct0.lus {} -PASS: ./lus2lic {-o struct_equality.lic struct_equality.lus} +PASS: ./lus2lic {} {-o struct_equality.lic struct_equality.lus} PASS: ./lus2lic {-ec -o struct_equality.ec struct_equality.lus} PASS: ./myec2c {-o struct_equality.c struct_equality.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node struct_equality.lus {} -PASS: ./lus2lic {-o struct_with.lic struct_with.lus} +PASS: ./lus2lic {} {-o struct_with.lic struct_with.lus} PASS: ./lus2lic {-ec -o struct_with.ec struct_with.lus} PASS: ./myec2c {-o struct_with.c struct_with.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node struct_with.lus {} -PASS: ./lus2lic {-o t0.lic t0.lus} +PASS: ./lus2lic {} {-o t0.lic t0.lus} PASS: ./lus2lic {-ec -o t0.ec t0.lus} PASS: ./myec2c {-o t0.c t0.ec} -PASS: ./lus2lic {-o t1.lic t1.lus} +PASS: ./lus2lic {} {-o t1.lic t1.lus} PASS: ./lus2lic {-ec -o t1.ec t1.lus} PASS: ./myec2c {-o t1.c t1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node t1.lus {} -PASS: ./lus2lic {-o t2.lic t2.lus} +PASS: ./lus2lic {} {-o t2.lic t2.lus} PASS: ./lus2lic {-ec -o t2.ec t2.lus} PASS: ./myec2c {-o t2.c t2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node t2.lus {} -PASS: ./lus2lic {-o test.lic test.lus} +PASS: ./lus2lic {} {-o test.lic test.lus} PASS: ./lus2lic {-ec -o test.ec test.lus} PASS: ./myec2c {-o test.c test.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test.lus {} -PASS: ./lus2lic {-o testBoite.lic testBoite.lus} +PASS: ./lus2lic {} {-o testBoite.lic testBoite.lus} PASS: ./lus2lic {-ec -o testBoite.ec testBoite.lus} PASS: ./myec2c {-o testBoite.c testBoite.ec} -PASS: ./lus2lic {-o testCA.lic testCA.lus} +PASS: ./lus2lic {} {-o testCA.lic testCA.lus} PASS: ./lus2lic {-ec -o testCA.ec testCA.lus} PASS: ./myec2c {-o testCA.c testCA.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node testCA.lus {} -PASS: ./lus2lic {-o testCapt.lic testCapt.lus} +PASS: ./lus2lic {} {-o testCapt.lic testCapt.lus} PASS: ./lus2lic {-ec -o testCapt.ec testCapt.lus} PASS: ./myec2c {-o testCapt.c testCapt.ec} -PASS: ./lus2lic {-o testPilote.lic testPilote.lus} +PASS: ./lus2lic {} {-o testPilote.lic testPilote.lus} PASS: ./lus2lic {-ec -o testPilote.ec testPilote.lus} PASS: ./myec2c {-o testPilote.c testPilote.ec} -PASS: ./lus2lic {-o test_Int.lic test_Int.lus} +PASS: ./lus2lic {} {-o test_Int.lic test_Int.lus} PASS: ./lus2lic {-ec -o test_Int.ec test_Int.lus} PASS: ./myec2c {-o test_Int.c test_Int.ec} -PASS: ./lus2lic {-o test_arrow.lic test_arrow.lus} +PASS: ./lus2lic {} {-o test_arrow.lic test_arrow.lus} PASS: ./lus2lic {-ec -o test_arrow.ec test_arrow.lus} PASS: ./myec2c {-o test_arrow.c test_arrow.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_arrow.lus {} -PASS: ./lus2lic {-o test_boolred.lic test_boolred.lus} +PASS: ./lus2lic {} {-o test_boolred.lic test_boolred.lus} PASS: ./lus2lic {-ec -o test_boolred.ec test_boolred.lus} PASS: ./myec2c {-o test_boolred.c test_boolred.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_boolred.lus {} -PASS: ./lus2lic {-o test_clash.lic test_clash.lus} +PASS: ./lus2lic {} {-o test_clash.lic test_clash.lus} PASS: ./lus2lic {-ec -o test_clash.ec test_clash.lus} PASS: ./myec2c {-o test_clash.c test_clash.ec} -PASS: ./lus2lic {-o test_condact.lic test_condact.lus} +PASS: ./lus2lic {} {-o test_condact.lic test_condact.lus} PASS: ./lus2lic {-ec -o test_condact.ec test_condact.lus} PASS: ./myec2c {-o test_condact.c test_condact.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_condact.lus {} -PASS: ./lus2lic {-o test_const.lic test_const.lus} +PASS: ./lus2lic {} {-o test_const.lic test_const.lus} PASS: ./lus2lic {-ec -o test_const.ec test_const.lus} PASS: ./myec2c {-o test_const.c test_const.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_const.lus {} -PASS: ./lus2lic {-o test_diese.lic test_diese.lus} +PASS: ./lus2lic {} {-o test_diese.lic test_diese.lus} PASS: ./lus2lic {-ec -o test_diese.ec test_diese.lus} PASS: ./myec2c {-o test_diese.c test_diese.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_diese.lus {} -PASS: ./lus2lic {-o test_enum.lic test_enum.lus} +PASS: ./lus2lic {} {-o test_enum.lic test_enum.lus} PASS: ./lus2lic {-ec -o test_enum.ec test_enum.lus} PASS: ./myec2c {-o test_enum.c test_enum.ec} -PASS: ./lus2lic {-o test_extern.lic test_extern.lus} +PASS: ./lus2lic {} {-o test_extern.lic test_extern.lus} PASS: ./lus2lic {-ec -o test_extern.ec test_extern.lus} PASS: ./myec2c {-o test_extern.c test_extern.ec} -PASS: ./lus2lic {-o test_lustre.lic test_lustre.lus} +PASS: ./lus2lic {} {-o test_lustre.lic test_lustre.lus} PASS: ./lus2lic {-ec -o test_lustre.ec test_lustre.lus} PASS: ./myec2c {-o test_lustre.c test_lustre.ec} -PASS: ./lus2lic {-o test_map.lic test_map.lus} +PASS: ./lus2lic {} {-o test_map.lic test_map.lus} PASS: ./lus2lic {-ec -o test_map.ec test_map.lus} PASS: ./myec2c {-o test_map.c test_map.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_map.lus {} -PASS: ./lus2lic {-o test_merge.lic test_merge.lus} +PASS: ./lus2lic {} {-o test_merge.lic test_merge.lus} PASS: ./lus2lic {-ec -o test_merge.ec test_merge.lus} -PASS: ./lus2lic {-o test_model.lic test_model.lus} +PASS: ./lus2lic {} {-o test_model.lic test_model.lus} PASS: ./lus2lic {-ec -o test_model.ec test_model.lus} PASS: ./myec2c {-o test_model.c test_model.ec} -FAIL: without any option: ./lus2lic {-o test_model2.lic test_model2.lus} -PASS: ./lus2lic {-o test_node_expand.lic test_node_expand.lus} +FAIL: without any option: ./lus2lic {} {-o test_model2.lic test_model2.lus} +PASS: ./lus2lic {} {-o test_node_expand.lic test_node_expand.lus} PASS: ./lus2lic {-ec -o test_node_expand.ec test_node_expand.lus} PASS: ./myec2c {-o test_node_expand.c test_node_expand.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_node_expand.lus {} -PASS: ./lus2lic {-o test_node_expand2.lic test_node_expand2.lus} +PASS: ./lus2lic {} {-o test_node_expand2.lic test_node_expand2.lus} PASS: ./lus2lic {-ec -o test_node_expand2.ec test_node_expand2.lus} PASS: ./myec2c {-o test_node_expand2.c test_node_expand2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_node_expand2.lus {} -PASS: ./lus2lic {-o test_poly.lic test_poly.lus} +PASS: ./lus2lic {} {-o test_poly.lic test_poly.lus} PASS: ./lus2lic {-ec -o test_poly.ec test_poly.lus} PASS: ./myec2c {-o test_poly.c test_poly.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_poly.lus {} -PASS: ./lus2lic {-o test_struct.lic test_struct.lus} +PASS: ./lus2lic {} {-o test_struct.lic test_struct.lus} PASS: ./lus2lic {-ec -o test_struct.ec test_struct.lus} PASS: ./myec2c {-o test_struct.c test_struct.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node test_struct.lus {} -PASS: ./lus2lic {-o titi.lic titi.lus} +PASS: ./lus2lic {} {-o titi.lic titi.lus} PASS: ./lus2lic {-ec -o titi.ec titi.lus} PASS: ./myec2c {-o titi.c titi.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node titi.lus {} -PASS: ./lus2lic {-o toolate.lic toolate.lus} +PASS: ./lus2lic {} {-o toolate.lic toolate.lus} PASS: ./lus2lic {-ec -o toolate.ec toolate.lus} PASS: ./myec2c {-o toolate.c toolate.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node toolate.lus {} -PASS: ./lus2lic {-o toto.lic toto.lus} +PASS: ./lus2lic {} {-o toto.lic toto.lus} PASS: ./lus2lic {-ec -o toto.ec toto.lus} PASS: ./myec2c {-o toto.c toto.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node toto.lus {} -FAIL: without any option: ./lus2lic {-o tranche.lic tranche.lus} -PASS: ./lus2lic {-o tri.lic tri.lus} +FAIL: without any option: ./lus2lic {} {-o tranche.lic tranche.lus} +PASS: ./lus2lic {} {-o tri.lic tri.lus} PASS: ./lus2lic {-ec -o tri.ec tri.lus} PASS: ./myec2c {-o tri.c tri.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node tri.lus {} -PASS: ./lus2lic {-o triSel.lic triSel.lus} +PASS: ./lus2lic {} {-o triSel.lic triSel.lus} PASS: ./lus2lic {-ec -o triSel.ec triSel.lus} PASS: ./myec2c {-o triSel.c triSel.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node triSel.lus {} -PASS: ./lus2lic {-o trivial.lic trivial.lus} +PASS: ./lus2lic {} {-o trivial.lic trivial.lus} PASS: ./lus2lic {-ec -o trivial.ec trivial.lus} PASS: ./myec2c {-o trivial.c trivial.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node trivial.lus {} -PASS: ./lus2lic {-o trivial2.lic trivial2.lus} +PASS: ./lus2lic {} {-o trivial2.lic trivial2.lus} PASS: ./lus2lic {-ec -o trivial2.ec trivial2.lus} PASS: ./myec2c {-o trivial2.c trivial2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node trivial2.lus {} -PASS: ./lus2lic {-o trivial_array.lic trivial_array.lus} +PASS: ./lus2lic {} {-o trivial_array.lic trivial_array.lus} PASS: ./lus2lic {-ec -o trivial_array.ec trivial_array.lus} PASS: ./myec2c {-o trivial_array.c trivial_array.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node trivial_array.lus {} -PASS: ./lus2lic {-o ts01.lic ts01.lus} +PASS: ./lus2lic {} {-o ts01.lic ts01.lus} PASS: ./lus2lic {-ec -o ts01.ec ts01.lus} PASS: ./myec2c {-o ts01.c ts01.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ts01.lus {} -PASS: ./lus2lic {-o ts04.lic ts04.lus} +PASS: ./lus2lic {} {-o ts04.lic ts04.lus} PASS: ./lus2lic {-ec -o ts04.ec ts04.lus} PASS: ./myec2c {-o ts04.c ts04.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node ts04.lus {} -PASS: ./lus2lic {-o tuple.lic tuple.lus} +PASS: ./lus2lic {} {-o tuple.lic tuple.lus} PASS: ./lus2lic {-ec -o tuple.ec tuple.lus} PASS: ./myec2c {-o tuple.c tuple.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node tuple.lus {} -PASS: ./lus2lic {-o type_decl.lic type_decl.lus} +PASS: ./lus2lic {} {-o type_decl.lic type_decl.lus} PASS: ./lus2lic {-ec -o type_decl.ec type_decl.lus} PASS: ./myec2c {-o type_decl.c type_decl.ec} -PASS: ./lus2lic {-o uu.lic uu.lus} +PASS: ./lus2lic {} {-o uu.lic uu.lus} PASS: ./lus2lic {-ec -o uu.ec uu.lus} PASS: ./myec2c {-o uu.c uu.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node uu.lus {} -PASS: ./lus2lic {-o v1.lic v1.lus} +PASS: ./lus2lic {} {-o v1.lic v1.lus} PASS: ./lus2lic {-ec -o v1.ec v1.lus} PASS: ./myec2c {-o v1.c v1.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node v1.lus {} -PASS: ./lus2lic {-o when_tuple.lic when_tuple.lus} +PASS: ./lus2lic {} {-o when_tuple.lic when_tuple.lus} PASS: ./lus2lic {-ec -o when_tuple.ec when_tuple.lus} PASS: ./myec2c {-o when_tuple.c when_tuple.ec} -PASS: ./lus2lic {-o xx.lic xx.lus} +PASS: ./lus2lic {} {-o xx.lic xx.lus} PASS: ./lus2lic {-ec -o xx.ec xx.lus} PASS: ./myec2c {-o xx.c xx.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node xx.lus {} -PASS: ./lus2lic {-o yyy.lic yyy.lus} +PASS: ./lus2lic {} {-o yyy.lic yyy.lus} PASS: ./lus2lic {-ec -o yyy.ec yyy.lus} PASS: ./myec2c {-o yyy.c yyy.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node yyy.lus {} -PASS: ./lus2lic {-o zzz.lic zzz.lus} +PASS: ./lus2lic {} {-o zzz.lic zzz.lus} PASS: ./lus2lic {-ec -o zzz.ec zzz.lus} PASS: ./myec2c {-o zzz.c zzz.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node zzz.lus {} -PASS: ./lus2lic {-o zzz2.lic zzz2.lus} +PASS: ./lus2lic {} {-o zzz2.lic zzz2.lus} PASS: ./lus2lic {-ec -o zzz2.ec zzz2.lus} PASS: ./myec2c {-o zzz2.c zzz2.ec} PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node zzz2.lus {} @@ -1761,18 +1762,18 @@ PASS: /home/jahier/lus2lic/test/../utils/test_lus2lic_no_node zzz2.lus {} # of unexpected failures 1 ==> lus2lic2.sum <== -PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c zzz2.lus 39953 {} === lus2lic2 Summary === -# of expected passes 328 +# of expected passes 327 +# of unexpected failures 1 ==> lus2lic3.sum <== === lus2lic3 Summary === -# of expected passes 491 -# of unexpected failures 7 -# of unresolved testcases 3 +# of expected passes 492 +# of unexpected failures 5 +# of unresolved testcases 4 ==> lus2lic4.sum <== @@ -1781,15 +1782,15 @@ PASS: /home/jahier/lus2lic/test/../utils/compare_exec_and_2c zzz2.lus 39953 {} # of expected passes 465 # of unexpected failures 6 =============================== -# Total number of failures: 14 -lus2lic0.log:testcase ./lus2lic.tests/test0.exp completed in 1 seconds -lus2lic1.log:testcase ./lus2lic.tests/test1.exp completed in 56 seconds -lus2lic2.log:testcase ./lus2lic.tests/test2.exp completed in 60 seconds -lus2lic3.log:testcase ./lus2lic.tests/test3.exp completed in 134 seconds -lus2lic4.log:testcase ./lus2lic.tests/test4.exp completed in 51 seconds +# Total number of failures: 13 +lus2lic0.log:testcase ./lus2lic.tests/test0.exp completed in 0 seconds +lus2lic1.log:testcase ./lus2lic.tests/test1.exp completed in 52 seconds +lus2lic2.log:testcase ./lus2lic.tests/test2.exp completed in 57 seconds +lus2lic3.log:testcase ./lus2lic.tests/test3.exp completed in 165 seconds +lus2lic4.log:testcase ./lus2lic.tests/test4.exp completed in 46 seconds * Ref time: -0.06user 0.02system 5:01.49elapsed 0%CPU (0avgtext+0avgdata 5636maxresident)k -96inputs+0outputs (0major+6198minor)pagefaults 0swaps +0.05user 0.02system 5:22.46elapsed 0%CPU (0avgtext+0avgdata 5744maxresident)k +128inputs+0outputs (0major+6114minor)pagefaults 0swaps * Quick time (-j 4): -0.06user 0.01system 2:48.11elapsed 0%CPU (0avgtext+0avgdata 5600maxresident)k -128inputs+0outputs (0major+6203minor)pagefaults 0swaps +0.06user 0.01system 2:52.10elapsed 0%CPU (0avgtext+0avgdata 5612maxresident)k +96inputs+0outputs (0major+6123minor)pagefaults 0swaps diff --git a/test/should_work/asservi.lus b/test/should_work/asservi.lus index c32b762dfaeca429b23ca7a207971eb0103be483..cc76f429d0f760e15063a0b15fe0a01708204ac7 100644 --- a/test/should_work/asservi.lus +++ b/test/should_work/asservi.lus @@ -36,7 +36,9 @@ node PEND( d2x0,d2y0:real) returns (teta:real); --G accelleration de la pesanteur ------------------------------------------------------------- let --- ??? ne peut pas marcher! ??? +-- ??? ne peut pas marcher! ??? Si: ca marche en mode -en si ce noeud +-- est appelé comme il faut (i.e., PEND( val -> qque chose)) +-- teta = I2((sin(teta)*(d2y0+G) -cos(teta)*d2x0)/L); tel; diff --git a/test/should_work/iter.lus b/test/should_work/iter.lus index c1412fde0c17d93906af684eff26f49d1e83ccaa..856b27485af509a84d63e34f56fe02d33874432d 100644 --- a/test/should_work/iter.lus +++ b/test/should_work/iter.lus @@ -7,7 +7,7 @@ var let bidon, T_inter = fill<<filled,n>>(init); Tab_out = map<<mapped,n>>(T_inter); - Red_plus = red<<plus,n>>(-100, Tab_out); + Red_plus = red<<myplus,n>>(-100, Tab_out); zorroAcc, zorroTab = fillred<<garcia,5>>(0,[0,0,0,0,0]); tel @@ -23,7 +23,7 @@ let elt_out = elt_in + 1; tel -node plus(accu_in, elt_in : int) returns (accu_out : int); +node myplus(accu_in, elt_in : int) returns (accu_out : int); let accu_out = accu_in + elt_in ; tel diff --git a/test/site.exp b/test/site.exp index 665c7d609c2b33e2af09183ef578622a9e8951ab..30bdb43ff21e8f79565eb0aa2f897e801fc7f0d5 100644 --- a/test/site.exp +++ b/test/site.exp @@ -1,4 +1,4 @@ -# Time-stamp: <modified the 21/04/2017 (at 17:59) by Erwan Jahier> +# Time-stamp: <modified the 20/07/2017 (at 14:35) by Erwan Jahier> # # (nonreg-)test harness main file @@ -236,7 +236,7 @@ proc nonreg_exec_and_2c {files tmp} { set node [file tail $f_no_ext] set port [get_free_port] - eval spawn "$lus2lic -o $bf.lic $f" + eval spawn "$lus2lic $opt -o $bf.lic $f" wait -i $spawn_id if { [nonemptyfile "$bf.lic"] && [does_not_contain_left_slices "$f"] } { set id1 [should_work "Generate c code " "$lus2lic $opt" "-2c $f -n $node"] @@ -281,7 +281,7 @@ proc nonreg_exec_and_ecexe {files tmp} { set opt [read_opt $f] set node [file tail $f_no_ext] - set id1 [should_work "without any option" "$lus2lic" "-o $bf.lic $f"] + set id1 [should_work "without any option" "$lus2lic" "$opt" "-o $bf.lic $f"] wait -i $id1 if { [nonemptyfile "$bf.lic"] } { set id2 [should_work "Generate ec code " "$lus2lic" "-ec -o $bf.ec $f"]