timothyw553 opened a new pull request, #825:
URL: https://github.com/apache/iceberg-cpp/pull/825
## Summary
Adds an opt-in benchmark build path so future C++ microbenchmarks can live
in-tree without affecting normal builds. Benchmarks stay disabled by default,
and this PR keeps the executable intentionally small so reviewers can focus on
CMake/Meson wiring and Google Benchmark integration.
- Adds `ICEBERG_BUILD_BENCHMARKS` for CMake and a disabled-by-default
`benchmarks` Meson feature.
- Wires `src/iceberg/benchmark` into both build systems.
- Adds Google Benchmark dependency setup for CMake and Meson.
- Adds a tiny smoke benchmark so the new target is buildable in isolation.
## Stack
This is PR 1 of 2.
PR 2 adds the actual metrics evaluator benchmark cases on top of this
scaffolding.
## Test Plan
- [x] Configured benchmark-enabled CMake build with
`-DICEBERG_BUILD_BENCHMARKS=ON`.
- [x] Built `metrics_evaluator_benchmark` on this branch.
- [x] Ran the smoke benchmark with `--benchmark_min_time=0.01s`.
- [x] Re-ran the default build and test suite on the top of the stack: 18/18
tests passed.
- [ ] Meson wiring is syntax-reviewed but not locally executed because
`meson` is not installed in this shell.
## Verification Commands
```bash
cmake -S . -B build-bench-stack -G Ninja \
-DFETCHCONTENT_TRY_FIND_PACKAGE_MODE=NEVER \
-DCMAKE_IGNORE_PREFIX_PATH=/opt/homebrew/anaconda3 \
-DCMAKE_PREFIX_PATH='/opt/homebrew/opt/snappy;/opt/homebrew/opt/zstd' \
-DICEBERG_BUILD_BENCHMARKS=ON
cmake --build build-bench-stack --target metrics_evaluator_benchmark
build-bench-stack/src/iceberg/benchmark/metrics_evaluator_benchmark
--benchmark_min_time=0.01s
cmake --build build
ctest --test-dir build --output-on-failure
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]