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

Side by Side Diff: runtime/lib/mirrors.cc

Issue 678763004: Make CTX allocatable by the register allocator. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: incorporated latest comments Created 6 years, 1 month 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 | « no previous file | runtime/vm/code_descriptors_test.cc » ('j') | runtime/vm/debugger.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "lib/invocation_mirror.h" 5 #include "lib/invocation_mirror.h"
6 #include "vm/bootstrap_natives.h" 6 #include "vm/bootstrap_natives.h"
7 #include "vm/class_finalizer.h" 7 #include "vm/class_finalizer.h"
8 #include "vm/compiler.h" 8 #include "vm/compiler.h"
9 #include "vm/dart_entry.h" 9 #include "vm/dart_entry.h"
10 #include "vm/exceptions.h" 10 #include "vm/exceptions.h"
(...skipping 1342 matching lines...) Expand 10 before | Expand all | Expand 10 after
1353 // runtime type of null is the Null type, which we correctly return here. 1353 // runtime type of null is the Null type, which we correctly return here.
1354 return type.Canonicalize(); 1354 return type.Canonicalize();
1355 } 1355 }
1356 1356
1357 1357
1358 DEFINE_NATIVE_ENTRY(ClosureMirror_function, 1) { 1358 DEFINE_NATIVE_ENTRY(ClosureMirror_function, 1) {
1359 GET_NON_NULL_NATIVE_ARGUMENT(Instance, closure, arguments->NativeArgAt(0)); 1359 GET_NON_NULL_NATIVE_ARGUMENT(Instance, closure, arguments->NativeArgAt(0));
1360 ASSERT(!closure.IsNull()); 1360 ASSERT(!closure.IsNull());
1361 1361
1362 Function& function = Function::Handle(); 1362 Function& function = Function::Handle();
1363 bool callable = closure.IsCallable(&function, NULL); 1363 bool callable = closure.IsCallable(&function);
1364 if (callable) { 1364 if (callable) {
1365 return CreateMethodMirror(function, Instance::null_instance()); 1365 return CreateMethodMirror(function, Instance::null_instance());
1366 } 1366 }
1367 return Instance::null(); 1367 return Instance::null();
1368 } 1368 }
1369 1369
1370 1370
1371 DEFINE_NATIVE_ENTRY(ClassMirror_invoke, 5) { 1371 DEFINE_NATIVE_ENTRY(ClassMirror_invoke, 5) {
1372 // Argument 0 is the mirror, which is unused by the native. It exists 1372 // Argument 0 is the mirror, which is unused by the native. It exists
1373 // because this native is an instance method in order to be polymorphic 1373 // because this native is an instance method in order to be polymorphic
(...skipping 588 matching lines...) Expand 10 before | Expand all | Expand 10 after
1962 } 1962 }
1963 1963
1964 DEFINE_NATIVE_ENTRY(TypeMirror_moreSpecificTest, 2) { 1964 DEFINE_NATIVE_ENTRY(TypeMirror_moreSpecificTest, 2) {
1965 GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, a, arguments->NativeArgAt(0)); 1965 GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, a, arguments->NativeArgAt(0));
1966 GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, b, arguments->NativeArgAt(1)); 1966 GET_NON_NULL_NATIVE_ARGUMENT(AbstractType, b, arguments->NativeArgAt(1));
1967 return Bool::Get(a.IsMoreSpecificThan(b, NULL)).raw(); 1967 return Bool::Get(a.IsMoreSpecificThan(b, NULL)).raw();
1968 } 1968 }
1969 1969
1970 1970
1971 } // namespace dart 1971 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/code_descriptors_test.cc » ('j') | runtime/vm/debugger.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698