From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29720 invoked by alias); 18 Dec 2012 15:16:38 -0000 Received: (qmail 29358 invoked by uid 48); 18 Dec 2012 15:16:18 -0000 From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/53198] [4.6/4.7 Regression] gcc wrongly emits "array subscript is above array bounds" for simple arrays Date: Tue, 18 Dec 2012 15:16:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.6.4 X-Bugzilla-Changed-Fields: Known to work Known to fail Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 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: 2012-12/txt/msg01756.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D53198 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- Known to work| |4.8.0 Known to fail|4.7.0, 4.8.0 |4.7.2 --- Comment #5 from Richard Biener 2012-12-18 = 15:16:16 UTC --- (In reply to comment #4) > (In reply to comment #3) > > Created attachment 27801 [details] > > another testcase - from xorg mouse driver >=20 > This warns with GCC 4.8 r192379: >=20 > pr53198.c: In function =E2=80=98CheckProtocol=E2=80=99: > pr53198.c:35:30: warning: array subscript is above array bounds > [-Warray-bounds] > for (i =3D 0; internalNames[i]; i++) > ^ >=20 > It doesn't warn with gcc 4.5.1 Doesn't warn any longer on trunk.