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

Side by Side Diff: src/runtime/runtime-interpreter.cc

Issue 1396693003: [Interpreter] Add function literal support. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@int_newcontext
Patch Set: Review comments Created 5 years, 2 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/runtime/runtime.h ('k') | test/cctest/interpreter/test-bytecode-generator.cc » ('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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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/runtime/runtime-utils.h" 5 #include "src/runtime/runtime-utils.h"
6 6
7 #include "src/arguments.h" 7 #include "src/arguments.h"
8 #include "src/isolate-inl.h" 8 #include "src/isolate-inl.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 130
131 131
132 RUNTIME_FUNCTION(Runtime_InterpreterTypeOf) { 132 RUNTIME_FUNCTION(Runtime_InterpreterTypeOf) {
133 SealHandleScope shs(isolate); 133 SealHandleScope shs(isolate);
134 DCHECK_EQ(1, args.length()); 134 DCHECK_EQ(1, args.length());
135 CONVERT_ARG_HANDLE_CHECKED(Object, x, 0); 135 CONVERT_ARG_HANDLE_CHECKED(Object, x, 0);
136 return Object::cast(*Object::TypeOf(isolate, x)); 136 return Object::cast(*Object::TypeOf(isolate, x));
137 } 137 }
138 138
139 139
140 RUNTIME_FUNCTION(Runtime_InterpreterNewClosure) {
141 HandleScope scope(isolate);
142 DCHECK_EQ(2, args.length());
143 CONVERT_ARG_HANDLE_CHECKED(SharedFunctionInfo, shared, 0);
144 CONVERT_SMI_ARG_CHECKED(pretenured_flag, 1);
145 Handle<Context> context(isolate->context(), isolate);
146 return *isolate->factory()->NewFunctionFromSharedFunctionInfo(
147 shared, context, static_cast<PretenureFlag>(pretenured_flag));
148 }
149
140 } // namespace internal 150 } // namespace internal
141 } // namespace v8 151 } // namespace v8
OLDNEW
« no previous file with comments | « src/runtime/runtime.h ('k') | test/cctest/interpreter/test-bytecode-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698