[Webkit-unassigned] [Bug 98586] Extend random precision to 53bits

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Oct 7 12:48:44 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=98586





--- Comment #14 from Yusuke Suzuki <utatane.tea at gmail.com>  2012-10-07 12:49:17 PST ---
(From update of attachment 167475)
View in context: https://bugs.webkit.org/attachment.cgi?id=167475&action=review

Thanks for your review. I'll fix test and attach revised patch.

>> LayoutTests/fast/js/script-tests/53bits-random.js:5
>> +var MAX = 1000000;
> 
> toString(2) will be 55 in length if the last bit is 1. The odds of that are 1/2. If we want the odds of test failure to be 1/1000000, we should only loop about 20 times. Looping 1000000 times will hide errors in the random distribution of the last bit.

Thanks for your pointing. Right. So I'll change it to 20.

>> LayoutTests/fast/js/script-tests/53bits-random.js:10
>> +        found = true;
> 
> You should look *both* for a case where the last bit is 1, *and* the case where the last bit is 0. Otherwise, putting all 1's in the non-random bits will pass this test.

You're right. I'll make sure that 53 + 1 length pattern comes (that is, last bit is 0).

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list