This is the mail archive of the gcc-patches@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: PATCH [mainline] speed up comparing enums declared in multiple translation units


I have incorporated Andrew Pinski's patch, which speeds up the case where the enum type values are in
the same order, In this patch. Combined patch improves compile-time build of mesa by additional 50%
(on my G5 512 Mbyte machine, build time went down from 13 minutes to 6.5 min).
bootstrapped, dejagnu tested on PPC-darwin. OK for mainline?


- Fariborz Jahanian (fjahanian@apple.com).


Attachment: ima-mesa-patch-2.txt
Description: Text document



On Mar 9, 2004, at 12:13 PM, Fariborz Jahanian wrote:


This is a performance bug fix which prevents mesa (SPEC program) to compile with IMA in a
reasonable amount of time. Performance hit is comparing two enumerated types declared in
different translation unit. Fix is in routine tagged_types_tu_compatible_p and uses
the infrastructure already there to prevent recursion when comparing composite types.
Essentially it remembers previous comparison results of the two enum types and uses the
saved result. bootstrapped, dejagnu tested on ppc-darwin. Furthermore, tested against
SPEC benchmark with IMA. mesa now takes minutes to compile, instead of days (on my
particular G5 machine anyway).


OK for mainline?


- fariborz jahanian (fjahanian@apple.com)


ChangeLog:

2004-03-09  Fariborz Jahanian <fjahanian@apple.com>
        * c-typeck.c (tagged_types_tu_compatible_p): speed up type
        comparison of enums declared in separate tus.


<ima-mesa-patch.txt>

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