mirror of
https://github.com/webmproject/libwebp.git
synced 2025-01-30 00:22:55 +01:00
fa63a96603
It was a bad implementation of a Lehmer random number generator (the saturation was done wrong and mostly & was used instead of % .....). That lead to "for" loop stuck with the same values given a specific seed, hence wasted "for" loops (e.g. seed getting at 374988608 and modulo of 64 later leads to 0 even when updating the seed with the old formula). As the "for" loops now always return a proper pair of histograms, their number can greatly be reduced, hence a speedup. Change-Id: I9f5b44d66cc96fd4824189d92276c3756c8ead5b