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
1.11.0: test suite is failing #3442
Comments
hey, it would be great if this was fixed before taking the abseil dependency! |
These failures appear to be platform-specific. In particular:
|
I'm using Linux/x86 with gcc 11.1.1 and googletest is build wqith LTO optimisation. |
I also tried to reproduce this and could not. I used the fedora:34 docker image since that seems like it is what you are using. We have a bug report form here https://github.com/google/googletest/blob/master/.github/ISSUE_TEMPLATE/00-bug_report.md. Please provide all of the information in that form, and a complete list of commands to reproduce the issue you are seeing. |
I'm not using fedora but own distribution. CFLAGS='-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none'
CXXFLAGS='-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none'
FFLAGS='-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -I/usr/lib64/gfortran/modules'
FCFLAGS='-O2 -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fdata-sections -ffunction-sections -flto=auto -flto-partition=none -I/usr/lib64/gfortran/modules'
LDFLAGS='-Wl,-z,relro -Wl,--as-needed -Wl,--gc-sections -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -flto=auto -flto-partition=none -fuse-linker-plugin'
CC=/usr/bin/gcc
CXX=/usr/bin/g++
FC=/usr/bin/gfortran
AR=/usr/bin/gcc-ar
NM=/usr/bin/gcc-nm
RANLIB=/usr/bin/gcc-ranlib
export CFLAGS CXXFLAGS FFLAGS FCFLAGS LDFLAGS CC CXX FC AR NM RANLIB
/usr/bin/cmake -B x86_64-redhat-linux-gnu -D BUILD_SHARED_LIBS=ON -D CMAKE_AR=/usr/bin/gcc-ar -D CMAKE_BUILD_TYPE=RelWithDebInfo -D CMAKE_C_FLAGS_RELEASE=-DNDEBUG -D CMAKE_CXX_FLAGS_RELEASE=-DNDEBUG -D CMAKE_Fortran_FLAGS_RELEASE=-DNDEBUG -D CMAKE_INSTALL_PREFIX=/usr -D CMAKE_NM=/usr/bin/gcc-nm -D CMAKE_RANLIB=/usr/bin/gcc-ranlib -D CMAKE_VERBOSE_MAKEFILE=ON -D DBUILD_SHARED_LIBS=ON -D INCLUDE_INSTALL_DIR=/usr/include -D LIB_INSTALL_DIR=/usr/lib64 -D LIB_SUFFIX=64 -D SHARE_INSTALL_PREFIX=/usr/share -D SYSCONF_INSTALL_DIR=/etc -S . -D BUILD_SHARED_LIBS=ON -D gmock_build_tests=ON -D gtest_build_samples=ON -D gtest_build_tests=ON -D gtest_disable_pthreads=OFF -D gtest_hide_internal_symbols=OFF -D PYTHON_EXECUTABLE=/usr/bin/python3
/usr/bin/cmake --build x86_64-redhat-linux-gnu --verbose
/usr/bin/make -O V=1 VERBOSE=1 -C x86_64-redhat-linux-gnu test ARGS=--output-on-failure |
Thank you for providing the complete reproduction. As far as I can tell, this seems like a GCC 11 bug. It does not reproduce in GCC 10. The combination of For reference, here is what I was able to simplify the issue to:
|
Good to know that it was possible to reporoduce that issue. |
I used the official GCC docker images.
|
Can you tell a little is that affecting only gtest suite or gtest libraries as well? |
FYI: I've temporary disabled LTO in my package build procedure so it is not critical however if you can share what you found it would be great :) |
This comment has been minimized.
This comment has been minimized.
I haven't looked at this since determining it is likely a GCC bug, probably in the LTO feature. Did you open a GCC ticket? |
Tests are broken, see google/googletest#3442
Tests are broken, see google/googletest#3442
Source tree configuration:
Test suite output:
The text was updated successfully, but these errors were encountered: