This is the mail archive of the
mailing list for the libstdc++ project.
Re: [patch] Use bit scanning and counting builtins for std::bitset
On Sun, 2 Feb 2003 13:19:39 -0500
Phil Edwards <email@example.com> wrote:
>On Sun, Feb 02, 2003 at 03:34:34AM +0100, Falk Hueffner wrote:
>> this patch utilizes gcc's builtin functions for bit counting and
>> scanning. With it, I can achieve a speedup of 32% for a toy program
>> of mine (by using the Alpha "ctpop" instruction).
>Nice. I'm the middle of ugly stuff right now, but I'll look closer at
>the patch tomorrow.
Agreed. I'll let you take care of this.
FYI config/link-map.gnu's export of std::_S_bit_count can now be
- while ( __byte_ptr < __end_ptr )
- while (__byte_ptr < __end_ptr)
- // find byte within word
- // Find byte within word.
also, it might be possible to completely eliminate the macro CHAR_BIT
now. If possible, this should be done.
Phil, you might want to try and port this back to 3.2/3.3.