-
Notifications
You must be signed in to change notification settings - Fork 89
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
StokesFO Kokkos Refactor and Boundary Layout Update #654
Conversation
…onCoefficient and GatherVerticallyContractedSolution
…me cleaning and to be extended to Jacobian and HessianVec. Also contains a GPU fix for previous commit
…set evaluator but it wasn't ported yet
…r problems that extend StokesFOBase
…adWeights initialization to PostRegistrationSetup, replaced quadWeights vector with Kokkos view
…ation back out of postRegistractionSetup. Would need to pass in numLayers during registration but it isn't a performance concern so it is fine as is
…or each workset even if they are empty and unused
… indexing bug in GatherVerticallyContractedSolution. Reverted changes to collapsed sideset layout constructor therefore all sidesets are now of size worksetSize*numSides in the sideSet_idx dimension
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks for working on this. I think mostly minor changes are needed. If you could send me StokesFO performance numbers on GPU that would be good to look at before pushing. We will need to discuss the left over evaluators which do not have kokkos kernels to see if we should add them. Could you post a list here and ping Mauro to see what he thinks? Also, it would be good to have that list/discussion for future porting.
src/LandIce/evaluators/LandIce_BasalFrictionCoefficient_Def.hpp
Outdated
Show resolved
Hide resolved
src/evaluators/response/PHAL_ResponseSquaredL2DifferenceSide_Def.hpp
Outdated
Show resolved
Hide resolved
src/evaluators/response/PHAL_ResponseSquaredL2DifferenceSide_Def.hpp
Outdated
Show resolved
Hide resolved
…ther Kokkos kernels to ComputeBasisFunctionsSide
…on into postRegistrationSetup in GatherVerticallyContractedSolution, disentangled collapsed and non-collapsed implementations in response evaluators and FieldFrobeniusNorm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Monstruous PR! Great work. I had some comments, but I believe they are just thoughts, for future development and/or to spark discussions.
src/LandIce/evaluators/LandIce_GatherVerticallyContractedSolution_Def.hpp
Show resolved
Hide resolved
@mcarlson801 @jewatkins I'm going to start working on some evaluators modified by this PR. Do you suggest that I base my work on this branch? |
If they're sideset evaluators, I would say yes. Although if you need things in master soon maybe not. I think there's still a few things Max needs to fix and it would be good to have the GPU performance tests up before merging this. See #661 and trilinos/Trilinos#8727. |
@mperego It looks like this change wasn't enough to pass unit tests. I'm working on a more comprehensive fix and I'll let you know as soon as this branch is testing clean. Sorry for the inconvenience, I'll try to get this working ASAP. |
@mcarlson801 Thanks. Do you mind if I cherry-pick your last commit onto my version where I just merged the master and force-push? Otherwise I need to do the merging again |
@mperego Yeah, if that works best for you, go for it. I'll work around whatever you decide to do, shouldn't be a problem. |
@mcarlson801 It's probably best if I hold off while you are fixing things. I won't mess with this branch |
src/LandIce/evaluators/LandIce_BasalFrictionCoefficient_Def.hpp
Outdated
Show resolved
Hide resolved
@mcarlson801 I notice that the |
@mperego The only problem that will be updated in this PR is StokesFO. The other problems that inherit from StokesFOBase will be changed in a later PR. Once I have tested this next (and hopefully final) commit for this PR, I will take a look at the StokesFOThermoCoupled problem to see what is needed to get it working with the collapsed sidesets. It may be that all of the evaluators for StokesFOThermoCoupled are ready for the new layout and in that case I could just switch a flag and it would use the new layouts. I'll update you when I know more. |
OK, thanks! I'll start working on that. For sure |
@mcarlson801 B.t.w. I confirm that |
…eSideSetStateField, and BasalFrictionCoefficient
@mcarlson801 thanks for all this work. I've merged master into the branch. @mcarlson801 @jewatkins is anything preventing this from being merged? More testing? |
I think there's still some lingering issues that Max was going to address today. |
The PR now has all the changes I was planning to make and is currently passing all unit tests, the only thing left is testing for GPU builds and then I think Jerry wants to look over it once more for a final review. |
I think the trilinos gpu fix is in develop so I'll go ahead and do a final review/test and push if everything looks good. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few more things. I think we're close. All performance tests pass except one (I think it's a known stability issue which I need to look into).
src/LandIce/evaluators/LandIce_GatherVerticallyContractedSolution_Def.hpp
Show resolved
Hide resolved
@mcarlson801 what's the ETC for this PR? We have enother PR that is ready to be merged in. My understanding is that they are complitely orthogonal. Should we merge the other PR first? |
There's a few minor edits and Max is seeing nondeterministic behavior in a performance test that needs to be tracked down. I don't see an issue with merging the other PR first. |
@jewatkins OK! I merged the other PR. Sorry for the nondeterministic behavior.. those are painful to fix. |
…on, cleaned up STKDiscretization, added comments for future work in CellToSide and ComputeBasisFunctionsSide
@mcarlson801 thanks!! |
This PR contains updates to the boundary conditions of the StokesFO problem. All sideset evaluators used in StokesFO have been updated to use the new collapsed sidesets layout while still allowing other problems to use these evaluators with the old sideset layouts. Additionally, the remaining performance intensive evaluators used in StokesFO have been ported to Kokkos. A summary of the changes in this PR is as follows: