Chromium Code Reviews| Index: test/cctest/test-alloc.cc |
| diff --git a/test/cctest/test-alloc.cc b/test/cctest/test-alloc.cc |
| index d8000fde2046fb818fa591783a17e94ae22213ad..4a089f62c472f77f0f6027966a20753e1c00a47e 100644 |
| --- a/test/cctest/test-alloc.cc |
| +++ b/test/cctest/test-alloc.cc |
| @@ -224,9 +224,12 @@ TEST(CodeRange) { |
| (Page::kMaxRegularHeapObjectSize << (Pseudorandom() % 3)) + |
| Pseudorandom() % 5000 + 1; |
| size_t allocated = 0; |
| - Address base = code_range.AllocateRawMemory(requested, |
| - requested, |
| - &allocated); |
| + |
| + // The request size has to be at least 2 code guard pages larger then the |
|
Michael Starzinger
2015/09/01 15:08:53
nit: s/then/than/
Michael Lippautz
2015/09/01 15:19:35
Done.
|
| + // actual commit size. |
| + Address base = code_range.AllocateRawMemory( |
| + requested, requested - (2 * MemoryAllocator::CodePageGuardSize()), |
| + &allocated); |
| CHECK(base != NULL); |
| blocks.Add(::Block(base, static_cast<int>(allocated))); |
| current_allocated += static_cast<int>(allocated); |