diff options
Diffstat (limited to 'deps/v8/src/utils.cc')
-rw-r--r-- | deps/v8/src/utils.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/deps/v8/src/utils.cc b/deps/v8/src/utils.cc index 08ee16ff2..374385b67 100644 --- a/deps/v8/src/utils.cc +++ b/deps/v8/src/utils.cc @@ -40,6 +40,7 @@ namespace internal { // Implementation is from "Hacker's Delight" by Henry S. Warren, Jr., // figure 3-3, page 48, where the function is called clp2. uint32_t RoundUpToPowerOf2(uint32_t x) { + ASSERT(x <= 0x80000000u); x = x - 1; x = x | (x >> 1); x = x | (x >> 2); |