Implement reading byref variants.
[mono-project.git] / mono / mini / jit-icalls.h
blob04e6d44f9c24839ff755b9f2c6ee2db46419b640
1 #ifndef __MONO_JIT_ICALLS_H__
2 #define __MONO_JIT_ICALLS_H__
4 #include <math.h>
6 #include "mini.h"
8 void* mono_ldftn (MonoMethod *method) MONO_INTERNAL;
10 void* mono_ldvirtfn (MonoObject *obj, MonoMethod *method) MONO_INTERNAL;
12 void* mono_ldvirtfn_gshared (MonoObject *obj, MonoMethod *method) MONO_INTERNAL;
14 void mono_helper_stelem_ref_check (MonoArray *array, MonoObject *val) MONO_INTERNAL;
16 gint64 mono_llmult (gint64 a, gint64 b) MONO_INTERNAL;
18 guint64 mono_llmult_ovf_un (guint64 a, guint64 b) MONO_INTERNAL;
20 guint64 mono_llmult_ovf (gint64 a, gint64 b) MONO_INTERNAL;
22 gint32 mono_idiv (gint32 a, gint32 b) MONO_INTERNAL;
24 guint32 mono_idiv_un (guint32 a, guint32 b) MONO_INTERNAL;
26 gint32 mono_irem (gint32 a, gint32 b) MONO_INTERNAL;
28 guint32 mono_irem_un (guint32 a, guint32 b) MONO_INTERNAL;
30 gint32 mono_imul (gint32 a, gint32 b) MONO_INTERNAL;
32 gint32 mono_imul_ovf (gint32 a, gint32 b) MONO_INTERNAL;
34 gint32 mono_imul_ovf_un (guint32 a, guint32 b) MONO_INTERNAL;
36 double mono_fdiv (double a, double b) MONO_INTERNAL;
38 gint64 mono_lldiv (gint64 a, gint64 b) MONO_INTERNAL;
40 gint64 mono_llrem (gint64 a, gint64 b) MONO_INTERNAL;
42 guint64 mono_lldiv_un (guint64 a, guint64 b) MONO_INTERNAL;
44 guint64 mono_llrem_un (guint64 a, guint64 b) MONO_INTERNAL;
46 guint64 mono_lshl (guint64 a, gint32 shamt) MONO_INTERNAL;
48 guint64 mono_lshr_un (guint64 a, gint32 shamt) MONO_INTERNAL;
50 gint64 mono_lshr (gint64 a, gint32 shamt) MONO_INTERNAL;
52 MonoArray *mono_array_new_va (MonoMethod *cm, ...) MONO_INTERNAL;
54 MonoArray *mono_array_new_1 (MonoMethod *cm, guint32 length) MONO_INTERNAL;
56 MonoArray *mono_array_new_2 (MonoMethod *cm, guint32 length1, guint32 length2) MONO_INTERNAL;
58 MonoArray *mono_array_new_3 (MonoMethod *cm, guint32 length1, guint32 length2, guint32 length3) MONO_INTERNAL;
60 MonoArray *mono_array_new_4 (MonoMethod *cm, guint32 length1, guint32 length2, guint32 length3, guint32 length4) MONO_INTERNAL;
62 gpointer mono_class_static_field_address (MonoDomain *domain, MonoClassField *field) MONO_INTERNAL;
64 gpointer mono_ldtoken_wrapper (MonoImage *image, int token, MonoGenericContext *context) MONO_INTERNAL;
66 gpointer mono_ldtoken_wrapper_generic_shared (MonoImage *image, int token, MonoMethod *method) MONO_INTERNAL;
68 guint64 mono_fconv_u8 (double v) MONO_INTERNAL;
70 gint64 mono_fconv_i8 (double v) MONO_INTERNAL;
72 guint32 mono_fconv_u4 (double v) MONO_INTERNAL;
74 gint64 mono_fconv_ovf_i8 (double v) MONO_INTERNAL;
76 guint64 mono_fconv_ovf_u8 (double v) MONO_INTERNAL;
78 double mono_lconv_to_r8 (gint64 a) MONO_INTERNAL;
80 double mono_conv_to_r8 (gint32 a) MONO_INTERNAL;
82 double mono_conv_to_r4 (gint32 a) MONO_INTERNAL;
84 float mono_lconv_to_r4 (gint64 a) MONO_INTERNAL;
86 double mono_conv_to_r8_un (guint32 a) MONO_INTERNAL;
88 double mono_lconv_to_r8_un (guint64 a) MONO_INTERNAL;
90 #if defined(__native_client_codegen__) || defined(__native_client__)
91 double mono_fmod(double a, double b) MONO_INTERNAL;
92 #endif
94 gpointer mono_helper_compile_generic_method (MonoObject *obj, MonoMethod *method, gpointer *this_arg) MONO_INTERNAL;
96 MonoString *mono_helper_ldstr (MonoImage *image, guint32 idx) MONO_INTERNAL;
98 MonoString *mono_helper_ldstr_mscorlib (guint32 idx) MONO_INTERNAL;
100 MonoObject *mono_helper_newobj_mscorlib (guint32 idx) MONO_INTERNAL;
102 double mono_fsub (double a, double b) MONO_INTERNAL;
104 double mono_fadd (double a, double b) MONO_INTERNAL;
106 double mono_fmul (double a, double b) MONO_INTERNAL;
108 double mono_fneg (double a) MONO_INTERNAL;
110 double mono_fconv_r4 (double a) MONO_INTERNAL;
112 gint8 mono_fconv_i1 (double a) MONO_INTERNAL;
114 gint16 mono_fconv_i2 (double a) MONO_INTERNAL;
116 gint32 mono_fconv_i4 (double a) MONO_INTERNAL;
118 guint8 mono_fconv_u1 (double a) MONO_INTERNAL;
120 guint16 mono_fconv_u2 (double a) MONO_INTERNAL;
122 gboolean mono_fcmp_eq (double a, double b) MONO_INTERNAL;
124 gboolean mono_fcmp_ge (double a, double b) MONO_INTERNAL;
126 gboolean mono_fcmp_gt (double a, double b) MONO_INTERNAL;
128 gboolean mono_fcmp_le (double a, double b) MONO_INTERNAL;
130 gboolean mono_fcmp_lt (double a, double b) MONO_INTERNAL;
132 gboolean mono_fcmp_ne_un (double a, double b) MONO_INTERNAL;
134 gboolean mono_fcmp_ge_un (double a, double b) MONO_INTERNAL;
136 gboolean mono_fcmp_gt_un (double a, double b) MONO_INTERNAL;
138 gboolean mono_fcmp_le_un (double a, double b) MONO_INTERNAL;
140 gboolean mono_fcmp_lt_un (double a, double b) MONO_INTERNAL;
142 gboolean mono_fceq (double a, double b) MONO_INTERNAL;
144 gboolean mono_fcgt (double a, double b) MONO_INTERNAL;
146 gboolean mono_fcgt_un (double a, double b) MONO_INTERNAL;
148 gboolean mono_fclt (double a, double b) MONO_INTERNAL;
150 gboolean mono_fclt_un (double a, double b) MONO_INTERNAL;
152 gboolean mono_isfinite (double a) MONO_INTERNAL;
154 double mono_fload_r4 (float *ptr) MONO_INTERNAL;
156 void mono_fstore_r4 (double val, float *ptr) MONO_INTERNAL;
158 guint32 mono_fload_r4_arg (double val) MONO_INTERNAL;
160 void mono_break (void) MONO_INTERNAL;
162 MonoException *mono_create_corlib_exception_0 (guint32 token) MONO_INTERNAL;
164 MonoException *mono_create_corlib_exception_1 (guint32 token, MonoString *arg) MONO_INTERNAL;
166 MonoException *mono_create_corlib_exception_2 (guint32 token, MonoString *arg1, MonoString *arg2) MONO_INTERNAL;
168 MonoObject* mono_object_castclass (MonoObject *obj, MonoClass *klass) MONO_INTERNAL;
170 gpointer mono_get_native_calli_wrapper (MonoImage *image, MonoMethodSignature *sig, gpointer func) MONO_INTERNAL;
172 MonoObject*
173 mono_object_isinst_with_cache (MonoObject *obj, MonoClass *klass, gpointer *cache);
175 MonoObject*
176 mono_object_castclass_with_cache (MonoObject *obj, MonoClass *klass, gpointer *cache);
178 MonoObject* mono_object_tostring_gsharedvt (gpointer mp, MonoMethod *cmethod, MonoClass *klass) MONO_INTERNAL;
180 int mono_object_gethashcode_gsharedvt (gpointer mp, MonoMethod *cmethod, MonoClass *klass) MONO_INTERNAL;
182 #endif /* __MONO_JIT_ICALLS_H__ */