projects
/
tatoo.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Refactor the statistics gathering code in run.ml
[tatoo.git]
/
src
/
tatoo.ml
diff --git
a/src/tatoo.ml
b/src/tatoo.ml
index
0987b6d
..
e0f29ee
100644
(file)
--- a/
src/tatoo.ml
+++ b/
src/tatoo.ml
@@
-124,10
+124,13
@@
let main () =
let s = Naive.stats () in
Run.(
Logger.msg `STATS
let s = Naive.stats () in
Run.(
Logger.msg `STATS
- "@[tree size: %d@\ntraversals: %d@\ntransition fetch cache hit ratio: %f@\ntransition eval cache hit ratio: %f@]"
- s.tree_size s.
run
+ "@[tree size: %d@\ntraversals: %d@\ntransition fetch cache hit ratio: %f@\ntransition eval cache hit ratio: %f@
\nNumber of visited nodes per pass: %a@
]"
+ s.tree_size s.
pass
(float s.fetch_trans_cache_hit /. float s.fetch_trans_cache_access)
(float s.fetch_trans_cache_hit /. float s.fetch_trans_cache_access)
- (float s.eval_trans_cache_hit /. float s.eval_trans_cache_access));
+ (float s.eval_trans_cache_hit /. float s.eval_trans_cache_access)
+ (let i = ref 0 in
+ Pretty.print_list ~sep:"," (fun fmt n -> Format.fprintf fmt "%i: %i" !i n;incr i))
+ s.nodes_per_run);
time (fun () ->
let count = ref 1 in
List.iter (fun results ->
time (fun () ->
let count = ref 1 in
List.iter (fun results ->