Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/prereleases/v1.0.0-alpha.3' in…
Browse files Browse the repository at this point in the history
…to v1.0.0-alpha.3-fermi
  • Loading branch information
greenc-FNAL committed Jan 16, 2025
2 parents 641af8b + 0cdece7 commit 47dab32
Show file tree
Hide file tree
Showing 377 changed files with 6,072 additions and 8,719 deletions.
7 changes: 3 additions & 4 deletions .github/workflows/unit_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
run: "brew install kcov"
- name: Install Python packages
run: |
pip install --upgrade pip setuptools pytest pytest-xdist pytest-cov
pip install --upgrade pip setuptools pytest pytest-xdist pytest-cov clingo
pip install --upgrade flake8 "isort>=4.3.5" "mypy>=0.900" "click" "black"
- name: Setup git configuration
run: |
Expand Down Expand Up @@ -185,7 +185,6 @@ jobs:
spack bootstrap disable github-actions-v0.5
spack bootstrap disable github-actions-v0.6
spack bootstrap status
spack solve zlib
spack unit-test --verbose --cov --cov-config=pyproject.toml --cov-report=xml:coverage.xml lib/spack/spack/test/concretization/core.py
- uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b
with:
Expand Down Expand Up @@ -223,7 +222,7 @@ jobs:
. share/spack/setup-env.sh
$(which spack) bootstrap disable spack-install
$(which spack) solve zlib
common_args=(--dist loadfile --tx '4*popen//python=./bin/spack-tmpconfig python -u ./bin/spack python' -x)
common_args=(--dist loadfile --tx '4*popen//python=./bin/spack-tmpconfig python -u ./bin/spack python')
$(which spack) unit-test --verbose --cov --cov-config=pyproject.toml --cov-report=xml:coverage.xml "${common_args[@]}"
- uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b
with:
Expand Down Expand Up @@ -254,7 +253,7 @@ jobs:
env:
COVERAGE_FILE: coverage/.coverage-windows
run: |
spack unit-test -x --verbose --cov --cov-config=pyproject.toml
spack unit-test --verbose --cov --cov-config=pyproject.toml
./share/spack/qa/validate_last_exit.ps1
- uses: actions/upload-artifact@6f51ac03b9356f520e9adb1b1b7802705f340c2b
with:
Expand Down
2 changes: 1 addition & 1 deletion etc/spack/defaults/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ config:
install_tree:
root: $spack/opt/spack
projections:
all: "{architecture}/{compiler.name}-{compiler.version}/{name}-{version}-{hash}"
all: "{architecture.platform}-{architecture.target}/{name}-{version}-{hash}"
# install_tree can include an optional padded length (int or boolean)
# default is False (do not pad)
# if padded_length is True, Spack will pad as close to the system max path
Expand Down
7 changes: 3 additions & 4 deletions etc/spack/defaults/darwin/packages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,11 @@
# -------------------------------------------------------------------------
packages:
all:
compiler:
- apple-clang
- clang
- gcc
providers:
c: [apple-clang, llvm, gcc]
cxx: [apple-clang, llvm, gcc]
elf: [libelf]
fortran: [gcc]
fuse: [macfuse]
gl: [apple-gl]
glu: [apple-glu]
Expand Down
7 changes: 3 additions & 4 deletions etc/spack/defaults/packages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,18 @@
# -------------------------------------------------------------------------
packages:
all:
compiler: [gcc, clang, oneapi, xl, nag, fj, aocc]
providers:
awk: [gawk]
armci: [armcimpi]
blas: [openblas, amdblis]
c: [gcc]
cxx: [gcc]
c: [gcc, llvm, intel-oneapi-compilers, xl, aocc]
cxx: [gcc, llvm, intel-oneapi-compilers, xl, aocc]
D: [ldc]
daal: [intel-oneapi-daal]
elf: [elfutils]
fftw-api: [fftw, amdfftw]
flame: [libflame, amdlibflame]
fortran: [gcc]
fortran: [gcc, llvm]
fortran-rt: [gcc-runtime, intel-oneapi-runtime]
fuse: [libfuse]
gl: [glx, osmesa]
Expand Down
4 changes: 2 additions & 2 deletions etc/spack/defaults/windows/packages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@
# -------------------------------------------------------------------------
packages:
all:
compiler:
- msvc
providers:
c : [msvc]
cxx: [msvc]
mpi: [msmpi]
gl: [wgl]
2 changes: 1 addition & 1 deletion lib/spack/docs/pipelines.rst
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ that ``--tests`` is passed to ``spack ci rebuild`` as part of the
- spack --version
- cd ${SPACK_CONCRETE_ENV_DIR}
- spack env activate --without-view .
- spack config add "config:install_tree:projections:${SPACK_JOB_SPEC_PKG_NAME}:'morepadding/{architecture}/{compiler.name}-{compiler.version}/{name}-{version}-{hash}'"
- spack config add "config:install_tree:projections:${SPACK_JOB_SPEC_PKG_NAME}:'morepadding/{architecture.platform}-{architecture.target}/{name}-{version}-{hash}'"
- mkdir -p ${SPACK_ARTIFACTS_ROOT}/user_data
- if [[ -r /mnt/key/intermediate_ci_signing_key.gpg ]]; then spack gpg trust /mnt/key/intermediate_ci_signing_key.gpg; fi
- if [[ -r /mnt/key/spack_public_key.gpg ]]; then spack gpg trust /mnt/key/spack_public_key.gpg; fi
Expand Down
1 change: 0 additions & 1 deletion lib/spack/env/aocc/clang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/aocc/clang++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/aocc/flang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/arm/armclang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/arm/armclang++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/arm/armflang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/c++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/c89

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/c99

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/case-insensitive/CC

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/cce/case-insensitive/CC

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/cce/case-insensitive/crayCC

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/cce/cc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/cce/craycc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/cce/crayftn

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/cce/ftn

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/clang/clang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/clang/clang++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/clang/flang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/clang/gfortran

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/cpp

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/f77

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/f90

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/f95

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/fc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/fj/case-insensitive/FCC

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/fj/fcc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/fj/frt

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/ftn

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/gcc/g++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/gcc/gcc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/gcc/gfortran

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/intel/icc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/intel/icpc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/intel/ifort

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/ld

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/ld.gold

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/ld.lld

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/nag/nagfor

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/nvhpc/nvc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/nvhpc/nvc++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/nvhpc/nvfortran

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/oneapi/dpcpp

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/oneapi/icpx

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/oneapi/icx

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/oneapi/ifx

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/pgi/pgc++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/pgi/pgcc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/pgi/pgfortran

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/rocmcc/amdclang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/rocmcc/amdclang++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/rocmcc/amdflang

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl/xlc

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl/xlc++

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl/xlf

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl/xlf90

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl_r/xlc++_r

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl_r/xlc_r

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl_r/xlf90_r

This file was deleted.

1 change: 0 additions & 1 deletion lib/spack/env/xl_r/xlf_r

This file was deleted.

9 changes: 3 additions & 6 deletions lib/spack/llnl/util/lang.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ def index_by(objects, *funcs):
if isinstance(f, str):
f = lambda x: getattr(x, funcs[0])
elif isinstance(f, tuple):
f = lambda x: tuple(getattr(x, p) for p in funcs[0])
f = lambda x: tuple(getattr(x, p, None) for p in funcs[0])

result = {}
for o in objects:
Expand Down Expand Up @@ -996,11 +996,8 @@ def _receive_forwarded(self, context: str, exc: Exception, tb: List[str]):
def grouped_message(self, with_tracebacks: bool = True) -> str:
"""Print out an error message coalescing all the forwarded errors."""
each_exception_message = [
"{0} raised {1}: {2}{3}".format(
context,
exc.__class__.__name__,
exc,
"\n{0}".format("".join(tb)) if with_tracebacks else "",
"\n\t{0} raised {1}: {2}\n{3}".format(
context, exc.__class__.__name__, exc, f"\n{''.join(tb)}" if with_tracebacks else ""
)
for context, exc, tb in self.exceptions
]
Expand Down
2 changes: 1 addition & 1 deletion lib/spack/spack/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import spack.util.git

#: PEP440 canonical <major>.<minor>.<micro>.<devN> string
__version__ = "0.24.0.dev0"
__version__ = "1.0.0-alpha.3"
spack_version = __version__


Expand Down
23 changes: 19 additions & 4 deletions lib/spack/spack/binary_distribution.py
Original file line number Diff line number Diff line change
Expand Up @@ -625,17 +625,32 @@ def tarball_directory_name(spec):
Return name of the tarball directory according to the convention
<os>-<architecture>/<compiler>/<package>-<version>/
"""
return spec.format_path("{architecture}/{compiler.name}-{compiler.version}/{name}-{version}")
if spec.original_spec_format() < 5:
compiler = spec.annotations.compiler_node_attribute
assert compiler is not None, "a compiler spec is expected"
return spec.format_path(
f"{spec.architecture}/{compiler.name}-{compiler.version}/{spec.name}-{spec.version}"
)

return spec.format_path(f"{spec.architecture.platform}/{spec.name}-{spec.version}")


def tarball_name(spec, ext):
"""
Return the name of the tarfile according to the convention
<os>-<architecture>-<package>-<dag_hash><ext>
"""
spec_formatted = spec.format_path(
"{architecture}-{compiler.name}-{compiler.version}-{name}-{version}-{hash}"
)
if spec.original_spec_format() < 5:
compiler = spec.annotations.compiler_node_attribute
assert compiler is not None, "a compiler spec is expected"
spec_formatted = (
f"{spec.architecture}-{compiler.name}-{compiler.version}-{spec.name}"
f"-{spec.version}-{spec.dag_hash()}"
)
else:
spec_formatted = (
f"{spec.architecture.platform}-{spec.name}-{spec.version}-{spec.dag_hash()}"
)
return f"{spec_formatted}{ext}"


Expand Down
11 changes: 6 additions & 5 deletions lib/spack/spack/bootstrap/_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -226,12 +226,13 @@ def _root_spec(spec_str: str) -> str:
# Add a compiler and platform requirement to the root spec.
platform = str(spack.platforms.host())

if platform == "darwin":
spec_str += " %apple-clang"
elif platform == "windows":
# FIXME (compiler as nodes): recover the compiler for source bootstrapping
# if platform == "darwin":
# spec_str += " %apple-clang"
if platform == "windows":
spec_str += " %msvc"
elif platform == "linux":
spec_str += " %gcc"
# elif platform == "linux":
# spec_str += " %gcc"
elif platform == "freebsd":
spec_str += " %clang"
spec_str += f" platform={platform}"
Expand Down
Loading

0 comments on commit 47dab32

Please sign in to comment.