[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[dotgnu-pnet-commits] pnet ChangeLog engine/cvm.h engine/cvm_inline.c...
From: |
Klaus Treichel |
Subject: |
[dotgnu-pnet-commits] pnet ChangeLog engine/cvm.h engine/cvm_inline.c... |
Date: |
Thu, 21 Aug 2008 12:20:42 +0000 |
CVSROOT: /cvsroot/dotgnu-pnet
Module name: pnet
Changes by: Klaus Treichel <ktreichel> 08/08/21 12:20:41
Modified files:
. : ChangeLog
engine : cvm.h cvm_inline.c cvmc_call.c jitc.c
jitc_call.c lib_array.c lib_defs.h null_coder.c
verify.c verify_call.c verify_except.c
include : il_coder.h
Log message:
Add inlining for Array.Copy and Array.Clear for vectors where
compatibility
can be verified during code generation.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/pnet/ChangeLog?cvsroot=dotgnu-pnet&r1=1.3562&r2=1.3563
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/cvm.h?cvsroot=dotgnu-pnet&r1=1.57&r2=1.58
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/cvm_inline.c?cvsroot=dotgnu-pnet&r1=1.21&r2=1.22
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/cvmc_call.c?cvsroot=dotgnu-pnet&r1=1.38&r2=1.39
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/jitc.c?cvsroot=dotgnu-pnet&r1=1.83&r2=1.84
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/jitc_call.c?cvsroot=dotgnu-pnet&r1=1.41&r2=1.42
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/lib_array.c?cvsroot=dotgnu-pnet&r1=1.32&r2=1.33
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/lib_defs.h?cvsroot=dotgnu-pnet&r1=1.29&r2=1.30
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/null_coder.c?cvsroot=dotgnu-pnet&r1=1.31&r2=1.32
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/verify.c?cvsroot=dotgnu-pnet&r1=1.53&r2=1.54
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/verify_call.c?cvsroot=dotgnu-pnet&r1=1.59&r2=1.60
http://cvs.savannah.gnu.org/viewcvs/pnet/engine/verify_except.c?cvsroot=dotgnu-pnet&r1=1.15&r2=1.16
http://cvs.savannah.gnu.org/viewcvs/pnet/include/il_coder.h?cvsroot=dotgnu-pnet&r1=1.57&r2=1.58
Patches:
Index: ChangeLog
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/ChangeLog,v
retrieving revision 1.3562
retrieving revision 1.3563
diff -u -b -r1.3562 -r1.3563
--- ChangeLog 18 Aug 2008 18:48:08 -0000 1.3562
+++ ChangeLog 21 Aug 2008 12:20:34 -0000 1.3563
@@ -1,3 +1,44 @@
+2008-08-21 Klaus Treichel <address@hidden>
+
+ * engine/cvm.h: Add opcodes for inlining array copy and clear for
vectors
+ where the elements can be verified at code generation time.
+
+ * engine/cvm_inline.c: Implement the new opcodes.
+
+ * engine/cvmc_call.c (CVMCoder_CallInlineable): Add the new argument
+ elementSize. Add codegeneration for the new opcodes.
+
+ * engine/jitc.c (ILJitInit): Create the signatures for the new array
+ functions.
+
+ * engine(jitc_call.c (JITCoder_CallInlineable): Add the new argument
+ elementSize. Add codegeneration for calling the new inlined functions.
+
+ * engine/lib_array.c (ValidateCopyArgs_AAI4, ValidateCopyArgs_AI4AI4I4,
+ ValidateClearArgs_AI4I4, ILSArrayCopy_AAI4, ILSArrayCopy_AI4AI4I4,
+ ILSArrayClear_AI4I4): Add functions to support Array.Copy and
Array.Clear
+ for vectors where the elements have been verified during verification
+ time.
+
+ * engine/lib_defs.h (ILSArrayCopy_AAI4, ILSArrayCopy_AI4AI4I4,
+ ILSArrayClear_AI4I4): Add prototypes.
+
+ * engine/null_coder.c (Coder_CallInlineable): Add the new argument
+ elementSize.
+
+ * engine/verify.c (PUSH_SYNC_OBJECT, _ILVerify): Add the new argument
+ elementSize to the calls of ILCoderCallInlineable with the value 0.
+
+ * engine/verify_except.c (OutputExceptionTable, IL_OP_THROW): likewise.
+
+ * engine/verify_call.c (IL_OP_RET): likewise.
+ (IL_OP_CALL): Handle the new inlines for Array.Copy and Array.Clear.
+ (GetArrayCopyHandler, GetArrayClearHandler): Add support functions to
+ verify array types.
+
+ * include/il_coder.h: Add the new inline functions for Array.Copy and
+ Array.Clear. Add argument elementSize to ILCoderCallInlineable.
+
2008-08-18 Klaus Treichel <address@hidden>
* engine/jitc.c (_ILJitOnDemandDriver): Add check if the current
function
Index: engine/cvm.h
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/cvm.h,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -b -r1.57 -r1.58
--- engine/cvm.h 14 Sep 2007 00:55:42 -0000 1.57
+++ engine/cvm.h 21 Aug 2008 12:20:35 -0000 1.58
@@ -577,16 +577,23 @@
#define COP_PREFIX_UNROLL_STACK_RETURN 0x8C
/*
-* Replace a word in the stack.
-*/
+ * Replace a word in the stack.
+ */
#define COP_PREFIX_REPL_WORD_N 0x8D
/*
-* Used to called an instance of a virtual generic method.
-*/
+ * Used to called an instance of a virtual generic method.
+ */
#define COP_PREFIX_CALL_VIRTGEN 0x8E
/*
+ * Some inlined array functions
+ */
+#define COP_PREFIX_SARRAY_COPY_AAI4 0x8F
+#define COP_PREFIX_SARRAY_COPY_AI4AI4I4 0x90
+#define COP_PREFIX_SARRAY_CLEAR_AI4I4 0x91
+
+/*
* Definition of a CVM stack word which can hold
* either 32-bit quantities or pointers.
*/
Index: engine/cvm_inline.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/cvm_inline.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -b -r1.21 -r1.22
--- engine/cvm_inline.c 13 Nov 2006 18:06:09 -0000 1.21
+++ engine/cvm_inline.c 21 Aug 2008 12:20:36 -0000 1.22
@@ -532,6 +532,113 @@
VMBREAK(COP_PREFIX_IS_WHITE_SPACE);
/**
+ * <opcode name="copy_AAi4" group="Inline methods">
+ * <operation>copy elements from one vector to an other</operation>
+ *
+ * <format>prefix<fsep/>copy_AAi4</format>
+ * <dformat>{copy_AAi4}</dformat>
+ *
+ * <form name="copy_AAi4" code="COP_PREFIX_SARRAY_COPY_AAI4"/>
+ *
+ * <before>..., src, dest, length</before>
+ * <after>..., </after>
+ *
+ * <description>The <i>src</i>, <i>dest</i> and <i>length</i>are
+ * popped from the stack as the types <code>ptr</code>, <code>ptr</code>
+ * and <code>int32</code> respectively. <i>Length</i> elements are copied
+ * from <i>dest</i> to <i>src</i> starting at index 0.</description>
+ *
+ * <notes>This instruction is used to inline calls to the
+ * <code>Array.Copy(src, dest, length)</code> method where the elements
+ * of the arrays can be determined at verification time.</notes>
+ * </opcode>
+ */
+VMCASE(COP_PREFIX_SARRAY_COPY_AAI4):
+{
+ COPY_STATE_TO_THREAD();
+ ILSArrayCopy_AAI4(thread,
+ (System_Array *)stacktop[-3].ptrValue,
+ (System_Array *)stacktop[-2].ptrValue,
+ stacktop[-1].intValue, CVM_ARG_WORD);
+ RESTORE_STATE_FROM_THREAD();
+ MODIFY_PC_AND_STACK(CVMP_LEN_WORD, -3);
+}
+VMBREAK(COP_PREFIX_SARRAY_COPY_AAI4);
+
+/**
+ * <opcode name="copy_Ai4Ai4i4" group="Inline methods">
+ * <operation>copy elements from one vector to an other</operation>
+ *
+ * <format>prefix<fsep/>copy_Ai4Ai4i4</format>
+ * <dformat>{copy_Ai4Ai4i4}</dformat>
+ *
+ * <form name="copy_Ai4Ai4i4" code="COP_PREFIX_SARRAY_COPY_AI4AI4I4"/>
+ *
+ * <before>..., src, srcIndex, dest, destIndex, length</before>
+ * <after>..., </after>
+ *
+ * <description>The <i>src</i>, <i>srcIndex</i>, <i>dest</i>,
+ * <i>destIndex</i> and <i>length</i> are popped from the stack as the
+ * types <code>ptr</code>, <code>int32</code>, <code>ptr</code>,
+ * <code>int32</code> and <code>int32</code> respectively.
+ * <i>Length</i> elements are copied from <i>dest</i> starting at
+ * <i>destIndex</i> to <i>src</i> starting at <i>srcIndex</i>.</description>
+ *
+ * <notes>This instruction is used to inline calls to the
+ * <code>Array.Copy(src, srcIndex, dest, destIndex, length)</code> method
+ * where the elements of the arrays can be determined at verification time.
+ * </notes>
+ * </opcode>
+ */
+VMCASE(COP_PREFIX_SARRAY_COPY_AI4AI4I4):
+{
+ COPY_STATE_TO_THREAD();
+ ILSArrayCopy_AI4AI4I4(thread,
+ (System_Array
*)stacktop[-5].ptrValue,
+ stacktop[-4].intValue,
+ (System_Array
*)stacktop[-3].ptrValue,
+ stacktop[-2].intValue,
+ stacktop[-1].intValue,
CVM_ARG_WORD);
+ RESTORE_STATE_FROM_THREAD();
+ MODIFY_PC_AND_STACK(CVMP_LEN_WORD, -5);
+}
+VMBREAK(COP_PREFIX_SARRAY_COPY_AI4AI4I4);
+
+/**
+ * <opcode name="clear_Ai4I4" group="Inline methods">
+ * <operation>clear elements in a vector</operation>
+ *
+ * <format>prefix<fsep/>clear_Ai4I4</format>
+ * <dformat>{clear_Ai4I4}</dformat>
+ *
+ * <form name="clear_Ai4I4" code="COP_PREFIX_SARRAY_CLEAR_AI4I4"/>
+ *
+ * <before>..., array, index, length</before>
+ * <after>..., </after>
+ *
+ * <description>The <i>array</i>, <i>index</i> and <i>length</i>are
+ * popped from the stack as the types <code>ptr</code>, <code>int32</code>
+ * and <code>int32</code> respectively. <i>Length</i> elements are cleared
+ * (set to 0) in <i>array</i> starting at <i>index</i>.</description>
+ *
+ * <notes>This instruction is used to inline calls to the
+ * <code>Array.Clear(array, index, length)</code> method where the element
+ * of the array can be determined at verification time.</notes>
+ * </opcode>
+ */
+VMCASE(COP_PREFIX_SARRAY_CLEAR_AI4I4):
+{
+ COPY_STATE_TO_THREAD();
+ ILSArrayClear_AI4I4(thread,
+ (System_Array
*)stacktop[-3].ptrValue,
+ stacktop[-2].intValue,
+ stacktop[-1].intValue,
CVM_ARG_WORD);
+ RESTORE_STATE_FROM_THREAD();
+ MODIFY_PC_AND_STACK(CVMP_LEN_WORD, -3);
+}
+VMBREAK(COP_PREFIX_SARRAY_CLEAR_AI4I4);
+
+/**
* <opcode name="abs_i4" group="Inline methods">
* <operation>Compute the absolute value of an int</operation>
*
Index: engine/cvmc_call.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/cvmc_call.c,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -b -r1.38 -r1.39
--- engine/cvmc_call.c 14 Sep 2007 00:55:42 -0000 1.38
+++ engine/cvmc_call.c 21 Aug 2008 12:20:37 -0000 1.39
@@ -237,7 +237,7 @@
return 1;
static int CVMCoder_CallInlineable(ILCoder *coder, int inlineType,
- ILMethod
*methodInfo)
+ ILMethod
*methodInfo, ILInt32 elementSize)
{
/* Determine what to do for the inlineable method type */
switch(inlineType)
@@ -278,7 +278,7 @@
{
/* The string length is at a fixed offset from the
pointer */
CVM_OUT_BYTE(COP_IREAD_FIELD,
- (unsigned)&(((System_String
*)0)->length));
+
(unsigned)(ILNativeUInt)&(((System_String *)0)->length));
return 1;
}
/* Not reached */
@@ -411,6 +411,30 @@
}
/* Not reached */
+ case IL_INLINEMETHOD_ARRAY_COPY_AAI4:
+ {
+ CVMP_OUT_WORD(COP_PREFIX_SARRAY_COPY_AAI4, elementSize);
+ CVM_ADJUST(-3);
+ return 1;
+ }
+ /* Not reached */
+
+ case IL_INLINEMETHOD_ARRAY_COPY_AI4AI4I4:
+ {
+ CVMP_OUT_WORD(COP_PREFIX_SARRAY_COPY_AI4AI4I4,
elementSize);
+ CVM_ADJUST(-5);
+ return 1;
+ }
+ /* Not reached */
+
+ case IL_INLINEMETHOD_ARRAY_CLEAR_AI4I4:
+ {
+ CVMP_OUT_WORD(COP_PREFIX_SARRAY_CLEAR_AI4I4,
elementSize);
+ CVM_ADJUST(-3);
+ return 1;
+ }
+ /* Not reached */
+
/*
* Cases for Math class inlines.
*/
Index: engine/jitc.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/jitc.c,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -b -r1.83 -r1.84
--- engine/jitc.c 18 Aug 2008 10:34:54 -0000 1.83
+++ engine/jitc.c 21 Aug 2008 12:20:37 -0000 1.84
@@ -325,6 +325,29 @@
static ILJitType _ILJitSignature_ILInterlockedIncrement = 0;
/*
+ * ILInt32 ILSArrayCopy_AAI4(ILExecThread *thread, System_Array *array1,
+ * System_Array *array2,
ILInt32 length,
+ * ILInt32 elementSize)
+ */
+static ILJitType _ILJitSignature_ILSArrayCopy_AAI4 = 0;
+
+/*
+ * ILInt32 ILSArrayCopy_AI4AI4I4(ILExecThread *thread,
+ * System_Array
*array1, ILInt32 index1,
+ * System_Array
*array2, ILInt32 index2,
+ * ILInt32 length,
+ * ILInt32
elementSize)
+ */
+static ILJitType _ILJitSignature_ILSArrayCopy_AI4AI4I4 = 0;
+
+/*
+ * ILInt32 ILSArrayClear_AI4I4(ILExecThread *thread, System_Array *array,
+ * ILInt32 index,
ILInt32 length,
+ * ILInt32 elementSize)
+ */
+static ILJitType _ILJitSignature_ILSArrayClear_AI4I4 = 0;
+
+/*
* void ILJitTraceIn(ILExecThread *thread, ILMethod *method)
* void ILJitTraceOut(ILExecThread *thread, ILMethod *method)
*/
@@ -2215,7 +2238,7 @@
int ILJitInit()
{
ILJitType returnType;
- ILJitType args[4];
+ ILJitType args[7];
/* Initialize libjit */
jit_init();
@@ -2531,6 +2554,44 @@
return 0;
}
+ args[0] = _IL_JIT_TYPE_VPTR;
+ args[1] = _IL_JIT_TYPE_VPTR;
+ args[2] = _IL_JIT_TYPE_VPTR;
+ args[3] = _IL_JIT_TYPE_INT32;
+ args[4] = _IL_JIT_TYPE_INT32;
+ returnType = _IL_JIT_TYPE_INT32;
+ if(!(_ILJitSignature_ILSArrayCopy_AAI4 =
+ jit_type_create_signature(IL_JIT_CALLCONV_CDECL, returnType,
args, 5, 1)))
+ {
+ return 0;
+ }
+
+ args[0] = _IL_JIT_TYPE_VPTR;
+ args[1] = _IL_JIT_TYPE_VPTR;
+ args[2] = _IL_JIT_TYPE_INT32;
+ args[3] = _IL_JIT_TYPE_VPTR;
+ args[4] = _IL_JIT_TYPE_INT32;
+ args[5] = _IL_JIT_TYPE_INT32;
+ args[6] = _IL_JIT_TYPE_INT32;
+ returnType = _IL_JIT_TYPE_INT32;
+ if(!(_ILJitSignature_ILSArrayCopy_AI4AI4I4 =
+ jit_type_create_signature(IL_JIT_CALLCONV_CDECL, returnType,
args, 7, 1)))
+ {
+ return 0;
+ }
+
+ args[0] = _IL_JIT_TYPE_VPTR;
+ args[1] = _IL_JIT_TYPE_VPTR;
+ args[2] = _IL_JIT_TYPE_INT32;
+ args[3] = _IL_JIT_TYPE_INT32;
+ args[4] = _IL_JIT_TYPE_INT32;
+ returnType = _IL_JIT_TYPE_INT32;
+ if(!(_ILJitSignature_ILSArrayClear_AI4I4 =
+ jit_type_create_signature(IL_JIT_CALLCONV_CDECL, returnType,
args, 5, 1)))
+ {
+ return 0;
+ }
+
#if !defined(IL_CONFIG_REDUCE_CODE) && !defined(IL_WITHOUT_TOOLS)
args[0] = _IL_JIT_TYPE_VPTR;
args[1] = _IL_JIT_TYPE_VPTR;
Index: engine/jitc_call.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/jitc_call.c,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -b -r1.41 -r1.42
--- engine/jitc_call.c 21 Apr 2008 19:05:56 -0000 1.41
+++ engine/jitc_call.c 21 Aug 2008 12:20:38 -0000 1.42
@@ -1186,7 +1186,7 @@
}
static int JITCoder_CallInlineable(ILCoder *coder, int inlineType,
- ILMethod
*methodInfo)
+ ILMethod
*methodInfo, ILInt32 elementSize)
{
ILJITCoder *jitCoder = _ILCoderToILJITCoder(coder);
@@ -1687,6 +1687,103 @@
return 1;
}
/* Not reached */
+
+ case IL_INLINEMETHOD_ARRAY_COPY_AAI4:
+ {
+ _ILJitStackItemNew(stackItem1);
+ _ILJitStackItemNew(stackItem2);
+ _ILJitStackItemNew(stackItem3);
+ ILJitValue args[5];
+
+ _ILJitStackPop(jitCoder, stackItem1);
+ _ILJitStackPop(jitCoder, stackItem2);
+ _ILJitStackPop(jitCoder, stackItem3);
+ args[0] = _ILJitCoderGetThread(jitCoder);
+ args[1] = _ILJitStackItemValue(stackItem3);
+ args[2] = _ILJitStackItemValue(stackItem2);
+ args[3] = _ILJitStackItemValue(stackItem1);
+ args[4] =
jit_value_create_nint_constant(jitCoder->jitFunction,
+
_IL_JIT_TYPE_INT32,
+
elementSize);
+
+ _ILJitBeginNativeCall(jitCoder->jitFunction, args[0]);
+ jit_insn_call_native(jitCoder->jitFunction,
+
"ILSArrayCopy_AAI4",
+
ILSArrayCopy_AAI4,
+
_ILJitSignature_ILSArrayCopy_AAI4,
+ args, 5, 0);
+ _ILJitEndNativeCall(jitCoder->jitFunction, args[0]);
+
+ return 1;
+ }
+ /* Not reached */
+
+ case IL_INLINEMETHOD_ARRAY_COPY_AI4AI4I4:
+ {
+ _ILJitStackItemNew(stackItem1);
+ _ILJitStackItemNew(stackItem2);
+ _ILJitStackItemNew(stackItem3);
+ _ILJitStackItemNew(stackItem4);
+ _ILJitStackItemNew(stackItem5);
+ ILJitValue args[7];
+
+ _ILJitStackPop(jitCoder, stackItem1);
+ _ILJitStackPop(jitCoder, stackItem2);
+ _ILJitStackPop(jitCoder, stackItem3);
+ _ILJitStackPop(jitCoder, stackItem4);
+ _ILJitStackPop(jitCoder, stackItem5);
+ args[0] = _ILJitCoderGetThread(jitCoder);
+ args[1] = _ILJitStackItemValue(stackItem5);
+ args[2] = _ILJitStackItemValue(stackItem4);
+ args[3] = _ILJitStackItemValue(stackItem3);
+ args[4] = _ILJitStackItemValue(stackItem2);
+ args[5] = _ILJitStackItemValue(stackItem1);
+ args[6] =
jit_value_create_nint_constant(jitCoder->jitFunction,
+
_IL_JIT_TYPE_INT32,
+
elementSize);
+
+ _ILJitBeginNativeCall(jitCoder->jitFunction, args[0]);
+ jit_insn_call_native(jitCoder->jitFunction,
+
"ILSArrayCopy_AI4AI4I4",
+
ILSArrayCopy_AI4AI4I4,
+
_ILJitSignature_ILSArrayCopy_AI4AI4I4,
+ args, 7, 0);
+ _ILJitEndNativeCall(jitCoder->jitFunction, args[0]);
+
+ return 1;
+ }
+ /* Not reached */
+
+ case IL_INLINEMETHOD_ARRAY_CLEAR_AI4I4:
+ {
+ _ILJitStackItemNew(stackItem1);
+ _ILJitStackItemNew(stackItem2);
+ _ILJitStackItemNew(stackItem3);
+ ILJitValue args[5];
+
+ _ILJitStackPop(jitCoder, stackItem1);
+ _ILJitStackPop(jitCoder, stackItem2);
+ _ILJitStackPop(jitCoder, stackItem3);
+
+ args[0] = _ILJitCoderGetThread(jitCoder);
+ args[1] = _ILJitStackItemValue(stackItem3);
+ args[2] = _ILJitStackItemValue(stackItem2);
+ args[3] = _ILJitStackItemValue(stackItem1);
+ args[4] =
jit_value_create_nint_constant(jitCoder->jitFunction,
+
_IL_JIT_TYPE_INT32,
+
elementSize);
+
+ _ILJitBeginNativeCall(jitCoder->jitFunction, args[0]);
+ jit_insn_call_native(jitCoder->jitFunction,
+
"ILSArrayClear_AI4I4",
+
ILSArrayClear_AI4I4,
+
_ILJitSignature_ILSArrayClear_AI4I4,
+ args, 5, 0);
+ _ILJitEndNativeCall(jitCoder->jitFunction, args[0]);
+
+ return 1;
+ }
+ /* Not reached */
}
/* If we get here, then we don't know how to inline the method */
return 0;
Index: engine/lib_array.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/lib_array.c,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -b -r1.32 -r1.33
--- engine/lib_array.c 17 Dec 2006 10:31:32 -0000 1.32
+++ engine/lib_array.c 21 Aug 2008 12:20:38 -0000 1.33
@@ -2557,6 +2557,227 @@
}
}
+/*
+ * Validate the arguments for a copy with array, array, length arguments.
+ */
+static int ValidateCopyArgs_AAI4(ILExecThread *thread,
+ System_Array
*array1,
+ System_Array
*array2,
+ ILInt32 length)
+{
+ if(!array1)
+ {
+ ILExecThreadThrowArgNull(thread, "sourceArray");
+ return 0;
+ }
+ if(!array2)
+ {
+ ILExecThreadThrowArgNull(thread, "destinationArray");
+ return 0;
+ }
+ if(length < 0)
+ {
+ ILExecThreadThrowArgRange(thread, "length",
"Arg_InvalidArrayIndex");
+ return 0;
+ }
+ if(array1 == array2)
+ {
+ /* We have nothing to do here but check the length anyways */
+ if(length > ArrayLength(array1))
+ {
+ ILExecThreadThrowSystem(thread,
"System.ArgumentException",
+
"Arg_InvalidArrayRange");
+ return 0;
+ }
+ }
+ else
+ {
+ if((length > ArrayLength(array1)) || (length >
ArrayLength(array2)))
+ {
+ ILExecThreadThrowSystem(thread,
"System.ArgumentException",
+
"Arg_InvalidArrayRange");
+ return 0;
+ }
+ }
+ return 1;
+}
+
+/*
+ * Validate the arguments for a copy with array, array, length arguments.
+ */
+static int ValidateCopyArgs_AI4AI4I4(ILExecThread *thread,
+
System_Array *array1,
+
ILInt32 index1,
+
System_Array *array2,
+
ILInt32 index2,
+
ILInt32 length)
+{
+ if(!array1)
+ {
+ ILExecThreadThrowArgNull(thread, "sourceArray");
+ return 0;
+ }
+ if(!array2)
+ {
+ ILExecThreadThrowArgNull(thread, "destinationArray");
+ return 0;
+ }
+ if(length < 0)
+ {
+ ILExecThreadThrowArgRange(thread, "length",
"Arg_InvalidArrayIndex");
+ return 0;
+ }
+ if(index1 < 0)
+ {
+ ILExecThreadThrowArgRange(thread, "sourceIndex",
"Arg_InvalidArrayIndex");
+ return 0;
+ }
+ if(index2 < 0)
+ {
+ ILExecThreadThrowArgRange(thread, "destinationIndex",
"Arg_InvalidArrayIndex");
+ return 0;
+ }
+ if(array1 == array2)
+ {
+ /* We have nothing to do here but check the length anyways */
+ if((index1 + length) > ArrayLength(array1))
+ {
+ ILExecThreadThrowSystem(thread,
"System.ArgumentException",
+
"Arg_InvalidArrayRange");
+ return 0;
+ }
+ }
+ else
+ {
+ if(((index1 + length) > ArrayLength(array1)) ||
+ ((index2 + length) > ArrayLength(array2)))
+ {
+ ILExecThreadThrowSystem(thread,
"System.ArgumentException",
+
"Arg_InvalidArrayRange");
+ return 0;
+ }
+ }
+ return 1;
+}
+
+/*
+ * Validate the arguments for a copy with array, array, length arguments.
+ */
+static int ValidateClearArgs_AI4I4(ILExecThread *thread,
+ System_Array
*array,
+ ILInt32
index,
+ ILInt32
length)
+{
+ if(!array)
+ {
+ ILExecThreadThrowArgNull(thread, "array");
+ return 0;
+ }
+ if(index < 0)
+ {
+ ILExecThreadThrowArgRange(thread, "index",
"Arg_InvalidArrayIndex");
+ return 0;
+ }
+ if(length < 0)
+ {
+ ILExecThreadThrowArgRange(thread, "length",
"Arg_InvalidArrayIndex");
+ return 0;
+ }
+ if((index + length) > ArrayLength(array))
+ {
+ ILExecThreadThrowSystem(thread, "System.ArgumentException",
+
"Arg_InvalidArrayRange");
+ return 0;
+ }
+ return 1;
+}
+
+/*
+ * Internal versions for Array.Copy(System.Array, System.Array, int) where the
+ * types of the arrays are known at verification time, the element types
+ * are known to be assignment compatible and the sizes of the elements are the
+ * same so that copying can be done with memcpy or memmove.
+ */
+ILInt32 ILSArrayCopy_AAI4(ILExecThread *thread,
+ System_Array *array1,
+ System_Array *array2,
+ ILInt32 length,
+ ILInt32 elementSize)
+{
+ if(ValidateCopyArgs_AAI4(thread, array1, array2, length))
+ {
+ if(array1 != array2)
+ {
+ void *base1 = ArrayToBuffer(array1);
+ void *base2 = ArrayToBuffer(array2);
+
+ ILMemCpy(base2, base1, length * elementSize);
+ }
+ return 1;
+ }
+ return 0;
+}
+
+/*
+ * Function for Array.Copy(System.Array, int, System.Array, int, int) where the
+ * types of the arrays are known at verification time, the element types
+ * are known to be assignment compatible and the sizes of the elements are the
+ * same so that copying can be done with memcpy or memmove.
+ */
+ILInt32 ILSArrayCopy_AI4AI4I4(ILExecThread *thread,
+ System_Array *array1,
+ ILInt32 index1,
+ System_Array *array2,
+ ILInt32 index2,
+ ILInt32 length,
+ ILInt32 elementSize)
+{
+ if(ValidateCopyArgs_AI4AI4I4(thread, array1, index1, array2, index2,
length))
+ {
+ ILInt8 *base1 = ArrayToBuffer(array1);
+ ILInt8 *base2 = ArrayToBuffer(array2);
+
+ if((array1 != array2) || ((index1 + length) < index2) ||
+ (index1 >
(index2 + length)))
+ {
+ /* Arrays are not the same or the ranges do not overlap
*/
+ ILMemCpy(&(base2[index2 * elementSize]),
+ &(base1[index1 * elementSize]),
+ length * elementSize);
+ }
+ else
+ {
+ /* Ranges overlap */
+ ILMemMove(&(base2[index2 * elementSize]),
+ &(base1[index1 * elementSize]),
+ length * elementSize);
+ }
+ return 1;
+ }
+ return 0;
+}
+
+/*
+ * Function for Array.Clear(System.Array, int, int) where the type of the
+ * array is known at verification time and it is zero based one dimensional.
+ */
+ILInt32 ILSArrayClear_AI4I4(ILExecThread *thread,
+ System_Array *array,
+ ILInt32 index,
+ ILInt32 length,
+ ILInt32 elementSize)
+{
+ if(ValidateClearArgs_AI4I4(thread, array, index, length))
+ {
+ ILInt8 *base = ArrayToBuffer(array);
+
+ ILMemZero(&(base[index * elementSize]),
+ length * elementSize);
+ return 1;
+ }
+ return 0;
+}
+
#ifdef IL_CONFIG_NON_VECTOR_ARRAYS
int _ILIsMArray(System_Array *array)
Index: engine/lib_defs.h
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/lib_defs.h,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -b -r1.29 -r1.30
--- engine/lib_defs.h 17 Dec 2006 10:31:32 -0000 1.29
+++ engine/lib_defs.h 21 Aug 2008 12:20:39 -0000 1.30
@@ -219,6 +219,44 @@
*/
ILObject *_ILCloneSArray(ILExecThread *thread, System_Array *array);
+/*
+ * Fuction for the engine for Array.Copy(System.Array, System.Array, Int32)
+ * where the arrays are known to be one dimensional zero based, elemment types
+ * are assignment compatible and of the same size so that copying can be one
+ * with memcpy.
+ * Return 0 if an exception was thrown and 1 if successfull.
+ */
+ILInt32 ILSArrayCopy_AAI4(ILExecThread *thread,
+ System_Array *array1,
+ System_Array *array2,
+ ILInt32 length,
+ ILInt32 elementSize);
+
+
+/*
+ * Function for Array.Copy(System.Array, int, System.Array, int, int) where the
+ * types of the arrays are known at verification time, the element types
+ * are known to be assignment compatible and the sizes of the elements are the
+ * same so that copying can be done with memcpy or memmove.
+ */
+ILInt32 ILSArrayCopy_AI4AI4I4(ILExecThread *thread,
+ System_Array *array1,
+ ILInt32 index1,
+ System_Array *array2,
+ ILInt32 index2,
+ ILInt32 length,
+ ILInt32 elementSize);
+
+/*
+ * Function for Array.Clear(System.Array, int, int) where the type of the
+ * array is known at verification time and it is zero based one dimensional.
+ */
+ILInt32 ILSArrayClear_AI4I4(ILExecThread *thread,
+ System_Array *array,
+ ILInt32 index,
+ ILInt32 length,
+ ILInt32 elementSize);
+
#ifdef IL_CONFIG_NON_VECTOR_ARRAYS
/*
Index: engine/null_coder.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/null_coder.c,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -b -r1.31 -r1.32
--- engine/null_coder.c 7 Oct 2007 19:20:12 -0000 1.31
+++ engine/null_coder.c 21 Aug 2008 12:20:39 -0000 1.32
@@ -307,7 +307,7 @@
{
}
static int Coder_CallInlineable(ILCoder *coder, int inlineType,
- ILMethod
*methodInfo)
+ ILMethod
*methodInfo, ILInt32 elementSize)
{
return 0;
}
Index: engine/verify.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/verify.c,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -b -r1.53 -r1.54
--- engine/verify.c 14 Sep 2007 00:55:42 -0000 1.53
+++ engine/verify.c 21 Aug 2008 12:20:40 -0000 1.54
@@ -581,7 +581,7 @@
if (isStatic) \
{ \
ILCoderPushToken(coder, (ILProgramItem
*)ILMethod_Owner(method)); \
- ILCoderCallInlineable(coder, IL_INLINEMETHOD_TYPE_FROM_HANDLE,
0); \
+ ILCoderCallInlineable(coder, IL_INLINEMETHOD_TYPE_FROM_HANDLE,
0, 0); \
} \
else \
{ \
@@ -1060,7 +1060,7 @@
if (isSynchronized)
{
PUSH_SYNC_OBJECT();
- ILCoderCallInlineable(coder, IL_INLINEMETHOD_MONITOR_ENTER, 0);
+ ILCoderCallInlineable(coder, IL_INLINEMETHOD_MONITOR_ENTER, 0,
0);
}
while(len > 0)
Index: engine/verify_call.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/verify_call.c,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -b -r1.59 -r1.60
--- engine/verify_call.c 14 Sep 2007 00:55:42 -0000 1.59
+++ engine/verify_call.c 21 Aug 2008 12:20:40 -0000 1.60
@@ -39,6 +39,35 @@
#define V_INLINE_FIELD_STORE (2)
#define V_INLINE_CONST_LOAD (3)
+#define TYPE_IS_I1(type) \
+ (((type) == ILType_Boolean) || ((type) == ILType_Int8) || \
+ ((type) == ILType_UInt8))
+
+#define TYPE_IS_I2(type) \
+ (((type) == ILType_Char) || ((type) == ILType_Int16) || \
+ ((type) == ILType_UInt16))
+
+#ifdef IL_NATIVE_INT64
+#define TYPE_IS_I4(type) \
+ (((type) == ILType_Int32) || ((type) == ILType_UInt32))
+
+#define TYPE_IS_I8(type) \
+ (((type) == ILType_Int) || ((type) == ILType_Int64) || \
+ ((type) == ILType_UInt64))
+#else /* !IL_NATIVE_INT64 */
+#define TYPE_IS_I4(type) \
+ (((type) == ILType_Int) || ((type) == ILType_Int32) || \
+ ((type) == ILType_UInt32))
+
+#define TYPE_IS_I8(type) \
+ (((type) == ILType_Int64) || ((type) == ILType_UInt64))
+#endif /* !IL_NATIVE_INT64 */
+
+/*
+ * Offsets to add to the base inline method to get the final inline method.
+ */
+#define ARRAY_INLINE_OFFSET_VECTORS (0)
+
static int TryInlineLoad(ILExecProcess *process, ILMethod *method, int
numParams,
ILMethodCode *code,
unsigned *inlineOpcode,
unsigned char
**inlinePc, ILField **field)
@@ -1259,6 +1288,15 @@
{"Char", "System", "IsWhiteSpace", "(c)Z",
IL_INLINEMETHOD_IS_WHITE_SPACE},
+ {"Array", "System", "Copy", "(oSystem.Array;oSystem.Array;i)V",
+ IL_INLINEMETHOD_ARRAY_COPY_AAI4},
+
+ {"Array", "System", "Copy", "(oSystem.Array;ioSystem.Array;ii)V",
+ IL_INLINEMETHOD_ARRAY_COPY_AI4AI4I4},
+
+ {"Array", "System", "Clear", "(oSystem.Array;ii)V",
+ IL_INLINEMETHOD_ARRAY_CLEAR_AI4I4},
+
{"Math", "System", "Abs", "(i)i", IL_INLINEMETHOD_ABS_I4},
{"Math", "System", "Max", "(ii)i", IL_INLINEMETHOD_MAX_I4},
{"Math", "System", "Min", "(ii)i", IL_INLINEMETHOD_MIN_I4},
@@ -1380,6 +1418,167 @@
}
/*
+ * Check if two items on the stack are arraytypes and the elements are
+ * assigncompatible for arrayelements.
+ * Array1 is the source and array2 the destination array.
+ */
+static int GetArrayCopyHandler(ILExecProcess *process,
+ ILMethod *method,
+ ILEngineStackItem
*array1,
+ ILEngineStackItem
*array2,
+ ILInt32 *elementSize)
+{
+ ILType *arrayType1;
+ ILType *arrayType2;
+
+ arrayType1 = array1->typeInfo;
+ arrayType2 = array2->typeInfo;
+
+ /* Check if the arrays are simple one dimensional arrays with a zero
+ lower bound */
+ if(ILType_IsSimpleArray(arrayType1) && ILType_IsSimpleArray(arrayType2))
+ {
+ ILType *elemType1;
+ ILType *elemType2;
+
+ elemType1 = ILTypeGetEnumType(ILType_ElemType(arrayType1));
+ elemType2 = ILType_ElemType(arrayType2);
+
+ if(ILType_IsPrimitive(elemType1) &&
ILType_IsPrimitive(elemType2))
+ {
+ /* Arrays are of primitive types */
+ if(TYPE_IS_I1(elemType1) && TYPE_IS_I1(elemType2))
+ {
+ *elementSize = sizeof(ILInt8);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(TYPE_IS_I2(elemType1) && TYPE_IS_I2(elemType2))
+ {
+ *elementSize = sizeof(ILInt16);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(TYPE_IS_I4(elemType1) && TYPE_IS_I4(elemType2))
+ {
+ *elementSize = sizeof(ILInt32);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(TYPE_IS_I8(elemType1) && TYPE_IS_I8(elemType2))
+ {
+ *elementSize = sizeof(ILInt64);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if((elemType1 == ILType_Float32) && (elemType2 ==
ILType_Float32))
+ {
+ *elementSize = sizeof(ILFloat);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if((elemType1 == ILType_Float64) && (elemType2 ==
ILType_Float64))
+ {
+ *elementSize = sizeof(ILDouble);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if((elemType1 == ILType_Float) && (elemType2 ==
ILType_Float))
+ {
+ *elementSize = sizeof(ILNativeFloat);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ }
+ else if(ILType_IsValueType(elemType1) &&
ILType_IsValueType(elemType2))
+ {
+ /* For value types the types must be identical */
+ if(elemType1 == elemType2)
+ {
+ *elementSize = _ILSizeOfTypeLocked(process,
elemType1);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ }
+ else if(ILType_IsClass(elemType1) && ILType_IsClass(elemType2))
+ {
+
if(ILTypeAssignCompatibleNonBoxing(ILProgramItem_Image(method),
+
elemType1, elemType2))
+ {
+ *elementSize = sizeof(ILNativeInt);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ }
+
+ }
+
+ return -1;
+}
+
+static int GetArrayClearHandler(ILExecProcess *process,
+ ILMethod
*method,
+
ILEngineStackItem *array,
+ ILInt32
*elementSize)
+{
+ ILType *arrayType;
+
+ arrayType = array->typeInfo;
+
+ /* Check if the array is a simple one dimensional array with a zero
+ lower bound */
+ if(ILType_IsSimpleArray(arrayType))
+ {
+ ILType *elemType;
+
+ elemType = ILTypeGetEnumType(ILType_ElemType(arrayType));
+
+ if(ILType_IsPrimitive(elemType))
+ {
+ /* Arrays are of primitive types */
+ if(TYPE_IS_I1(elemType))
+ {
+ *elementSize = sizeof(ILInt8);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(TYPE_IS_I2(elemType))
+ {
+ *elementSize = sizeof(ILInt16);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(TYPE_IS_I4(elemType))
+ {
+ *elementSize = sizeof(ILInt32);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(TYPE_IS_I8(elemType))
+ {
+ *elementSize = sizeof(ILInt64);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(elemType == ILType_Float32)
+ {
+ *elementSize = sizeof(ILFloat);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(elemType == ILType_Float64)
+ {
+ *elementSize = sizeof(ILDouble);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(elemType == ILType_Float)
+ {
+ *elementSize = sizeof(ILNativeFloat);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ }
+ else if(ILType_IsValueType(elemType))
+ {
+ *elementSize = _ILSizeOfTypeLocked(process, elemType);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ else if(ILType_IsClass(elemType))
+ {
+ *elementSize = sizeof(ILNativeInt);
+ return ARRAY_INLINE_OFFSET_VECTORS;
+ }
+ }
+
+ return -1;
+}
+
+/*
* Set return type information within a stack item.
*/
static void SetReturnType(ILEngineStackItem *item, ILType *returnType)
@@ -1476,10 +1675,84 @@
|
IL_CODER_FLAG_METHOD_PROFILE
|
IL_CODER_FLAG_METHOD_TRACE)) == 0)
{
+ ILInt32 elementSize = 0;
+
inlineType =
GetInlineMethodType(methodInfo);
+ switch(inlineType)
+ {
+ case
IL_INLINEMETHOD_ARRAY_COPY_AAI4:
+ {
+ /* Check if the types
of the arrays are known */
+ int inlineOffset;
+
+ inlineOffset =
GetArrayCopyHandler(
+
_ILExecThreadProcess(thread),
+
method,
+
&(stack[stackSize - numParams]),
+
&(stack[stackSize - numParams + 1]),
+
&elementSize);
+
+ if(inlineOffset >= 0)
+ {
+ inlineType +=
inlineOffset;
+ }
+ else
+ {
+ inlineType = -1;
+ }
+ }
+ break;
+
+ case
IL_INLINEMETHOD_ARRAY_COPY_AI4AI4I4:
+ {
+ /* Check if the types
of the arrays are known */
+ int inlineOffset;
+
+ inlineOffset =
GetArrayCopyHandler(
+
_ILExecThreadProcess(thread),
+
method,
+
&(stack[stackSize - numParams]),
+
&(stack[stackSize - numParams + 2]),
+
&elementSize);
+
+ if(inlineOffset >= 0)
+ {
+ inlineType +=
inlineOffset;
+ }
+ else
+ {
+ inlineType = -1;
+ }
+ }
+ break;
+
+ case
IL_INLINEMETHOD_ARRAY_CLEAR_AI4I4:
+ {
+ /* Check if the types
of the arrays are known */
+ int inlineOffset;
+
+ inlineOffset =
GetArrayClearHandler(
+
_ILExecThreadProcess(thread),
+
method,
+
&(stack[stackSize - numParams]),
+
&elementSize);
+
+ if(inlineOffset >= 0)
+ {
+ inlineType +=
inlineOffset;
+ }
+ else
+ {
+ inlineType = -1;
+ }
+ }
+ break;
+ }
+
if (inlineType != -1
- && ILCoderCallInlineable(coder,
inlineType, methodInfo))
+ && ILCoderCallInlineable(coder,
inlineType,
+
methodInfo, elementSize))
{
#if !defined(IL_CONFIG_REDUCE_CODE) && !defined(IL_WITHOUT_TOOLS)
if (coderFlags &
IL_CODER_FLAG_STATS)
@@ -1976,7 +2249,7 @@
if (isSynchronized)
{
PUSH_SYNC_OBJECT();
- ILCoderCallInlineable(coder,
IL_INLINEMETHOD_MONITOR_EXIT, 0);
+ ILCoderCallInlineable(coder,
IL_INLINEMETHOD_MONITOR_EXIT, 0, 0);
}
/* Notify the coder of the return instruction */
@@ -1990,7 +2263,7 @@
if (isSynchronized)
{
PUSH_SYNC_OBJECT();
- ILCoderCallInlineable(coder,
IL_INLINEMETHOD_MONITOR_EXIT, 0);
+ ILCoderCallInlineable(coder,
IL_INLINEMETHOD_MONITOR_EXIT, 0, 0);
}
/* Notify the coder of a non-value return instruction */
Index: engine/verify_except.c
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/engine/verify_except.c,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -b -r1.15 -r1.16
--- engine/verify_except.c 30 May 2004 10:04:00 -0000 1.15
+++ engine/verify_except.c 21 Aug 2008 12:20:41 -0000 1.16
@@ -124,7 +124,7 @@
/* Exit the sync lock before throwing to the calling method */
isStatic = ILMethod_IsStatic(method);
PUSH_SYNC_OBJECT();
- ILCoderCallInlineable(coder, IL_INLINEMETHOD_MONITOR_EXIT, 0);
+ ILCoderCallInlineable(coder, IL_INLINEMETHOD_MONITOR_EXIT, 0,
0);
}
ILCoderThrow(coder, 0);
@@ -238,7 +238,7 @@
if (isSynchronized)
{
PUSH_SYNC_OBJECT();
- ILCoderCallInlineable(coder,
IL_INLINEMETHOD_MONITOR_EXIT, 0);
+ ILCoderCallInlineable(coder,
IL_INLINEMETHOD_MONITOR_EXIT, 0, 0);
}
ILCoderThrow(coder, 0);
Index: include/il_coder.h
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnet/include/il_coder.h,v
retrieving revision 1.57
retrieving revision 1.58
diff -u -b -r1.57 -r1.58
--- include/il_coder.h 7 Oct 2007 19:20:11 -0000 1.57
+++ include/il_coder.h 21 Aug 2008 12:20:41 -0000 1.58
@@ -147,6 +147,10 @@
#define IL_INLINEMETHOD_ABS_I4 46
#define IL_INLINEMETHOD_ABS_R4 47
#define IL_INLINEMETHOD_ABS_R8 48
+#define IL_INLINEMETHOD_ARRAY_COPY_AAI4 49
+#define IL_INLINEMETHOD_ARRAY_COPY_AI4AI4I4 50
+#define IL_INLINEMETHOD_ARRAY_CLEAR_AI4I4 51
+
/*
* Return values for "ILCoderFinish".
*/
@@ -627,7 +631,8 @@
* Call an inlineable method. Returns zero if the coder
* cannot inline the method.
*/
- int (*callInlineable)(ILCoder *coder, int inlineType, ILMethod
*methodInfo);
+ int (*callInlineable)(ILCoder *coder, int inlineType,
+ ILMethod *methodInfo, ILInt32
elementSize);
/*
* Jump to a method with the same signature as the current method.
@@ -1056,9 +1061,10 @@
((*((coder)->classInfo->callInterface))((coder),
(info), \
(returnItem), \
(methodInfo)))
-#define ILCoderCallInlineable(coder,inlineType,methodInfo) \
+#define ILCoderCallInlineable(coder,inlineType,methodInfo,elementSize) \
((*((coder)->classInfo->callInlineable))((coder),
(inlineType), \
-
(methodInfo)))
+
(methodInfo), \
+
(elementSize)))
#define ILCoderJumpMethod(coder,methodInfo) \
((*((coder)->classInfo->jumpMethod))((coder),
(methodInfo)))
#define ILCoderReturnInsn(coder,engineType,returnType) \
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [dotgnu-pnet-commits] pnet ChangeLog engine/cvm.h engine/cvm_inline.c...,
Klaus Treichel <=