https://github.com/thozza/osbuild-depsolve-dnf-benchmark
Benchmark tooling for osbuild-depsolve-dnf — measures runtime, peak memory (via memray), and CPU profiles across solver commands.
https://github.com/thozza/osbuild-depsolve-dnf-benchmark
Last synced: about 1 month ago
JSON representation
Benchmark tooling for osbuild-depsolve-dnf — measures runtime, peak memory (via memray), and CPU profiles across solver commands.
- Host: GitHub
- URL: https://github.com/thozza/osbuild-depsolve-dnf-benchmark
- Owner: thozza
- License: apache-2.0
- Created: 2026-05-20T19:16:49.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2026-05-20T19:30:27.000Z (about 1 month ago)
- Last Synced: 2026-05-21T00:57:06.599Z (about 1 month ago)
- Language: Python
- Size: 10.7 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# osbuild-depsolve-dnf-benchmark
Benchmark tooling for [osbuild-depsolve-dnf](https://github.com/osbuild/osbuild) — measures runtime, peak memory (via [memray](https://github.com/bloomberg/memray)), and CPU profiles across solver commands (`dump`, `search`, `depsolve`).
## Prerequisites
- Python 3
- [memray](https://pypi.org/project/memray/) (`pip install memray`)
- A checkout of the [osbuild](https://github.com/osbuild/osbuild) repository
## Usage
Run from the osbuild repo checkout root:
```sh
python3 benchmark.py \
--tool-path /path/to/osbuild_repo/tools/osbuild-depsolve-dnf \
--pythonpath /path/to/osbuild_repo \
--queries-dir . \
--profile \
```
### Options
| Flag | Description |
|---|---|
| `--tool-path` | Path to the `osbuild-depsolve-dnf` script (required) |
| `--queries-dir` | Directory containing JSON query files (required) |
| `--api-version` | API version to benchmark: `1` or `2` (required) |
| `--iterations` | Number of iterations per command (default: 5) |
| `--pythonpath` | `PYTHONPATH` for the tool invocation (default: `.`) |
| `--commands` | Commands to benchmark: `dump`, `search`, `depsolve` (default: all) |
| `--profile` | Enable cProfile profiling (saves `.prof` files) |
| `--dnf5` | Use the dnf5 solver instead of dnf4 |
## Query files
Sample query JSON files are included for both API versions:
- `dump.json` / `dump_v2.json`
- `search.json` / `search_v2.json`
- `depsolve.json` / `depsolve_v2.json`
## License
Apache-2.0