From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 130593 invoked by alias); 2 Jul 2015 05:03:44 -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 130218 invoked by uid 89); 2 Jul 2015 05:03:07 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.6 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,KAM_ASCII_DIVIDERS,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=no version=3.3.2 X-HELO: mail-oi0-f50.google.com Received: from mail-oi0-f50.google.com (HELO mail-oi0-f50.google.com) (209.85.218.50) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Thu, 02 Jul 2015 05:03:06 +0000 Received: by oigx81 with SMTP id x81so47693279oig.1 for ; Wed, 01 Jul 2015 22:03:04 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.60.55.36 with SMTP id o4mr29480391oep.0.1435813384361; Wed, 01 Jul 2015 22:03:04 -0700 (PDT) Received: by 10.76.160.68 with HTTP; Wed, 1 Jul 2015 22:03:04 -0700 (PDT) In-Reply-To: <20150618101646.GC28183@msticlxl57.ims.intel.com> References: <20150618101646.GC28183@msticlxl57.ims.intel.com> Date: Thu, 02 Jul 2015 05:03:00 -0000 Message-ID: Subject: Re: [PATCH, CHKP, PR middle-end/66568] Fix internal compiler error: in expand_expr_addr_expr_1 From: "H.J. Lu" To: Ilya Enkovich Cc: GCC Patches Content-Type: text/plain; charset=UTF-8 X-IsSubscribed: yes X-SW-Source: 2015-07/txt/msg00100.txt.bz2 On Thu, Jun 18, 2015 at 3:16 AM, Ilya Enkovich wrote: > Hi, > > Currently return statement with no bounds in instrumented function causes ICE. This patch uses zero bounds in such cases instead. Bootstrapped and regtested for x86_64-unknown-linux-gnu. Applied to trunk. Is it OK for gcc-5-branch? > > diff --git a/gcc/testsuite/gcc.target/i386/mpx/pr66568.c b/gcc/testsuite/gcc.target/i386/mpx/pr66568.c > new file mode 100644 > index 0000000..d7bb9f6 > --- /dev/null > +++ b/gcc/testsuite/gcc.target/i386/mpx/pr66568.c > @@ -0,0 +1,10 @@ > +/* { dg-do compile } */ > +/* { dg-require-effective-target fpic } */ > +/* { dg-options "-O2 -fcheck-pointer-bounds -mmpx -O2 -fPIC" } */ > + > +int a, b, c; > +void *set_test () { > + if (b) > + a ? exit (0) : exit (1); > + b = c; > +} I checked in this patch to add a prototype for exit. H.J. Index: ChangeLog =================================================================== --- ChangeLog (revision 225294) +++ ChangeLog (working copy) @@ -1,3 +1,7 @@ +2015-07-01 H.J. Lu + + * gcc.target/i386/mpx/pr66568.c (exit): New prototype. + 2015-07-01 Jason Merrill * lib/target-supports.exp (cxx_default): Set to C++14. Index: gcc.target/i386/mpx/pr66568.c =================================================================== --- gcc.target/i386/mpx/pr66568.c (revision 225294) +++ gcc.target/i386/mpx/pr66568.c (working copy) @@ -2,6 +2,7 @@ /* { dg-require-effective-target fpic } */ /* { dg-options "-O2 -fcheck-pointer-bounds -mmpx -O2 -fPIC" } */ +extern void exit (int); int a, b, c; void *set_test () { if (b) -- H.J.