fix(benchmark): use real FastSync flags and Release builds #282

Merged
TapTap merged 1 commits from fix/benchmark-invalid-flags into dev 2026-09-13 10:18:21 +02:00
Owner

What

The benchmark tool (benchmark/bench.py) was measuring the wrong thing because it used stale rsync-style flag spellings that now map to different FastSync options:

Old flag Actually meant Correct flag
-c --checksum -z compression
-m --prune-empty-dirs -j multithreading
-s --secluded-args (no-op) --chunk-serialization
-f --filter (needs arg) --sendfile

Changes

  • FASTSYNC_CONFIGS now uses the real flags (-z, -j, --chunk-serialization, --sendfile).
  • Benchmark build forces -DCMAKE_BUILD_TYPE=Release (was building debug).
  • Informational output moved to stderr so --output json emits valid JSON (previously corrupted by build/data prose).
  • Client/rsync failures now print the error instead of silently returning None.
  • Results table widened for the longer config names.
  • SERVER_CMD gains --allow-unauthenticated (required for plain TCP).
  • .opencode/skills/benchmark/SKILL.md: corrected config list, report labels, server invocation (-p, --allow-unauthenticated), and replaced the nonexistent python3 test.py --full with benchmark/bench.py.

Verification

  • ./build/tests → 40/40 pass.
  • python3 benchmark/bench.py --runs 2 --size-mb 8 → all FastSync + rsync configs run, distinct timings.
  • --output json parses cleanly.
  • Invalid --configs flag now surfaces fastsync failed (exit 1): Unknown option: ....
  • Custom network shaping (--throughput 100mbit) works.
## What The benchmark tool (`benchmark/bench.py`) was measuring the wrong thing because it used stale rsync-style flag spellings that now map to different FastSync options: | Old flag | Actually meant | Correct flag | |----------|----------------|--------------| | `-c` | `--checksum` | `-z` compression | | `-m` | `--prune-empty-dirs` | `-j` multithreading | | `-s` | `--secluded-args` (no-op) | `--chunk-serialization` | | `-f` | `--filter` (needs arg) | `--sendfile` | ## Changes - `FASTSYNC_CONFIGS` now uses the real flags (`-z`, `-j`, `--chunk-serialization`, `--sendfile`). - Benchmark build forces `-DCMAKE_BUILD_TYPE=Release` (was building debug). - Informational output moved to stderr so `--output json` emits valid JSON (previously corrupted by build/data prose). - Client/rsync failures now print the error instead of silently returning `None`. - Results table widened for the longer config names. - `SERVER_CMD` gains `--allow-unauthenticated` (required for plain TCP). - `.opencode/skills/benchmark/SKILL.md`: corrected config list, report labels, server invocation (`-p`, `--allow-unauthenticated`), and replaced the nonexistent `python3 test.py --full` with `benchmark/bench.py`. ## Verification - `./build/tests` → 40/40 pass. - `python3 benchmark/bench.py --runs 2 --size-mb 8` → all FastSync + rsync configs run, distinct timings. - `--output json` parses cleanly. - Invalid `--configs` flag now surfaces `fastsync failed (exit 1): Unknown option: ...`. - Custom network shaping (`--throughput 100mbit`) works.
TapTap added 1 commit 2026-09-13 10:14:46 +02:00
fix(benchmark): use real FastSync flags and Release builds
CI / lint (pull_request) Successful in 1m29s
CI / sanitizers (address) (pull_request) Skipped
CI / sanitizers (undefined) (pull_request) Skipped
CI / fuzz-build (pull_request) Skipped
CI / coverage (pull_request) Skipped
CI / valgrind (pull_request) Skipped
CI / build-and-test (pull_request) Successful in 1m44s
5aca91ab22
The benchmark tool used stale rsync-style spellings that map to

different FastSync options, so it never enabled the features it

claimed to measure:

  -c -> --checksum (not compression)

  -m -> --prune-empty-dirs (not multithreading)

  -s -> --secluded-args, a no-op (not chunk serialization)

  -f -> --filter, needs an argument (not sendfile)

Replace them with the real flags (-z, -j, --chunk-serialization,

--sendfile), force CMAKE_BUILD_TYPE=Release, route informational

output to stderr so --output json emits valid JSON, surface

client/rsync failures instead of silently dropping them, and widen

the results table for the longer config names. Update the benchmark

skill to match (correct flags, server invocation, and replace the

nonexistent test.py --full with benchmark/bench.py).
TapTap merged commit 6968ff6734 into dev 2026-09-13 10:18:21 +02:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: TapTap/FastSync#282