Build failure in r600 with gcc 10
Linux, amd64
Mesa master @ 4e623726
I am using gcc 10.2.0-10 from Debian unstable.
Just yesterday it seams to work all fine with my gcc.
Today:
[1335/1522] Compiling C++ object src/gallium/drivers/r600/libr600.a.p/sfn_sfn_vertexstageexport.cpp.o
FAILED: src/gallium/drivers/r600/libr600.a.p/sfn_sfn_vertexstageexport.cpp.o
/usr/bin/x86_64-linux-gnu-g++-10 -Isrc/gallium/drivers/r600/libr600.a.p -Isrc/gallium/drivers/r600 -I../../src/gallium/drivers/r600 -Isrc -I../../src -Isrc/mapi -I../../src/mapi -Isrc/mesa -I../../src/mesa -Iinclude -I../../include -Isrc/compiler -I../../src/compiler -I../../src/gallium/include -Isrc/gallium/auxiliary -I../../src/gallium/auxiliary -Isrc/amd/common -I../../src/amd/common -Isrc/gallium/drivers -I../../src/gallium/drivers -Isrc/compiler/nir -I../../src/compiler/nir -Isrc/util -I../../src/util -I/usr/include/libdrm -I/usr/include/valgrind -fvisibility=hidden -fdiagnostics-color=always -DNDEBUG -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wnon-virtual-dtor -std=c++14 -ffunction-sections -fdata-sections '-DPACKAGE_VERSION="21.0.0-devel"' '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DUSE_ELF_TLS -DHAVE_ST_VDPAU -DENABLE_ST_OMX_BELLAGIO=0 -DENABLE_ST_OMX_TIZONIA=0 -DHAVE_X11_PLATFORM -DHAVE_XCB_PLATFORM -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_DRM -DHAVE_DRM_PLATFORM -DENABLE_SHADER_CACHE -DHAVE___BUILTIN_BSWAP32 -DHAVE___BUILTIN_BSWAP64 -DHAVE___BUILTIN_CLZ -DHAVE___BUILTIN_CLZLL -DHAVE___BUILTIN_CTZ -DHAVE___BUILTIN_EXPECT -DHAVE___BUILTIN_FFS -DHAVE___BUILTIN_FFSLL -DHAVE___BUILTIN_POPCOUNT -DHAVE___BUILTIN_POPCOUNTLL -DHAVE___BUILTIN_UNREACHABLE -DHAVE_FUNC_ATTRIBUTE_CONST -DHAVE_FUNC_ATTRIBUTE_FLATTEN -DHAVE_FUNC_ATTRIBUTE_MALLOC -DHAVE_FUNC_ATTRIBUTE_PURE -DHAVE_FUNC_ATTRIBUTE_UNUSED -DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT -DHAVE_FUNC_ATTRIBUTE_WEAK -DHAVE_FUNC_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_ALIAS -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DHAVE_UINT128 -DUSE_SSE41 -DUSE_GCC_ATOMIC_BUILTINS -DUSE_X86_64_ASM -DMAJOR_IN_SYSMACROS -DHAVE_LINUX_FUTEX_H -DHAVE_ENDIAN_H -DHAVE_DLFCN_H -DHAVE_EXECINFO_H -DHAVE_SYS_SHM_H -DHAVE_CET_H -DHAVE_STRTOF -DHAVE_MKOSTEMP -DHAVE_TIMESPEC_GET -DHAVE_MEMFD_CREATE -DHAVE_RANDOM_R -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_GETRANDOM -DHAVE_PROGRAM_INVOCATION_NAME -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_DL_ITERATE_PHDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_PTHREAD -DHAVE_PTHREAD_SETAFFINITY -DHAVE_LIBDRM -DLLVM_AVAILABLE '-DMESA_LLVM_VERSION_STRING="11.0.0"' -DLLVM_IS_SHARED=1 -DUSE_LIBGLVND=1 -DHAVE_VALGRIND -DHAVE_LIBUNWIND -DHAVE_WAYLAND_PLATFORM -DWL_HIDE_DEPRECATED -DHAVE_DRI3 -DHAVE_DRI3_MODIFIERS -DHAVE_GALLIUM_EXTRA_HUD=1 -DHAVE_LIBSENSORS=1 -Werror=return-type -Werror=empty-body -Wno-non-virtual-dtor -Wno-missing-field-initializers -Wno-format-truncation -fno-math-errno -fno-trapping-math -flifetime-dse=1 -Werror=format -Wformat-security -std=c++17 -Og -ggdb -fPIC -pthread -isystem/usr/lib/llvm-11/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -D__STDC_FORMAT_MACROS -MD -MQ src/gallium/drivers/r600/libr600.a.p/sfn_sfn_vertexstageexport.cpp.o -MF src/gallium/drivers/r600/libr600.a.p/sfn_sfn_vertexstageexport.cpp.o.d -o src/gallium/drivers/r600/libr600.a.p/sfn_sfn_vertexstageexport.cpp.o -c ../../src/gallium/drivers/r600/sfn/sfn_vertexstageexport.cpp
In file included from /usr/include/c++/10/queue:64,
from ../../src/gallium/drivers/r600/sfn/sfn_valuepool.h:35,
from ../../src/gallium/drivers/r600/sfn/sfn_shader_base.h:39,
from ../../src/gallium/drivers/r600/sfn/sfn_vertexstageexport.h:4,
from ../../src/gallium/drivers/r600/sfn/sfn_vertexstageexport.cpp:1:
/usr/include/c++/10/bits/stl_queue.h: In instantiation of ‘class std::priority_queue<unsigned int, std::vector<int>, std::greater<int> >’:
../../src/gallium/drivers/r600/sfn/sfn_vertexstageexport.h:55:72: required from here
/usr/include/c++/10/bits/stl_queue.h:480:67: error: static assertion failed: value_type must be the same as the underlying container
480 | static_assert(is_same<_Tp, typename _Sequence::value_type>::value,
| ^~~~~
[1341/1522] Compiling C object src/gallium/drivers/radeonsi/libradeonsi.a.p/si_state_draw.c.o
../../src/gallium/drivers/radeonsi/si_state_draw.c: In function ‘si_emit_derived_tess_state’:
../../src/gallium/drivers/radeonsi/si_state_draw.c:88:29: warning: variable ‘max_lds_size’ set but not used [-Wunused-but-set-variable]
88 | unsigned offchip_layout, max_lds_size, target_lds_size, ls_hs_config;
| ^~~~~~~~~~~~
...
...
...
[1357/1522] Compiling C++ object src/gallium/drivers/r600/libr600.a.p/sfn_sfn_shader_fragment.cpp.o
FAILED: src/gallium/drivers/r600/libr600.a.p/sfn_sfn_shader_fragment.cpp.o
/usr/bin/x86_64-linux-gnu-g++-10 -Isrc/gallium/drivers/r600/libr600.a.p -Isrc/gallium/drivers/r600 -I../../src/gallium/drivers/r600 -Isrc -I../../src -Isrc/mapi -I../../src/mapi -Isrc/mesa -I../../src/mesa -Iinclude -I../../include -Isrc/compiler -I../../src/compiler -I../../src/gallium/include -Isrc/gallium/auxiliary -I../../src/gallium/auxiliary -Isrc/amd/common -I../../src/amd/common -Isrc/gallium/drivers -I../../src/gallium/drivers -Isrc/compiler/nir -I../../src/compiler/nir -Isrc/util -I../../src/util -I/usr/include/libdrm -I/usr/include/valgrind -fvisibility=hidden -fdiagnostics-color=always -DNDEBUG -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wnon-virtual-dtor -std=c++14 -ffunction-sections -fdata-sections '-DPACKAGE_VERSION="21.0.0-devel"' '-DPACKAGE_BUGREPORT="https://gitlab.freedesktop.org/mesa/mesa/-/issues"' -DUSE_ELF_TLS -DHAVE_ST_VDPAU -DENABLE_ST_OMX_BELLAGIO=0 -DENABLE_ST_OMX_TIZONIA=0 -DHAVE_X11_PLATFORM -DHAVE_XCB_PLATFORM -DGLX_INDIRECT_RENDERING -DGLX_DIRECT_RENDERING -DGLX_USE_DRM -DHAVE_DRM_PLATFORM -DENABLE_SHADER_CACHE -DHAVE___BUILTIN_BSWAP32 -DHAVE___BUILTIN_BSWAP64 -DHAVE___BUILTIN_CLZ -DHAVE___BUILTIN_CLZLL -DHAVE___BUILTIN_CTZ -DHAVE___BUILTIN_EXPECT -DHAVE___BUILTIN_FFS -DHAVE___BUILTIN_FFSLL -DHAVE___BUILTIN_POPCOUNT -DHAVE___BUILTIN_POPCOUNTLL -DHAVE___BUILTIN_UNREACHABLE -DHAVE_FUNC_ATTRIBUTE_CONST -DHAVE_FUNC_ATTRIBUTE_FLATTEN -DHAVE_FUNC_ATTRIBUTE_MALLOC -DHAVE_FUNC_ATTRIBUTE_PURE -DHAVE_FUNC_ATTRIBUTE_UNUSED -DHAVE_FUNC_ATTRIBUTE_WARN_UNUSED_RESULT -DHAVE_FUNC_ATTRIBUTE_WEAK -DHAVE_FUNC_ATTRIBUTE_FORMAT -DHAVE_FUNC_ATTRIBUTE_PACKED -DHAVE_FUNC_ATTRIBUTE_RETURNS_NONNULL -DHAVE_FUNC_ATTRIBUTE_ALIAS -DHAVE_FUNC_ATTRIBUTE_NORETURN -DHAVE_FUNC_ATTRIBUTE_VISIBILITY -DHAVE_UINT128 -DUSE_SSE41 -DUSE_GCC_ATOMIC_BUILTINS -DUSE_X86_64_ASM -DMAJOR_IN_SYSMACROS -DHAVE_LINUX_FUTEX_H -DHAVE_ENDIAN_H -DHAVE_DLFCN_H -DHAVE_EXECINFO_H -DHAVE_SYS_SHM_H -DHAVE_CET_H -DHAVE_STRTOF -DHAVE_MKOSTEMP -DHAVE_TIMESPEC_GET -DHAVE_MEMFD_CREATE -DHAVE_RANDOM_R -DHAVE_FLOCK -DHAVE_STRTOK_R -DHAVE_GETRANDOM -DHAVE_PROGRAM_INVOCATION_NAME -DHAVE_POSIX_MEMALIGN -DHAVE_DIRENT_D_TYPE -DHAVE_STRTOD_L -DHAVE_DLADDR -DHAVE_DL_ITERATE_PHDR -DHAVE_ZLIB -DHAVE_ZSTD -DHAVE_PTHREAD -DHAVE_PTHREAD_SETAFFINITY -DHAVE_LIBDRM -DLLVM_AVAILABLE '-DMESA_LLVM_VERSION_STRING="11.0.0"' -DLLVM_IS_SHARED=1 -DUSE_LIBGLVND=1 -DHAVE_VALGRIND -DHAVE_LIBUNWIND -DHAVE_WAYLAND_PLATFORM -DWL_HIDE_DEPRECATED -DHAVE_DRI3 -DHAVE_DRI3_MODIFIERS -DHAVE_GALLIUM_EXTRA_HUD=1 -DHAVE_LIBSENSORS=1 -Werror=return-type -Werror=empty-body -Wno-non-virtual-dtor -Wno-missing-field-initializers -Wno-format-truncation -fno-math-errno -fno-trapping-math -flifetime-dse=1 -Werror=format -Wformat-security -std=c++17 -Og -ggdb -fPIC -pthread -isystem/usr/lib/llvm-11/include -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -D__STDC_FORMAT_MACROS -MD -MQ src/gallium/drivers/r600/libr600.a.p/sfn_sfn_shader_fragment.cpp.o -MF src/gallium/drivers/r600/libr600.a.p/sfn_sfn_shader_fragment.cpp.o.d -o src/gallium/drivers/r600/libr600.a.p/sfn_sfn_shader_fragment.cpp.o -c ../../src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp
../../src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp: In function ‘unsigned int r600::barycentric_ij_index(nir_intrinsic_instr*)’:
../../src/gallium/drivers/r600/sfn/sfn_shader_fragment.cpp:102:4: error: control reaches end of non-void function [-Werror=return-type]
102 | case INTERP_MODE_FLAT:
| ^~~~
cc1plus: some warnings being treated as errors
The only thing I can blame is probably b8fdcffc and 98bb63b2, which indeed add a priority queue use and cases stuff there.
@gerddie Any idea?