From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 112660 invoked by alias); 15 May 2015 16:43:01 -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 112620 invoked by uid 48); 15 May 2015 16:42:57 -0000 From: "marxin at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/66163] [6 Regression] Not working Firefox built with LTO Date: Fri, 15 May 2015 16:43: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-Version: 6.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: marxin at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: hubicka at ucw dot cz X-Bugzilla-Target-Milestone: --- 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: 2015-05/txt/msg01203.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D66163 --- Comment #2 from Martin Li=C5=A1ka --- (In reply to Andrew Pinski from comment #1) > This really sounds like a bug in Firefox. This argument is not valid to be > null. Hmm, I suspect there should be an undefined sanitizer that should be > added to catch this case if not already there. Well, I can try to update my Firefox tree to verify that the issue still persists. I'm wondering how can call a class method having this =3D=3D NULL? Are you talking about ubsan? >>From gcc-bugs-return-486364-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri May 15 17:00:10 2015 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 50300 invoked by alias); 15 May 2015 17:00:10 -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 50186 invoked by uid 48); 15 May 2015 17:00:05 -0000 From: "manu at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/66130] "invalid use of non-static member function" message could be clearer Date: Fri, 15 May 2015 17:00:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 4.9.2 X-Bugzilla-Keywords: easyhack, patch X-Bugzilla-Severity: normal X-Bugzilla-Who: manu at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: 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: 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: 2015-05/txt/msg01204.txt.bz2 Content-length: 1733 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D66130 --- Comment #10 from Manuel L=C3=B3pez-Ib=C3=A1=C3=B1ez --- (In reply to Paolo Carlini from comment #9) > But the error message is about l->*ptr, not about ptr per se.=20 Yes, but the location should already point to l->*ptr. I'm thinking in cases such as: struct Local { void f(); int z; }; Local *l; void (Local::*j)(); int Local::*i; decltype((l->*j)) x; where printing "invalid use of non-static member function 'void (Local::*j)= ()'" seems more useful than "invalid use of non-static member function 'l->*j'" = in order to spot the typo (i vs j). > that in such cases using dump_type (or %qT at the call site) on TREE_TYPE > (t) (TREE_TYPE (expr)) should be Ok. Yes! @@ -1826,11 +1826,16 @@ invalid_nonstatic_memfn_p (tree expr, ts if (is_overloaded_fn (expr) && !really_overloaded_fn (expr)) expr =3D get_first_fn (expr); if (DECL_NONSTATIC_MEMBER_FUNCTION_P (expr)) { if (complain & tf_error) - error ("invalid use of non-static member function"); + { + if (DECL_P (expr)) + error_at (loc, "invalid use of non-static member function %qD", expr); + else + error_at (loc, "invalid use of non-static member function %qT", TREE_TYPE (expr)); + } return true; } return false; } prints: test.cc:10:17: error: invalid use of non-static member function =E2=80=98vo= id (Local::)()=E2=80=99 decltype((l->*j)) x; ^ which looks fine to me, except for the column location, but that seems hard= er to fix. We could also print a "note: declared here" to be extra helpful, but I'll l= eave that to whoever gets to finish this ;-) >>From gcc-bugs-return-486365-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Fri May 15 17:34:52 2015 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 60234 invoked by alias); 15 May 2015 17:34: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 60191 invoked by uid 55); 15 May 2015 17:34:48 -0000 From: "glisse at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/64454] optimize (x%5)%5 Date: Fri, 15 May 2015 17:34: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-Version: 5.0 X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: normal X-Bugzilla-Who: glisse at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: 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: Message-ID: In-Reply-To: References: 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: 2015-05/txt/msg01205.txt.bz2 Content-length: 653 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64454 --- Comment #11 from Marc Glisse --- Author: glisse Date: Fri May 15 17:34:15 2015 New Revision: 223221 URL: https://gcc.gnu.org/viewcvs?rev=223221&root=gcc&view=rev Log: 2015-05-15 Marc Glisse PR tree-optimization/64454 gcc/ * match.pd ((X % Y) % Y, (X % Y) < Y): New patterns. (-1 - A -> ~A): Remove unnecessary condition. gcc/testsuite/ * gcc.dg/modmod.c: New testcase. Added: trunk/gcc/testsuite/gcc.dg/modmod.c Modified: trunk/gcc/ChangeLog trunk/gcc/match.pd trunk/gcc/testsuite/ChangeLog