Skip to content

Issues with the new clingo concretizer #20040

@v-dobrev

Description

@v-dobrev

I am trying the new concretizer and ran into two issues. (I also posted these in a thread on Slack.)

Steps to reproduce the issue

The first issue is that the clingo concretizer seems to ignore some settings from packages.yaml like these:

packages:
  netlib-lapack:
    variants: +external-blas~lapacke

Basically, when I run

spack spec -I netlib-lapack

I get

Input spec
--------------------------------
 -   netlib-lapack

Concretized
--------------------------------
 -   [email protected]%[email protected]~external-blas~ipo~lapacke+shared~xblas build_type=RelWithDebInfo patches=0046d24487c0b7cbc84527fc36300d4e970cb4191b44e8b1619523fae15137f1,5c79286f3d08a0b0f1f3acba2a92ee698647716ba8c6c0ae20c9cc2713e6f139,ad3d41fe9ff94b7661e09fceaf2b2e4b8c83510c1465c016e161541b4429b5ee arch=linux-rhel7-power9le
 -       ^[email protected]%[email protected]~doc+ncurses+openssl+ownlibs~qt patches=1c540040c7e203dd8e27aa20345ecb07fe06570d56410a24a266ae570b1c4c39 arch=linux-rhel7-power9le

As you can see the spec has ~external-blas instead of +external-blas as specified in packages.yaml.

The second issue I noticed is that sometimes variants which are off by default are enabled (without explicitly being enabled anywhere). The specific case I ran into is this:

spack spec -I mfem

which gives:

Input spec
--------------------------------
 -   mfem

Concretized
--------------------------------
 -   [email protected]%[email protected]~amgx~conduit~cuda~debug~examples~gnutls~gslib~lapack~libceed~libunwind+metis~miniapps~mpfr+mpi~netcdf~occa~openmp~petsc~pumi~raja~shared+static~strumpack~suite-sparse~sundials~superlu-dist~threadsafe~umpire+zlib cuda_arch=sm_60 timer=auto arch=linux-rhel7-power9le
 -       ^[email protected]%[email protected]~complex~debug~int64~internal-superlu~mixedint+mpi~openmp+shared+superlu-dist patches=6e3336b1d62155f6350dfe42b0f9ea25d4fa0af60c7e540959139deb93a26059 arch=linux-rhel7-power9le
 -           ^[email protected]%[email protected]~external-blas~ipo~lapacke+shared~xblas build_type=RelWithDebInfo patches=0046d24487c0b7cbc84527fc36300d4e970cb4191b44e8b1619523fae15137f1,5c79286f3d08a0b0f1f3acba2a92ee698647716ba8c6c0ae20c9cc2713e6f139,ad3d41fe9ff94b7661e09fceaf2b2e4b8c83510c1465c016e161541b4429b5ee arch=linux-rhel7-power9le
 -               ^[email protected]%[email protected]~doc+ncurses+openssl+ownlibs~qt patches=1c540040c7e203dd8e27aa20345ecb07fe06570d56410a24a266ae570b1c4c39 arch=linux-rhel7-power9le
[+]          ^spectrum-mpi@rolling%[email protected] arch=linux-rhel7-power9le
 -           ^[email protected]%[email protected]+cuda~int64~ipo~openmp+shared build_type=RelWithDebInfo cuda_arch=none arch=linux-rhel7-power9le
[+]              ^[email protected]%[email protected] arch=linux-rhel7-power9le
[+]              ^[email protected]%[email protected]~gdb~int64~real64+shared build_type=Release patches=4991da938c1d3a1d3dea78e49bbebecba00273f98df2a656e38b83d55b281da1 arch=linux-rhel7-power9le
[+]              ^[email protected]%[email protected]~gdb~int64~ipo+shared build_type=RelWithDebInfo patches=4f892531eb0a807eb1b82e683a416d3e35154a455274cf9b162fb02054d11a5b,50ed2081bc939269689789942067c58b3e522c269269a430d5d34c00edbc5870,704b84f7c7444d4372cb59cca6e1209df4ef3b033bc4ee3cf50f369bce972a9d arch=linux-rhel7-power9le
[+]      ^[email protected]%[email protected]+optimize+pic+shared arch=linux-rhel7-power9le

You can see that the variant superlu-dist of hypre is enabled while its default is off (and I do not have anything related to mfem, hypre, or superlu-dist in my packages.yaml).

Note that if I run

spack spec -I hypre

I get a spec with superlu-dist disabled, as expected:

Input spec
--------------------------------
 -   hypre

Concretized
--------------------------------
 -   [email protected]%[email protected]~complex~debug~int64~internal-superlu~mixedint+mpi~openmp+shared~superlu-dist patches=6e3336b1d62155f6350dfe42b0f9ea25d4fa0af60c7e540959139deb93a26059 arch=linux-rhel7-power9le
 -       ^[email protected]%[email protected]~external-blas~ipo~lapacke+shared~xblas build_type=RelWithDebInfo patches=0046d24487c0b7cbc84527fc36300d4e970cb4191b44e8b1619523fae15137f1,5c79286f3d08a0b0f1f3acba2a92ee698647716ba8c6c0ae20c9cc2713e6f139,ad3d41fe9ff94b7661e09fceaf2b2e4b8c83510c1465c016e161541b4429b5ee arch=linux-rhel7-power9le
 -           ^[email protected]%[email protected]~doc+ncurses+openssl+ownlibs~qt patches=1c540040c7e203dd8e27aa20345ecb07fe06570d56410a24a266ae570b1c4c39 arch=linux-rhel7-power9le
[+]      ^spectrum-mpi@rolling%[email protected] arch=linux-rhel7-power9le

Error Message

N/A

Information on your system

The output from spack debug report is:

* **Spack:** 0.16.0-34-8d5a93358
* **Python:** 3.8.2
* **Platform:** linux-rhel7-power9le
* **Concretizer:** clingo

These observations are from LLNL's Lassen machine with custom packages.yaml, compilers.yaml, and config.yaml (to enable clingo) which are all placed in <spack-root>/etc/spack/. I've only included above the portion of packages.yaml that is relevant. I can post the whole files too, if necessary.

Additional information

  • I have run spack debug report and reported the version of Spack/Python/Platform
  • I have searched the issues of this repo and believe this is not a duplicate
  • I have run the failing commands in debug mode and reported the output

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingconcretizationtriageThe issue needs to be prioritized

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions