From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 4A6F63858D37; Thu, 18 Jan 2024 19:48:45 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4A6F63858D37 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1705607325; bh=Pbis2mm2Lk8YJFxkvJYXPhUhbghjMZBNT5XUJ0RKtmQ=; h=From:To:Subject:Date:From; b=evK5wRVRZYwYA9A3N+KjzviVu+ZbC81+VEpXc7lEk0zDLNUosWt9VhQmpAmvITi1D LqoWajJ6JOuhweXtdjpvt74NVJG62LMWbFbbqJ22X3iYZodmntNwo6AH4PDnDCMgDE GutggQrQRE6m+RLQD0fX5022Mlm58g6maCGo9ox4= From: "zsojka at seznam dot cz" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/113491] New: ICE: SIGSEGV in make_ssa_name_fn (tree-ssanames.cc:354) at -Os with _BitInt() used as switch control expression Date: Thu, 18 Jan 2024 19:48:44 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: zsojka at seznam dot cz 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 keywords bug_severity priority component assigned_to reporter cc target_milestone cf_gcchost cf_gcctarget 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D113491 Bug ID: 113491 Summary: ICE: SIGSEGV in make_ssa_name_fn (tree-ssanames.cc:354) at -Os with _BitInt() used as switch control expression Product: gcc Version: 14.0 Status: UNCONFIRMED Keywords: ice-on-valid-code Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: zsojka at seznam dot cz CC: jakub at gcc dot gnu.org Target Milestone: --- Host: x86_64-pc-linux-gnu Target: x86_64-pc-linux-gnu Created attachment 57146 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=3D57146&action=3Dedit reduced testcase (from gcc.c-torture/compile/pr34093.c -Dint=3D_BitInt(617)= ) Compiler output: $ x86_64-pc-linux-gnu-gcc -Os testcase.c -wrapper valgrind,-q =3D=3D8560=3D=3D Invalid read of size 2 =3D=3D8560=3D=3D at 0x177D8AA: make_ssa_name_fn(function*, tree_node*, g= imple*, unsigned int) (tree-ssanames.cc:354) =3D=3D8560=3D=3D by 0x1610EB2: make_ssa_name (tree-ssanames.h:98) =3D=3D8560=3D=3D by 0x1610EB2: tree_switch_conversion::switch_conversion::build_arrays() (tree-switch-conversion.cc:727) =3D=3D8560=3D=3D by 0x1611296: tree_switch_conversion::switch_conversion::expand(gswitch*) [clone .part.0] (tree-switch-conversion.cc:1067) =3D=3D8560=3D=3D by 0x161135A: expand (tree-switch-conversion.cc:2546) =3D=3D8560=3D=3D by 0x161135A: (anonymous namespace)::pass_convert_switch::execute(function*) (tree-switch-conversion.cc:2564) =3D=3D8560=3D=3D by 0x13CC03A: execute_one_pass(opt_pass*) (passes.cc:26= 46) =3D=3D8560=3D=3D by 0x13CC92F: execute_pass_list_1(opt_pass*) (passes.cc= :2755) =3D=3D8560=3D=3D by 0x13CC941: execute_pass_list_1(opt_pass*) (passes.cc= :2756) =3D=3D8560=3D=3D by 0x13CC968: execute_pass_list(function*, opt_pass*) (passes.cc:2766) =3D=3D8560=3D=3D by 0x13CD28C: do_per_function_toporder(void (*)(functio= n*, void*), void*) [clone .part.0] (passes.cc:1773) =3D=3D8560=3D=3D by 0x13CD4BE: do_per_function_toporder (passes.cc:1740) =3D=3D8560=3D=3D by 0x13CD4BE: execute_ipa_pass_list(opt_pass*) (passes.= cc:3100) =3D=3D8560=3D=3D by 0xFCDD37: ipa_passes (cgraphunit.cc:2211) =3D=3D8560=3D=3D by 0xFCDD37: symbol_table::compile() [clone .part.0] (cgraphunit.cc:2332) =3D=3D8560=3D=3D by 0xFD05B7: compile (cgraphunit.cc:2312) =3D=3D8560=3D=3D by 0xFD05B7: symbol_table::finalize_compilation_unit() (cgraphunit.cc:2584) =3D=3D8560=3D=3D Address 0x0 is not stack'd, malloc'd or (recently) free'd =3D=3D8560=3D=3D=20 during GIMPLE pass: switchconv testcase.c: In function 'foo': testcase.c:263:1: internal compiler error: Segmentation fault 263 | } | ^ 0x150ddef crash_signal /repo/gcc-trunk/gcc/toplev.cc:317 0x177d8aa make_ssa_name_fn(function*, tree_node*, gimple*, unsigned int) /repo/gcc-trunk/gcc/tree-ssanames.cc:354 0x1610eb2 make_ssa_name(tree_node*, gimple*) /repo/gcc-trunk/gcc/tree-ssanames.h:98 0x1610eb2 tree_switch_conversion::switch_conversion::build_arrays() /repo/gcc-trunk/gcc/tree-switch-conversion.cc:727 0x1611296 tree_switch_conversion::switch_conversion::expand(gswitch*) /repo/gcc-trunk/gcc/tree-switch-conversion.cc:1067 0x161135a tree_switch_conversion::switch_conversion::expand(gswitch*) /repo/gcc-trunk/gcc/tree-switch-conversion.cc:2546 0x161135a execute /repo/gcc-trunk/gcc/tree-switch-conversion.cc:2564 Please submit a full bug report, with preprocessed source (by using -freport-bug). Please include the complete backtrace with any bug report. See for instructions.=