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

Unified Diff: src/heap/heap.h

Issue 1230753004: [Interpreter] Add BytecodeArray class and add to SharedFunctionInfo. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Use BytecodeArray in bytecode emission path in interpreter. Created 5 years, 5 months 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
Index: src/heap/heap.h
diff --git a/src/heap/heap.h b/src/heap/heap.h
index 5c6f49927007a008b42ad499f88ad67fc3cd5d5d..b707e269dee082b3b320ef5468b36f836903cfae 100644
--- a/src/heap/heap.h
+++ b/src/heap/heap.h
@@ -60,6 +60,7 @@ namespace internal {
V(Map, function_context_map, FunctionContextMap) \
V(FixedArray, empty_fixed_array, EmptyFixedArray) \
V(ByteArray, empty_byte_array, EmptyByteArray) \
+ V(BytecodeArray, empty_bytecode_array, EmptyBytecodeArray) \
V(DescriptorArray, empty_descriptor_array, EmptyDescriptorArray) \
/* The roots above this line should be boring from a GC point of view. */ \
/* This means they are never in new space and never on a page that is */ \
@@ -1671,6 +1672,11 @@ class Heap {
MUST_USE_RESULT AllocationResult
AllocateByteArray(int length, PretenureFlag pretenure = NOT_TENURED);
+ // Allocates a bytecode array with given contents
rmcilroy 2015/07/15 13:33:38 nit - fullstop at the end of the comment.
oth 2015/07/16 09:15:50 Done and renamed 'start' to 'raw_bytecodes'.
+ MUST_USE_RESULT AllocationResult
+ AllocateBytecodeArray(int length, const byte* start,
+ PretenureFlag pretenure = NOT_TENURED);
+
// Copy the code and scope info part of the code object, but insert
// the provided data as the relocation information.
MUST_USE_RESULT AllocationResult

Powered by Google App Engine
This is Rietveld 408576698