Skip to content
Snippets Groups Projects
Commit 00fd74db authored by erwan's avatar erwan
Browse files

fix: various fixes and improvements in rdbgui4sasa

parent b790ebab
No related branches found
No related tags found
No related merge requests found
(* *)
#use "rdbg-cmds.ml";;
#use "sasa-rdbg-cmds.ml";;
This diff is collapsed.
......@@ -50,7 +50,14 @@ let enabled pl = (* returns the enabled processes *)
(* called at each event via the time-travel hook *)
let (round : RdbgEvent.t -> bool) =
fun e ->
if e.kind=Exit && e.name = "sasa" then get_round e else false
let get_it =
if args.salut_mode then
e.kind=Call && e.name = "mv_hook"
else
true
(* e.kind=Exit && e.name = "sasa" *)
in
if get_it then get_round e else false
(**********************************************************************)
let d_par () = dot true (get_round_nb !e) p dotfile !e;;
......@@ -145,12 +152,15 @@ It is the case for sasa and lutin at least.
let (string_to_string_list : string -> string list) =
fun str ->
Str.split (Str.regexp "[ \t]+") str
Str.split (Str.regexp "[ \t]+") str
let (change_ocaml_plugin_seed: int -> RdbgPlugin.t -> RdbgPlugin.t) =
fun seed rdbgplugin ->
let new_sasa_call = Printf.sprintf "%s --seed %d" rdbgplugin.id seed in
Sasa.SasaRun.make(Array.of_list (string_to_string_list new_sasa_call))
fun seed rdbgplugin ->
if args.salut_mode then ((* nothing to do here *) rdbgplugin) else
let new_sasa_call = Printf.sprintf "%s --seed %d" rdbgplugin.id seed in
Printf.printf "%s\n%!" new_sasa_call;
Sasa.SasaRun.make (Array.of_list (string_to_string_list new_sasa_call))
let (change_plugin_seed : int -> RdbgArg.reactive_program -> RdbgArg.reactive_program) =
fun seed plugin ->
......@@ -318,11 +328,12 @@ let _ = add_doc_entry
"potential" "unit -> float option" "returns the current potential if available"
"sasa" "sasa-rdbg-cmds.ml"
(**********************************************************************)
(* Perform the checkpointing at rounds! *)
let _ = check_ref := fun e -> e.nb = 1 || round e;;
(* overide the default checkpointing at rounds
nb : this is overridden in gtkgui.ml
*)
let _ = check_ref := fun e -> e.nb = 1 || (e.kind=Exit && e.name="sasa" && round e);;
(**********************************************************************)
let _ =
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment