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

Refactor: clean up BLACS initialization in Parallel_2D #4207

Merged
merged 3 commits into from
May 23, 2024

Conversation

jinzx10
Copy link
Collaborator

@jinzx10 jinzx10 commented May 22, 2024

Reminder

  • Have you linked an issue with this pull request?
  • Have you added adequate unit tests and/or case tests for your pull request?
  • Have you noticed possible changes of behavior below or in the linked issue?
  • Have you explained the changes of codes in core modules of ESolver, HSolver, ElecState, Hamilt, Operator or Psi? (ignore if not applicable)

What's changed?

Code relevant to the initialization of BLACS grid & its information is made slightly easier to read & maintain.

This PR is just a stage-1; further refactoring towards more convenient manipulation on 2d-block-cyclic data structure will follow.

Question

I gather BLACS would split the given communicator to get some new ones for its own purpose when initializing the process grid, so it might be unnecessary to create a Cartesian MPI communicator in advance, which means we might get rid of the function mpi_create_cart(MPI_Comm). However, I'm not completely sure whether a Cartesian MPI grid would have performance benefit; this needs to be verified by an MPI/ScaLAPACK expert.

Any changes of core modules? (ignore if not applicable)

No.

@jinzx10 jinzx10 added the Refactor Refactor ABACUS codes label May 22, 2024
Copy link
Collaborator

@mohanchen mohanchen left a comment

Choose a reason for hiding this comment

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

Nice job!

@mohanchen mohanchen merged commit 425feeb into deepmodeling:develop May 23, 2024
13 checks passed
@jinzx10 jinzx10 deleted the parallel_2d_cleanup branch May 23, 2024 05:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Refactor Refactor ABACUS codes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants