public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/64500] New: push_to_top_level() shows up high during Chromium build.
@ 2015-01-05 13:21 trippels at gcc dot gnu.org
  2015-01-20 11:24 ` [Bug c++/64500] " marxin at gcc dot gnu.org
  0 siblings, 1 reply; 2+ messages in thread
From: trippels at gcc dot gnu.org @ 2015-01-05 13:21 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64500

            Bug ID: 64500
           Summary: push_to_top_level() shows up high during Chromium
                    build.
           Product: gcc
           Version: 5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: trippels at gcc dot gnu.org
                CC: jason at gcc dot gnu.org, marxin at gcc dot gnu.org

Created attachment 34378
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=34378&action=edit
unreduced testcase

Running "perf top" during Chromium build shows that push_to_top_level() is in
the 8-12% range.

This is an older issue, because it already happens for 4.8.4.

Here is an example:

markus@x4 Release % perf record c++ -std=gnu++11 -O2 -c InspectorCSSAgent.ii
[ perf record: Woken up 6 times to write data ]
[ perf record: Captured and wrote 1.275 MB perf.data (~55717 samples) ]
markus@x4 Release % perf report
   8.01%  cc1plus  cc1plus          [.] push_to_top_level
   4.23%  cc1plus  cc1plus          [.] gt_ggc_mx_lang_tree_node
   2.13%  cc1plus  cc1plus          [.] ggc_set_mark
   1.98%  cc1plus  cc1plus          [.] lookup_page_table_entry
   1.75%  cc1plus  libc-2.19.90.so  [.] _int_malloc
   1.61%  cc1plus  cc1plus          [.] ggc_internal_alloc
   1.57%  cc1plus  cc1plus          [.] lookup_field_r


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug c++/64500] push_to_top_level() shows up high during Chromium build.
  2015-01-05 13:21 [Bug c++/64500] New: push_to_top_level() shows up high during Chromium build trippels at gcc dot gnu.org
@ 2015-01-20 11:24 ` marxin at gcc dot gnu.org
  0 siblings, 0 replies; 2+ messages in thread
From: marxin at gcc dot gnu.org @ 2015-01-20 11:24 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64500

--- Comment #1 from Martin Liška <marxin at gcc dot gnu.org> ---
Created attachment 34498
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=34498&action=edit
perf report for the testcase
>From gcc-bugs-return-474027-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jan 20 11:26:18 2015
Return-Path: <gcc-bugs-return-474027-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 29604 invoked by alias); 20 Jan 2015 11:26:18 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 29574 invoked by uid 48); 20 Jan 2015 11:26:14 -0000
From: "manu at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c/64639] missing warning by -Wunused-value in compound expressions
Date: Tue, 20 Jan 2015 11:26: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: 5.0
X-Bugzilla-Keywords: diagnostic
X-Bugzilla-Severity: normal
X-Bugzilla-Who: manu at gcc dot gnu.org
X-Bugzilla-Status: NEW
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: keywords short_desc
Message-ID: <bug-64639-4-zaB6J4hKEm@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-64639-4@http.gcc.gnu.org/bugzilla/>
References: <bug-64639-4@http.gcc.gnu.org/bugzilla/>
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-01/txt/msg02021.txt.bz2
Content-length: 2003

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64639

Manuel López-Ibáñez <manu at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |diagnostic
            Summary|false negative of           |missing warning by
                   |-Wunused-value              |-Wunused-value in compound
                   |                            |expressions

--- Comment #6 from Manuel López-Ibáñez <manu at gcc dot gnu.org> ---
(In reply to Mikhail Maltsev from comment #5)
> > gets somehow transformed into
> > b = (a = 0B) != 0B;, 0;
> 
> Probably folding works this way. Anyway, I think, I can explain how the

It would be interesting to know if the above is a faithful representation of
the AST representation or the pretty-printer is printing something weird. As
printed, the code does not look right. If it is a faithful representation, it
would be great to know where this folding occurs (and disable it).

> P.S. I know, that it all might be obvious for most of you, but I'm just
> trying to get acquainted with GCC sources and (hopefully) do something
> useful for the project, while waiting for next stage1 (bugs being fixed
> during stage 4 are obviously not for newcomers).

It wasn't obvious to me at all. I think it is extremely useful to provide a
deep analysis of PRs. A good analysis makes other devs more inclined to take a
bug and fix it. If you were only to do that, it would already be a great
contribution.

The logic in the second branch is wrong. This made me think of another testcase
where it is even more obvious that there is a missing warning:

int *a;
int b;
void g();
void f() {
  b = (g(), (a = 0) != 0, 0);
  b = ((g(), (a = 0) != 0), 0);
  b = (g(), ((a = 0) != 0, 0));
}

We should get a warning in all three lines, but we only get it in the last one.
>From gcc-bugs-return-474028-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jan 20 11:27:29 2015
Return-Path: <gcc-bugs-return-474028-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 30551 invoked by alias); 20 Jan 2015 11:27:28 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 30525 invoked by uid 48); 20 Jan 2015 11:27:24 -0000
From: "azanella at linux dot vnet.ibm.com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c/64687] New: powerpc: GCC 5.0 (trunk@219851) build failure for powerpc with hardware decimal floating point disabled
Date: Tue, 20 Jan 2015 11:27:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: new
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: c
X-Bugzilla-Version: 5.0
X-Bugzilla-Keywords:
X-Bugzilla-Severity: normal
X-Bugzilla-Who: azanella at linux dot vnet.ibm.com
X-Bugzilla-Status: UNCONFIRMED
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: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created
Message-ID: <bug-64687-4@http.gcc.gnu.org/bugzilla/>
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-01/txt/msg02022.txt.bz2
Content-length: 2159

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64687

            Bug ID: 64687
           Summary: powerpc: GCC 5.0 (trunk@219851) build failure for
                    powerpc with hardware decimal floating point disabled
           Product: gcc
           Version: 5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: azanella at linux dot vnet.ibm.com

Created attachment 34499
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=34499&action=edit
Testcase to trigger the issue

GCC 5.0 (trunk@219851) trigger the following issue when building a C file with
Decimal types for powerpc64 with hardware decimal floating point disabled
(-DSHARED -O3 -fpic -ggdb3 -mno-hard-dfp):

../libdfp-git/sysdeps/dpd/decode.c: In function ‘__decoded32’:
../libdfp-git/sysdeps/dpd/decode.c:77:1: error: insn does not satisfy its
constraints:
 }
 ^
(insn 278 13 279 2 (set (mem/c:SD (plus:DI (reg/f:DI 1 1)
                (const_int -16 [0xfffffffffffffff0])) [18 %sfp+48 S4 A32])
        (reg:SD 33 1)) ../libdfp-git/sysdeps/dpd/decode.c:40 492
{movsd_hardfloat}
     (nil))
../libdfp-git/sysdeps/dpd/decode.c:77:1: internal compiler error: in
extract_constrain_insn, at recog.c:2246
0x105f6b13 _fatal_insn(char const*, rtx_def const*, char const*, int, char
const*)
        ../../gcc-git/gcc/rtl-error.c:110
0x105f6b6b _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
        ../../gcc-git/gcc/rtl-error.c:121
0x105bf81b extract_constrain_insn(rtx_insn*)
        ../../gcc-git/gcc/recog.c:2246
0x1059c8d7 reload_cse_simplify_operands
        ../../gcc-git/gcc/postreload.c:430
0x1059dd33 reload_cse_simplify
        ../../gcc-git/gcc/postreload.c:207
0x1059dd33 reload_cse_regs_1
        ../../gcc-git/gcc/postreload.c:246
0x1059f9d7 reload_cse_regs
        ../../gcc-git/gcc/postreload.c:94
0x1059f9d7 execute
        ../../gcc-git/gcc/postreload.c:2367


Temporary files in attachments (decode.i and decode.s), to reproduce just
issue:

$ gcc decode.i -c -DSHARED -O3 -fpic -ggdb3 -mno-hard-dfp
>From gcc-bugs-return-474029-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jan 20 11:35:08 2015
Return-Path: <gcc-bugs-return-474029-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 3507 invoked by alias); 20 Jan 2015 11:35:04 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 3459 invoked by uid 48); 20 Jan 2015 11:34:59 -0000
From: "manu at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/64383] missed warning for unused variable.
Date: Tue, 20 Jan 2015 11:35: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: diagnostic
X-Bugzilla-Severity: normal
X-Bugzilla-Who: manu at gcc dot gnu.org
X-Bugzilla-Status: UNCONFIRMED
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: cc
Message-ID: <bug-64383-4-HZj8Qa5C9S@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-64383-4@http.gcc.gnu.org/bugzilla/>
References: <bug-64383-4@http.gcc.gnu.org/bugzilla/>
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-01/txt/msg02023.txt.bz2
Content-length: 856

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64383

Manuel López-Ibáñez <manu at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |paolo.carlini at oracle dot com

--- Comment #4 from Manuel López-Ibáñez <manu at gcc dot gnu.org> ---
According to http://gcc.godbolt.org/ g++ 4.8 used to warn, so this could be a
regression. If we add a dummy foo() call to the dtor, so one could argue that
it could be doing something useful, it doesn't change anything for g++4.8, 4.9
or clang.

Is the dtor of Y actually called when the reference goes out of scope? That
sounds strange to me. Note that no warning is given by clang or g++4.8 when y
is not a reference.
>From gcc-bugs-return-474030-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Tue Jan 20 11:47:39 2015
Return-Path: <gcc-bugs-return-474030-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 8345 invoked by alias); 20 Jan 2015 11:47:38 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 8295 invoked by uid 48); 20 Jan 2015 11:47:32 -0000
From: "paolo.carlini at oracle dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/62241] C++14 generalized lambda capture doesn't work with uniform initialization syntax.
Date: Tue, 20 Jan 2015 11:47: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.1
X-Bugzilla-Keywords: rejects-valid
X-Bugzilla-Severity: normal
X-Bugzilla-Who: paolo.carlini at oracle dot com
X-Bugzilla-Status: NEW
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: <bug-62241-4-cILlbgnzlw@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-62241-4@http.gcc.gnu.org/bugzilla/>
References: <bug-62241-4@http.gcc.gnu.org/bugzilla/>
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-01/txt/msg02024.txt.bz2
Content-length: 193

https://gcc.gnu.org/bugzilla/show_bug.cgi?idb241

--- Comment #7 from Paolo Carlini <paolo.carlini at oracle dot com> ---
I'm adding a reduced testcase and closing the bug as fixed for 5.0.


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-01-20 11:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-05 13:21 [Bug c++/64500] New: push_to_top_level() shows up high during Chromium build trippels at gcc dot gnu.org
2015-01-20 11:24 ` [Bug c++/64500] " marxin at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).