Fix Win64 build after r23316.
TBR=hpayer@chromium.org Review URL: https://codereview.chromium.org/494393002 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@23318 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
8d1deb385f
commit
785876eed2
@ -74,7 +74,8 @@ TEST_F(GCIdleTimeHandlerTest, AfterContextDisposeLargeIdleTime) {
|
|||||||
heap_state.contexts_disposed = 1;
|
heap_state.contexts_disposed = 1;
|
||||||
heap_state.incremental_marking_stopped = true;
|
heap_state.incremental_marking_stopped = true;
|
||||||
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
||||||
int idle_time_ms = (heap_state.size_of_objects + speed - 1) / speed;
|
int idle_time_ms =
|
||||||
|
static_cast<int>((heap_state.size_of_objects + speed - 1) / speed);
|
||||||
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
||||||
EXPECT_EQ(DO_FULL_GC, action.type);
|
EXPECT_EQ(DO_FULL_GC, action.type);
|
||||||
}
|
}
|
||||||
@ -85,7 +86,7 @@ TEST_F(GCIdleTimeHandlerTest, AfterContextDisposeSmallIdleTime1) {
|
|||||||
heap_state.contexts_disposed = 1;
|
heap_state.contexts_disposed = 1;
|
||||||
heap_state.incremental_marking_stopped = true;
|
heap_state.incremental_marking_stopped = true;
|
||||||
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
||||||
int idle_time_ms = heap_state.size_of_objects / speed - 1;
|
int idle_time_ms = static_cast<int>(heap_state.size_of_objects / speed - 1);
|
||||||
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
||||||
EXPECT_EQ(DO_INCREMENTAL_MARKING, action.type);
|
EXPECT_EQ(DO_INCREMENTAL_MARKING, action.type);
|
||||||
}
|
}
|
||||||
@ -95,7 +96,7 @@ TEST_F(GCIdleTimeHandlerTest, AfterContextDisposeSmallIdleTime2) {
|
|||||||
GCIdleTimeHandler::HeapState heap_state = DefaultHeapState();
|
GCIdleTimeHandler::HeapState heap_state = DefaultHeapState();
|
||||||
heap_state.contexts_disposed = 1;
|
heap_state.contexts_disposed = 1;
|
||||||
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
||||||
int idle_time_ms = heap_state.size_of_objects / speed - 1;
|
int idle_time_ms = static_cast<int>(heap_state.size_of_objects / speed - 1);
|
||||||
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
||||||
EXPECT_EQ(DO_INCREMENTAL_MARKING, action.type);
|
EXPECT_EQ(DO_INCREMENTAL_MARKING, action.type);
|
||||||
}
|
}
|
||||||
@ -131,7 +132,7 @@ TEST_F(GCIdleTimeHandlerTest, NotEnoughTime) {
|
|||||||
heap_state.incremental_marking_stopped = true;
|
heap_state.incremental_marking_stopped = true;
|
||||||
heap_state.can_start_incremental_marking = false;
|
heap_state.can_start_incremental_marking = false;
|
||||||
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
||||||
int idle_time_ms = heap_state.size_of_objects / speed - 1;
|
int idle_time_ms = static_cast<int>(heap_state.size_of_objects / speed - 1);
|
||||||
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
||||||
EXPECT_EQ(DO_NOTHING, action.type);
|
EXPECT_EQ(DO_NOTHING, action.type);
|
||||||
}
|
}
|
||||||
@ -142,7 +143,7 @@ TEST_F(GCIdleTimeHandlerTest, StopEventually1) {
|
|||||||
heap_state.incremental_marking_stopped = true;
|
heap_state.incremental_marking_stopped = true;
|
||||||
heap_state.can_start_incremental_marking = false;
|
heap_state.can_start_incremental_marking = false;
|
||||||
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
||||||
int idle_time_ms = heap_state.size_of_objects / speed + 1;
|
int idle_time_ms = static_cast<int>(heap_state.size_of_objects / speed + 1);
|
||||||
for (int i = 0; i < GCIdleTimeHandler::kMaxMarkCompactsInIdleRound; i++) {
|
for (int i = 0; i < GCIdleTimeHandler::kMaxMarkCompactsInIdleRound; i++) {
|
||||||
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
||||||
EXPECT_EQ(DO_FULL_GC, action.type);
|
EXPECT_EQ(DO_FULL_GC, action.type);
|
||||||
@ -171,7 +172,7 @@ TEST_F(GCIdleTimeHandlerTest, ContinueAfterStop1) {
|
|||||||
heap_state.incremental_marking_stopped = true;
|
heap_state.incremental_marking_stopped = true;
|
||||||
heap_state.can_start_incremental_marking = false;
|
heap_state.can_start_incremental_marking = false;
|
||||||
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
size_t speed = heap_state.mark_compact_speed_in_bytes_per_ms;
|
||||||
int idle_time_ms = heap_state.size_of_objects / speed + 1;
|
int idle_time_ms = static_cast<int>(heap_state.size_of_objects / speed + 1);
|
||||||
for (int i = 0; i < GCIdleTimeHandler::kMaxMarkCompactsInIdleRound; i++) {
|
for (int i = 0; i < GCIdleTimeHandler::kMaxMarkCompactsInIdleRound; i++) {
|
||||||
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
GCIdleTimeAction action = handler()->Compute(idle_time_ms, heap_state);
|
||||||
EXPECT_EQ(DO_FULL_GC, action.type);
|
EXPECT_EQ(DO_FULL_GC, action.type);
|
||||||
|
Loading…
Reference in New Issue
Block a user