spack/var/spack/repos/builtin/packages/minigmg/package.py
Todd Gamblin a8ccb8e116 copyrights: update all files with license headers for 2021
- [x] add `concretize.lp`, `spack.yaml`, etc. to licensed files
- [x] update all licensed files to say 2013-2021 using
      `spack license update-copyright-year`
- [x] appease mypy with some additions to package.py that needed
      for oneapi.py
2021-01-02 12:12:00 -08:00

44 lines
1.8 KiB
Python

# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
class Minigmg(Package):
"""miniGMG is a compact benchmark for understanding the performance
challenges associated with geometric multigrid solvers
found in applications built from AMR MG frameworks
like CHOMBO or BoxLib when running
on modern multi- and manycore-based supercomputers.
It includes both productive reference examples as well as
highly-optimized implementations for CPUs and GPUs.
It is sufficiently general that it has been used to evaluate
a broad range of research topics including PGAS programming models
and algorithmic tradeoffs inherit in multigrid. miniGMG was developed
under the CACHE Joint Math-CS Institute.
Note, miniGMG code has been supersceded by HPGMG. """
homepage = "http://crd.lbl.gov/departments/computer-science/PAR/research/previous-projects/miniGMG/"
url = "http://crd.lbl.gov/assets/Uploads/FTG/Projects/miniGMG/miniGMG.tar.gz"
version('master', sha256='1c2d27496a881f655f5e849d6a7a132625e535739f82575991c511cc2cf899ac')
depends_on('mpi')
phases = ['build', 'install']
def build(self, spec, prefix):
cc = Executable(spec['mpi'].mpicc)
cc('-O3', self.compiler.openmp_flag, 'miniGMG.c',
'mg.c', 'box.c', 'solver.c', 'operators.ompif.c', 'timer.x86.c',
'-D__MPI', '-D__COLLABORATIVE_THREADING=6',
'-D__TEST_MG_CONVERGENCE', '-D__PRINT_NORM', '-D__USE_BICGSTAB',
'-o', 'run.miniGMG', '-lm')
def install(self, spec, prefix):
mkdir(prefix.bin)
install('run.miniGMG', prefix.bin)
mkdir(prefix.jobs)
install('job*', prefix.jobs)