17339, "mstrout", "compiler bug when use incorrect syntax for anonymous domains (e.g., {0..4},{1..2})", "2021-03-04T16:52:23Z"
Summary of Problem
I used the wrong syntax to specify an anonymous domain and got the following error at compile time:
sparse-matmatmult.chpl:18: internal error: UTI-MIS-0894 chpl version 1.24.0 pre-release (47885a6ded)
Note: This source location is a guess.
Internal errors indicate a bug in the Chapel compiler ("It's us, not you"),
and we're sorry for the hassle. We would appreciate your reporting this bug --
please see https://chapel-lang.org/bugs.html for instructions. In the meantime,
the filename + line number above may be useful in working around the issue.
Steps to Reproduce
Source Code:
// a test file for sparse matrix matrix multiplication that has a zero indexed,
// 1-indexed, and a wonky index example
import LinearAlgebra;
use LinearAlgebra.Sparse;
use IO;
// Usage similar to primers/sparse.chpl
proc writeArr(spsArr: [?Dom] ?eltType) {
const colHigh = spsArr.domain.dim(1).high;
writeln("colHigh=", colHigh);
for (i,j) in Dom {
write(spsArr(i,j), " ");
if (j == colHigh) then writeln();
}
writeln();
}
var ADom: sparse subdomain({0..4},{1..2}); // <== line 18, {0..4,1..2} makes error go away
var A: [ADom] real;
...
Compile command:
chpl sparse-matmatmult.chpl
Execution command:
./sparse-matmatmult
Associated Future Test(s):
I am not aware of any tests in the Chapel's test system that demonstrates this issue, but some could exist.
Configuration Information
- Output of
chpl --version:chpl version 1.24.0 pre-release (47885a6ded) - Output of
$CHPL_HOME/util/printchplenv --anonymize:
CHPL_TARGET_PLATFORM: darwin
CHPL_TARGET_COMPILER: clang
CHPL_TARGET_ARCH: x86_64
CHPL_TARGET_CPU: native
CHPL_LOCALE_MODEL: flat
CHPL_COMM: none
CHPL_TASKS: qthreads
CHPL_LAUNCHER: none
CHPL_TIMERS: generic
CHPL_UNWIND: none
CHPL_MEM: jemalloc
CHPL_ATOMICS: cstdlib
CHPL_GMP: bundled
CHPL_HWLOC: bundled
CHPL_REGEXP: re2
CHPL_LLVM: none
CHPL_AUX_FILESYS: none
- Back-end compiler and version, e.g.
gcc --versionorclang --version:
gcc --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk/usr/include/c++/4.2.1
Apple clang version 12.0.0 (clang-1200.0.32.29)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
clang --version
Apple clang version 12.0.0 (clang-1200.0.32.29)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
- (For Cray systems only) Output of
module list: on Mac so N/A