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

Remove CCE dependency from Interpolation #4299

Merged

Conversation

knelli2
Copy link
Contributor

@knelli2 knelli2 commented Oct 17, 2022

Proposed changes

Addresses the CCE part of #3561.

Moves SendGhWorldtubeData to CCE.

Upgrade instructions

src/ParallelAlgorithms/Interpolation/Callbacks/SendGhWorldtubeData.hpp has been moved to src/Evolution/Systems/Cce/SendGhWorldtubeData.hpp

Code review checklist

  • The code is documented and the documentation renders correctly. Run
    make doc to generate the documentation locally into BUILD_DIR/docs/html.
    Then open index.html.
  • The code follows the stylistic and code quality guidelines listed in the
    code review guide.
  • The PR lists upgrade instructions and is labeled bugfix or
    new feature if appropriate.

Further comments

@knelli2 knelli2 added the small Only changes a few lines of code, does a rename or is otherwise quick to review label Oct 17, 2022
@knelli2 knelli2 requested a review from nikwit October 17, 2022 18:24
@nikwit
Copy link
Contributor

nikwit commented Oct 17, 2022

maybe it would be more logical to move the callback into CCE itself? By forward declaring it, it seems like it can be used without CCE but if the executable does not have CCE as a link target, you will end up with an undefined symbol, or am I not seeing it right?

@knelli2
Copy link
Contributor Author

knelli2 commented Oct 17, 2022

You're right, but that's true of any forward declaration and we use forward declarations in a lot of places. I guess it's just a preference on whether we want to keep all the interpolation callbacks in the same place or not. I don't see an obvious reason to require them to be in the same place.

Furthermore, up until now, we haven't had any callbacks that truly depended on other libs. But in theory you could write a callback that does depend upon other libs. So in that case, you'd want to store it elsewhere. I think that's enough reason for me to move it to CCE. Does that sound good @nikwit?

@nikwit
Copy link
Contributor

nikwit commented Oct 17, 2022

I think the reason we use forward declaration is mostly to reduce compilation time so we only include the symbols that we need rather than the entire header. Correct me if I'm wrong but the forward declaration here does not do much in terms of dependencies and I suspect just deleting the link dependency from CMake would also compile and link fine. I agree we should put it into CCE to actually get rid of the dependency and so that the symbol can not exist without its definition.

@knelli2 knelli2 force-pushed the fix_intrp_cce_dependence branch from 5813b18 to 9336716 Compare October 17, 2022 20:16
@knelli2
Copy link
Contributor Author

knelli2 commented Oct 17, 2022

@nikwit ok it has been moved!

@knelli2 knelli2 mentioned this pull request Oct 17, 2022
3 tasks
Copy link
Contributor

@nikwit nikwit 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, but I am not sure if we shouldn't also move it into the CCE namespace? Whaat do you think?

@knelli2
Copy link
Contributor Author

knelli2 commented Oct 18, 2022

We could, but currently this isn't actually used anywhere except a test so not super important. I think I'll leave it as is for now

@nilsdeppe nilsdeppe merged commit 0357ede into sxs-collaboration:develop Oct 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
small Only changes a few lines of code, does a rename or is otherwise quick to review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants