public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/59614] New: [4.9 regression] Explostion in compile time of heavily templated code
@ 2013-12-27 23:58 ivanov.maxim at gmail dot com
  2013-12-27 23:59 ` [Bug c++/59614] " ivanov.maxim at gmail dot com
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: ivanov.maxim at gmail dot com @ 2013-12-27 23:58 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59614

            Bug ID: 59614
           Summary: [4.9 regression] Explostion in compile time of heavily
                    templated code
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ivanov.maxim at gmail dot com

4.9 takes forever to compile code, which compiles in 9 seconds by version
4.8.2.

gdb shows that g++ spends time in "mark_type_abi_tags" function, which was
introduced in
http://gcc.gnu.org/git/?p=gcc.git;a=commit;h=9181c3d9ceed054efd8488eaea91d89353bb8d21

If I read patch correctly, 4.9 visits all template arguments recursively for
every template instantiation, but 4.8 didn't, at least not in "check_abi_tags".

I created following somewhat pathological, but still correct test case, with
help of Boost.MPL and Boost.Fusion, to make very deep template with high number
of occurrences of same templates in different parts of that template tree, you
can find it in this ticket attachment (had to compress it, otherwise it
wouldn't fit into bugzilla's 1000K size limit).

Version I was testing on is:

GNU C++ (SUSE Linux) version 4.9.0 20131210 [trunk revision 205857]
(x86_64-suse-linux)
    compiled by GNU C version 4.9.0 20131210 [trunk revision 205857], GMP
version 5.1.2, MPFR version 3.1.2, MPC version 1.0

Thank you for your time.


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

end of thread, other threads:[~2014-01-08 19:00 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-12-27 23:58 [Bug c++/59614] New: [4.9 regression] Explostion in compile time of heavily templated code ivanov.maxim at gmail dot com
2013-12-27 23:59 ` [Bug c++/59614] " ivanov.maxim at gmail dot com
2013-12-28  0:06 ` ivanov.maxim at gmail dot com
2013-12-28  0:38 ` steven at gcc dot gnu.org
2014-01-07 11:53 ` rguenth at gcc dot gnu.org
2014-01-07 22:14 ` jason at gcc dot gnu.org
2014-01-08 19:00 ` jason 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).