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

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

Issue 2490523003: [heap] Use size_t for heap and space counters. (Closed)
Patch Set: more fixes Created 4 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/heap/test-alloc.cc ('k') | test/cctest/heap/test-spaces.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/heap/test-heap.cc
diff --git a/test/cctest/heap/test-heap.cc b/test/cctest/heap/test-heap.cc
index 59161003bf4f8c878c41c48e657b14b809974d19..495a3980df322681fce691a31af8285ac6fb8137 100644
--- a/test/cctest/heap/test-heap.cc
+++ b/test/cctest/heap/test-heap.cc
@@ -2339,7 +2339,7 @@ TEST(GrowAndShrinkNewSpace) {
}
// Explicitly growing should double the space capacity.
- intptr_t old_capacity, new_capacity;
+ size_t old_capacity, new_capacity;
old_capacity = new_space->TotalCapacity();
new_space->Grow();
new_capacity = new_space->TotalCapacity();
@@ -2387,7 +2387,7 @@ TEST(CollectingAllAvailableGarbageShrinksNewSpace) {
v8::HandleScope scope(CcTest::isolate());
NewSpace* new_space = heap->new_space();
- intptr_t old_capacity, new_capacity;
+ size_t old_capacity, new_capacity;
old_capacity = new_space->TotalCapacity();
new_space->Grow();
new_capacity = new_space->TotalCapacity();
@@ -5678,7 +5678,8 @@ UNINITIALIZED_TEST(PromotionQueue) {
CHECK(new_space->IsAtMaximumCapacity());
- CHECK(i::FLAG_min_semi_space_size * MB == new_space->TotalCapacity());
+ CHECK_EQ(static_cast<size_t>(i::FLAG_min_semi_space_size * MB),
+ new_space->TotalCapacity());
// Call the scavenger two times to get an empty new space
heap->CollectGarbage(NEW_SPACE, i::GarbageCollectionReason::kTesting);
@@ -5694,7 +5695,8 @@ UNINITIALIZED_TEST(PromotionQueue) {
}
heap->CollectGarbage(NEW_SPACE, i::GarbageCollectionReason::kTesting);
- CHECK(i::FLAG_min_semi_space_size * MB == new_space->TotalCapacity());
+ CHECK_EQ(static_cast<size_t>(i::FLAG_min_semi_space_size * MB),
+ new_space->TotalCapacity());
// Fill-up the first semi-space page.
heap::FillUpOnePage(new_space);
« no previous file with comments | « test/cctest/heap/test-alloc.cc ('k') | test/cctest/heap/test-spaces.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698