Adopt the DspTap FIR substrate via submodule#40
Merged
Conversation
SampleRateTap now consumes the shared design/format/kernel/measurement layer from DspTap (submodules/dsptap, pinned at the substrate-extraction merge) instead of carrying it privately — the M0 adoption step of the RatioTap plan, following the MuTap fft.h re-export pattern throughout: - submodules/dsptap + tap::dsp linked into the INTERFACE target; every workflow checkout now fetches submodules recursively. - srt/detail/kaiser.h -> re-export shim (tap::samplerate::detail names unchanged for existing includes). - srt/sample_traits.h -> refinement: each specialization derives from the tap::dsp format core and adds the ASRC-specific blend stratum (make_blend_factor, blend_factor_from_q64, blend); the sample_type concept states the full combined contract. detail::round_sat/ clamp_sat re-exported. - srt/polyphase_filter.h -> dot kernels consumed from tap::dsp::fir_kernels (SRT_ macro names forwarded to the TAP_DSP_ gates); the bank constructor's inline largest-remainder correction replaced by tap::dsp::quantize_row_preserving_sum. - tests/support analysis headers -> shims over tap::dsp::analysis. - Book: 21 anchor includes repointed to the submodule paths (kaiser design, dot kernels, row-sum quantization, moved sample-traits regions, multitone/sine instruments); every remaining include verified to resolve. Behavior change: none. Full suite green under GCC and clang -Werror (73/73 both), clang-tidy clean; the icount CI gates (+-3% on M33/M55/ Hexagon) are the final proof the relocation costs nothing on the hot path. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Ldeq57sBySx2nFTQsGcQB6
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.
The adoption half of M0 in the RatioTap plan (Appendix B), following tap/DspTap#5: SampleRateTap now consumes the shared design/format/kernel/measurement layer from DspTap instead of carrying it privately. Net −820 lines. The MuTap
fft.hre-export shim is the pattern throughout, so every historical include path and name keeps compiling.What changed
submodules/dsptappinned at the substrate-extraction merge (98abb04);tap::dsplinked into theSampleRateTap::SampleRateTapINTERFACE target. All workflow checkouts now usesubmodules: recursive(the MuTap convention); the SessionStart hook already ran submodule init.srt/detail/kaiser.h→ re-export shim:tap::samplerate::detailnames unchanged.srt/sample_traits.h→ refinement: each specialization derives from thetap::dspformat core and adds the ASRC-specific blend stratum (make_blend_factor,blend_factor_from_q64,blend— the mu-interpolation machinery a fixed-ratio converter has no use for, which is why it stays here). Thesample_typeconcept states the full combined contract;detail::round_sat/clamp_satre-exported.srt/polyphase_filter.h→ dot kernels consumed fromtap::dspvia using-declarations (SRT_*macro names forwarded to theTAP_DSP_*gates, including theSRT_CP_MIN_CHANNELSoverride); the bank constructor's inline largest-remainder correction replaced bytap::dsp::quantize_row_preserving_sum. The bank, mu-blend functions, andfractional_resamplerare untouched.tests/support/analysis headers → shims overtap::dsp::analysis; thesrt_testnames keep working.{{#include}}verified to resolve against its anchors — the book CI's stale-anchor gate re-verifies. The sample-traits and optimization chapters now show the refinement/relocated code where their anchors moved; a prose pass over those chapters is deliberately out of scope here so the diff stays mechanical.Behavior change: none — and how that's proven
-Werror(73/73 both — includes the SNR quality suites, DC-gain exactness, and multichannel bit-exactness tests, which would catch any arithmetic drift).scripts/tidy.shclean over the affected TUs; clang-format clean.One reviewable nuance: the bank constructor now accumulates each row's exact sum in storage (tap-reversed) order rather than prototype order inside the shared utility. The per-tap quantization and largest-remainder scan are order-identical; only the
llroundinput can differ in the last ulp, which the DC-gain and row-sum tests bound to the same one-LSB guarantee as before.🤖 Generated with Claude Code
https://claude.ai/code/session_01Ldeq57sBySx2nFTQsGcQB6
Generated by Claude Code