Repository navigation
Commit a73533c
committed
docs: add inlineDemo tracing example (leaf helper, two sites) (#232)
A small leaf helper square(x) called from two sites with
storage-read args. At O2/O3 both sites inline into the caller ->
two virtual activations in the tracer (the inline showcase, as
sum/factorial were for tailcall). Args are non-constant (storage
reads) so L1 fold can't collapse the inlined bodies.
Verified against bugc: correct result (3^2 + 4^2 = 25) at O0-O3;
zero inline marks at O0/O1, both sites inlined at O2 (108 -> 50
runtime instrs) and O3.
Prose + TraceExample wiring to follow (writer/docs).1 parent 36a5992 commit a73533c
1 file changed
Lines changed: 24 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
138 | 138 | | |
139 | 139 | | |
140 | 140 | | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
0 commit comments