This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ 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] Fix istream::ignore + minor things


"Damour, James A" <James.Damour@dfa.state.ny.us> writes:

| Would your ignore code benefit from using __builtin_expect (see example
| below)?
| 
| -          if (__n != numeric_limits<streamsize>::max())
| +          if (__builtin_expect(__n !=
| numeric_limits<streamsize>::max(),1))

I've asked in the past for data, in supporting the __builtin_expect
cluttering in the codes (not that I'm firmly opposed, but I would need
to see data).  It was claimed that it would be faster with a different
compiler, but the actual experiment with GCC wa unconclusive.  So far.

-- Gaby


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