remove valgrind, update docs

This commit is contained in:
illustris
2026-01-11 10:53:20 +05:30
parent 4f680b6a2d
commit c8f56cf3f1
3 changed files with 25 additions and 7 deletions

View File

@@ -134,6 +134,24 @@ Look at:
- `cpu-migrations`
- `instructions per cycle`
## Exercise 6: Benchmarking with hyperfine
Use `hyperfine` for proper statistical benchmarking with warmup runs:
```bash
hyperfine --warmup 1 './read_slow testfile' './read_fast testfile'
```
This gives you:
- Mean execution time with standard deviation
- Min/max times
- Direct comparison between implementations
For all three implementations:
```bash
hyperfine --warmup 1 './read_slow testfile' './read_stdio testfile' './read_fast testfile'
```
## Further Exploration
1. What happens with `read(fd, buf, 4096)` vs `read(fd, buf, 65536)`?