-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] 0.17.0 fails with GCC14 with: error: control reaches end of non-void function [-Werror=return-type]
#17459
Comments
If I add
|
Build works fine on my machine. Tested on OpenSUSE docker image. # spawn openSUSE container
docker run -it --rm opensuse/tumbleweed:latest
# run the below commands inside the container
zypper install -y awk git cmake ninja gcc gcc-c++ llvm-devel clang
zypper install -y python3 python3-devel python3-pip
zypper install -y ncurses-devel libxml2-devel zlib-devel
python3 -m pip install --break-system-packages numpy decorator attrs pytest
git clone https://github.com/apache/tvm --branch v0.17.0 --recursive
cd tvm
cmake -E make_directory build
cmake -S . -G Ninja -B build \
-DUSE_RPC=ON \
-DUSE_GRAPH_RUNTIME=ON \
-DUSE_LLVM=ON
cmake --build build
python3 -m pip install --break-system-packages ./python
python3 -c "import tvm; print(tvm.__version__)" # -> shows 0.17.0 |
You need the C/CXX flags |
Ah, I think I understand what you're trying to do. |
Right, TVM 0.16.0 is already available in openSUSE as an RPM package, but update to 0.17.0 fails with errors above. |
Build worked fine with Repro: # spawn openSUSE container
docker run -it --rm opensuse/tumbleweed:latest
# run the below commands inside the container
zypper install -y awk git cmake ninja gcc gcc-c++ llvm-devel clang python3 \
python3-devel python3-pip ncurses-devel libxml2-devel zlib-devel
python3 -m pip install --break-system-packages numpy decorator attrs pytest
git clone https://github.com/apache/tvm --branch v0.17.0 --recursive
cd tvm
cmake -E make_directory build
CC=gcc-14 CXX=g++-14 cmake -S . -G Ninja -B build \
-DCMAKE_C_FLAGS="-Werror=return-type" \
-DCMAKE_CXX_FLAGS="-Werror=return-type" \
-DUSE_RPC=ON -DUSE_GRAPH_RUNTIME=ON -DUSE_LLVM=ON
cmake --build build
python3 -m pip install --break-system-packages ./python
python3 -c "import tvm; print(tvm.__version__)" # -> shows 0.17.0 |
To be more complete, here is the cmake commandline used for x86_64:
And for aarch64, we also have |
I guess |
Right. Updating |
0.17.0 fails with GCC14 (on openSSUE Tumbleweed) with:
error: control reaches end of non-void function [-Werror=return-type]
Expected behavior
Build should succeed with GCC14.
Actual behavior
Build fails with:
Environment
openSUSE Tumbleweed
TVM 0.17.0
Steps to reproduce
Try to build with GCC14.
Triage
Please refer to the list of label tags here to find the relevant tags and add them below in a bullet format (example below).
The text was updated successfully, but these errors were encountered: