aboutsummaryrefslogtreecommitdiffstats
path: root/progs/bench
diff options
context:
space:
mode:
authorGustav Sörnäs <gustav@sornas.net>2021-03-05 19:47:00 +0100
committerGustav Sörnäs <gustav@sornas.net>2021-03-05 19:47:00 +0100
commitb1fab16befb78232d7a913f58beef639c5891e26 (patch)
tree3a8596bca862ecee3d464aa933bd6411d4c442a8 /progs/bench
parent0b15a38e324c3940318df462812c42f74a544267 (diff)
downloadsylt-b1fab16befb78232d7a913f58beef639c5891e26.tar.gz
set no_print in tests
Diffstat (limited to 'progs/bench')
-rw-r--r--progs/bench/fib.sy6
-rw-r--r--progs/bench/fib_iter.sy3
-rw-r--r--progs/bench/sum.sy3
3 files changed, 7 insertions, 5 deletions
diff --git a/progs/bench/fib.sy b/progs/bench/fib.sy
index 76c3af7..ad10e20 100644
--- a/progs/bench/fib.sy
+++ b/progs/bench/fib.sy
@@ -8,7 +8,7 @@ fib :: fn a:int -> int {
}
// 23 is around where things start getting slow.
start :: fn {
- //TODO pass arguments to skip debug printing. this test is very slow otherwise
- <!>
- // fib(23) <=> 28657
+ fib(23) <=> 28657
}
+
+// flags: no_print
diff --git a/progs/bench/fib_iter.sy b/progs/bench/fib_iter.sy
index f82d6f8..7ed1021 100644
--- a/progs/bench/fib_iter.sy
+++ b/progs/bench/fib_iter.sy
@@ -1,7 +1,6 @@
// A Fibonacci implementation that is a little
// less awful. But we run it 1000 times instead.
start :: fn {
- <!>
j := 0
for , j < 1000, j = j + 1 {
a := 0
@@ -15,3 +14,5 @@ start :: fn {
a <=> 12586269025
}
}
+
+// flags: no_print
diff --git a/progs/bench/sum.sy b/progs/bench/sum.sy
index 39252cd..76fe392 100644
--- a/progs/bench/sum.sy
+++ b/progs/bench/sum.sy
@@ -1,9 +1,10 @@
// Adds the numbers 0 to 100000
start :: fn {
- <!>
sum := 0
for i := 0, i <= 100000, i += 1 {
sum += i
}
sum <=> 5000050000
}
+
+// flags: no_print