Fixed undefined behavior in RNG.

We're basically trading undefined behavior for implementation defined
behavior, which should be OK for UBSan. :-) The generated code should
be identical, at least I checked that for GCC 4.6.3 on x64.

BUG=377790
LOG=y
R=dcarney@chromium.org

Review URL: https://codereview.chromium.org/332733002

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@21828 ce2b1a6d-e550-0410-aec6-3dcde31c8c00