OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 1292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1303 Handle<Code> code = | 1303 Handle<Code> code = |
1304 Handle<Code>(isolate->builtins()->builtin( | 1304 Handle<Code>(isolate->builtins()->builtin( |
1305 Builtins::kHandleApiCallAsConstructor)); | 1305 Builtins::kHandleApiCallAsConstructor)); |
1306 Handle<JSFunction> delegate = | 1306 Handle<JSFunction> delegate = |
1307 factory->NewFunction(factory->empty_string(), JS_OBJECT_TYPE, | 1307 factory->NewFunction(factory->empty_string(), JS_OBJECT_TYPE, |
1308 JSObject::kHeaderSize, code, true); | 1308 JSObject::kHeaderSize, code, true); |
1309 native_context()->set_call_as_constructor_delegate(*delegate); | 1309 native_context()->set_call_as_constructor_delegate(*delegate); |
1310 delegate->shared()->DontAdaptArguments(); | 1310 delegate->shared()->DontAdaptArguments(); |
1311 } | 1311 } |
1312 | 1312 |
1313 // Initialize the out of memory slot. | |
1314 native_context()->set_out_of_memory(heap->false_value()); | |
1315 | |
1316 // Initialize the embedder data slot. | 1313 // Initialize the embedder data slot. |
1317 Handle<FixedArray> embedder_data = factory->NewFixedArray(3); | 1314 Handle<FixedArray> embedder_data = factory->NewFixedArray(3); |
1318 native_context()->set_embedder_data(*embedder_data); | 1315 native_context()->set_embedder_data(*embedder_data); |
1319 } | 1316 } |
1320 | 1317 |
1321 | 1318 |
1322 Handle<JSFunction> Genesis::InstallTypedArray( | 1319 Handle<JSFunction> Genesis::InstallTypedArray( |
1323 const char* name, ElementsKind elementsKind) { | 1320 const char* name, ElementsKind elementsKind) { |
1324 Handle<JSObject> global = Handle<JSObject>(native_context()->global_object()); | 1321 Handle<JSObject> global = Handle<JSObject>(native_context()->global_object()); |
1325 Handle<JSFunction> result = InstallFunction(global, name, JS_TYPED_ARRAY_TYPE, | 1322 Handle<JSFunction> result = InstallFunction(global, name, JS_TYPED_ARRAY_TYPE, |
(...skipping 1424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2750 return from + sizeof(NestingCounterType); | 2747 return from + sizeof(NestingCounterType); |
2751 } | 2748 } |
2752 | 2749 |
2753 | 2750 |
2754 // Called when the top-level V8 mutex is destroyed. | 2751 // Called when the top-level V8 mutex is destroyed. |
2755 void Bootstrapper::FreeThreadResources() { | 2752 void Bootstrapper::FreeThreadResources() { |
2756 ASSERT(!IsActive()); | 2753 ASSERT(!IsActive()); |
2757 } | 2754 } |
2758 | 2755 |
2759 } } // namespace v8::internal | 2756 } } // namespace v8::internal |
OLD | NEW |