Skip to content

DFTU: Use ScalapackConnector instead of direct math library calls#7196

Merged
mohanchen merged 2 commits intodeepmodeling:developfrom
lanshuyue:packaging
Mar 31, 2026
Merged

DFTU: Use ScalapackConnector instead of direct math library calls#7196
mohanchen merged 2 commits intodeepmodeling:developfrom
lanshuyue:packaging

Conversation

@lanshuyue
Copy link
Copy Markdown
Collaborator

This PR modifies the DFT+U module to use the ScalapackConnector class instead of direct math library function calls. The changes improve code maintainability and consistency by centralizing ScaLAPACK function calls through a unified interface.

Changes Made

  1. Modified files:

    • source/source_lcao/module_dftu/dftu_hamilt.cpp
    • source/source_lcao/module_dftu/dftu_force.cpp
  2. Key changes:

    • Replaced direct pzgemm_ and pdgemm_ calls with ScalapackConnector::gemm
    • Replaced direct pztranc_ calls with ScalapackConnector::tranu
    • Added proper inclusion of scalapack_connector.h header
    • Removed redundant function prototypes in dftu_force.cpp

@lanshuyue lanshuyue requested a review from mohanchen March 31, 2026 03:19
@mohanchen mohanchen added the Refactor Refactor ABACUS codes label Mar 31, 2026
@mohanchen
Copy link
Copy Markdown
Collaborator

LGTM, thanks for your contribution.

@mohanchen mohanchen merged commit f814048 into deepmodeling:develop Mar 31, 2026
15 checks passed
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