OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 779 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
790 | 790 |
791 | 791 |
792 Handle<HeapNumber> Factory::NewHeapNumber(double value, | 792 Handle<HeapNumber> Factory::NewHeapNumber(double value, |
793 PretenureFlag pretenure) { | 793 PretenureFlag pretenure) { |
794 CALL_HEAP_FUNCTION( | 794 CALL_HEAP_FUNCTION( |
795 isolate(), | 795 isolate(), |
796 isolate()->heap()->AllocateHeapNumber(value, pretenure), HeapNumber); | 796 isolate()->heap()->AllocateHeapNumber(value, pretenure), HeapNumber); |
797 } | 797 } |
798 | 798 |
799 | 799 |
| 800 Handle<Float32x4> Factory::NewFloat32x4(float32x4_value_t value, |
| 801 PretenureFlag pretenure) { |
| 802 CALL_HEAP_FUNCTION( |
| 803 isolate(), |
| 804 isolate()->heap()->AllocateFloat32x4(value, pretenure), Float32x4); |
| 805 } |
| 806 |
| 807 |
| 808 Handle<Int32x4> Factory::NewInt32x4(int32x4_value_t value, |
| 809 PretenureFlag pretenure) { |
| 810 CALL_HEAP_FUNCTION( |
| 811 isolate(), |
| 812 isolate()->heap()->AllocateInt32x4(value, pretenure), Int32x4); |
| 813 } |
| 814 |
| 815 |
800 Handle<JSObject> Factory::NewNeanderObject() { | 816 Handle<JSObject> Factory::NewNeanderObject() { |
801 CALL_HEAP_FUNCTION( | 817 CALL_HEAP_FUNCTION( |
802 isolate(), | 818 isolate(), |
803 isolate()->heap()->AllocateJSObjectFromMap( | 819 isolate()->heap()->AllocateJSObjectFromMap( |
804 isolate()->heap()->neander_map()), | 820 isolate()->heap()->neander_map()), |
805 JSObject); | 821 JSObject); |
806 } | 822 } |
807 | 823 |
808 | 824 |
809 Handle<Object> Factory::NewTypeError(const char* message, | 825 Handle<Object> Factory::NewTypeError(const char* message, |
(...skipping 477 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1287 | 1303 |
1288 case kExternalUnsignedIntArray: | 1304 case kExternalUnsignedIntArray: |
1289 return native_context->uint32_array_fun(); | 1305 return native_context->uint32_array_fun(); |
1290 | 1306 |
1291 case kExternalIntArray: | 1307 case kExternalIntArray: |
1292 return native_context->int32_array_fun(); | 1308 return native_context->int32_array_fun(); |
1293 | 1309 |
1294 case kExternalFloatArray: | 1310 case kExternalFloatArray: |
1295 return native_context->float_array_fun(); | 1311 return native_context->float_array_fun(); |
1296 | 1312 |
| 1313 case kExternalFloat32x4Array: |
| 1314 return native_context->float32x4_array_fun(); |
| 1315 |
| 1316 case kExternalInt32x4Array: |
| 1317 return native_context->int32x4_array_fun(); |
| 1318 |
1297 case kExternalDoubleArray: | 1319 case kExternalDoubleArray: |
1298 return native_context->double_array_fun(); | 1320 return native_context->double_array_fun(); |
1299 | 1321 |
1300 case kExternalPixelArray: | 1322 case kExternalPixelArray: |
1301 return native_context->uint8c_array_fun(); | 1323 return native_context->uint8c_array_fun(); |
1302 | 1324 |
1303 default: | 1325 default: |
1304 UNREACHABLE(); | 1326 UNREACHABLE(); |
1305 return NULL; | 1327 return NULL; |
1306 } | 1328 } |
(...skipping 490 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1797 return Handle<Object>::null(); | 1819 return Handle<Object>::null(); |
1798 } | 1820 } |
1799 | 1821 |
1800 | 1822 |
1801 Handle<Object> Factory::ToBoolean(bool value) { | 1823 Handle<Object> Factory::ToBoolean(bool value) { |
1802 return value ? true_value() : false_value(); | 1824 return value ? true_value() : false_value(); |
1803 } | 1825 } |
1804 | 1826 |
1805 | 1827 |
1806 } } // namespace v8::internal | 1828 } } // namespace v8::internal |
OLD | NEW |