Chromium Code Reviews| 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 |