mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-10 03:45:46 +00:00
Bug 164580 - Back out fix. It's not much (if at all) faster and may cause problems on some architectures. r=glandium
This commit is contained in:
parent
76c3511501
commit
fbe6419352
@ -73,10 +73,12 @@ struct nsID {
|
||||
*/
|
||||
|
||||
inline bool Equals(const nsID& other) const {
|
||||
// First cast to void* in order to silence the alignment warnings.
|
||||
// Unfortunately memcmp isn't faster than this.
|
||||
return
|
||||
((PRUint64*)(void*) &m0)[0] == ((PRUint64*)(void*) &other.m0)[0] &&
|
||||
((PRUint64*)(void*) &m0)[1] == ((PRUint64*)(void*) &other.m0)[1];
|
||||
((((PRUint32*) &m0)[0] == ((PRUint32*) &other.m0)[0]) &&
|
||||
(((PRUint32*) &m0)[1] == ((PRUint32*) &other.m0)[1]) &&
|
||||
(((PRUint32*) &m0)[2] == ((PRUint32*) &other.m0)[2]) &&
|
||||
(((PRUint32*) &m0)[3] == ((PRUint32*) &other.m0)[3]));
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user