Update benchmarks and adjust tests

This commit updates benchmark values in several example files to reflect
minor performance variations. It also includes adjustments to
integration
and unit tests to align with recent changes in the type checking and VM
logic, specifically concerning closures and TCO handling.
This commit is contained in:
Michael Schimmel
2026-02-19 23:54:53 +01:00
parent 3c0f2ec8ce
commit 1331aabbe1
13 changed files with 108 additions and 71 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
;; Closure Scope Test
;; Benchmark: 600ns
;; Benchmark: 700ns
;; Output: 15
(do
(def make-adder (fn [x]
+1 -1
View File
@@ -1,5 +1,5 @@
;; Complex Data Structure Test
;; Benchmark: 49.4us
;; Benchmark: 51.8us
;; Output: {:input 10, :name "Fibonacci", :output 55}
(do
(def fib (fn [n]
+1 -1
View File
@@ -1,4 +1,4 @@
;; Benchmark: 1.5us
;; Benchmark: 1.6us
;; Output: 36
(do
;; Excessive capture test
+1 -1
View File
@@ -1,4 +1,4 @@
;; Benchmark: 300ns
;; Benchmark: 400ns
;; Nested Macro and Arithmetic example
;; Output: 81
+1 -1
View File
@@ -1,4 +1,4 @@
;; Benchmark: 200ns
;; Benchmark: 300ns
;; Macro Splicing example
;; Demonstrates unrolling a list into another list.
;; Output: [0 1 2 3 4]
+1 -1
View File
@@ -1,4 +1,4 @@
;; Benchmark: 100ns
;; Benchmark: 200ns
;; Classic "unless" macro example
;; Demonstrates simple template substitution.
;; Output: 42
+5 -6
View File
@@ -1,17 +1,16 @@
;; Benchmark: 602.1us
;; Takeuchi Function Benchmark
;; Benchmark: ~150ms (Specialized) vs ~1.5s (Dynamic)
;; heavily recursive, benefits significantly from specialization of integer arithmetic
;; and direct function calls (skipping dynamic dispatch).
;; Output: 7
;; Output: 4
;; Benchmark: 468.7us
(do
(def tak (fn [x y z]
y
(if (<= x y)
z
(tak (tak (- x 1) y z)
(tak (- y 1) z x)
(tak (- z 1) x y)))))
(tak 10 6 3)
(tak 12 8 4)
+1 -1
View File
@@ -1,4 +1,4 @@
;; Benchmark: 2.7ms
;; Benchmark: 2.8ms
;; Output: "done"
(do
(def count_down (fn [n]