33 using namespace v8::internal;
36 static void VerifyRegionMarking(
Address page_start) {
37 #ifdef ENABLE_CARDMARKING_WRITE_BARRIER
40 p->SetRegionMarks(Page::kAllRegionsCleanMarks);
42 for (
Address addr = p->ObjectAreaStart();
43 addr < p->ObjectAreaEnd();
48 for (
Address addr = p->ObjectAreaStart();
49 addr < p->ObjectAreaEnd();
54 for (
Address addr = p->ObjectAreaStart();
55 addr < p->ObjectAreaEnd();
80 p->SetIsLargeObjectPage(
false);
94 VerifyRegionMarking(page_start);
109 old_allocator_(isolate->memory_allocator_) {
110 isolate->memory_allocator_ = allocator;
114 isolate_->memory_allocator_ = old_allocator_;
129 Isolate* isolate = Isolate::Current();
143 Page* first_page = memory_allocator->AllocatePage(
146 first_page->
InsertAfter(faked_space.anchor()->prev_page());
147 CHECK(first_page->is_valid());
148 CHECK(first_page->next_page() == faked_space.anchor());
151 for (
Page* p = first_page; p != faked_space.anchor(); p = p->
next_page()) {
156 Page* other = memory_allocator->AllocatePage(
162 for (
Page* p = first_page; p != faked_space.anchor(); p = p->
next_page()) {
166 CHECK(total_pages == page_count);
170 memory_allocator->Free(first_page);
171 memory_allocator->Free(second_page);
172 memory_allocator->TearDown();
173 delete memory_allocator;
179 Isolate* isolate = Isolate::Current();
191 HEAP->ReservedSemiSpaceSize()));
202 memory_allocator->TearDown();
203 delete memory_allocator;
209 Isolate* isolate = Isolate::Current();
233 delete memory_allocator;
246 CHECK(obj->IsHeapObject());
259 if (!maybe_obj->ToObject(&obj))
break;
MUST_USE_RESULT MaybeObject * AllocateRaw(int size_in_bytes)
static MemoryChunk * FromAddress(Address a)
static HeapObject * cast(Object *obj)
Address OffsetToAddress(int offset)
static const int kPageSize
activate correct semantics for inheriting readonliness enable harmony semantics for typeof enable harmony enable harmony proxies enable all harmony harmony_scoping harmony_proxies harmony_scoping tracks arrays with only smi values automatically unbox arrays of doubles use crankshaft use hydrogen range analysis use hydrogen global value numbering use function inlining maximum number of AST nodes considered for a single inlining loop invariant code motion print statistics for hydrogen trace generated IR for specified phases trace register allocator trace range analysis trace representation types environment for every instruction put a break point before deoptimizing polymorphic inlining perform array bounds checks elimination use dead code elimination trace on stack replacement optimize closures cache optimized code for closures functions with arguments object loop weight for representation inference allow uint32 values on optimize frames if they are used only in safe operations track parallel recompilation enable all profiler experiments number of stack frames inspected by the profiler call recompile stub directly when self optimizing trigger profiler ticks based on counting instead of timing weight back edges by jump distance for interrupt triggering percentage of ICs that must have type info to allow optimization watch_ic_patching retry_self_opt interrupt_at_exit extra verbose compilation tracing generate extra emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of SAHF instruction if available(X64 only)") DEFINE_bool(enable_vfp3
~TestMemoryAllocatorScope()
intptr_t MaxOldGenerationSize()
bool ConfigureHeapDefault()
TestMemoryAllocatorScope(Isolate *isolate, MemoryAllocator *allocator)
#define DISALLOW_COPY_AND_ASSIGN(TypeName)
T RoundUp(T x, intptr_t m)
static const int kMaxNonCodeHeapObjectSize
MaybeObject * FindObject(Address a)
static const int kObjectStartOffset
bool Contains(HeapObject *obj)
void InitializeLoggingAndCounters()
void InsertAfter(MemoryChunk *other)
activate correct semantics for inheriting readonliness enable harmony semantics for typeof enable harmony enable harmony proxies enable all harmony harmony_scoping harmony_proxies harmony_scoping tracks arrays with only smi values automatically unbox arrays of doubles use crankshaft use hydrogen range analysis use hydrogen global value numbering use function inlining maximum number of AST nodes considered for a single inlining loop invariant code motion print statistics for hydrogen trace generated IR for specified phases trace register allocator trace range analysis trace representation types environment for every instruction put a break point before deoptimizing polymorphic inlining perform array bounds checks elimination use dead code elimination trace on stack replacement optimize closures cache optimized code for closures functions with arguments object loop weight for representation inference allow uint32 values on optimize frames if they are used only in safe operations track parallel recompilation enable all profiler experiments number of stack frames inspected by the profiler call recompile stub directly when self optimizing trigger profiler ticks based on counting instead of timing weight back edges by jump distance for interrupt triggering percentage of ICs that must have type info to allow optimization watch_ic_patching retry_self_opt interrupt_at_exit extra verbose compilation tracing generate extra emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of SAHF instruction if enable use of VFP3 instructions if available this implies enabling ARMv7 and VFP2 enable use of VFP2 instructions if available enable use of SDIV and UDIV instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of MIPS FPU instructions if NULL
bool SetUp(int reserved_semispace_size_, int max_semispace_size)
void DeleteArray(T *array)
MUST_USE_RESULT MaybeObject * AllocateRaw(int object_size, Executability executable)
intptr_t MaxExecutableSize()