Skip to content

GPU: Add GPU Baseline for ABACUS !#1535

Merged
denghuilu merged 17 commits into
deepmodeling:developfrom
denghuilu:cuda
Nov 22, 2022
Merged

GPU: Add GPU Baseline for ABACUS !#1535
denghuilu merged 17 commits into
deepmodeling:developfrom
denghuilu:cuda

Conversation

@denghuilu

@denghuilu denghuilu commented Nov 19, 2022

Copy link
Copy Markdown
Member

CUDA GPU implementations

In ABACUS, we provide the option to use the GPU devices to accelerate the performance. In the tested si16_pw system, we have found an order of magnitude speedup compared with the CPU code.
And it has the following general features:

  • Full gpu implementations: During the SCF progress, Psi, Hamilt, Hsolver, and DiagCG classes are stored or calculated by the GPU devices.

  • Electronic state data: (e.g. electronic density) are moved from the GPU to the CPU(s) every SCF step.

  • Acclerated by the NVIDIA libraries: cuBLAS for common linear algebra calculations, cuSolver for eigen values/vectors, and cuFFT for the conversions between the real and recip spaces.

  • Multi GPU supprted: Using multiple MPI tasks will often give the best performance. Note each MPI task will be bind to a GPU device with automatically computing load balancing.

  • Parallel strategy: K point parallel.

Building ABACUS with the GPU support:

Check the Advanced Installation Options for the installation of CUDA version support.

Run with the GPU support by editing the INPUT script:

In INPUT file we need to set the value keyword device to be gpu.

Examples

We provides examples of gpu calculations.

Known limitations

  • Only CG method is supported, so the input keyword ks_solver can only take the value cg,
  • Only PW basis is supported, so the input keyword basis_type can only take the value pw,
  • Only k point parallelization is supported, so the input keyword kpar will be set to match the number of MPI tasks automatically.
  • Supported CUDA architectures:
    • 60 # P100, 1080ti
    • 70 # V100
    • 75 # T4
    • 80 # A100, 3090

@denghuilu denghuilu requested review from Qianruipku and dyzheng and removed request for dyzheng November 19, 2022 14:49
@denghuilu denghuilu changed the title GPU: Add GPU Baseline for ABACUS! GPU: Add GPU Baseline for ABACUS ! Nov 19, 2022
@denghuilu denghuilu enabled auto-merge (squash) November 22, 2022 14:13
@denghuilu denghuilu disabled auto-merge November 22, 2022 14:14
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