test(benchmarks): isolated microbenchmarks for core hot-path kernels#213
Open
HanSur94 wants to merge 1 commit into
Open
test(benchmarks): isolated microbenchmarks for core hot-path kernels#213HanSur94 wants to merge 1 commit into
HanSur94 wants to merge 1 commit into
Conversation
Grows benchmark coverage over the performance-critical surface with five
focused, deterministic bench_*.m files, each isolating one hot-path kernel
as pure computation (no figure/render) and guarding it with a
machine-independent scaling gate:
- bench_downsample_kernels.m MinMax + LTTB downsampling (minmax_core_mex /
lttb_core_mex). LTTB had zero coverage anywhere before this.
- bench_binary_search.m range-window lookup (binary_search_mex);
log-scaling gate catches an O(log N) -> O(N) regression.
- bench_violation_cull.m fused threshold-marker detect+cull
(violation_cull_mex), constant + step-function branches.
- bench_datastore_range.m disk-backed range query
(FastSenseDataStore.getRange); gate asserts fixed-window query time stays
~constant as the dataset grows (catches a full-scan regression).
- bench_delimited_parse.m CSV ingestion (delimited_parse_mex);
row-scaling gate. Tag-pipeline ingestion was previously unbenchmarked.
Each follows the existing bench_*.m house style and reaches private wrappers
by cd-ing into the owning private/ folder (works in both MATLAB and Octave,
unlike addpath of a private dir). benchmarks/.reports/coverage.md records the
ranked surface, what each run added, and the remaining gaps so coverage keeps
expanding toward what matters.
No library/production code changed; new files only.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds five focused, deterministic benchmarks that grow coverage over FastSense's performance-critical surface. Each isolates one hot-path kernel as pure computation (no figure / no rendering) and guards it with a machine-independent scaling gate — so a regression trips the gate regardless of host speed.
bench_downsample_kernels.mminmax_core_mex/lttb_core_mex)bench_binary_search.mbinary_search_mex)bench_violation_cull.mviolation_cull_mex), constant + step-functionbench_datastore_range.mFastSenseDataStore.getRange)bench_delimited_parse.mdelimited_parse_mex)Why
Notes
bench_*.mhouse style (path/install()header, size sweep, warmup, median-of-runs, printed table +assertgate).cd-ing into the owningprivate/folder — works in both MATLAB and Octave, unlikeaddpathof a private dir (which MATLAB rejects).benchmarks/.reports/coverage.mddocuments the ranked surface, what each run added, and the remaining gaps (e.g. EventStore persistence, LiveEventPipeline tick)./bench-guardwill baseline these on its next run.🤖 Generated with Claude Code