{
uint32_t Hash = 5381;
for (string::const_iterator I = Str.begin(); I != Str.end(); ++I)
- Hash = 33 * Hash + tolower_ascii(*I);
+ Hash = 33 * Hash + tolower_ascii((signed char)*I);
return Hash % HeaderP->GetHashTableSize();
}
{
uint32_t Hash = 5381;
for (const char *I = Str; *I != 0; ++I)
- Hash = 33 * Hash + tolower_ascii(*I);
+ Hash = 33 * Hash + tolower_ascii((signed char)*I);
return Hash % HeaderP->GetHashTableSize();
}
cout << "Total buckets in " << Type << ": " << NumBuckets << std::endl;
cout << " Unused: " << UnusedBuckets << std::endl;
cout << " Used: " << UsedBuckets << std::endl;
+ cout << " Utilization: " << 100.0 * UsedBuckets/NumBuckets << "%" << std::endl;
cout << " Average entries: " << Entries/(double)UsedBuckets << std::endl;
cout << " Longest: " << LongestBucket << std::endl;
cout << " Shortest: " << ShortestBucket << std::endl;