From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 61D273858423; Wed, 16 Feb 2022 13:11:00 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 61D273858423 From: "xanderlenstra at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug driver/104566] New: Internal compiler error while building from source Date: Wed, 16 Feb 2022 13:11:00 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: driver X-Bugzilla-Version: 11.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: xanderlenstra at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Feb 2022 13:11:00 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D104566 Bug ID: 104566 Summary: Internal compiler error while building from source Product: gcc Version: 11.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: driver Assignee: unassigned at gcc dot gnu.org Reporter: xanderlenstra at gmail dot com Target Milestone: --- Created attachment 52453 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D52453&action=3Dedit Full terminal output as far as I can scroll back I was trying to get a compiler with support for c++20, but I'm working on a university computer so I have no sudo rights. Easiest solution seemed to bu= ild g++10 or newer from source, so I did exactly that, following the tutorial on https://gcc.gnu.org/install/ I've downloaded it from this mirror: http://mirror.koddos.net/gcc/releases/gcc-11.2.0/ which is marked as an official mirror on this page: https://gcc.gnu.org/mirrors.html Due to space concerns, I only installed the c++ component ('--enable-languages=3Dc++') and did the lean bootstrap ('make bootstrap-le= an'), otherwise I have not deviated from the default commands recommended to be r= un. I did have to restart the bootstrap once, as the variable `CPLUS_INCLUDE_PA= TH` was already set to a different value, resulting in the crash described in #61427. I `unset` the variable, and ran the same command again. This time, = the terminal showed the following error: ``` cc1: internal compiler error: in fail_formatted, at selftest.c:63 0x24d14f5 selftest::fail_formatted(selftest::location const&, char const*, = ...) ../../gcc-11.2.0/gcc/selftest.c:63 0x24d15e4 selftest::assert_streq(selftest::location const&, char const*, ch= ar const*, char const*, char const*) ../../gcc-11.2.0/gcc/selftest.c:92 0x24e86d3 test_add_location_if_nearby ../../gcc-11.2.0/gcc/diagnostic-show-locus.c:4124 0x2514db1 selftest::for_each_line_table_case(void (*)(selftest::line_table_= case const&)) ../../gcc-11.2.0/gcc/input.c:3573 0x24ef897 selftest::diagnostic_show_locus_c_tests() ../../gcc-11.2.0/gcc/diagnostic-show-locus.c:5266 0x23fb40c selftest::run_tests() ../../gcc-11.2.0/gcc/selftest-run-tests.c:98 0x12e8ad5 toplev::run_self_tests() ../../gcc-11.2.0/gcc/toplev.c:2265 ``` To reiterate, the exact command I ran was `make bootstrap-lean`, while insi= de the objdir The entire output as far as my terminal still shows it, is included as an attachment. My $HOME on this pc is `/vol/s1935534`. Running `gcc -v` gave the following output: ``` Using built-in specs. COLLECT_GCC=3Dgcc COLLECT_LTO_WRAPPER=3D/usr/lib/gcc/x86_64-linux-gnu/7/lto-wrapper OFFLOAD_TARGET_NAMES=3Dnvptx-none OFFLOAD_TARGET_DEFAULT=3D1 Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion=3D'Ubuntu 7.5.0-3ubuntu1~18.04' --with-bugurl=3Dfile:///usr/share/doc/gcc-7/README.Bu= gs --enable-languages=3Dc,ada,c++,go,brig,d,fortran,objc,obj-c++ --prefix=3D/u= sr --with-gcc-major-version-only --program-suffix=3D-7 --program-prefix=3Dx86_64-linux-gnu- --enable-shared --enable-linker-build-= id --libexecdir=3D/usr/lib --without-included-gettext --enable-threads=3Dposix --libdir=3D/usr/lib --enable-nls --enable-bootstrap --enable-clocale=3Dgnu --enable-libstdcxx-debug --enable-libstdcxx-time=3Dyes --with-default-libstdcxx-abi=3Dnew --enable-gnu-unique-object --disable-vtable-verify --enable-libmpx --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib --enable-objc-gc=3Dauto --enable-multiarch --disable-werror --with-arch-32=3Di686 --with-abi=3Dm64 --with-multilib-list=3Dm32,m64,mx32 --enable-multilib --with-tune=3Dgeneric --enable-offload-targets=3Dnvptx-none --without-cuda-driver --enable-checking=3Drelease --build=3Dx86_64-linux-gnu --host=3Dx86_64-linu= x-gnu --target=3Dx86_64-linux-gnu Thread model: posix ``` I have googled for this error, but the only other bug even mentioning the `fail_formatted` function is #81101, which appears unrelated to building gcc from source. If any additional information is required,=