Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

solve_bicgstab: use linop.make instead of MF constructor #3619

Merged

Conversation

eebasso
Copy link
Contributor

@eebasso eebasso commented Nov 8, 2023

Summary

This PR replaces the explicit use of MF constructors in MLCGSolverT<MF>::solve_bicgstab with calls to the make method of the linear operator associated with the MLCGSolverT object.

Additional background

The use of MLLinOpT<MF>::make allows for inheritance of MLCGSolverT without an override of solve_bicgstab even if the MF class lacks a constructor with the same arguments as those MultiFab. For the MLMG template classes, make should generally be used instead of explicit MF constructors. Another PR to change this in solve_cg will follow once this is fully vetted and approved.

@WeiqunZhang
Copy link
Member

Need to fix some warnings.

@WeiqunZhang WeiqunZhang merged commit 6e2b831 into AMReX-Codes:development Nov 13, 2023
69 checks passed
@eebasso eebasso deleted the solve_bicgstab-use-linop-make branch November 14, 2023 23:45
guj pushed a commit to guj/amrex that referenced this pull request Dec 13, 2023
…#3619)

## Summary

This PR replaces the explicit use of MF constructors in
```MLCGSolverT<MF>::solve_bicgstab``` with calls to the `make` method of
the linear operator associated with the MLCGSolverT object.

## Additional background

The use of `MLLinOpT<MF>::make` allows for inheritance of MLCGSolverT
without an override of `solve_bicgstab` even if the MF class lacks a
constructor with the same arguments as those MultiFab. For the MLMG
template classes, `make` should generally be used instead of explicit MF
constructors. Another PR to change this in `solve_cg` will follow once
this is fully vetted and approved.
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.

2 participants