CPU Architecture support (#27924)
* CPU Architecture Support This commit removes the `native` variant in favor of Spack's built-in support for specifying a target cpu architecture. It also passes this information to the Legion build system so that it correctly passes the architecture to GASNet when built internally * fixing whitespace * Update package.py based on a conversation with @streichler, this change sets `BUILD_MARCH` to an empty string, which will prevent legion's CMake build system from inserting `-march=native` and allow Spack to provide the correct architecture flags. * Update package.py adding a comment on what problem this MR solves. * Update package.py formatting
This commit is contained in:
parent
f876813531
commit
28d31316b7
1 changed files with 3 additions and 7 deletions
|
@ -198,9 +198,6 @@ def validate_gasnet_root(value):
|
|||
variant('max_fields', values=int, default=512,
|
||||
description="Maximum number of fields allowed in a logical region.")
|
||||
|
||||
variant('native', default=False,
|
||||
description="Enable native/host processor optimizaton target.")
|
||||
|
||||
def cmake_args(self):
|
||||
spec = self.spec
|
||||
cmake_cxx_flags = []
|
||||
|
@ -339,10 +336,9 @@ def cmake_args(self):
|
|||
maxfields = maxfields << 1
|
||||
options.append('-DLegion_MAX_FIELDS=%d' % maxfields)
|
||||
|
||||
if '+native' in spec:
|
||||
# default is off.
|
||||
options.append('-DBUILD_MARCH:STRING=native')
|
||||
|
||||
# This disables Legion's CMake build system's logic for targeting the native
|
||||
# CPU architecture in favor of Spack-provided compiler flags
|
||||
options.append('-DBUILD_MARCH:STRING=')
|
||||
return options
|
||||
|
||||
@run_after('install')
|
||||
|
|
Loading…
Reference in a new issue