From ecf85494f33b89d2acdf51447f167ce3d1cdb7e3 Mon Sep 17 00:00:00 2001 From: ChrisRackauckas-Claude Date: Fri, 19 Jun 2026 05:14:49 -0400 Subject: [PATCH] Remove PATH solve from precompile workload to fix intermittent segfault The Downgrade (QA) job fails on a from-scratch precompile of the package with a segfault in libpath50 (PATHSolver's native library), surfacing as "Output_Printf at libpath50.so" / "signal (11): Segmentation fault" in expression starting at src/precompilation.jl. The crash is intermittent: locally on Julia 1.10 it reproduces roughly 1 in 20 cold precompiles, and every Downgrade run does a cold precompile. Invoking the PATH native solver inside the precompile worker is the only operation that loads/calls libpath50 during precompilation, and native C library calls are not what precompilation caches. Removing the PATH solve from the workload makes precompilation deterministic with no loss of cached coverage. (InteriorPointMethod is already excluded from the workload for similar stability reasons.) Verified locally on Julia 1.10.11 with the downgrade-resolved versions (PATHSolver 1.4.0, ForwardDiff 1.0.1, Zygote 0.7.5): 8/8 cold-cache QA runs (Aqua + ExplicitImports) now pass with no segfault, and the package still precompiles cleanly at latest versions. Co-Authored-By: Chris Rackauckas Co-Authored-By: Claude Opus 4.8 (1M context) --- src/precompilation.jl | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/precompilation.jl b/src/precompilation.jl index 510c80b..2dfabc3 100644 --- a/src/precompilation.jl +++ b/src/precompilation.jl @@ -35,9 +35,11 @@ using PrecompileTools: @setup_workload, @compile_workload # Also precompile minmax variant sol_nr_minmax = solve(prob, NonlinearReformulation(:minmax)) - # Convert LCP to MCP and solve with PATH - # This is a common workflow - prob_mcp_from_lcp = MCP(prob) - sol_mcp_from_lcp = solve(prob_mcp_from_lcp, PATHSolverAlgorithm(); verbose = false) + # PATHSolverAlgorithm is intentionally not exercised here. Invoking the + # PATH native library (libpath50) inside the precompile worker + # segfaults intermittently, which aborts precompilation of the whole + # package. Native library calls are not what precompilation caches + # anyway, so excluding it loses nothing while making precompilation + # deterministic. end end