mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-15 14:16:07 -06:00
Removed DDUMPs
git-svn-id: svn://ultimatepp.org/upp/trunk@10010 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
ea54b22ec4
commit
7519e94105
4 changed files with 3 additions and 7 deletions
|
|
@ -1103,14 +1103,14 @@ void CompareStream::Flush() {
|
|||
}
|
||||
|
||||
void CompareStream::_Put(const void *data, dword size) {
|
||||
wrlim = buffer + 128;
|
||||
wrlim = buffer + sizeof(h);
|
||||
ASSERT(ptr <= wrlim);
|
||||
Flush();
|
||||
pos += ptr - buffer;
|
||||
ptr = buffer;
|
||||
byte *b = (byte *) data;
|
||||
while(size && equal) {
|
||||
int sz = min<int>(size, 128);
|
||||
int sz = min<int>(size, sizeof(h));
|
||||
Compare(pos, b, sz);
|
||||
pos += sz;
|
||||
b += sz;
|
||||
|
|
|
|||
|
|
@ -521,7 +521,7 @@ public:
|
|||
};
|
||||
|
||||
class OutStream : public Stream {
|
||||
byte h[128];
|
||||
byte h[512];
|
||||
protected:
|
||||
virtual void _Put(int w);
|
||||
virtual void _Put(const void *data, dword size);
|
||||
|
|
|
|||
|
|
@ -24,18 +24,15 @@ void StreamContainer(Stream& s, T& cont)
|
|||
template <class T>
|
||||
dword HashBySerialize(const T& cont)
|
||||
{
|
||||
RTIMING("HashBySerialize");
|
||||
TimeStop tm;
|
||||
xxHashStream xxh;
|
||||
const_cast<T&>(cont).Serialize(xxh);
|
||||
RLOG("Hash by serialize: " << typeid(T).name() << " " << tm);
|
||||
return xxh.Finish();
|
||||
}
|
||||
|
||||
template <class T>
|
||||
bool IsEqualBySerialize(const T& a, const T& b)
|
||||
{
|
||||
RTIMING("IsEqualBySerialize");
|
||||
StringStream sa, sb;
|
||||
const_cast<T&>(a).Serialize(sa);
|
||||
const_cast<T&>(b).Serialize(sb);
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ void xxHashStream::Reset(dword seed)
|
|||
|
||||
void xxHashStream::Out(const void *data, dword size)
|
||||
{
|
||||
RTIMING("xxHash");
|
||||
XXH32_update((XXH32_state_t *)context, data, size);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue