Howe-Young opened a new issue, #16408:
URL: https://github.com/apache/tvm/issues/16408
I encountered the following error when building the tvm cuda backend using
Conda:
```sh
[ 98%] Building CXX object
CMakeFiles/tvm_objs.dir/src/contrib/hybrid/codegen_hybrid.cc.o
$BUILD_PREFIX/bin/x86_64-conda-linux-gnu-c++ -DDMLC_USE_FOPEN64=0
-DDMLC_USE_LOGGING_LIBRARY="<tvm/runtime/logging.h>" -DNDEBUG -DNDEBUG=1
-DTVM_INDEX_DEFAULT_I64=1 -DTVM_LLVM_VERSION=170 -DTVM_THREADPOOL_USE_OPENMP=0
-DTVM_USE_LIBBACKTRACE=1 -DUSE_FALLBACK_STL_MAP=0 -D_GNU_SOURCE
-D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS
-I$SRC_DIR/include -I$SRC_DIR/build/libbacktrace/include
-I$SRC_DIR/3rdparty/libcrc/include -isystem $SRC_DIR/3rdparty/dlpack/include
-isystem $SRC_DIR/3rdparty/dmlc-core/include -isystem
$SRC_DIR/3rdparty/rang/include -isystem $SRC_DIR/3rdparty/compiler-rt -isystem
$SRC_DIR/3rdparty/picojson -isystem $SRC_DIR/build/crt_config -isystem
/usr/local/cuda/include -std=c++17 -faligned-new -O2 -Wall -fPIC
-fvisibility-inlines-hidden -fmessage-length=0 -march=nocona -mtune=haswell
-ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O2
-ffunction-sections -pipe -isystem $PREFIX/include
-fdebug-prefix-map=$SRC_DIR=/usr/local/src/conda/tvm
-cu114-package-0.13.0 -fdebug-prefix-map=$PREFIX=/usr/local/src/conda-prefix
-O3 -DNDEBUG -MD -MT
CMakeFiles/tvm_objs.dir/src/contrib/hybrid/codegen_hybrid.cc.o -MF
CMakeFiles/tvm_objs.dir/src/contrib/hybrid/codegen_hybrid.cc.o.d -o
CMakeFiles/tvm_objs.dir/src/contrib/hybrid/codegen_hybrid.cc.o -c
$SRC_DIR/src/contrib/hybrid/codegen_hybrid.cc
make[2]: Leaving directory '$SRC_DIR/build'
[ 98%] Built target tvm_objs
make[1]: Leaving directory '$SRC_DIR/build'
make: *** [Makefile:146: all] Error 2
Traceback (most recent call last):
File "/tmp/yanghao/miniconda3/envs/tvm-build/bin/conda-build", line 11, in
<module>
sys.exit(main())
File
"/tmp/yanghao/miniconda3/envs/tvm-build/lib/python3.7/site-packages/conda_build/cli/main_build.py",
line 495, in main
execute(sys.argv[1:])
File
"/tmp/yanghao/miniconda3/envs/tvm-build/lib/python3.7/site-packages/conda_build/cli/main_build.py",
line 485, in execute
cache_dir=args.cache_dir,
File
"/tmp/yanghao/miniconda3/envs/tvm-build/lib/python3.7/site-packages/conda_build/api.py",
line 189, in build
variants=variants
File
"/tmp/yanghao/miniconda3/envs/tvm-build/lib/python3.7/site-packages/conda_build/build.py",
line 3102, in build_tree
notest=notest,
File
"/tmp/yanghao/miniconda3/envs/tvm-build/lib/python3.7/site-packages/conda_build/build.py",
line 2210, in build
cwd=src_dir, stats=build_stats)
File
"/tmp/yanghao/miniconda3/envs/tvm-build/lib/python3.7/site-packages/conda_build/utils.py",
line 402, in check_call_env
return _func_defaulting_env_to_os_environ('call', *popenargs, **kwargs)
File
"/tmp/yanghao/miniconda3/envs/tvm-build/lib/python3.7/site-packages/conda_build/utils.py",
line 382, in _func_defaulting_env_to_os_environ
raise subprocess.CalledProcessError(proc.returncode, _args)
subprocess.CalledProcessError: Command '['/bin/bash', '-o', 'errexit',
'/tmp/yanghao/miniconda3/envs/tvm-build/conda-bld/tvm-cu114-package_1705392846915/work/conda_build.sh']'
returned non-zero exit status 2.
```
My machine environment is as follows:
`OS: CentOS Linux release 7.6.1810 (Core)`
```sh
$ nvcc --version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2021 NVIDIA Corporation
Built on Mon_Oct_11_21:27:02_PDT_2021
Cuda compilation tools, release 11.4, V11.4.152
Build cuda_11.4.r11.4/compiler.30521435_0
$ conda list
# packages in environment at /tmp/xxx/miniconda3/envs/tvm-build:
#
# Name Version Build Channel
_libgcc_mutex 0.1 conda_forge conda-forge
_openmp_mutex 4.5 2_kmp_llvm conda-forge
attrs 22.1.0 py37h06a4308_0 anaconda
beautifulsoup4 4.11.1 py37h06a4308_0 anaconda
blas 1.0 mkl anaconda
brotlipy 0.7.0 py37h27cfd23_1003 anaconda
bzip2 1.0.8 h7b6447c_0 anaconda
c-ares 1.19.1 h5eee18b_0 anaconda
ca-certificates 2023.08.22 h06a4308_0 anaconda
certifi 2022.12.7 py37h06a4308_0 anaconda
cffi 1.15.1 py37h5eee18b_3 anaconda
chardet 4.0.0 py37h06a4308_1003 anaconda
charset-normalizer 2.0.4 pyhd3eb1b0_0 anaconda
cmake 3.26.4 h96355d8_0 anaconda
conda 23.1.0 py37h06a4308_0 anaconda
conda-build 3.23.3 py37h06a4308_0 anaconda
conda-package-handling 2.0.2 py37h06a4308_0 anaconda
conda-package-streaming 0.7.0 py37h06a4308_0 anaconda
cryptography 39.0.1 py37h9ce1e76_0 anaconda
curl 7.88.1 h37d81fd_2 anaconda
cython 0.29.33 py37h6a678d5_0 anaconda
expat 2.5.0 h6a678d5_0 anaconda
fftw 3.3.9 h27cfd23_1 anaconda
filelock 3.9.0 py37h06a4308_0 anaconda
flit-core 3.6.0 pyhd3eb1b0_0 anaconda
freetype 2.12.1 h4a9f257_0 anaconda
gdbm 1.18 hd4cb3f1_4 anaconda
gettext 0.21.0 h39681ba_1 anaconda
giflib 5.2.1 h5eee18b_3 anaconda
git 2.40.1 pl5340h4fa2fa2_1 anaconda
glob2 0.7 pyhd3eb1b0_0 anaconda
icu 73.1 h6a678d5_0 anaconda
idna 3.4 py37h06a4308_0 anaconda
importlib-metadata 4.11.3 py37h06a4308_0 anaconda
importlib_metadata 4.11.3 hd3eb1b0_0 anaconda
iniconfig 1.1.1 pyhd3eb1b0_0 anaconda
intel-openmp 2021.4.0 h06a4308_3561 anaconda
jinja2 3.1.2 py37h06a4308_0 anaconda
jpeg 9e h5eee18b_1 anaconda
krb5 1.20.1 h568e23c_1 anaconda
lcms2 2.12 h3be6417_0 anaconda
ld_impl_linux-64 2.38 h1181459_1 anaconda
lerc 3.0 h295c915_0 anaconda
libarchive 3.6.2 hb4bd9a0_1 anaconda
libcurl 7.88.1 h91b91d3_2 anaconda
libdeflate 1.17 h5eee18b_1 anaconda
libedit 3.1.20221030 h5eee18b_0 anaconda
libev 4.33 h7f8727e_1 anaconda
libffi 3.4.4 h6a678d5_0 anaconda
libgcc-ng 13.2.0 h807b86a_3 conda-forge
libgfortran-ng 11.2.0 h00389a5_1 anaconda
libgfortran5 11.2.0 h1234567_1 anaconda
liblief 0.12.3 h6a678d5_0 anaconda
libllvm14 14.0.6 hdb19cb5_3 anaconda
libnghttp2 1.52.0 ha637b67_1 anaconda
libpng 1.6.39 h5eee18b_0 anaconda
libssh2 1.10.0 h37d81fd_2 anaconda
libstdcxx-ng 11.2.0 h1234567_1 anaconda
libtiff 4.5.1 h6a678d5_0 anaconda
libuv 1.44.2 h5eee18b_0 anaconda
libwebp 1.2.4 h11a3e52_1 anaconda
libwebp-base 1.2.4 h5eee18b_1 anaconda
libxml2 2.10.4 hf1b16e4_1 anaconda
llvm-openmp 14.0.6 h9e868ea_0 anaconda
llvm-tools 14.0.6 hdb19cb5_3 anaconda
llvmdev 14.0.6 hdb19cb5_3 anaconda
lz4-c 1.9.4 h6a678d5_0 anaconda
make 4.2.1 h1bed415_1 anaconda
markupsafe 2.1.1 py37h7f8727e_0 anaconda
mkl 2021.4.0 h06a4308_640 anaconda
mkl-service 2.4.0 py37h7f8727e_0 anaconda
mkl_fft 1.3.1 py37hd3c417c_0 anaconda
mkl_random 1.2.2 py37h51133e4_0 anaconda
ncurses 6.4 h6a678d5_0 anaconda
numpy 1.21.5 py37h6c91a56_3 anaconda
numpy-base 1.21.5 py37ha15fc14_3 anaconda
openssl 1.1.1w h7f8727e_0 anaconda
packaging 22.0 py37h06a4308_0 anaconda
patch 2.7.6 h7b6447c_1001 anaconda
patchelf 0.17.2 h6a678d5_0 anaconda
pcre2 10.42 hebb0a14_0 anaconda
perl 5.34.0 h5eee18b_2 anaconda
pillow 9.4.0 py37h6a678d5_0 anaconda
pip 22.3.1 py37h06a4308_0 anaconda
pkginfo 1.8.3 py37h06a4308_0 anaconda
pluggy 1.0.0 py37h06a4308_1 anaconda
psutil 5.9.0 py37h5eee18b_0 anaconda
py 1.11.0 pyhd3eb1b0_0 anaconda
py-lief 0.12.3 py37h6a678d5_0 anaconda
pycosat 0.6.4 py37h5eee18b_0 anaconda
pycparser 2.21 pyhd3eb1b0_0 anaconda
pyopenssl 23.0.0 py37h06a4308_0 anaconda
pysocks 1.7.1 py37_1 anaconda
pytest 7.1.2 py37h06a4308_0 anaconda
python 3.7.16 h7a1cb2a_0 anaconda
python-libarchive-c 2.9 pyhd3eb1b0_1 anaconda
pytz 2022.7 py37h06a4308_0 anaconda
pyyaml 6.0 py37h5eee18b_1 anaconda
readline 8.2 h5eee18b_0 anaconda
requests 2.28.1 py37h06a4308_0 anaconda
rhash 1.4.4 hd590300_0 conda-forge
ripgrep 13.0.0 h35604bb_1 anaconda
ruamel.yaml 0.17.21 py37h5eee18b_0 anaconda
ruamel.yaml.clib 0.2.6 py37h5eee18b_1 anaconda
scipy 1.7.3 py37h6c91a56_2 anaconda
setuptools 65.6.3 py37h06a4308_0 anaconda
six 1.16.0 pyhd3eb1b0_1 anaconda
soupsieve 2.3.2.post1 py37h06a4308_0 anaconda
sqlite 3.41.2 h5eee18b_0 anaconda
tk 8.6.12 h1ccaba5_0 anaconda
toml 0.10.2 pyhd3eb1b0_0 anaconda
tomli 2.0.1 py37h06a4308_0 anaconda
toolz 0.12.0 py37h06a4308_0 anaconda
tqdm 4.64.1 py37h06a4308_0 anaconda
typing_extensions 4.4.0 py37h06a4308_0 anaconda
urllib3 1.26.14 py37h06a4308_0 anaconda
wheel 0.38.4 py37h06a4308_0 anaconda
xz 5.4.2 h5eee18b_0 anaconda
yaml 0.2.5 h7b6447c_0 anaconda
zipp 3.11.0 py37h06a4308_0 anaconda
zlib 1.2.13 h5eee18b_0 anaconda
zstandard 0.19.0 py37h5eee18b_0 anaconda
zstd 1.5.5 hc292b87_0 anaconda
```
### Expected behavior
Building success.
### Actual behavior
Building failure.
Any environment details, such as: Operating System, TVM version, etc
### Steps to reproduce
From official document:
[https://tvm.hyper.ai/docs/install/from_source](https://tvm.hyper.ai/docs/install/from_source)
```sh
sh conda/build_cuda.sh
```
### Triage
Please refer to the list of label tags
[here](https://github.com/apache/tvm/wiki/Issue-Triage-Labels) to find the
relevant tags and add them below in a bullet format (example below).
* [needs-triage](backend: cuda)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]