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

Side by Side Diff: src/factory.cc

Issue 1314953004: [interpreter] Add constant_pool() to BytecodeArray. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@int_args
Patch Set: Fix test flag. Created 5 years, 3 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 unified diff | Download patch
« no previous file with comments | « src/factory.h ('k') | src/heap/heap.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/factory.h" 5 #include "src/factory.h"
6 6
7 #include "src/allocation-site-scopes.h" 7 #include "src/allocation-site-scopes.h"
8 #include "src/base/bits.h" 8 #include "src/base/bits.h"
9 #include "src/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/conversions.h" 10 #include "src/conversions.h"
(...skipping 869 matching lines...) Expand 10 before | Expand all | Expand 10 after
880 880
881 Handle<ByteArray> Factory::NewByteArray(int length, PretenureFlag pretenure) { 881 Handle<ByteArray> Factory::NewByteArray(int length, PretenureFlag pretenure) {
882 DCHECK(0 <= length); 882 DCHECK(0 <= length);
883 CALL_HEAP_FUNCTION( 883 CALL_HEAP_FUNCTION(
884 isolate(), 884 isolate(),
885 isolate()->heap()->AllocateByteArray(length, pretenure), 885 isolate()->heap()->AllocateByteArray(length, pretenure),
886 ByteArray); 886 ByteArray);
887 } 887 }
888 888
889 889
890 Handle<BytecodeArray> Factory::NewBytecodeArray(int length, 890 Handle<BytecodeArray> Factory::NewBytecodeArray(
891 const byte* raw_bytecodes, 891 int length, const byte* raw_bytecodes, int frame_size, int parameter_count,
892 int frame_size, 892 Handle<FixedArray> constant_pool) {
893 int parameter_count) {
894 DCHECK(0 <= length); 893 DCHECK(0 <= length);
895 CALL_HEAP_FUNCTION(isolate(), 894 CALL_HEAP_FUNCTION(isolate(), isolate()->heap()->AllocateBytecodeArray(
896 isolate()->heap()->AllocateBytecodeArray( 895 length, raw_bytecodes, frame_size,
897 length, raw_bytecodes, frame_size, parameter_count), 896 parameter_count, *constant_pool),
898 BytecodeArray); 897 BytecodeArray);
899 } 898 }
900 899
901 900
902 Handle<FixedTypedArrayBase> Factory::NewFixedTypedArrayWithExternalPointer( 901 Handle<FixedTypedArrayBase> Factory::NewFixedTypedArrayWithExternalPointer(
903 int length, ExternalArrayType array_type, void* external_pointer, 902 int length, ExternalArrayType array_type, void* external_pointer,
904 PretenureFlag pretenure) { 903 PretenureFlag pretenure) {
905 DCHECK(0 <= length && length <= Smi::kMaxValue); 904 DCHECK(0 <= length && length <= Smi::kMaxValue);
906 CALL_HEAP_FUNCTION( 905 CALL_HEAP_FUNCTION(
907 isolate(), isolate()->heap()->AllocateFixedTypedArrayWithExternalPointer( 906 isolate(), isolate()->heap()->AllocateFixedTypedArrayWithExternalPointer(
(...skipping 1425 matching lines...) Expand 10 before | Expand all | Expand 10 after
2333 } 2332 }
2334 2333
2335 2334
2336 Handle<Object> Factory::ToBoolean(bool value) { 2335 Handle<Object> Factory::ToBoolean(bool value) {
2337 return value ? true_value() : false_value(); 2336 return value ? true_value() : false_value();
2338 } 2337 }
2339 2338
2340 2339
2341 } // namespace internal 2340 } // namespace internal
2342 } // namespace v8 2341 } // namespace v8
OLDNEW
« no previous file with comments | « src/factory.h ('k') | src/heap/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698