Revision: 15210
Author: [email protected]
Date: Wed Jun 19 10:01:43 2013
Log: Lower limit for external allocation and improve tracing.
[email protected]
Review URL: https://codereview.chromium.org/16896012
http://code.google.com/p/v8/source/detail?r=15210
Modified:
/branches/bleeding_edge/src/heap-inl.h
/branches/bleeding_edge/src/heap.cc
=======================================
--- /branches/bleeding_edge/src/heap-inl.h Fri Jun 14 09:06:12 2013
+++ /branches/bleeding_edge/src/heap-inl.h Wed Jun 19 10:01:43 2013
@@ -550,7 +550,7 @@
if (amount >= 0) {
amount_of_external_allocated_memory_ = amount;
} else {
- // Give up and reset the counters in case of an overflow.
+ // Give up and reset the counters in case of an underflow.
amount_of_external_allocated_memory_ = 0;
amount_of_external_allocated_memory_at_last_global_gc_ = 0;
}
@@ -558,8 +558,11 @@
if (FLAG_trace_external_memory) {
PrintPID("%8.0f ms: ", isolate()->time_millis_since_init());
PrintF("Adjust amount of external memory: delta=%6" V8_PTR_PREFIX "d
KB, "
- " amount=%6" V8_PTR_PREFIX "d KB, isolate=0x%08"
V8PRIxPTR ".\n",
- change_in_bytes / 1024, amount_of_external_allocated_memory_ /
1024,
+ "amount=%6" V8_PTR_PREFIX "d KB, since_gc=%6" V8_PTR_PREFIX "d
KB, "
+ "isolate=0x%08" V8PRIxPTR ".\n",
+ change_in_bytes / KB,
+ amount_of_external_allocated_memory_ / KB,
+ PromotedExternalMemorySize() / KB,
reinterpret_cast<intptr_t>(isolate()));
}
ASSERT(amount_of_external_allocated_memory_ >= 0);
=======================================
--- /branches/bleeding_edge/src/heap.cc Wed Jun 19 04:53:30 2013
+++ /branches/bleeding_edge/src/heap.cc Wed Jun 19 10:01:43 2013
@@ -6645,7 +6645,12 @@
max_semispace_size_ = RoundUpToPowerOf2(max_semispace_size_);
reserved_semispace_size_ = RoundUpToPowerOf2(reserved_semispace_size_);
initial_semispace_size_ = Min(initial_semispace_size_,
max_semispace_size_);
- external_allocation_limit_ = 16 * max_semispace_size_;
+
+ // The external allocation limit should be below 256 MB on all
architectures
+ // to avoid unnecessary low memory notifications, as that is the
threshold
+ // for some embedders.
+ external_allocation_limit_ = 12 * max_semispace_size_;
+ ASSERT(external_allocation_limit_ <= 256 * MB);
// The old generation is paged and needs at least one page for each
space.
int paged_space_count = LAST_PAGED_SPACE - FIRST_PAGED_SPACE + 1;
--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.