From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 102834 invoked by alias); 20 Nov 2015 17:28:45 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 102825 invoked by uid 89); 20 Nov 2015 17:28:44 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.2 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-ob0-f177.google.com Received: from mail-ob0-f177.google.com (HELO mail-ob0-f177.google.com) (209.85.214.177) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Fri, 20 Nov 2015 17:28:43 +0000 Received: by obbbj7 with SMTP id bj7so91613901obb.1 for ; Fri, 20 Nov 2015 09:28:41 -0800 (PST) MIME-Version: 1.0 X-Received: by 10.182.88.165 with SMTP id bh5mr9505377obb.21.1448040521277; Fri, 20 Nov 2015 09:28:41 -0800 (PST) Received: by 10.202.95.213 with HTTP; Fri, 20 Nov 2015 09:28:41 -0800 (PST) In-Reply-To: References: <563C817D.1060107@arm.com> Date: Fri, 20 Nov 2015 17:28:00 -0000 Message-ID: Subject: Re: [PATCH] Fix PR68067 From: Alan Lawrence To: Richard Biener Cc: "gcc-patches@gcc.gnu.org" Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes X-SW-Source: 2015-11/txt/msg02516.txt.bz2 On 6 November 2015 at 10:39, Richard Biener wrote: >> ../spec2000/benchspec/CINT2000/254.gap/src/polynom.c:358:11: error: location >> references block not in block tree >> l1_279 = PHI <1(28), l1_299(33)> > > ^^^ > > this is the error to look at! It means that the GC heap will be corrupted > quite easily. > This looked very similar to PR68117 - the invalid phi arg, and block not in block-tree, even if not the invalid tree code - and as the posters there were having success with valgrind, whereas I wasn't, I watched and waited. First observation is that it triggers the asserts you suggested in comment 27 (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D68117#c27). Indeed, it fails those asserts, even after the patch in comment 25 (committed as r230594) to tree-ssa.c (delete_tree_ssa), and the patch in comment#35 to function.c (set_cfun), and the patch in comment#30 (committed as r230424) to cfgexpand.c (pass_expand::execute). The patch in comment#29 (which replaces the asserts in comment#27 with empties), however, fixes the problem - although I can't rule out, that that's just by changing the memory allocation pattern. Moreover, if I take those patches and rebase onto a recent trunk (onto which the delete_tree_ssa and pass_expand::execute patches have already been committed), i.e. just adding the assertions from comment#27 and the call in function.c (set_cfun) - the assertions are still failing on my testcase, whereas the original (assertionless) failure was very erratic, and had since disappeared/been hidden on trunk. Indeed those same assertions break in a few other places (even in a --disable-bootstrap build after gcc/xgcc is built), so I feel I have a good chance of producing a reasonable assertion-breaking testcase. So I have to ask, how sure are you that those assertions are(/should be!) "correct"? :) --Alan