From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 9DD233858D32; Thu, 2 Nov 2023 09:49:19 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9DD233858D32 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1698918559; bh=uz+X7t4iAUoEJQGL1BlRArk0far25vY8ehYVf0xzumQ=; h=From:To:Subject:Date:From; b=kPA+FQawc216PJBdVxXTSWAlOO9KF/ZBll09+HfQTSwhAnE2GLN1J9oH53CSBdlEr svfNEu6W2qF0tXhJ5O94mCVs81R7QK3Rv32VBSA9O34lIZgolFd2/Axp3g1cdGjiXt FK45xH5HpafdM2cV8wlpKlFOhMZPG7kC3iy8Bi08= From: "slyfox at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/112347] New: [14 regression] ICE on jemalloc-5.3.0: Segmentation fault around convert_for_assignment() Date: Thu, 02 Nov 2023 09:49:18 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: slyfox at gcc dot gnu.org 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 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D112347 Bug ID: 112347 Summary: [14 regression] ICE on jemalloc-5.3.0: Segmentation fault around convert_for_assignment() Product: gcc Version: 14.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: slyfox at gcc dot gnu.org Target Milestone: --- Noticed ICE on today's `gcc-master` r14-5073-g36a26298ec7dfc when building jemalloc-5.3.0. Extracted the following example: // $ cat a.c.c int * mallocx(unsigned long) __attribute__((malloc)) __attribute__((alloc_size(1))); void test_oom(void) { void *a_ =3D mallocx(1); } Crashing: $ gcc/xgcc -Bgcc -std=3Dgnu11 -Wextra -c /tmp/a.c.c /tmp/a.c.c: In function =E2=80=98test_oom=E2=80=99: /tmp/a.c.c:2:1: internal compiler error: Segmentation fault 2 | void test_oom(void) { void *a_ =3D mallocx(1); } | ^~~~ 0x225a30b diagnostic_impl(rich_location*, diagnostic_metadata const*, int, = char const*, __va_list_tag (*) [1], diagnostic_t) ???:0 0x225b12e internal_error(char const*, ...) ???:0 0xee1c4f crash_signal(int) ???:0 0x7bfff6 convert_for_assignment(unsigned int, unsigned int, tree_node*, tree_node*, tree_node*, impl_conv, bool, tree_node*, tree_node*, int, int) ???:0 0x7cc38d digest_init(unsigned int, tree_node*, tree_node*, tree_node*, bool, bool, bool, bool, bool, bool) ???:0 0x7cf3af store_init_value(unsigned int, tree_node*, tree_node*, tree_node*) ???:0 0x795284 finish_decl(tree_node*, unsigned int, tree_node*, tree_node*, tree_node*) ???:0 0x817385 c_parser_declaration_or_fndef(c_parser*, bool, bool, bool, bool, b= ool, tree_node**, vec*, bool, tree_node*, oacc_routine_data*, bool*) ???:0 0x814efb c_parser_compound_statement_nostart(c_parser*) ???:0 0x81573f c_parser_compound_statement(c_parser*, unsigned int*) ???:0 0x81719a c_parser_declaration_or_fndef(c_parser*, bool, bool, bool, bool, b= ool, tree_node**, vec*, bool, tree_node*, oacc_routine_data*, bool*) ???:0 0x821ab9 c_parser_external_declaration(c_parser*) ???:0 0x822610 c_parse_file() ???:0 0x8a274f c_common_parse_file() ???:0 $ gcc/xgcc -Bgcc -v Reading specs from gcc/specs COLLECT_GCC=3Dgcc/xgcc COLLECT_LTO_WRAPPER=3Dgcc/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: /home/slyfox/dev/git/gcc/configure --disable-multilib --disable-bootstrap --disable-lto --disable-libsanitizer --enable-languages= =3Dc CFLAGS=3D'-O1 -g0' CXXFLAGS=3D'-O1 -g0' LDFLAGS=3D'-O1 -g0' Thread model: posix Supported LTO compression algorithms: zlib gcc version 14.0.0 20231102 (experimental) (GCC)=