Repository navigation
Conversation
Collaborator
Coverage Report for CI Build 42685150389Warning No base build found for commit Coverage: 54.949%Details
Uncovered ChangesNo uncovered changes found. Coverage RegressionsRequires a base build to compare against. How to fix this → Coverage Stats
💛 - Coveralls |
frankier
force-pushed
the
codex/prepared-log-mepv
branch
from
November 9, 2026 17:46
6f798b9 to
b771153
Compare
This branch has not been deployed
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.
Stacked on #93. Replace binary log-MEPV's separate normalization and checked moment sweeps with PBB #24, using FIB #25's prepared native log-response evaluator once per candidate.
Candidate conditioning stays in log space until each outcome has been shifted by its own maximum. Scratch explicitly stores per-outcome logs and scaled weights, preserving extreme tails and long-history behavior. At the point estimate, banks already recognized as preserving both ordinary response tails use
resp_vecdirectly, avoiding a log/exp round trip. Custom banks and logarithmic wrappers retain the native-log fallback. Explicit inlining keeps that dispatch allocation-free; tests cover workspace reuse and floating criteria throughLogItemBank.This PR remains a draft. Root/test/docs sources pin PBB
3e23026and FIBc2a882b; released dependencies must replace these pins before acceptance. Minimum-dependency downgrading is deferred while draft sources exist. Julia 1.12 and 1.13 still run tests; coverage uploads only from 1.13 to avoid the observed Coveralls build-close race.Focused numerical, tail, derivative, long-history and prepared-scan tests pass on Julia 1.13.3, including zero allocations per prepared candidate. Full CI passes on the final revision
2c8103a: Julia 1.12, Julia 1.13 and documentation.Fresh Julia 1.13.3 benchmarks
Single thread pinned to CPU 0; 33 points on [-4,4], Normal(0,1), ten fixed responses and the original CATExperiments 100-million-item RNG prefix. Warmed variants are randomly interleaved: 31 rounds through 10,000 items, 21 at 100,000. All 456 timed samples have zero compilation and GC time.
¹ Medians of paired ratios; timing columns are medians. The control reconstructs the preceding PR's candidate kernel (CAT
b00f94b, FIBad929b5) in local benchmark functions using the unchanged PBB kernel. It does not override package methods; its entry-point overhead differs slightly fromStateful.next_item. Absolute timings vary between sessions, so compare the fresh interleaved controls within this run.At 100,000 items, the new FIB evaluator with the old point-probability calculation takes 447.160 ms. Paired speedups are 1.077× from FIB and another 1.037× from CAT's point probabilities. This step reduces log time by about 10%; the 2×-linear target remains unmet, requiring roughly another 4.6× log speedup.
Selections remain 21/809/9424/30483 at 32/1,000/10,000/100,000 items. Maximum relative criterion difference is 1.78e-15 versus linear, 5.97e-16 versus the previous log control. New log selection allocates a constant 4,240 bytes at the three larger sizes; individual prepared candidates allocate zero.
LLVM and remaining work
The producer now contains four-wide Float64 arithmetic and vector table gathers, with no generic apply or out-of-line
exp/log1pcalls. Previously it had eight scalar math call sites and only two-wide channel operations. Producer IR grows from 400 to 1,165 lines as Base's transcendental implementations are inlined. Moment reductions remain four-wide. The generic PBB loop needed no additional changes.The remaining cost is the expanded transcendental algorithms, their table access and control flow; enabling SIMD alone does not remove that work. A separate maximum pass did not help, and a guarded probability-space prototype offered only a modest extra gain for substantially more conditions/fallback logic, so neither was adopted.
Driver:
CATExperiments/bench/log_optimisation_20261109/next_step/run.jl. Raw samples, correctness checks, source revisions, dependency manifest and LLVM are retained locally inCATExperiments/data/analysis/20261109-log-vectorized/; these are not claimed to be published repository artifacts.