From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 538 invoked by alias); 2 May 2014 13:29:22 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 474 invoked by uid 48); 2 May 2014 13:29:17 -0000 From: "tgard at opentext dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug bootstrap/60984] [4.9 Regression] AIX: gcc-4.9.0 bootstrap fails in stage-2 Date: Fri, 02 May 2014 13:29:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: bootstrap X-Bugzilla-Version: 4.9.1 X-Bugzilla-Keywords: build, ice-on-valid-code X-Bugzilla-Severity: blocker X-Bugzilla-Who: tgard at opentext dot com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.9.1 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 X-SW-Source: 2014-05/txt/msg00069.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D60984 --- Comment #11 from Torbj=C3=B6rn Gard --- No failure but restarted it in /home/tga01/obj_gcc with the thought of havi= ng a shorter and simpler path. >>From gcc-bugs-return-450378-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri May 02 13:30:52 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 1802 invoked by alias); 2 May 2014 13:30:52 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 1769 invoked by uid 48); 2 May 2014 13:30:49 -0000 From: "jb at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libfortran/61035] New: Crash in getcwd intrinsic due to stack overflow Date: Fri, 02 May 2014 13:30:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libfortran X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: minor X-Bugzilla-Who: jb at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED 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 Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-05/txt/msg00070.txt.bz2 Content-length: 760 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=61035 Bug ID: 61035 Summary: Crash in getcwd intrinsic due to stack overflow Product: gcc Version: unknown Status: UNCONFIRMED Severity: minor Priority: P3 Component: libfortran Assignee: unassigned at gcc dot gnu.org Reporter: jb at gcc dot gnu.org The example program below crashes (my stack size limit is 8 MiB). program getcwd_overflow implicit none character(len=10485760) :: str ! 10 MiB call getcwd(str) print *, trim(str) end program getcwd_overflow The reason is that in libgfortran/intrinsics/getcwd.c we try to allocate space for a NULL-terminated duplicate of the string on the stack.