This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: c++/1687: Extreme compile time regression from 2.95.2


On Sun, Nov 10, 2002 at 03:51:12PM -0600, Wolfgang Bangerth wrote:
> 
> Zack,
> you had a patch for this problem, as mentioned in the audit. Do you know 
> whether it was applied? I cannot find it in the ChangeLogs.

Yes, the patch was applied.  It's in cp/ChangeLog:

2001-04-24  Zack Weinberg  <zackw@stanford.edu>

        * cp/optimize.c: Include hashtab.h.
        (struct inline_data): Add tree_pruner.
        (expand_call_inline, expand_calls_inline): Use it when calling
        walk_tree.
        (optimize_function): Initialize and free tree_pruner.

This code is now in tree-inline.c, by the way

> However, at -O3 it still takes forever, now with both C and C++, which 
> seems a further regression (since previously this held only for C++). I 
> don't trust this for various reasons, so maybe someone can confirm this 
> with -O3?

C being slow is a consequence of its using the tree-based inliner
(previously only C++ did).  I don't know why -O3 would cause further
trouble.  You could build cc1plus profiled (make clean in both
libiberty and gcc, make all in libiberty with CFLAGS="-g -O2 -profile",
make cc1plus in gcc with CFLAGS="-g -O2 -profile"), run it on the test
case, and take a look at the gprof output.

zw


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]