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, libfortran] [4.7/4.8/4.9 Regression] PR38199 missed optimization: I/O performance


On Sat, Mar 8, 2014 at 7:38 AM, Jerry DeLisle wrote:
> The speedup is accomplished by simply skipping over spaces without calling
> next_read, then backing up one character and letting the existing execution path
> proceed, preserving all the end of record code needed in next_char.
>
> I also remove some unneeded error checks.

Would it be enough to make them "unlikely" instead?

-      if (length < 0)
+      if (unlikely(length < 0))

Ciao!
Steven


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