Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(275)

Unified Diff: test/cctest/test-spaces.cc

Issue 1406393005: [test] Move away from deprecated API for heap-related tests. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Move delta between last PS1 and PS2 to new API Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « test/cctest/test-incremental-marking.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-spaces.cc
diff --git a/test/cctest/test-spaces.cc b/test/cctest/test-spaces.cc
index e11d82b03b965a6d7d06dd7ffa176f50aecae0c5..cf053d0a9c53ad6595a4a72e3861c815cb99c43e 100644
--- a/test/cctest/test-spaces.cc
+++ b/test/cctest/test-spaces.cc
@@ -36,7 +36,8 @@
#include "test/cctest/cctest.h"
#include "test/cctest/heap-tester.h"
-using namespace v8::internal;
+namespace v8 {
+namespace internal {
#if 0
static void VerifyRegionMarking(Address page_start) {
@@ -104,9 +105,6 @@ TEST(Page) {
#endif
-namespace v8 {
-namespace internal {
-
// Temporarily sets a given allocator in an isolate.
class TestMemoryAllocatorScope {
public:
@@ -148,9 +146,6 @@ class TestCodeRangeScope {
DISALLOW_COPY_AND_ASSIGN(TestCodeRangeScope);
};
-} // namespace internal
-} // namespace v8
-
static void VerifyMemoryChunk(Isolate* isolate,
Heap* heap,
@@ -176,14 +171,15 @@ static void VerifyMemoryChunk(Isolate* isolate,
commit_area_size,
executable,
NULL);
- size_t alignment = code_range != NULL && code_range->valid() ?
- MemoryChunk::kAlignment : v8::base::OS::CommitPageSize();
+ size_t alignment = code_range != NULL && code_range->valid()
+ ? MemoryChunk::kAlignment
+ : base::OS::CommitPageSize();
size_t reserved_size =
((executable == EXECUTABLE))
? RoundUp(header_size + guard_size + reserve_area_size + guard_size,
alignment)
: RoundUp(header_size + reserve_area_size,
- v8::base::OS::CommitPageSize());
+ base::OS::CommitPageSize());
CHECK(memory_chunk->size() == reserved_size);
CHECK(memory_chunk->area_start() < memory_chunk->address() +
memory_chunk->size());
@@ -888,3 +884,6 @@ UNINITIALIZED_TEST(InlineAllocationObserver) {
}
isolate->Dispose();
}
+
+} // namespace internal
+} // namespace v8
« no previous file with comments | « test/cctest/test-incremental-marking.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698