OLD | NEW |
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 1470 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1481 } | 1481 } |
1482 | 1482 |
1483 | 1483 |
1484 Handle<Code> Factory::CopyCode(Handle<Code> code) { | 1484 Handle<Code> Factory::CopyCode(Handle<Code> code) { |
1485 CALL_HEAP_FUNCTION(isolate(), | 1485 CALL_HEAP_FUNCTION(isolate(), |
1486 isolate()->heap()->CopyCode(*code), | 1486 isolate()->heap()->CopyCode(*code), |
1487 Code); | 1487 Code); |
1488 } | 1488 } |
1489 | 1489 |
1490 | 1490 |
1491 Handle<Code> Factory::CopyCode(Handle<Code> code, Vector<byte> reloc_info) { | |
1492 CALL_HEAP_FUNCTION(isolate(), | |
1493 isolate()->heap()->CopyCode(*code, reloc_info), | |
1494 Code); | |
1495 } | |
1496 | |
1497 Handle<BytecodeArray> Factory::CopyBytecodeArray( | 1491 Handle<BytecodeArray> Factory::CopyBytecodeArray( |
1498 Handle<BytecodeArray> bytecode_array) { | 1492 Handle<BytecodeArray> bytecode_array) { |
1499 CALL_HEAP_FUNCTION(isolate(), | 1493 CALL_HEAP_FUNCTION(isolate(), |
1500 isolate()->heap()->CopyBytecodeArray(*bytecode_array), | 1494 isolate()->heap()->CopyBytecodeArray(*bytecode_array), |
1501 BytecodeArray); | 1495 BytecodeArray); |
1502 } | 1496 } |
1503 | 1497 |
1504 Handle<JSObject> Factory::NewJSObject(Handle<JSFunction> constructor, | 1498 Handle<JSObject> Factory::NewJSObject(Handle<JSFunction> constructor, |
1505 PretenureFlag pretenure) { | 1499 PretenureFlag pretenure) { |
1506 JSFunction::EnsureHasInitialMap(constructor); | 1500 JSFunction::EnsureHasInitialMap(constructor); |
(...skipping 891 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2398 } | 2392 } |
2399 | 2393 |
2400 | 2394 |
2401 Handle<Object> Factory::ToBoolean(bool value) { | 2395 Handle<Object> Factory::ToBoolean(bool value) { |
2402 return value ? true_value() : false_value(); | 2396 return value ? true_value() : false_value(); |
2403 } | 2397 } |
2404 | 2398 |
2405 | 2399 |
2406 } // namespace internal | 2400 } // namespace internal |
2407 } // namespace v8 | 2401 } // namespace v8 |
OLD | NEW |