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

Side by Side Diff: runtime/vm/native_entry.h

Issue 3007603002: [VM generic function reification] Support generic functions in Invocation class. (Closed)
Patch Set: address review comment Created 3 years, 3 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 | « runtime/vm/kernel_to_il.cc ('k') | runtime/vm/object.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 (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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 #ifndef RUNTIME_VM_NATIVE_ENTRY_H_ 5 #ifndef RUNTIME_VM_NATIVE_ENTRY_H_
6 #define RUNTIME_VM_NATIVE_ENTRY_H_ 6 #define RUNTIME_VM_NATIVE_ENTRY_H_
7 7
8 #include "platform/memory_sanitizer.h" 8 #include "platform/memory_sanitizer.h"
9 9
10 #include "vm/allocation.h" 10 #include "vm/allocation.h"
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 #define TRACE_NATIVE_CALL(format, name) \ 46 #define TRACE_NATIVE_CALL(format, name) \
47 do { \ 47 do { \
48 } while (0) 48 } while (0)
49 #endif 49 #endif
50 50
51 #define NATIVE_ENTRY_FUNCTION(name) BootstrapNatives::DN_##name 51 #define NATIVE_ENTRY_FUNCTION(name) BootstrapNatives::DN_##name
52 52
53 #ifdef DEBUG 53 #ifdef DEBUG
54 #define SET_NATIVE_RETVAL(args, value) \ 54 #define SET_NATIVE_RETVAL(args, value) \
55 RawObject* retval = value; \ 55 RawObject* retval = value; \
56 ASSERT(retval->IsDartInstance() || retval->IsTypeArguments()); \ 56 ASSERT(retval->IsDartInstance()); \
57 arguments->SetReturnUnsafe(retval); 57 arguments->SetReturnUnsafe(retval);
58 #else 58 #else
59 #define SET_NATIVE_RETVAL(arguments, value) arguments->SetReturnUnsafe(value); 59 #define SET_NATIVE_RETVAL(arguments, value) arguments->SetReturnUnsafe(value);
60 #endif 60 #endif
61 61
62 #define DEFINE_NATIVE_ENTRY(name, argument_count) \ 62 #define DEFINE_NATIVE_ENTRY(name, argument_count) \
63 static RawObject* DN_Helper##name(Isolate* isolate, Thread* thread, \ 63 static RawObject* DN_Helper##name(Isolate* isolate, Thread* thread, \
64 Zone* zone, NativeArguments* arguments); \ 64 Zone* zone, NativeArguments* arguments); \
65 void NATIVE_ENTRY_FUNCTION(name)(Dart_NativeArguments args) { \ 65 void NATIVE_ENTRY_FUNCTION(name)(Dart_NativeArguments args) { \
66 CHECK_STACK_ALIGNMENT; \ 66 CHECK_STACK_ALIGNMENT; \
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 static void AutoScopeNativeCallWrapperNoStackCheck(Dart_NativeArguments args, 147 static void AutoScopeNativeCallWrapperNoStackCheck(Dart_NativeArguments args,
148 Dart_NativeFunction func); 148 Dart_NativeFunction func);
149 149
150 static bool ReturnValueIsError(NativeArguments* arguments); 150 static bool ReturnValueIsError(NativeArguments* arguments);
151 static void PropagateErrors(NativeArguments* arguments); 151 static void PropagateErrors(NativeArguments* arguments);
152 }; 152 };
153 153
154 } // namespace dart 154 } // namespace dart
155 155
156 #endif // RUNTIME_VM_NATIVE_ENTRY_H_ 156 #endif // RUNTIME_VM_NATIVE_ENTRY_H_
OLDNEW
« no previous file with comments | « runtime/vm/kernel_to_il.cc ('k') | runtime/vm/object.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698