Skip to content
Snippets Groups Projects
Unverified Commit 92b8177b authored by Massimiliano Culpo's avatar Massimiliano Culpo Committed by GitHub
Browse files

gromacs: remove 'rdtscp' variant, deduce the flag from the target (#18868)

refers #18858
parent acf4dc2e
No related branches found
No related tags found
No related merge requests found
...@@ -65,8 +65,6 @@ class Gromacs(CMakePackage): ...@@ -65,8 +65,6 @@ class Gromacs(CMakePackage):
description='The build type to build', description='The build type to build',
values=('Debug', 'Release', 'RelWithDebInfo', 'MinSizeRel', values=('Debug', 'Release', 'RelWithDebInfo', 'MinSizeRel',
'Reference', 'RelWithAssert', 'Profile')) 'Reference', 'RelWithAssert', 'Profile'))
variant('rdtscp', default=True,
description='Enable RDTSCP instruction usage')
variant('mdrun_only', default=False, variant('mdrun_only', default=False,
description='Enables the build of a cut-down version' description='Enables the build of a cut-down version'
' of libgromacs and/or the mdrun program') ' of libgromacs and/or the mdrun program')
...@@ -181,10 +179,11 @@ def cmake_args(self): ...@@ -181,10 +179,11 @@ def cmake_args(self):
# Fall back to this for unknown microarchitectures # Fall back to this for unknown microarchitectures
options.append('-DGMX_SIMD:STRING=None') options.append('-DGMX_SIMD:STRING=None')
if '-rdtscp' in self.spec: # Use the 'rtdscp' assembly instruction only on
options.append('-DGMX_USE_RDTSCP:BOOL=OFF') # appropriate architectures
else: options.append(self.define(
options.append('-DGMX_USE_RDTSCP:BOOL=ON') 'GMX_USE_RDTSCP', str(target.family) in ('x86_64', 'x86')
))
if '+mdrun_only' in self.spec: if '+mdrun_only' in self.spec:
options.append('-DGMX_BUILD_MDRUN_ONLY:BOOL=ON') options.append('-DGMX_BUILD_MDRUN_ONLY:BOOL=ON')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment