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]

[PATCH] speedup the java front-end a little


I noticed that we were speeding 2% of our time while compiling
libgcj in fnmatch, so I decided to take a look to see why we
were calling it and I noticed that java_or_class_file could
be improved by using strcmp.  This patch implements the speedup.
Also note that on platforms like x86 there is an even more speedup
than I saw because the strlen and strcmp will be inlined.


OK? Bootstrapped on powerpc-apple-darwin7.2.0 with no regressions.


Thanks,
Andrew Pinski

ChangeLog:

* jcf-io.c (java_or_class_file): Use strcmp instead of fnmatch.



Attachment: speedupjava.diff.txt
Description: Text document


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