File tree Expand file tree Collapse file tree 1 file changed +22
-6
lines changed
Expand file tree Collapse file tree 1 file changed +22
-6
lines changed Original file line number Diff line number Diff line change 22
33A simple keyword-based chatbot with implementations in both C and Zig.
44
5- ## Benchmark
5+ ## Benchmarks
66
7- See [ BENCHMARK.md ] ( BENCHMARK.md ) for build time and executable size comparisons.
7+ ### Build Time & Size
88
9- Quick summary:
10- - ** C** : 93ms build time, 33K executable
11- - ** Zig** : 710ms build time, 1.3M executable
9+ See [ BENCHMARK.md] ( BENCHMARK.md ) for detailed build metrics.
1210
13- To run the benchmark:
11+ | Metric | C | Zig | Difference |
12+ | --------| ---| -----| -----------|
13+ | Build Time | 93ms | 710ms | Zig is 7.63x slower |
14+ | Executable Size | 33K | 1.3M | Zig is 39x larger |
15+
16+ Run build benchmark:
1417``` bash
1518./benchmark.sh
1619```
1720
21+ ### Runtime Performance
22+
23+ Both versions produce identical output. Runtime measurements with test inputs:
24+
25+ | Metric | C | Zig | Difference |
26+ | --------| ---| -----| -----------|
27+ | Execution Time | 286ms | 526ms | C is 1.83x faster |
28+
29+ Run runtime benchmark:
30+ ``` bash
31+ ./run_benchmarks.sh
32+ ```
33+
1834## Building
1935
2036### C Version
You can’t perform that action at this time.
0 commit comments