[kaffe] CVS kaffe (robilad): use getMethodCodeStart and setMethodCodeStart consistently
Kaffe CVS
cvs-commits at kaffe.org
Sat Apr 22 16:51:04 PDT 2006
PatchSet 7264
Date: 2006/04/22 23:42:04
Author: robilad
Branch: HEAD
Tag: (none)
Log:
use getMethodCodeStart and setMethodCodeStart consistently
2006-04-23 Dalibor Topic <robilad at kaffe.org>
* kaffe/kaffevm/jit3/machine.c (installMethodCode),
kaffe/kaffevm/jit/machine.c (installMethodCode)
(installMethodCode),
kaffe/kaffevm/gcFuncs.c (destroyClass),
kaffe/kaffevm/classPool.c (statClass),
kaffe/kaffevm/classMethod.c (METHOD_TRUE_NCODE, processClass)
(processClass),
kaffe/jvmpi/jvmpi_kaffe.c (jvmpiFillMethodLoad):
Use getMethodCodeStart and setMethodCodeStart instead accessing
struct fields directly.
Members:
ChangeLog:1.4769->1.4770
kaffe/jvmpi/jvmpi_kaffe.c:1.19->1.20
kaffe/kaffevm/classMethod.c:1.155->1.156
kaffe/kaffevm/classPool.c:1.38->1.39
kaffe/kaffevm/gcFuncs.c:1.83->1.84
kaffe/kaffevm/jit/machine.c:1.85->1.86
kaffe/kaffevm/jit3/machine.c:1.82->1.83
Index: kaffe/ChangeLog
diff -u kaffe/ChangeLog:1.4769 kaffe/ChangeLog:1.4770
--- kaffe/ChangeLog:1.4769 Sat Apr 22 20:56:06 2006
+++ kaffe/ChangeLog Sat Apr 22 23:42:04 2006
@@ -1,3 +1,16 @@
+2006-04-23 Dalibor Topic <robilad at kaffe.org>
+
+ * kaffe/kaffevm/jit3/machine.c (installMethodCode),
+ kaffe/kaffevm/jit/machine.c (installMethodCode)
+ (installMethodCode),
+ kaffe/kaffevm/gcFuncs.c (destroyClass),
+ kaffe/kaffevm/classPool.c (statClass),
+ kaffe/kaffevm/classMethod.c (METHOD_TRUE_NCODE, processClass)
+ (processClass),
+ kaffe/jvmpi/jvmpi_kaffe.c (jvmpiFillMethodLoad):
+ Use getMethodCodeStart and setMethodCodeStart instead accessing
+ struct fields directly.
+
2006-04-22 Dalibor Topic <robilad at kaffe.org>
* kaffe/kaffevm/intrp/methodcalls.c (engine_dispatchException):
Index: kaffe/kaffe/jvmpi/jvmpi_kaffe.c
diff -u kaffe/kaffe/jvmpi/jvmpi_kaffe.c:1.19 kaffe/kaffe/jvmpi/jvmpi_kaffe.c:1.20
--- kaffe/kaffe/jvmpi/jvmpi_kaffe.c:1.19 Sun Apr 16 07:20:14 2006
+++ kaffe/kaffe/jvmpi/jvmpi_kaffe.c Sat Apr 22 23:42:06 2006
@@ -271,7 +271,7 @@
ev->u.compiled_method_load.method_id = xmeth;
ev->u.compiled_method_load.code_addr = METHOD_NATIVECODE(xmeth);
ev->u.compiled_method_load.code_size =
- (uintp)xmeth->c.ncode.ncode_end - (uintp)xmeth->c.ncode.ncode_start;
+ (uintp)xmeth->c.ncode.ncode_end - (uintp)getMethodCodeStart(xmeth);
if( xmeth->lines )
{
Index: kaffe/kaffe/kaffevm/classMethod.c
diff -u kaffe/kaffe/kaffevm/classMethod.c:1.155 kaffe/kaffe/kaffevm/classMethod.c:1.156
--- kaffe/kaffe/kaffevm/classMethod.c:1.155 Sat Apr 22 01:53:40 2006
+++ kaffe/kaffe/kaffevm/classMethod.c Sat Apr 22 23:42:06 2006
@@ -50,7 +50,7 @@
#include "methodcalls.h"
#if 0
-#define METHOD_TRUE_NCODE(METH) (METH)->c.ncode.ncode_start
+#define METHOD_TRUE_NCODE(METH) getMethodCodeStart(METH)
#define METHOD_PRE_COMPILED(METH) ((int16)(METH)->localsz < 0)
#define SET_METHOD_PRE_COMPILED(METH, VAL) ((METH)->localsz = -(VAL))
#endif
@@ -630,7 +630,7 @@
#if defined(TRANSLATOR) && (defined (MD_UNREGISTER_JIT_EXCEPTION_INFO) || defined (JIT3))
#if defined(MD_UNREGISTER_JIT_EXCEPTION_INFO)
if (exc == 0) {
- MD_UNREGISTER_JIT_EXCEPTION_INFO (meth->c.ncode.ncode_start,
+ MD_UNREGISTER_JIT_EXCEPTION_INFO (getMethodCodeStart(meth),
METHOD_NATIVECODE(meth),
meth->c.ncode.ncode_end);
}
@@ -645,7 +645,7 @@
#endif
1) {
_SET_METHOD_NATIVECODE(meth, NULL);
- meth->c.ncode.ncode_start = NULL;
+ setMethodCodeStart(meth, NULL);
meth->c.ncode.ncode_end = NULL;
}
}
Index: kaffe/kaffe/kaffevm/classPool.c
diff -u kaffe/kaffe/kaffevm/classPool.c:1.38 kaffe/kaffe/kaffevm/classPool.c:1.39
--- kaffe/kaffe/kaffevm/classPool.c:1.38 Sun Dec 18 10:39:55 2005
+++ kaffe/kaffe/kaffevm/classPool.c Sat Apr 22 23:42:06 2006
@@ -621,7 +621,7 @@
/* bytecode or jitted code */
if ((m->accflags & ACC_NATIVE) == 0) {
if (METHOD_TRANSLATED(m)) {
- jitmem += SIZE_IFNONZERO(m->c.ncode.ncode_start);
+ jitmem += SIZE_IFNONZERO(getMethodCodeStart(m));
} else {
bytecodemem += SIZE_IFNONZERO(m->c.bcode.code);
}
Index: kaffe/kaffe/kaffevm/gcFuncs.c
diff -u kaffe/kaffe/kaffevm/gcFuncs.c:1.83 kaffe/kaffe/kaffevm/gcFuncs.c:1.84
--- kaffe/kaffe/kaffevm/gcFuncs.c:1.83 Sat Jan 14 09:11:35 2006
+++ kaffe/kaffe/kaffevm/gcFuncs.c Sat Apr 22 23:42:06 2006
@@ -122,7 +122,7 @@
ncode = METHOD_NATIVECODE(m);
if (METHOD_JITTED(m)) {
#if defined(TRANSLATOR) && defined (MD_UNREGISTER_JIT_EXCEPTION_INFO)
- MD_UNREGISTER_JIT_EXCEPTION_INFO (m->c.ncode.ncode_start,
+ MD_UNREGISTER_JIT_EXCEPTION_INFO (getMethodCodeStart(m),
ncode,
m->c.ncode.ncode_end);
#endif
Index: kaffe/kaffe/kaffevm/jit/machine.c
diff -u kaffe/kaffe/kaffevm/jit/machine.c:1.85 kaffe/kaffe/kaffevm/jit/machine.c:1.86
--- kaffe/kaffe/kaffevm/jit/machine.c:1.85 Sat Jan 14 09:11:36 2006
+++ kaffe/kaffe/kaffevm/jit/machine.c Sat Apr 22 23:42:07 2006
@@ -575,7 +575,7 @@
/* install the jitted code */
SET_METHOD_JITCODE(meth, code->code);
- meth->c.ncode.ncode_start = code->mem;
+ setMethodCodeStart(meth, code->mem);
meth->c.ncode.ncode_end = (char*)code->code + code->codelen;
jch = (jitCodeHeader *)code->mem;
@@ -585,7 +585,7 @@
FLUSH_DCACHE(METHOD_NATIVECODE(meth), meth->c.ncode.ncode_end);
#if defined(MD_REGISTER_JIT_EXCEPTION_INFO)
- MD_REGISTER_JIT_EXCEPTION_INFO (meth->c.ncode.ncode_start,
+ MD_REGISTER_JIT_EXCEPTION_INFO (getMethodCodeStart(meth),
METHOD_NATIVECODE(meth),
meth->c.ncode.ncode_end);
#endif
Index: kaffe/kaffe/kaffevm/jit3/machine.c
diff -u kaffe/kaffe/kaffevm/jit3/machine.c:1.82 kaffe/kaffe/kaffevm/jit3/machine.c:1.83
--- kaffe/kaffe/kaffevm/jit3/machine.c:1.82 Sat Apr 22 00:32:21 2006
+++ kaffe/kaffe/kaffevm/jit3/machine.c Sat Apr 22 23:42:07 2006
@@ -648,7 +648,7 @@
SET_METHOD_JITCODE(meth, code->code);
- meth->c.ncode.ncode_start = code->mem;
+ setMethodCodeStart(meth, code->mem);
meth->c.ncode.ncode_end = (void*)((uintp)code->code + code->codelen);
#if defined(KAFFE_FEEDBACK)
More information about the kaffe
mailing list