Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
4a43573
contractor,solver: establish FE_UPWARD at two unguarded gaol boundaries
kunalsheth Jun 19, 2026
b24de11
util/rounding: zero-cost debug rounding assertions + shadow consisten…
kunalsheth Jun 19, 2026
0e5a3bd
contractor: capability token + phase-hoist FE_UPWARD out of the Prune…
kunalsheth Jun 19, 2026
f2cceab
util/rounded_double: typed directed-rounding doubles + sound Tighten …
kunalsheth Jun 19, 2026
f12e4f1
util/ibex_guarded + rounding_lint: token-gate raw ibex calls and enfo…
kunalsheth Jun 19, 2026
0a5e8c9
benchmark: onboard ode_expressivity set + cross-solver comparison
kunalsheth Jun 19, 2026
effa058
docs: document UpwardRounding token + Debug rounding gate
kunalsheth Jun 19, 2026
7f53c02
docs: replace stale Codac references with CAPD-sole ODE backend
kunalsheth Jun 19, 2026
8a23671
docs(contractor/odes): fix stale order-20 and nullptr comments
kunalsheth Jun 19, 2026
6d21863
refactor(rounding): unify FPU rounding into one symmetric two-regime …
kunalsheth Jun 20, 2026
f55d480
test(util): gaol transcendental bit-identity + soundness gate
kunalsheth Jun 20, 2026
2629b8c
rounding: always-on clobber tripwire + ExpectClobber containment
kunalsheth Jun 20, 2026
363d91d
gitignore: anchor overbroad "smt2" pattern to the top-level dir
kunalsheth Jun 20, 2026
5e96fa6
test(rounding): direct unit + death tests for the clobber tripwire / …
kunalsheth Jun 20, 2026
0d2cc79
docs: warn that a new GLOB'd test file needs a CMake reconfigure
kunalsheth Jun 20, 2026
2eae8ea
docs(OPTIMIZATION_LOG): record gaol-internal fesetround levers (ibex-…
kunalsheth Jun 20, 2026
d47a659
build: pin ibex to fork sha e6d2403d (10-patch series incl. gaol roun…
kunalsheth Jun 20, 2026
4085235
build,test,docs: pin ibex cf3928c7 (return-status backward) + HC4 emp…
kunalsheth Jun 20, 2026
96fc118
perf,docs: gate IcpStat timer guards on stat.enabled() + post-Phase-2…
kunalsheth Jun 20, 2026
44d503d
fix(soundness): dreal/dreal4#321 denormal/underflow false-unsat (two …
kunalsheth Jun 21, 2026
c310e52
docs: `msr fpcr` writeup in OPTIMIZATION_LOG.md
kunalsheth Jun 21, 2026
0296a8e
fix(model-print): dreal/dreal4 BUG-005 scrambled model on QF_NRA_ODE
kunalsheth Jun 22, 2026
935dc57
refactor(lint),fix(soundness): generalize rounding_lint→lint + BUG-00…
kunalsheth Jun 22, 2026
9d807fb
build: export compile_commands.json for clangd/editor tooling
kunalsheth Jun 22, 2026
5934825
benchmark: ODE-subset selection (select.py --family/--all) + do_ab.sh…
kunalsheth Jun 22, 2026
5d619fe
fix(soundness): restore cav26 per-slice ODE filter — fixes false-unsa…
kunalsheth Jun 22, 2026
a925eba
fix(soundness): full-precision ODE vector-field feed — to_capd_string…
kunalsheth Jun 23, 2026
761ed39
benchmark: reconcile false-unsat artifacts in state.json exceptional …
kunalsheth Jun 23, 2026
8c16f93
fix(soundness): round-trip CAPD vector-field constants; lint+token ba…
kunalsheth Jun 23, 2026
34f13cf
build,lint: incremental clang-tidy copy gate (copy_lint.sh + .clang-t…
kunalsheth Jun 23, 2026
32b3d01
perf(ode): build CapdOdeCache IMaps in place — drop double copy
kunalsheth Jun 23, 2026
81994c1
perf,lint(api): const-ref Config params — drop copy + no-op move
kunalsheth Jun 23, 2026
cafb7ad
lint: expand clang-tidy gate to perf + UB/memory-safety; clear tree
kunalsheth Jun 23, 2026
a60b0ff
fix(ode): clip terminal gate to time window — pinned-time endpoint (B…
kunalsheth Jun 23, 2026
7711aa9
test(ode): regression replicators for dReal bugs 001/003/004/005/006/…
kunalsheth Jun 23, 2026
65e0680
fix(ode,visualize): parse `_k<step>` BMC naming for trace step field …
kunalsheth Jun 23, 2026
6f57f08
docs: condense root logs into decisions.md; fix staleness
kunalsheth Jun 23, 2026
a15d299
benchmark: trash data invalidated by soundness fixes
kunalsheth Jun 23, 2026
020d61f
feat(ode): runtime CAPD tuning flags + retuned defaults (order 12 / h…
kunalsheth Jun 24, 2026
226c6d3
docs(terminology): distinguish soundness from completeness; relabel F…
kunalsheth Jun 24, 2026
e9fd97c
docs: condense CLAUDE.md (43k→10k chars) into docs/rounding.md + docs…
kunalsheth Jun 24, 2026
9aceaa9
test(ode): aspirational BUG-002 negated-ODE semantics + cout-safety fix
kunalsheth Jun 24, 2026
20d055e
benchmark: exclude OOM-risk benchmarks from runnable set
kunalsheth Jun 24, 2026
aa409c6
fix(ode): centered-in-time mean-value tube range — resolves hull-grid…
kunalsheth Jun 24, 2026
419cbe1
docs: record centered-in-time resolution in HULL_COMPLETENESS + OPTIM…
kunalsheth Jun 24, 2026
0bef618
benchmark: commit baseline/probe/state artifacts; add --frozen-baseli…
kunalsheth Jun 24, 2026
61af662
docs: add bug log, issue321 repros, capd API reference; gitignore dre…
kunalsheth Jun 24, 2026
00431da
feat(build): enrich --version with git hash, dirty flag, OS, arch, ti…
kunalsheth Jun 25, 2026
5691dd4
docs: Gao paper summaries, rigorous forall expansion, forall/forall_t…
kunalsheth Jun 25, 2026
bdfbc3c
docs: move --version internals to build.md; split build-doc roles; de…
kunalsheth Jun 25, 2026
b1cc0f4
docs: add ibex_docs — IBEX architecture reference, audit, knobs, drea…
kunalsheth Jun 26, 2026
a2c2b32
docs(syntax-reference): fix binary-verified inaccuracies; cross-link …
kunalsheth Jun 26, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
74 changes: 74 additions & 0 deletions .clang-tidy
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# clang-tidy gate config — the type-aware companion to the regex lint.py.
#
# Three concerns, all things a regex lint structurally cannot see (they are
# *semantic*, type-dependent), run via ./copy_lint.sh (incremental by default,
# --all for a full sweep; it adds --warnings-as-errors and the macOS -isysroot fixup):
#
# 1. Accidental by-value COPIES of heavy types (Box, capd::IMap, Environment,
# IntervalVector, ...). This solver is memory-bound; a stray copy where a
# const& / move belongs is a silent regression. Covered by the performance-*
# copy subset (unnecessary-value-param, for-range-copy,
# unnecessary-copy-initialization, move-const-arg, implicit-conversion-in-loop).
#
# 2. Other PERFORMANCE pitfalls (avoid-endl, inefficient-vector-operation,
# noexcept-move, etc.) — the rest of performance-*.
#
# 3. UNDEFINED BEHAVIOR / memory-safety / segfault-class bugs — an explicit
# allow-list of the bugprone-* checks whose findings are genuine UB or memory
# corruption (use-after-move, dangling-handle, undefined-memory-manipulation,
# ptr/array mismatches, sizeof misuse, ...). The whole tree is currently clean
# on every one of these, so they cost zero noise and exist purely to catch a
# future regression. NOT the style/intent bugprone checks (easily-swappable-
# parameters, narrowing-conversions, branch-clone, ...) — those are noise here.
#
# Findings are resolved by fixing (const& / move / the real bug) or, when genuinely
# intended, justified inline with // NOLINT(<check>) <reason> — the type-aware twin
# of lint.py's `// lint: allow`.
#
# Two deliberately-excluded checks (see ./copy_lint.sh history):
# -performance-enum-size micro-opt only (smaller enum base); 12 core
# enums, mild serialization/arithmetic risk, no
# correctness value.
# -bugprone-unchecked-optional-access crash-class but FP-prone; its only hits are
# in the semi-dead pattern_matching trie code.
#
# No WarningsAsErrors here on purpose: editors/clangd surface these as plain
# warnings; the hard fail is the gate script's job (copy_lint.sh adds it).
Checks: >
-*,
performance-*,
-performance-enum-size,
bugprone-bitwise-pointer-cast,
bugprone-bool-pointer-implicit-conversion,
bugprone-casting-through-void,
bugprone-dangling-handle,
bugprone-dynamic-static-initializers,
bugprone-fold-init-type,
bugprone-incorrect-roundings,
bugprone-invalid-enum-default-initialization,
bugprone-misplaced-operator-in-strlen-in-alloc,
bugprone-misplaced-pointer-arithmetic-in-alloc,
bugprone-misplaced-widening-cast,
bugprone-multi-level-implicit-pointer-conversion,
bugprone-multiple-new-in-one-expression,
bugprone-not-null-terminated-result,
bugprone-pointer-arithmetic-on-polymorphic-object,
bugprone-raw-memory-call-on-non-trivial-type,
bugprone-return-const-ref-from-parameter,
bugprone-shared-ptr-array-mismatch,
bugprone-signed-char-misuse,
bugprone-sizeof-container,
bugprone-sizeof-expression,
bugprone-string-constructor,
bugprone-string-literal-with-embedded-nul,
bugprone-stringview-nullptr,
bugprone-suspicious-memory-comparison,
bugprone-suspicious-memset-usage,
bugprone-suspicious-realloc-usage,
bugprone-suspicious-stringview-data-usage,
bugprone-unhandled-self-assignment,
bugprone-undefined-memory-manipulation,
bugprone-unique-ptr-array-mismatch,
bugprone-unused-raii,
bugprone-use-after-move
HeaderFilterRegex: 'src/dreal/.*'
12 changes: 6 additions & 6 deletions .claude/skills/benchmark-baseline/skill.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ description: Re-establish a local performance baseline by running ~30 stratified
# /benchmark-baseline skill

1. **Confirm with user first:**
> This will run ~30 benchmarks (~15-20 min) and update `benchmark/state.json` to use a local baseline. Proceed?
> This will run ~70 benchmarks (all 43 odeexpr + ~10 each of saradc/github/tacas, at the 600 s timeout — can take 30-45 min) and update `benchmark/state.json` to use a local baseline. Proceed?

Wait for confirmation before continuing.

Expand All @@ -15,18 +15,18 @@ description: Re-establish a local performance baseline by running ~30 stratified
3. Spawn a Haiku subagent with this exact prompt:

---
Run the dReal4 baseline script (foreground, 1200000ms timeout):
Run the dReal4 baseline script (foreground, 1800000ms timeout):
```bash
bash /Users/kunalsheth/Documents/new_dreal/dreal4-cmake/benchmark/do_baseline.sh
```
The script prints OUT_DIR to stdout when done. Use the Read tool to read `<OUT_DIR>/aggregate.json`. Do not run any other commands or read any other files.

The `aggregate.json` contains a `family_comparison` key with per-family frozen vs local averages, and a `baseline_sha` key.
The `aggregate.json` contains a `family_comparison` key with per-family frozen vs local averages (including a weighted `odeexpr` family and a `weighted_overall` row), and a `baseline_sha` key.

Return a formatted summary as your only output:
- Header: `Baseline established from <baseline_sha> — <n_ran> benchmarks across 3 families`
- Table: one row per family from `family_comparison` — family | n | frozen PAR2 avg | local PAR2 avg | ratio (keys: `frozen_avg_par2`, `local_avg_par2`)
- One sentence: faster/slower/comparable? Flag >20% systematic differences as potentially a build config issue.
- Header: `Baseline established from <baseline_sha> — <n_ran> benchmarks across 4 families`
- Table: one row per family from `family_comparison` — family | n | weight | frozen PAR2 avg | local PAR2 avg | ratio (keys: `frozen_avg_par2`, `local_avg_par2`, `weight`), then the `weighted_overall` row last
- One sentence: faster/slower/comparable? Flag >20% systematic differences as potentially a build config issue. PAR2 is CPU time (user+sys), 600 s timeout.
- Last line: `baseline_local: benchmark/baseline_local.csv`

Be terse. Only return the final summary — no narration.
Expand Down
9 changes: 6 additions & 3 deletions .claude/skills/benchmark/skill.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,23 @@ description: Run a quick regression benchmark batch (~8-12 benchmarks) for the d
2. Spawn a Haiku subagent with this exact prompt:

---
Run the dReal4 benchmark script (foreground, 420000ms timeout):
Run the dReal4 benchmark script (foreground, 1500000ms timeout):
```bash
bash /Users/kunalsheth/Documents/new_dreal/dreal4-cmake/benchmark/do_benchmark.sh
```
The script prints OUT_DIR to stdout when done. Use the Read tool to read `<OUT_DIR>/aggregate.json`.

Return a formatted summary as your only output:
- If `correctness_flips` is non-empty, lead with: **CORRECTNESS REGRESSION**: [names] changed SAT/UNSAT result.
- Then, if any regression has priority `ODEEXPR-HIGH`/`ODEEXPR` (the high-priority ode_expressivity family — names start `odeexpr_`), lead with those next: **ODEEXPR REGRESSION**: [names]. odeexpr is weighted ~3× the other families, so treat its regressions as more serious and its speedups as more meaningful.
- First line: `N ran, M regressions, K exceptional`
- 2–4 sentences: (1) overall health, (2) notable timing changes using PAR2 scores (e.g. "PAR2: 50 s vs 600 s (0.08×, formerly TIM)" for a benchmark that went from timeout to solve), (3) whether exceptional speedups look real or noise
- 2–4 sentences: (1) overall health, (2) notable timing changes using PAR2 scores — PAR2 is now CPU time (user+sys), 600 s timeout / 1200 s penalty (e.g. "PAR2: 50 s vs 1200 s (0.04×, formerly TIM)"), (3) whether exceptional speedups look real or noise
- One sentence: what needs investigation before continuing, if anything
- Last line: `anomaly_report: <OUT_DIR>/anomaly_report.txt`

Be terse. Only return the final summary — no narration.
Then, as the FINAL part of your output, ALWAYS render the per-family PAR2 table from `family_comparison` in `aggregate.json` (the run vs the frozen baseline, `baseline_sha` in the same file). One markdown table, one row per family plus `weighted_overall`, columns: Family | Weight | n | Baseline PAR2 (s) | This run PAR2 (s) | Ratio. Sort families by descending weight (odeexpr, saradc, tacas, github) with `weighted_overall` last. Flag ratio >1.5 as a regression and <0.6 as exceptional. If `family_comparison` is absent (older run), say so in one line instead of inventing numbers.

Be terse. Only return the final summary + the PAR2 table — no narration.

---

Expand Down
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Binary research papers (docs/papers/) are stored via Git LFS, not as blobs.
*.pdf filter=lfs diff=lfs merge=lfs -text
7 changes: 5 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,10 @@ pip-selfcheck.json

.idea
.idea/**
smt2
# top-level SMT2 examples/scratch dir only — anchored so it does NOT match the
# source dir src/dreal/smt2/ or the test fixtures under test/dreal/test/smt2/.
/smt2/
gcc_build
past_compilations
benchmark/results/
benchmark/results/
dreal_popl27
Loading