-
Notifications
You must be signed in to change notification settings - Fork 1
/
test_tame.hl
52 lines (36 loc) · 1.51 KB
/
test_tame.hl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
(* Make sure that load_path contains a path to eval_compile.hl *)
(* load_path := "path to eval_*.hl" :: !load_path *)
(* Make sure that load_path contains a path to the latest version
of formal_ineqs. It can be obtained with:
git clone https://github.com/monadius/formal_ineqs *)
(* load_path := "path to formal_ineqs" :: !load_path *)
needs "tests/common.hl";;
needs "tame/tame_db.hl";;
let db, consts =
tame_db ~result:`tameEnumFilterBounded,tameCountFinalsBounded` tame_rules;;
write_rules_consts db "tame/out.hl" consts;;
needs "tame/out.hl";;
(* 1000 iterations (p = 0): about 17 seconds *)
reset_all_counters();;
clear_all_memos();;
test 1 (f_tameEnumFilterBounded (numeral `0`) (numeral `1000`)) None;;
(* 10000 iterations (p = 0): about 240 seconds *)
reset_all_counters();;
clear_all_memos();;
test 1 (f_tameEnumFilterBounded (numeral `0`) (numeral `10000`)) None;;
(* 1000 iterations (p = 1): about 35 seconds *)
reset_all_counters();;
clear_all_memos();;
test 1 (f_tameEnumFilterBounded (numeral `1`) (numeral `1000`)) None;;
(* 10000 iterations (p = 1): about 248 seconds *)
reset_all_counters();;
clear_all_memos();;
test 1 (f_tameEnumFilterBounded (numeral `1`) (numeral `10000`)) None;;
(* 1000 iterations (p = 2): about 35 seconds *)
reset_all_counters();;
clear_all_memos();;
test 1 (f_tameEnumFilterBounded (numeral `2`) (numeral `1000`)) None;;
(* 1000 iterations (p = 3): about 35 seconds *)
reset_all_counters();;
clear_all_memos();;
test 1 (f_tameEnumFilterBounded (numeral `3`) (numeral `1000`)) None;;