Branch: Tag:

2010-11-13

2010-11-13 23:19:15 by 0

Disallow threads during hashing of small strings (current threshold is 1 MB).
This change improves ApacheBench numbers ~20% for a Roxen benchmark on a
quad-core Core i5.

12:    Pike_error("Bad argument. Must be 8-bit string.\n"); \    } while(0)    +  + /* Hashing methods can normally process hundres of megabytes per second +  so it's rather wasteful to enable threads during hashing of smaller +  data sizes. Limit is now 1 MB. */ + #define THREADS_ALLOW_THRESHOLD (1024 * 1024) +  +    char *pike_crypt_md5(int pl, const char *const pw,    int sl, const char *const salt);