Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
- $Id: loader.c 7246 2007-01-29 18:49:05Z twisti $
+ $Id: loader.c 7464 2007-03-06 00:26:31Z edwin $
*/
#include "vm/stringlocal.h"
#include "vm/vm.h"
-#include "vm/jit/asmpart.h"
-#include "vm/jit/codegen-common.h"
+#include "vm/jit_interface.h"
#if defined(ENABLE_JAVASE)
# include "vmcore/annotation.h"
c = cb->class;
-#if defined(ENABLE_THREADS)
- lock_init_object_lock(&m->header);
-#endif
-
#if defined(ENABLE_STATISTICS)
if (opt_stat)
count_all_methods++;
return false;
}
+ /* initialize the hit countdown field */
+
+#if defined(ENABLE_REPLACEMENT)
+ m->hitcountdown = METHOD_INITIAL_HIT_COUNTDOWN;
+#endif
+
/* everything was ok */
return true;
if (!suck_check_classbuffer_size(cb, 2))
goto return_exception;
- c->flags = suck_u2(cb);
+ /* We OR the flags here, as we set already some flags in
+ class_create_classinfo. */
+
+ c->flags |= suck_u2(cb);
/* check ACC flags consistency */
c->super.cls = class_java_lang_Object;
- c->interfacescount = 0;
- c->interfaces = NULL;
-
#if defined(ENABLE_JAVASE)
- c->interfaces = MNEW(classref_or_classinfo, 2);
+ c->interfacescount = 2;
+ c->interfaces = MNEW(classref_or_classinfo, 2);
if (opt_eager) {
classinfo *tc;
c->interfaces[0].cls = class_java_lang_Cloneable;
c->interfaces[1].cls = class_java_io_Serializable;
}
+#elif defined(ENABLE_JAVAME_CLDC1_1)
+ c->interfacescount = 0;
+ c->interfaces = NULL;
+#else
+#error unknow Java configuration
#endif
c->methodscount = 1;
clone = c->methods;
MSET(clone, 0, methodinfo, 1);
-#if defined(ENABLE_THREADS)
- lock_init_object_lock(&clone->header);
-#endif
-
/* ATTENTION: if you delete the ACC_NATIVE below, set
clone->maxlocals=1 (interpreter related) */