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

Updated the cpmd recipe #27

Open
wants to merge 1 commit into
base: releases/syrah
Choose a base branch
from

Conversation

batatasfritas
Copy link
Contributor

  • Added FFTW support (improves by 10% on GCC)
  • Added proper Intel support

- Added FFTW support (improves by 10% on GCC)
- Added proper Intel support
Copy link
Contributor

@nrichart nrichart left a comment

Choose a reason for hiding this comment

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

In addition to the remaks in the code, it seems that to get cpmd it is easier now
no need for manual_download
https://github.com/CPMD-code/CPMD

Comment on lines +89 to +92
cp.filter("FFLAGS='", "FFLAGS='-I{0}".format(spec['fftw'].include))
cp.filter(
"LIBS='",
"LIBS='{0} ".format(spec['fftw'].libs.ld_flags)
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
cp.filter("FFLAGS='", "FFLAGS='-I{0}".format(spec['fftw'].include))
cp.filter(
"LIBS='",
"LIBS='{0} ".format(spec['fftw'].libs.ld_flags)
cp.filter("FFLAGS='", "FFLAGS='-I{0}".format(spec['fftw-api'].include))
cp.filter(
"LIBS='",
"LIBS='{0} ".format(spec['fftw-api'].libs.ld_flags)

if spec.satisfies('%intel'):
cp.filter('CPP=', 'CPP=/lib/cpp -P -traditional')
#cp.filter("CPPFLAGS='-D__Linux", "CPPFLAGS='-D__Linux -DLINUX_IFC")
cp.filter("-D__HAS_FFT_DEFAULT", "-D__HAS_FFT_FFTW3")
Copy link
Contributor

@nrichart nrichart Dec 23, 2022

Choose a reason for hiding this comment

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

Suggested change
cp.filter("-D__HAS_FFT_DEFAULT", "-D__HAS_FFT_FFTW3")

It should be handled by the variant test higher

Comment on lines +47 to +50
if spec.satisfies('%gcc'):
cbase = 'LINUX-GFORTRAN'
elif spec.satisfies('%intel'):
cbase = 'LINUX-INTEL'
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
if spec.satisfies('%gcc'):
cbase = 'LINUX-GFORTRAN'
elif spec.satisfies('%intel'):
cbase = 'LINUX-INTEL'
cbase = 'LINUX-GFORTRAN'
if spec.satisfies('%intel'):
cbase = 'LINUX-INTEL'

Other why it will fail with any other compiler
If it should fail the conflicts() lines are missing

Comment on lines +116 to +120
if not spec.satisfies('^mkl'):
cp.filter(
'LIBS=.+',
"LIBS='{0}'".format(spec['lapack'].libs.ld_flags)
)
Copy link
Contributor

Choose a reason for hiding this comment

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

This should work for intel-mkl also no ?
In which case it is already above other why the test can be combined with the previous one line 79
if not spec.satisfies('%intel') or not spec.satisfies('^mkl'):

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.

2 participants