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

Side by Side Diff: src/bootstrapper.cc

Issue 151603004: A64: Synchronize with r16587. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/a64
Patch Set: Created 6 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « src/ast.cc ('k') | src/builtins.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 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 1534 matching lines...) Expand 10 before | Expand all | Expand 10 after
1545 factory->NewFunctionFromSharedFunctionInfo(function_info, context); 1545 factory->NewFunctionFromSharedFunctionInfo(function_info, context);
1546 1546
1547 // Call function using either the runtime object or the global 1547 // Call function using either the runtime object or the global
1548 // object as the receiver. Provide no parameters. 1548 // object as the receiver. Provide no parameters.
1549 Handle<Object> receiver = 1549 Handle<Object> receiver =
1550 Handle<Object>(use_runtime_context 1550 Handle<Object>(use_runtime_context
1551 ? top_context->builtins() 1551 ? top_context->builtins()
1552 : top_context->global_object(), 1552 : top_context->global_object(),
1553 isolate); 1553 isolate);
1554 bool has_pending_exception; 1554 bool has_pending_exception;
1555 Execution::Call(fun, receiver, 0, NULL, &has_pending_exception); 1555 Execution::Call(isolate, fun, receiver, 0, NULL, &has_pending_exception);
1556 if (has_pending_exception) return false; 1556 if (has_pending_exception) return false;
1557 return true; 1557 return true;
1558 } 1558 }
1559 1559
1560 1560
1561 #define INSTALL_NATIVE(Type, name, var) \ 1561 #define INSTALL_NATIVE(Type, name, var) \
1562 Handle<String> var##_name = \ 1562 Handle<String> var##_name = \
1563 factory()->InternalizeOneByteString(STATIC_ASCII_VECTOR(name)); \ 1563 factory()->InternalizeOneByteString(STATIC_ASCII_VECTOR(name)); \
1564 Object* var##_native = \ 1564 Object* var##_native = \
1565 native_context()->builtins()->GetPropertyNoExceptionThrown( \ 1565 native_context()->builtins()->GetPropertyNoExceptionThrown( \
(...skipping 1031 matching lines...) Expand 10 before | Expand all | Expand 10 after
2597 2597
2598 // During genesis, the boilerplate for stack overflow won't work until the 2598 // During genesis, the boilerplate for stack overflow won't work until the
2599 // environment has been at least partially initialized. Add a stack check 2599 // environment has been at least partially initialized. Add a stack check
2600 // before entering JS code to catch overflow early. 2600 // before entering JS code to catch overflow early.
2601 StackLimitCheck check(isolate); 2601 StackLimitCheck check(isolate);
2602 if (check.HasOverflowed()) return; 2602 if (check.HasOverflowed()) return;
2603 2603
2604 // We can only de-serialize a context if the isolate was initialized from 2604 // We can only de-serialize a context if the isolate was initialized from
2605 // a snapshot. Otherwise we have to build the context from scratch. 2605 // a snapshot. Otherwise we have to build the context from scratch.
2606 if (isolate->initialized_from_snapshot()) { 2606 if (isolate->initialized_from_snapshot()) {
2607 native_context_ = Snapshot::NewContextFromSnapshot(); 2607 native_context_ = Snapshot::NewContextFromSnapshot(isolate);
2608 } else { 2608 } else {
2609 native_context_ = Handle<Context>(); 2609 native_context_ = Handle<Context>();
2610 } 2610 }
2611 2611
2612 if (!native_context().is_null()) { 2612 if (!native_context().is_null()) {
2613 AddToWeakNativeContextList(*native_context()); 2613 AddToWeakNativeContextList(*native_context());
2614 isolate->set_context(*native_context()); 2614 isolate->set_context(*native_context());
2615 isolate->counters()->contexts_created_by_snapshot()->Increment(); 2615 isolate->counters()->contexts_created_by_snapshot()->Increment();
2616 Handle<GlobalObject> inner_global; 2616 Handle<GlobalObject> inner_global;
2617 Handle<JSGlobalProxy> global_proxy = 2617 Handle<JSGlobalProxy> global_proxy =
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
2675 return from + sizeof(NestingCounterType); 2675 return from + sizeof(NestingCounterType);
2676 } 2676 }
2677 2677
2678 2678
2679 // Called when the top-level V8 mutex is destroyed. 2679 // Called when the top-level V8 mutex is destroyed.
2680 void Bootstrapper::FreeThreadResources() { 2680 void Bootstrapper::FreeThreadResources() {
2681 ASSERT(!IsActive()); 2681 ASSERT(!IsActive());
2682 } 2682 }
2683 2683
2684 } } // namespace v8::internal 2684 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/ast.cc ('k') | src/builtins.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698