Skip to content

Initialize HYPRE before creating objects when using plain Julia arrays#1001

Open
AJ0070 wants to merge 5 commits into
SciML:mainfrom
AJ0070:fix/777
Open

Initialize HYPRE before creating objects when using plain Julia arrays#1001
AJ0070 wants to merge 5 commits into
SciML:mainfrom
AJ0070:fix/777

Conversation

@AJ0070

@AJ0070 AJ0070 commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Checklist

  • Appropriate tests were added
  • Any code changes were done in a way that does not break public API
  • All documentation related to code changes were updated
  • The new code follows the
    contributor guidelines, in particular the SciML Style Guide and
    COLPRAC.
  • Any new documentation only uses public API

Additional context

This fixes a HYPRE initialization bug in the LinearSolveHYPREExt path for plain Julia matrix/vector inputs.

Previously, SciMLBase.init could auto-construct HYPREMatrix / HYPREVector before HYPRE.Init() had been called. Since those constructors touch MPI internally, a serial solve(prob, HYPREAlgorithm(...)) call could fail with:

Attempting to use an MPI routine (internal_Comm_size) before initializing or after finalizing MPICH

This PR initializes HYPRE before the auto-conversion path runs, while preserving the existing public API and solver behavior.

fixed #777
AI Disclosure: Used GPT 5.4

@AJ0070 AJ0070 closed this Jun 8, 2026
@AJ0070 AJ0070 reopened this Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

solve falls with HYPRE

1 participant