From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 1448B3858D38; Sun, 29 Jan 2023 20:57:42 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1448B3858D38 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1675025862; bh=TImnoYyPbdzc2DHeQbl6CNZ509nJIKOYuOqbNdP8bdA=; h=From:To:Subject:Date:In-Reply-To:References:From; b=cZ+JATTOJWY98F8lp0n/da3f7V2V5D7ps8WcKPHiF6qH+U9rSDI3c0GAYfPlr/Qa2 S2XM484bMGHoYdwLQF7V0wT0Hda9fnzgr2kUbBjLlTJy2cXTYnSlcJAWfJz7bMKIDu impPIapOo/m3F4zkwf+VbZnv1ej8KhrYFqtP0M6k= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/108450] [12/13 Regression] ICE in sort_actual, at fortran/intrinsic.cc:4380 since r12-5793-g689407ef916503b2 Date: Sun, 29 Jan 2023 20:57:41 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: 13.0 X-Bugzilla-Keywords: ice-on-invalid-code, openmp X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P4 X-Bugzilla-Assigned-To: mikael at gcc dot gnu.org X-Bugzilla-Target-Milestone: 12.3 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: 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=3D108450 --- Comment #4 from CVS Commits --- The master branch has been updated by Mikael Morin : https://gcc.gnu.org/g:2e32a12c04c72f692a7bd119fd3e4e5b74392c9d commit r13-5486-g2e32a12c04c72f692a7bd119fd3e4e5b74392c9d Author: Mikael Morin Date: Sun Jan 29 21:57:24 2023 +0100 fortran: Set name for *LOC default BACK argument [PR108450] This change fixes an ICE caused by the double resolution of MINLOC, MAXLOC and FINDLOC expressions which get a default value for the BACK argument at resolution time. That argument is added without name, and argument reordering code is not prepared to handle unnamed arguments coming after named ones, so the second resolution causes a NULL pointer dereference. The problem is fixed by explicitly setting the argument name. PR fortran/108450 gcc/fortran/ChangeLog: * check.cc (gfc_check_minloc_maxloc): Explicitly set argument n= ame. (gfc_check_findloc): Ditto. gcc/testsuite/ChangeLog: * gfortran.dg/gomp/minmaxloc_1.f90: New test.=