This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug pch/53880] [4.8 Regression] compile time regression when generating precompiled headers for boost
- From: "markus at trippelsdorf dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sun, 08 Jul 2012 07:08:13 +0000
- Subject: [Bug pch/53880] [4.8 Regression] compile time regression when generating precompiled headers for boost
- Auto-submitted: auto-generated
- References: <bug-53880-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53880
--- Comment #3 from Markus Trippelsdorf <markus at trippelsdorf dot de> 2012-07-08 07:08:13 UTC ---
Unfortunately jimis' patch from Bug 53525 doesn't help much:
c++ -c -o pch.hpp.gch /usr/include/boost/math/special_functions.hpp 156.69s
user 0.33s system 99% cpu 2:37.50 total
From "perf top":
99.78% cc1plus [.] gt_pch_p_9line_maps
0.04% cc1plus [.] htab_find_with_hash
0.02% cc1plus [.] gt_pch_p_14lang_tree_node
0.02% libc-2.16.so [.] fwrite_unlocked â
0.01% libc-2.16.so [.] __mempcpy
0.01% [kernel] [k] do_timer
Zoom into gt_pch_p_9line_maps:
â size_t l3 = (size_t)(((*x).info_macro).used);
â if ((*x).info_macro.maps != NULL) {
â size_t i3;
â for (i3 = 0; i3 != (size_t)(l3); i3++) {
3.89 â109: cmp %rcx,%rbx
3.69 â nop
3.15 â â je 188
3.11 â112: mov 0x18(%rbp),%rax
3.04 â add $0x1,%rbx
â break;
â }
â }
â
â void
â gt_pch_p_9line_maps (ATTRIBUTE_UNUSED void *this_obj,
2.76 â11a: lea (%rbx,%rbx,4),%r15
3.53 â shl $0x3,%r15
â {
â size_t l3 = (size_t)(((*x).info_macro).used);
â if ((*x).info_macro.maps != NULL) {
â size_t i3;
â for (i3 = 0; i3 != (size_t)(l3); i3++) {
â switch (((*x).info_macro.maps[i3]).reason ==
LC_ENTER_MACRO)
3.46 â lea (%rax,%r15,1),%rdi
3.42 â cmpb $0x4,0x4(%rdi)
4.40 â â jne 100
â case 1:
â {
â size_t l4 = (size_t)(2 *
((*x).info_macro.maps[i3].d.macro).n_tokens);
â {
â union tree_node * x5 =
â ((*x).info_macro.maps[i3].d.macro.macro) ?
HT_IDENT_TO_GCC_IDENT (HT_NODE (((*x).info_macro.maps[i3].d.macro.macro)))
4.38 â mov 0x8(%rdi),%rsi
4.25 â xor %edx,%edx
2.22 â lea -0x18(%rsi),%r8
2.16 â test %rsi,%rsi
2.68 â cmovne %r8,%rdx
â if ((void *)((*x).info_macro.maps) == this_obj)
2.72 â cmp %rax,%r14
â break;
â case 1:
â {
â size_t l4 = (size_t)(2 *
((*x).info_macro.maps[i3].d.macro).n_tokens);
â {
â union tree_node * x5 =
2.62 â mov %rdx,0x18(%rsp)
â ((*x).info_macro.maps[i3].d.macro.macro) ?
HT_IDENT_TO_GCC_IDENT (HT_NODE (((*x).info_macro.maps[i3].d.macro.macro)))
â if ((void *)((*x).info_macro.maps) == this_obj)
2.68 â â je 1a0
â op (&(x5), cookie);
â (*x).info_macro.maps[i3].d.macro.macro = (x5) ?
CPP_HASHNODE (GCC_IDENT_TO_HT_IDENT ((x5))) : NULL;
2.68 â147: lea 0x18(%rdx),%rsi
2.85 â xor %eax,%eax
3.39 â test %rdx,%rdx
3.11 â cmovne %rsi,%rax
3.23 â mov %rax,0x8(%rdi)
â }
â if ((*x).info_macro.maps[i3].d.macro.macro_locations
!= NULL) {
5.10 â mov 0x18(%rbp),%rax
4.93 â add %rax,%r15
5.48 â cmpq $0x0,0x18(%r15)
3.57 â â je 109
â size_t i4;
â for (i4 = 0; i4 != (size_t)(l4); i4++) {
â }
â if ((void *)((*x).info_macro.maps) == this_obj)
3.20 â cmp %rax,%r14
2.82 â â jne 109
â op
(&((*x).info_macro.maps[i3].d.macro.macro_locations), cookie);
â mov %rcx,0x8(%rsp)
â lea 0x18(%r15),%rdi
â mov %r13,%rsi
â â callq *%r12
â mov 0x8(%rsp),%rcx
â }