From 12cedcbf4dcfe4fd43ab9f4b648314cac26b82db Mon Sep 17 00:00:00 2001 From: Jason Gross Date: Sun, 3 Jul 2016 17:13:37 -0400 Subject: Add support for testing output mod timing changes Uses sed 's/\s*[0-9]*\.[0-9]\+\s*//g' and 's/\s*0\.\s*//g' to strip numbers of seconds and to strip percentages. (This can potentially be extended later.) Add a test-suite file to make sure that LtacProf outputs some table. --- test-suite/output-modulo-time/ltacprof.out | 12 ++++++++++++ test-suite/output-modulo-time/ltacprof.v | 8 ++++++++ 2 files changed, 20 insertions(+) create mode 100644 test-suite/output-modulo-time/ltacprof.out create mode 100644 test-suite/output-modulo-time/ltacprof.v (limited to 'test-suite/output-modulo-time') diff --git a/test-suite/output-modulo-time/ltacprof.out b/test-suite/output-modulo-time/ltacprof.out new file mode 100644 index 000000000..cc04c2c9b --- /dev/null +++ b/test-suite/output-modulo-time/ltacprof.out @@ -0,0 +1,12 @@ +total time: 1.528s + + tactic local total calls max +────────────────────────────────────────┴──────┴──────┴───────┴─────────┘ +─sleep' -------------------------------- 100.0% 100.0% 1 1.528s +─constructor --------------------------- 0.0% 0.0% 1 0.000s + + tactic local total calls max +────────────────────────────────────────┴──────┴──────┴───────┴─────────┘ +─sleep' -------------------------------- 100.0% 100.0% 1 1.528s +─constructor --------------------------- 0.0% 0.0% 1 0.000s + diff --git a/test-suite/output-modulo-time/ltacprof.v b/test-suite/output-modulo-time/ltacprof.v new file mode 100644 index 000000000..d79451f0f --- /dev/null +++ b/test-suite/output-modulo-time/ltacprof.v @@ -0,0 +1,8 @@ +(* -*- coq-prog-args: ("-emacs" "-profile-ltac") -*- *) +Ltac sleep' := do 100 (do 100 (do 100 idtac)). +Ltac sleep := sleep'. + +Theorem x : True. +Proof. + idtac. idtac. sleep. constructor. +Defined. -- cgit v1.2.3