From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13770 invoked by alias); 21 Oct 2009 09:11:05 -0000 Received: (qmail 13734 invoked by uid 48); 21 Oct 2009 09:10:53 -0000 Date: Wed, 21 Oct 2009 09:11:00 -0000 Message-ID: <20091021091053.13733.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug fortran/41777] wrong-code shown with EXCITING In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "burnus at gcc dot gnu dot org" 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 X-SW-Source: 2009-10/txt/msg01801.txt.bz2 ------- Comment #1 from burnus at gcc dot gnu dot org 2009-10-21 09:10 ------- Created an attachment (id=18851) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=18851&action=view) Slightly reduced test case - needs now only FoX Reduced test case -- still pretty large, but now only depends on FoX. Use similarly to PR 41772: wget http://www.uszla.me.uk/FoX/source/FoX-4.0.4.tar.gz tar xfz FoX-4.0.4.tar.gz cd FoX-4.0.4 && ./configure FC=gfortran && make -j4 gfortran -Iobjs/finclude fox.f90 objs/lib/libFoX_{dom,utils,sax,common,fsys}.a ./a.out In order to see better what goes wrong, patch dom/m_dom_dom.F90's removeChild by adding the PRINT statements: do i = 1, size(arg%childNodes%nodes) print *, 'removeChild: Walking list, i = ', i if (associated(arg%childNodes%nodes(i)%this, oldChild)) then print *, 'removeChild: Walking list, fount it, i_t = ', i_t The gfortran output is then: removeChild: Walking list, i = 1 [...] removeChild: Walking list, i = 9 NOT_FOUND_ERR While g95/NAG f95 have: removeChild: Walking list, i = 1 [...] removeChild: Walking list, fount it, i_t = 4 [...] removeChild: Walking list, i = 9 FoX_NODE_IS_NULL (Afterwards, all core dump. The result that it = 4 is found, can also be seen with the full program, where no segfault occurs.) The needed input.xml can be found in attachment 18846 of PR 41772 -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41777