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

Breaking changes with PCU #433

Open
wants to merge 147 commits into
base: develop
Choose a base branch
from

Conversation

flagdanger
Copy link

Breaking changes with PCU

  • Removed pcu.cc and all uses of it
  • Changed functions that optionally took a PCUObj to take one

jacobmerson and others added 30 commits March 28, 2023 04:14
This commit adds a MPI state that's separate from the global variables
to the internal pcu_mpi interfaces. The user level PCU interface remains
unchanged. However, this change lays the groundwork for PCU2 that will
not make use of global state. This is important for some use cases like
working around the spectrum-mpi comm_dup bug. The removal of global
state also improves testability and modularity of this code.
Throughout the code base it was assumed that the mpi functions were
implemented through pmpi and so no other implementation really could
have been implemented. This change just removes the complexity
from having the vtable.
This commit allows the pcu_mpi to be initialized into a stack variable
rather than allways allocating on the heap.
This commit adds a MPI state that's separate from the global variables
to the internal pcu_mpi interfaces. The user level PCU interface remains
unchanged. However, this change lays the groundwork for PCU2 that will
not make use of global state. This is important for some use cases like
working around the spectrum-mpi comm_dup bug. The removal of global
state also improves testability and modularity of this code.
Throughout the code base it was assumed that the mpi functions were
implemented through pmpi and so no other implementation really could
have been implemented. This change just removes the complexity
from having the vtable.
This commit allows the pcu_mpi to be initialized into a stack variable
rather than allways allocating on the heap.
@flagdanger
Copy link
Author

@cwsmith, I also changed the file naming of PCUObj.h and PCU.h, and added explicitly declared data types to the templated add, min, max functions. I'm not seeing in the reviews any other changes we'd talked about making, but let me know if you'd like anything done differently.

Copy link
Contributor

@jacobmerson jacobmerson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Found at least some instances of mismatched types between the templated functions and the original ones.

crv/crvShape.cc Outdated Show resolved Hide resolved
crv/crvShape.cc Outdated Show resolved Hide resolved
crv/crvShape.cc Outdated Show resolved Hide resolved
crv/crvShape.cc Outdated Show resolved Hide resolved
apf/apfCGNS.cc Outdated Show resolved Hide resolved
apf/apfConvertTags.h Outdated Show resolved Hide resolved
apf/apfMixedNumbering.cc Outdated Show resolved Hide resolved
Copy link
Contributor

@cwsmith cwsmith left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thank you.

@flagdanger Do you have the output from the delta wing case?

Besides the comments/edits below, we need to capture a summary of the changes in the opening comment so it can be added to the merge commit.

apf/apfConstruct.cc Outdated Show resolved Hide resolved
mds/apfMDS.cc Outdated Show resolved Hide resolved
parma/parma.cc Outdated Show resolved Hide resolved
pcu/pcu_c.cc Outdated
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was git mv used to create this file from pcu/pcu.c? The github PR interface it shows pcu/pcu.c as being deleted and pcu/pcu_c.cc as a new file. It would be nice to maintain the history of the file.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@flagdanger I'd like to maintain the linkage between these files so history is preserved. Please let me know if you need help with that.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I forgot. I might need help doing this, I was having trouble before.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. No problem. I'll message you offline to setup a time.

pumi/pumi_mesh.cc Outdated Show resolved Hide resolved
test/matchedNodeElmReader.cc Outdated Show resolved Hide resolved
test/fusion2.cc Outdated Show resolved Hide resolved
test/fusion2.cc Outdated Show resolved Hide resolved
test/ma_test_analytic_model.cc Outdated Show resolved Hide resolved
@jacobmerson
Copy link
Contributor

/runtests

@cwsmith
Copy link
Contributor

cwsmith commented Aug 28, 2024

@jacobmerson

  • The issue with the CGNS build of pumi on the github runner issue is still being resolved. Hopefully I'll have an update on it tomorrow afternoon.
  • I've added you to the approved list of users who can trigger the tests via runtests. That change should merge into master in the morning and you can try `runtests' again.

@cwsmith
Copy link
Contributor

cwsmith commented Aug 28, 2024

Update:

  • The github hosted runner had its core count increased to eight to support the larger process counts the CGNS tests need.
  • HDF5 (needed by CGNS) has file locking requirements (see https://github.com/HDFGroup/hdf5/blob/develop/doc/file-locking.md) which /lore didn't appear to support. A support ticket was created to record this issue; 146981.
  • The github runner is now working out of /space to avoid this.

/runtests

Copy link

Simmetrix + CGNS Test Result: failure

@cwsmith
Copy link
Contributor

cwsmith commented Aug 28, 2024

It looks like adding the C++14 standard into the mix for the cgns build causes some more errors to be emitted:
https://github.com/SCOREC/core/actions/runs/10604091991/job/29389889050#step:4:187

@jacobmerson
Copy link
Contributor

@flagdanger looks like that error is just an extra semicolon

@flagdanger
Copy link
Author

@jacobmerson Could you try running tests again?

@cwsmith
Copy link
Contributor

cwsmith commented Aug 30, 2024

/runtests

Copy link

Simmetrix + CGNS Test Result: failure
Build Log
Simmetrix Test Result: success
Simmetrix + CGNS Test Result: failure

@cwsmith
Copy link
Contributor

cwsmith commented Sep 24, 2024

/runtests

Copy link

Build Log
Simmetrix Test Result: success
Simmetrix + CGNS Test Result: failure

@flagdanger
Copy link
Author

@cwsmith Could you run tests again?

@cwsmith
Copy link
Contributor

cwsmith commented Oct 16, 2024

/runtests

Copy link

Build Log
Simmetrix Test Result: success
Simmetrix + CGNS Test Result: success

@jacobmerson
Copy link
Contributor

@flagdanger @cwsmith Is all that's left fixing merge conflicts and rerunning the tests?

Copy link
Contributor

@cwsmith cwsmith left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. I saw only one left over unique_ptr use.

@@ -98,7 +97,7 @@ int main(int argc, char** argv)
auto PCUObj = std::unique_ptr<pcu::PCU>(new pcu::PCU(MPI_COMM_WORLD));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the other examples the unique_ptr was removed, I assume that can be done here too?

@cwsmith
Copy link
Contributor

cwsmith commented Oct 23, 2024

@flagdanger @cwsmith Is all that's left fixing merge conflicts and rerunning the tests?

Yeah, and we need to have a summary of the changes in the opening comment so it can be recorded in the merge commit.

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.

3 participants