Files
RustAst/examples/optimizer_repro.myc
T
Michael Schimmel d1b8d03604 Update benchmark and repeat counts
This commit updates the benchmark and repeat counts for various example
files. These changes reflect potential performance improvements or
variations observed during testing.
2026-03-03 18:55:31 +01:00

22 lines
544 B
Plaintext

;; Benchmark: 167ns
;; Benchmark-Repeat: 12120
;; Output: [42 150]
(do
;; 1. Provokation Stack-Gap (bei Optimization Level 2)
(def result
(fn []
(do
(def unused 10) ;; Wird entfernt, Slot 0 ist dann "leer"
(def used 42) ;; Bleibt auf Slot 1 -> Lücke!
used)))
;; 2. Provokation Inlining-Blockade
;; Diese Funktion wird nicht inlined, weil sie ein 'def' enthält
(def complex-add
(fn [a]
(do
(def b 100)
(+ a b))))
[(result) (complex-add 50)]
)