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: debug mode performance patch


Hi,

> I thought about suggesting that too. FranÃois's improved get_mutex
> function only uses the lowest few bits, and I don't know how well
> Hash_bytes works if you don't use the whole value ... probably still
> better distributed than simply taking the address, and might avoid
> pathological cases where distinct pairs of objects always get the same
> two mutexes.

> 
If there aren't other issues, I think the new Murmur hash is pretty good even when only a limited range of values is eventually computed. Matt told me that if only we could use it uniformly over *all* the std::hash specializations he would even feel comfortable with simplifying the unordered containers to use a power of two number of buckets. Anyway, in case if need, in the .cc file we also have a reference to the main Google web page.

Paolo


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