Skip to content

REGRESSION - IMPROVEMENT - Run GPEC subprocesses with -t auto - #373

Merged
matt-pharr merged 4 commits into
developfrom
performance/regression-harness-threading
Aug 15, 2026
Merged

REGRESSION - IMPROVEMENT - Run GPEC subprocesses with -t auto#373
matt-pharr merged 4 commits into
developfrom
performance/regression-harness-threading

Conversation

@logan-nc

Copy link
Copy Markdown
Collaborator

Summary

The regression harness spawned GPEC subprocesses with no --threads flag, so all of GPEC's threaded kernels (Riccati parallel FM, ballooning, field reconstruction, kinetic forces, vacuum kernels) ran single-threaded unless JULIA_NUM_THREADS happened to be exported. Subprocesses now launch with --startup-file=no -t auto; override with GPEC_REGRESS_THREADS=1 (documented in --help and the harness docs). --startup-file=no also removes the user's startup.jl as an uncontrolled variable in regression runs.

Stacked on #369 (touches the same spawn sites in runner.jl); this PR's diff shows only the threading change. Retargets to develop when #369 merges.

Determinism

Riccati's parallel FM was reviewed for thread-count sensitivity: chunks integrate independently with per-chunk state and are assembled serially in chunk order; the only cross-thread reduction is an integer step count. Verified empirically: threaded local runs are bitwise identical to cached single-threaded baselines for every tracked quantity.

Regression report

  • solovev_n1: 21/21 unchanged (all diffs 0.0e+00), runtime 102.7s → 96.3s
  • diiid_n1: 48/48 unchanged (all diffs 0.0e+00), runtime 242.0s → 157.7s (−35%)

Note: Runtime (s) rows cached from single-threaded runs are not comparable to threaded ones — re-baseline with --force where runtime tracking matters. A caveat for future decks: chunk decomposition depends on parallel_threads ≥ 3 (EulerLagrange.jlbalance_integration_chunks), so decks raising that setting should re-verify; all current decks use ≤ 2.

⚠️ Requires third-party human review before merging — do not merge without an approving review.

🤖 Generated with Claude Code

Subprocesses previously launched with no --threads flag, so GPEC's threaded
kernels (Riccati parallel FM, ballooning, field reconstruction, kinetic
forces) ran single-threaded unless JULIA_NUM_THREADS happened to be set.
Launch with --startup-file=no -t auto (override via GPEC_REGRESS_THREADS)
for a ~35% diiid_n1 wall-time reduction. Tracked quantities verified
bitwise thread-count independent; only runtime rows change meaning.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@logan-nclogan-nc added feature New capability test Tests only labels Aug 14, 2026
@logan-nc

Copy link
Copy Markdown
CollaboratorAuthor

@d-burg@jhalpern30@matt-pharr do we want this? Or keep everything 1 thread for basic tests

…formance/regression-harness-threading
# Conflicts:
#	docs/development/regression-harness.md
#	regression-harness/regress.jl
#	regression-harness/src/runner.jl
Base automatically changed from performance/regression-harness-worktree-reuse to developAugust 14, 2026 18:32
@logan-nc

Copy link
Copy Markdown
CollaboratorAuthor

@matt-pharr this ran into your known issue in that it didn't edit enough to trigger the tests but the tests are required to merge. I am assigning you to this PR to either manual override or fix the testing/blocking logic

@matt-pharr
matt-pharr merged commit e3a74f4 into developAug 15, 2026
5 checks passed
@matt-pharr
matt-pharr deleted the performance/regression-harness-threading branch August 15, 2026 21:09
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

featureNew capabilitytestTests only

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@logan-nc@d-burg@matt-pharr@jhalpern30