cacao.git
16 years ago* configure.ac: Only check AC_PROG_JAVAC and AC_PROG_JAR for CLDC-1.1
twisti [Tue, 31 Jul 2007 12:47:11 +0000 (12:47 +0000)]
* configure.ac: Only check AC_PROG_JAVAC and AC_PROG_JAR for CLDC-1.1
and GNU.

* m4/classpath.m4 (AC_CHECK_WITH_CLASSPATH_CLASSES): Changed default
value for different configurations..

16 years ago* src/vm/jit/arm/arch.h, src/vm/jit/powerpc/arch.h, src/vm/jit/sparc64/arch.h,
michi [Tue, 31 Jul 2007 12:06:44 +0000 (12:06 +0000)]
* src/vm/jit/arm/arch.h, src/vm/jit/powerpc/arch.h, src/vm/jit/sparc64/arch.h,
src/vm/jit/alpha/arch.h, src/vm/jit/s390/arch.h, src/vm/jit/mips/arch.h,
src/vm/jit/powerpc64/arch.h, src/vm/jit/i386/arch.h, src/vm/jit/x86_64/arch.h
(REPLACEMENT_STUB_SIZE): Removed obsolete define.

* src/vm/jit/powerpc/md.c, src/vm/jit/sparc64/md.c, src/vm/jit/alpha/md.c,
src/vm/jit/mips/md.c, src/vm/jit/powerpc64/md.c, src/vm/jit/i386/md.c,
src/vm/jit/x86_64/md.c
(md_patch_replacement_point): We have to use trap instructions here.

16 years ago* src/vm/jit/sparc64/md.c: Fixed file header.
michi [Tue, 31 Jul 2007 11:36:03 +0000 (11:36 +0000)]
* src/vm/jit/sparc64/md.c: Fixed file header.

16 years ago* src/vm/jit/replace.c (replace_me_wrapper): Added.
michi [Tue, 31 Jul 2007 09:30:28 +0000 (09:30 +0000)]
* src/vm/jit/replace.c (replace_me_wrapper): Added.
* src/vm/jit/replace.h (replace_me_wrapper): Added.
* src/vm/exceptions.c (exceptions_new_hardware_exception): Call above function.

16 years ago* src/vm/exceptions.c (exceptions_new_hardware_exception): Do not create sfi.
michi [Tue, 31 Jul 2007 08:57:54 +0000 (08:57 +0000)]
* src/vm/exceptions.c (exceptions_new_hardware_exception): Do not create sfi.
* src/vm/exceptions.h (exceptions_new_hardware_exception): Changed signature.

* src/vm/jit/arm/linux/md-os.c
* src/vm/jit/powerpc/linux/md-os.c
* src/vm/jit/powerpc/darwin/md-os.c
* src/vm/jit/sparc64/linux/md-os.c
* src/vm/jit/sparc64/solaris/md-os.c
* src/vm/jit/alpha/linux/md-os.c
* src/vm/jit/s390/md.c
* src/vm/jit/mips/linux/md-os.c
* src/vm/jit/mips/irix/md-os.c
* src/vm/jit/m68k/linux/md-os.c
* src/vm/jit/powerpc64/linux/md-os.c
* src/vm/jit/i386/darwin/md-os.c
* src/vm/jit/i386/linux/md-os.c
* src/vm/jit/x86_64/linux/md-os.c:
Signal handlers create the sfi now.
Adapted to above changes.
Exception object variable is now called "e" on all archs.

16 years ago* src/mm/boehm.c (heap_allocate): Call GC_REGISTER_FINALIZER_NO_ORDER
twisti [Tue, 31 Jul 2007 08:45:35 +0000 (08:45 +0000)]
* src/mm/boehm.c (heap_allocate): Call GC_REGISTER_FINALIZER_NO_ORDER
instead of GC_REGISTER_FINALIZER. This fixes the GC heap memory leak
seen with e.g. Jetty.

16 years ago* m4/ac_prog_javac.m4 (AC_PROG_JAVAC): Try javac as first
twisti [Mon, 30 Jul 2007 09:26:31 +0000 (09:26 +0000)]
* m4/ac_prog_javac.m4 (AC_PROG_JAVAC): Try javac as first
compiler. Left jikes in there so configure can finish on machines
where we don't have a javac or ecj.

16 years ago* src/vm/jit/replace.c: Enaled replacement on s390.
pm [Sun, 29 Jul 2007 20:36:47 +0000 (20:36 +0000)]
* src/vm/jit/replace.c: Enaled replacement on s390.
* src/vm/jit/s390/arch.h,
src/vm/jit/s390/codegen.h,
src/vm/jit/s390/codegen.c,
src/vm/jit/s390/emit.c,
src/vm/jit/s390/md.c: Changed a lot: implemented profiling, fixed bugs found by mauve, begun work on replacament.

16 years ago* src/vm/vm.c (vm_create) [WITH_CLASSPATH_SUN]: Set bootclasspath as
twisti [Sun, 29 Jul 2007 19:21:18 +0000 (19:21 +0000)]
* src/vm/vm.c (vm_create) [WITH_CLASSPATH_SUN]: Set bootclasspath as
HotSpot does.

16 years ago* src/vmcore/class.c (class_resolve_superclass): New function.
twisti [Fri, 27 Jul 2007 18:41:53 +0000 (18:41 +0000)]
* src/vmcore/class.c (class_resolve_superclass): New function.
(class_issubclass): Use class_resolve_superclass.
(class_get_superclass): Likewise.

16 years ago* src/vmcore/class.c (class_sun_reflect_MagicAccessorImpl): Added.
twisti [Fri, 27 Jul 2007 16:15:29 +0000 (16:15 +0000)]
* src/vmcore/class.c (class_sun_reflect_MagicAccessorImpl): Added.
(class_issubclass): Don't get super-class directly, it can be
unresolved. Use class_get_superclass.

* src/vmcore/class.h (class_sun_reflect_MagicAccessorImpl): Added.

* src/vmcore/loader.c (loader_init): Load
class_sun_reflect_MagicAccessorImpl.

* src/vmcore/linker.c (linker_init): Link
class_sun_reflect_MagicAccessorImpl.

* src/vm/access.c (access_is_accessible_class) [WITH_CLASSPATH_SUN]:
Added sun/reflect/MagicAccessorImpl check.
(access_is_accessible_member): Likewise.

16 years ago* src/vm/vm.c (version): Removed configuration output.
twisti [Fri, 27 Jul 2007 10:18:17 +0000 (10:18 +0000)]
* src/vm/vm.c (version): Removed configuration output.
(vm_printconfig): New function.
(vm_create): Set bootclasspath and classpath whenever changed and
don't call properties_postinit. This fixes a bug with
-Djava.class.path.
* src/vm/vm.h (vm_printconfig): Added.

* src/vm/properties.c (properties_init): Set java.vm.info for all
JavaSE configurations.
(properties_postinit): Removed.
* src/vm/properties.h (properties_postinit): Likewise.

* src/vmcore/options.c (opt_PrintConfig): Added.
(options_xx): Likewise.
* src/vmcore/options.h (opt_PrintConfig): Likewise.

* src/vmcore/suck.c (suck_add_from_property): Reset the bootclasspath
after it changed.

* src/cacaoh/dummy.c (properties_add): New dummy.
(vm_printconfig): Likewise.

16 years ago* THIRDPARTY: Fixed classes path, added contrib/mapfile-vers-product,
twisti [Thu, 26 Jul 2007 08:29:24 +0000 (08:29 +0000)]
* THIRDPARTY: Fixed classes path, added contrib/mapfile-vers-product,
src/lib/gnu/sun/misc/Unsafe.java

16 years ago* src/vmcore/linker.c (dummy_alignment_long_t): New structure.
twisti [Thu, 26 Jul 2007 08:21:25 +0000 (08:21 +0000)]
* src/vmcore/linker.c (dummy_alignment_long_t): New structure.
(dummy_alignment_double_t): Likewise.
(linker_init): Added long/double alignment check.

16 years ago* src/vmcore/descriptor.c (descriptor_to_basic_type): Changed return
twisti [Wed, 25 Jul 2007 15:11:20 +0000 (15:11 +0000)]
* src/vmcore/descriptor.c (descriptor_to_basic_type): Changed return
type to int.
(descriptor_typesize): Likewise.
* src/vmcore/descriptor.h: Likewise.

16 years ago* src/vmcore/descriptor.c (vm/vm.h): Added.
twisti [Wed, 25 Jul 2007 14:51:40 +0000 (14:51 +0000)]
* src/vmcore/descriptor.c (vm/vm.h): Added.
(descriptor_to_basic_type): Code cleanup.
(descriptor_typesize): Likewise.

16 years ago* src/vmcore/class.c [ENABLE_JAVASE] (class_get_signature): Only for
twisti [Wed, 25 Jul 2007 14:21:24 +0000 (14:21 +0000)]
* src/vmcore/class.c [ENABLE_JAVASE] (class_get_signature): Only for
JavaSE.
* src/vmcore/class.h: Likewise.

* src/vmcore/method.h (vmcore/loader.h): Added.

16 years ago* src/vm/string.c,
twisti [Wed, 25 Jul 2007 08:23:10 +0000 (08:23 +0000)]
* src/vm/string.c,
src/vm/vm.c,
src/vmcore/class.c,
src/vmcore/class.h,
src/vmcore/loader.c,
src/vmcore/options.c,
src/vmcore/options.h: Removed eager-loading stuff (as it was broken
anyways).

16 years ago* src/vmcore/field.h (vmcore/loader.h): Added.
twisti [Tue, 24 Jul 2007 18:42:44 +0000 (18:42 +0000)]
* src/vmcore/field.h (vmcore/loader.h): Added.

16 years ago* src/vmcore/loader.c (vmcore/method.h): Added.
twisti [Tue, 24 Jul 2007 12:37:25 +0000 (12:37 +0000)]
* src/vmcore/loader.c (vmcore/method.h): Added.
(loader_load_method): Removed.
(load_class_from_classbuffer): Call method_load.

* src/vmcore/method.c (stdint.h): Added.
(threads/lock-common): Likewise.
(vm/exceptions.h): Likewise.
(vmcore/suck.h): Likewise.
(method_load): New function.

* src/vmcore/method.h (method_load): Added.

16 years ago* src/vmcore/loader.c (vmcore/field.h): Added.
twisti [Tue, 24 Jul 2007 11:55:07 +0000 (11:55 +0000)]
* src/vmcore/loader.c (vmcore/field.h): Added.
(load_field): Removed.
(load_class_from_classbuffer): Call field_load.

* src/vmcore/field.c (stdint.h): Added.
(vm/exceptions.h): Likewise.
(vm/stringlocal.h): Likewise.
(vm/vm.h): Likewise.
(vmcore/descriptor.h): Likewise.
(vmcore/loader.h): Likewise.
(vmcore/options.h): Likewise.
(vmcore/suck.h): Likewise.
(field_load): New function.

* src/vmcore/field.h (field_load): Added.

16 years ago* src/native/vm/sun_misc_Unsafe.c [WITH_CLASSPATH_SUN]
twisti [Tue, 24 Jul 2007 08:21:23 +0000 (08:21 +0000)]
* src/native/vm/sun_misc_Unsafe.c [WITH_CLASSPATH_SUN]
(native/include/java_security_ProtectionDomain.h): Removed #ifdef.
(defineClass) [WITH_CLASSPATH_GNU]: Renamed pd to protectionDomain.

16 years ago* src/native/vm/sun_misc_Unsafe.c (vm/stringlocal.h): Added.
twisti [Mon, 23 Jul 2007 21:33:16 +0000 (21:33 +0000)]
* src/native/vm/sun_misc_Unsafe.c (vm/stringlocal.h): Added.
(putInt): New function.
(getObject): Likewise.
(defineClass): Likewise.

16 years ago* src/vmcore/class.h (classinfo): Removed unused listnode.
twisti [Mon, 23 Jul 2007 19:07:48 +0000 (19:07 +0000)]
* src/vmcore/class.h (classinfo): Removed unused listnode.

16 years ago* src/vmcore/class.c (class_get_signature): New function.
twisti [Sun, 22 Jul 2007 20:43:05 +0000 (20:43 +0000)]
* src/vmcore/class.c (class_get_signature): New function.
* src/vmcore/class.h: Likewise.

16 years ago* src/threads/native/threads.h (threads_yield): Removed.
twisti [Sun, 22 Jul 2007 20:07:55 +0000 (20:07 +0000)]
* src/threads/native/threads.h (threads_yield): Removed.
* src/threads/threads-common.h (threads_yield): Added.

16 years ago* src/native/jni.c (_Jv_JNI_GetSuperclass): Fixed TRACEJNICALLS.
twisti [Sun, 22 Jul 2007 19:31:41 +0000 (19:31 +0000)]
* src/native/jni.c (_Jv_JNI_GetSuperclass): Fixed TRACEJNICALLS.
(_Jv_JNI_GetStringUTFRegion): Bugfix, start at offset to copy data.

16 years ago* src/vmcore/options.c (opt_TraceJNICalls): Added.
twisti [Sun, 22 Jul 2007 15:37:52 +0000 (15:37 +0000)]
* src/vmcore/options.c (opt_TraceJNICalls): Added.
* src/vmcore/options.h: Likewise.

* src/native/jni.c (TRACEJNICALLS): Enabled.
(_Jv_JNI_GetStringLength): Added TRACEJNICALLS.
(_Jv_JNI_NewStringUTF): Likewise.
(_Jv_JNI_GetStringUTFLength): Likewise.

16 years ago* src/vmcore/class.c (class_get_superclass): New function.
twisti [Fri, 20 Jul 2007 16:52:11 +0000 (16:52 +0000)]
* src/vmcore/class.c (class_get_superclass): New function.
* src/vmcore/class.h: Likewise.

* src/native/jni.c (_Jv_JNI_GetSuperclass): Use class_get_superclass.
* src/native/vm/java_lang_Class.c (getSuperclass): Likewise.

16 years ago* src/vm/jit/s390/md.c (md_get_method_patch_address): Fixed cornercase
michi [Thu, 19 Jul 2007 16:33:19 +0000 (16:33 +0000)]
* src/vm/jit/s390/md.c (md_get_method_patch_address): Fixed cornercase
for replacement.

* src/vm/jit/m68k/md.c (md_get_method_patch_address): Likewise.

16 years ago* src/vm/jit/arm/md-os.c (md_signal_handler_sigsegv): Added additional
michi [Thu, 19 Jul 2007 15:44:41 +0000 (15:44 +0000)]
* src/vm/jit/arm/md-os.c (md_signal_handler_sigsegv): Added additional
debug output.

16 years ago* src/vm/jit/powerpc/emit.c (emit_patcher_traps): Formerly known
michi [Thu, 19 Jul 2007 13:51:21 +0000 (13:51 +0000)]
* src/vm/jit/powerpc/emit.c (emit_patcher_traps): Formerly known
as emit_patcher_stubs, now emits traps instead of stubs.

* src/vm/jit/powerpc/codegen.c (codegen_emit, codegen_emit_stub_native): Call the
new patcher functions and adapted to above change.

* src/vm/jit/powerpc/patcher.c: Adapted patchers to new signature for traps.
(patcher_wrapper): Removed, this is obsolete.

* src/vm/jit/powerpc/asmpart.S (asm_patcher_wrapper): Removed, this is obsolete.

* src/vm/jit/powerpc/linux/md-os.c (md_signal_handler_sigsegv): Only calls the
exception handling if exception object present.

* src/vm/jit/powerpc/darwin/md-os.c (md_signal_handler_sigsegv): Likewise.

* src/vm/jit/patcher-common.h [__POWERPC__]: Enabled new patcher stuff.

* src/vm/jit/patcher.h [__POWERPC__]: Defined away old patcher stuff.

16 years ago* src/vm/jit/code.h (codeinfo) [ENABLE_REPLACEMENT]: Removed obsolet pointer
michi [Wed, 18 Jul 2007 20:31:21 +0000 (20:31 +0000)]
* src/vm/jit/code.h (codeinfo) [ENABLE_REPLACEMENT]: Removed obsolet pointer
to replacementstubs.

* src/vm/jit/codegen-common.c (codegen_finish) [ENABLE_REPLACEMENT]: Do not
resolve pointer to replacementstubs.

16 years ago* src/vmcore/options.c (options_XX): Fixed -XX:TraceReplacement.
michi [Wed, 18 Jul 2007 20:27:12 +0000 (20:27 +0000)]
* src/vmcore/options.c (options_XX): Fixed -XX:TraceReplacement.

16 years ago* src/vmcore/options.h (opt_replace_verbose): Removed.
michi [Wed, 18 Jul 2007 20:08:26 +0000 (20:08 +0000)]
* src/vmcore/options.h (opt_replace_verbose): Removed.
* src/vmcore/options.c (opt_replace_verbose): Removed.
* src/vm/vm.c [ENABLE_INLINING]: Removed options -ir and -iR, this is now
called -XX:TraceReplacement.

16 years ago* src/vm/vm.c (opts): Added -XX.
twisti [Wed, 18 Jul 2007 19:59:32 +0000 (19:59 +0000)]
* src/vm/vm.c (opts): Added -XX.
(usage): Small text change.

* src/vmcore/options.c (opt_DebugStackFrameInfo): Added.
(opt_DebugStackTrace): Likewise.
(options_XX): Added type and some documentation.
(options_xxusage): New function.
(options_xx): Do more error checking.

* src/vmcore/options.h (option_t): Added type and renamed option to
value.
(opt_DebugStackFrameInfo): Added.
(opt_DebugStackTrace): Likewise.

16 years ago* src/vm/jit/replace.h (REPLACEMENT_EMIT_STUBS): Removed macro.
michi [Wed, 18 Jul 2007 19:52:23 +0000 (19:52 +0000)]
* src/vm/jit/replace.h (REPLACEMENT_EMIT_STUBS): Removed macro.

* src/vm/jit/emit-common.h (emit_replacement_stubs): Removed.

* src/vm/jit/arm/emit.c,
* src/vm/jit/arm/codegen.c,
* src/vm/jit/powerpc/emit.c,
* src/vm/jit/powerpc/codegen.c,
* src/vm/jit/sparc64/emit.c,
* src/vm/jit/sparc64/codegen.c,
* src/vm/jit/alpha/emit.c,
* src/vm/jit/alpha/codegen.c,
* src/vm/jit/s390/emit.c,
* src/vm/jit/mips/emit.c,
* src/vm/jit/mips/codegen.c,
* src/vm/jit/m68k/codegen.c,
* src/vm/jit/powerpc64/emit.c,
* src/vm/jit/powerpc64/codegen.c,
* src/vm/jit/i386/emit.c,
* src/vm/jit/i386/codegen.c,
* src/vm/jit/x86_64/emit.c,
* src/vm/jit/x86_64/codegen.c
(emit_replacement_stubs): Removed.
(codegen_emit): Do not create replacement stubs anymore.

16 years ago* src/vm/jit/allocator/simplereg.c: Replaced HAS_4BYTE_STACKSLOT with
twisti [Wed, 18 Jul 2007 12:51:00 +0000 (12:51 +0000)]
* src/vm/jit/allocator/simplereg.c: Replaced HAS_4BYTE_STACKSLOT with
SIZEOF_VOID_P == 4.

* src/vm/jit/i386/emit.c (vm/jit/abi.h): Added.
(emit_verbosecall_enter): Changed to 8-byte stackslots.

* src/vm/jit/i386/codegen.c (codegen_emit): Changed to 8-byte
stackslots.
(codegen_emit_stub_native): Likewise.

* src/vm/jit/i386/arch.h (HAS_4BYTE_STACKSLOT): Removed.
(ALIGN_LONGS_IN_MEMORY): Likewise.
(ALIGN_DOUBLES_IN_MEMORY): Likewise.

* src/vm/jit/i386/asmpart.S (asm_vm_call_method): Rewritten for new
argument passing.
(asm_handle_exception): Use 8-byte stackslots.

* src/vm/jit/i386/md-abi.c (md_param_alloc): Use 8-byte stackslots and
set pd->index.
(md_param_alloc_native): New function.

* src/vm/global.h (ALIGN_EVEN): New macro.
(ALIGN_ODD): Likewise.
(ALIGN_2): Defined to ALIGN_EVEN.

* src/vm/builtintable.inc (builtintable_function): Removed #ifdef for
java.lang.VMSystem.arraycopy, this works now correctly.

* src/vm/builtin.c (builtintable_init): Set ACC_METHOD_BUILTIN when
parsing the decriptor.

* src/vm/jit_interface.h (md_param_alloc_native): Added.

* src/vm/exceptions.c (exceptions_handle_exception): Temporarily added
__I386__ to get the monitor object correctly.

* src/vmcore/descriptor.c (descriptor_pool_parse_method_descriptor):
Check for ACC_METHOD_BUILTIN flag.
(descriptor_params_from_paramtypes): Likewise.

* src/cacaoh/dummy.c (md_param_alloc_native): Added.

* src/vm/jit/asmpart.h: Added __I386__ ifdef.
* src/vm/vm.c: Likewise.
* src/vm/vm.h: Likewise.
* src/native/jni.c: Likewise.
(_Jv_jni_invokeNative): Check for exception too when
vm_array_from_objectarray returns.

16 years ago* src/vmcore/class.c (vm/resolve.h): Added.
twisti [Tue, 17 Jul 2007 20:13:23 +0000 (20:13 +0000)]
* src/vmcore/class.c (vm/resolve.h): Added.
(class_define): Changed signature.
* src/vmcore/class.h (class_define): Likewise.

* src/native/jni.c (_Jv_JNI_DefineClass): Bug fix, use class_define.

* src/native/vm/java_lang_ClassLoader.c (defineClass): Use
class_define.

16 years ago* src/native/jni.c (TRACEJNICALLS): Added but still unused.
twisti [Tue, 17 Jul 2007 09:06:22 +0000 (09:06 +0000)]
* src/native/jni.c (TRACEJNICALLS): Added but still unused.
(JNI_GetCreatedJavaVMs): Implemented.

16 years ago* src/vmcore/class.c (class_get_declaringclass): New function.
twisti [Mon, 16 Jul 2007 15:18:32 +0000 (15:18 +0000)]
* src/vmcore/class.c (class_get_declaringclass): New function.
* src/vmcore/class.h: Likewise.

* src/native/vm/java_lang_Class.c (getDeclaringClass): Use
class_get_declaringclass.

16 years ago* src/vmcore/options.c (opt_TraceJVMCalls): Added.
twisti [Sun, 15 Jul 2007 14:26:33 +0000 (14:26 +0000)]
* src/vmcore/options.c (opt_TraceJVMCalls): Added.
* src/vmcore/options.h: Likewise.

* src/native/vm/sun/jvm.c (vmcore/options.h): Added.
(DEBUG_JVM): Renamed to TRACEJVMCALLS.
(JVM_GetArrayLength): Implemented.

16 years ago* src/native/vm/sun/jvm.c: Set Id keyword.
twisti [Sun, 15 Jul 2007 12:45:40 +0000 (12:45 +0000)]
* src/native/vm/sun/jvm.c: Set Id keyword.

16 years ago* src/native/vm/sun/jvm.c (JVM_ArrayCopy): Fixed warnings.
twisti [Sun, 15 Jul 2007 12:44:22 +0000 (12:44 +0000)]
* src/native/vm/sun/jvm.c (JVM_ArrayCopy): Fixed warnings.
(JVM_GetStackTraceElement): Likewise.
(JVM_FindLoadedClass): Likewise.

16 years ago* src/vmcore/primitive.c (primitive_class_is_primitive): Removed.
twisti [Sun, 15 Jul 2007 12:30:04 +0000 (12:30 +0000)]
* src/vmcore/primitive.c (primitive_class_is_primitive): Removed.
* src/vmcore/primitive.h: Likewise.

* src/vmcore/class.c (class_is_primitive): New function.
(class_isanysubclass): Use class_is_primitive.
* src/vmcore/class.h: Likewise.

* src/native/vm/java_lang_Class.c (isPrimitive): Use
class_is_primitive.
(getDeclaringClass): Likewise.
(getDeclaredClasses): Likewise.

* src/native/vm/sun/jvm.c (JVM_GetProtectionDomain): Likewise.
(JVM_IsPrimitiveClass): Likewise.
(JVM_NewArray): Likewise.

16 years ago* src/native/include/Makefile.am [WITH_CLASSPATH_SUN]
twisti [Sun, 15 Jul 2007 12:08:18 +0000 (12:08 +0000)]
* src/native/include/Makefile.am [WITH_CLASSPATH_SUN]
(JAVASE_HEADER_FILES): Added sun_reflect_ConstantPool.h.

16 years ago* src/vmcore/primitive.c (stdint.h): Added.
twisti [Sun, 15 Jul 2007 10:37:50 +0000 (10:37 +0000)]
* src/vmcore/primitive.c (stdint.h): Added.
(primitive_arrayclass_get_by_name): New function.

* src/vmcore/primitive.h (stdint.h): Added.
(primitive_arrayclass_get_by_name): Likewise.

* src/native/vm/sun/jvm.c (JVM_NewArray): Implemented handling for
primitive arrays.

16 years ago* src/vm/vm.c: Build fix.
twisti [Sun, 15 Jul 2007 09:47:21 +0000 (09:47 +0000)]
* src/vm/vm.c: Build fix.

16 years ago* src/vmcore/statistics.h (size_patchref): Added.
michi [Fri, 13 Jul 2007 00:39:49 +0000 (00:39 +0000)]
* src/vmcore/statistics.h (size_patchref): Added.
* src/vmcore/statistics.c (size_patchref): Added.
(statistics_print_memory_usage): Print size of patcher references.

* src/vm/jit/patcher-common.c (patcher_add_patch_ref, patcher_list_free)
[ENABLE_STATISTICS] Set size of patcher references accordingly.

16 years ago* src/vm/jit/alpha/asmpart.S (asm_vm_call_method): Rewritten for new
twisti [Thu, 12 Jul 2007 07:16:24 +0000 (07:16 +0000)]
* src/vm/jit/alpha/asmpart.S (asm_vm_call_method): Rewritten for new
argument passing.

* src/vm/jit/alpha/md-abi.c (md_param_alloc): Set pd->index.

* src/native/jni.c: Added __ALPHA__ ifdef.
* src/vm/vm.c: Likewise.
* src/vm/vm.h: Likewise.
* src/vm/jit/asmpart.h: Likewise.

16 years ago* src/vm/jit/x86_64/asmpart.S (asm_vm_call_method): Fixed stack
twisti [Wed, 11 Jul 2007 19:17:04 +0000 (19:17 +0000)]
* src/vm/jit/x86_64/asmpart.S (asm_vm_call_method): Fixed stack
alignment.

16 years ago* src/vm/jit/powerpc/codegen.c (codegen_emit): Fixed bug when taking
twisti [Wed, 11 Jul 2007 13:54:21 +0000 (13:54 +0000)]
* src/vm/jit/powerpc/codegen.c (codegen_emit): Fixed bug when taking
out double arguments.
(codegen_emit_stub_native): Use switch-case for saving and restoring
argument registers.

16 years ago* src/vm/jit/s390/codegen.c (codegen_emit): Extended maximal interface table offset...
pm [Wed, 11 Jul 2007 11:27:55 +0000 (11:27 +0000)]
* src/vm/jit/s390/codegen.c (codegen_emit): Extended maximal interface table offset from 12 bit to 16 bit in ICMD_INVOKEINTERFACE.
* src/vm/jit/s390/patcher.c (patcher_invokeinterface): Likewise.

16 years ago* src/vmcore/options.c (opt_TraceJavaCalls): Added.
twisti [Tue, 10 Jul 2007 13:44:37 +0000 (13:44 +0000)]
* src/vmcore/options.c (opt_TraceJavaCalls): Added.
(options_XX): Added opt_TraceJavaCalls.
(options_xx): Likewise.

* src/vmcore/options.h (opt_TraceJavaCalls): Added.

* src/vm/vm.c (XXusage): Removed -verbose:call.
(vm_create): Likewise.

16 years ago* src/vm/global.h (ALIGN_2): Use logical arithmetic.
twisti [Mon, 9 Jul 2007 14:37:49 +0000 (14:37 +0000)]
* src/vm/global.h (ALIGN_2): Use logical arithmetic.

16 years ago* src/vm/jit/x86_64/linux/md-os.c (md_signal_handler_sigsegv): Fixed
twisti [Mon, 9 Jul 2007 11:18:48 +0000 (11:18 +0000)]
* src/vm/jit/x86_64/linux/md-os.c (md_signal_handler_sigsegv): Fixed
typo.

16 years ago* src/vm/jit/powerpc/emit.c (stdint.h): Added
twisti [Sun, 8 Jul 2007 15:15:53 +0000 (15:15 +0000)]
* src/vm/jit/powerpc/emit.c (stdint.h): Added
(emit_verbosecall_enter): Reimplemented (this implementation is much
simpler and maybe should be extended to trace also arguments on the
stack). Darwin support is still missing.

* src/vm/jit/powerpc/darwin/md-abi.h (TRACE_ARGS_NUM): Changed to 4.
* src/vm/jit/powerpc/linux/md-abi.h (TRACE_ARGS_NUM): Likewise.

16 years ago* src/vm/jit/powerpc/linux/md-abi.c (vm/types.h): Removed.
twisti [Sun, 8 Jul 2007 13:42:06 +0000 (13:42 +0000)]
* src/vm/jit/powerpc/linux/md-abi.c (vm/types.h): Removed.
(stdint.h): Added and use stdint-types in this file.
(_ALIGN): Removed and use ALIGN_2 in this file.

16 years ago* src/vm/jit/sparc64/solaris/md-os.c: Implemented hardware exception handling.
ajordan [Sat, 7 Jul 2007 12:03:38 +0000 (12:03 +0000)]
* src/vm/jit/sparc64/solaris/md-os.c: Implemented hardware exception handling.

16 years ago* src/vm/jit/alpha/emit.c (emit_patcher_traps): Formerly known
michi [Thu, 5 Jul 2007 23:48:16 +0000 (23:48 +0000)]
* src/vm/jit/alpha/emit.c (emit_patcher_traps): Formerly known
as emit_patcher_stubs, now emits traps instead of stubs.

* src/vm/jit/alpha/codegen.c (codegen_emit, codegen_emit_stub_native): Call the
new patcher functions and adapted to above change.

* src/vm/jit/alpha/patcher.c: Adapted patchers to new signature for traps.
(patcher_wrapper): Removed, this is obsolete.

* src/vm/jit/alpha/asmpart.S (asm_patcher_wrapper): Removed, this is obsolete.

* src/vm/jit/alpha/linux/md-os.c (md_signal_handler_sigsegv): Only calls the
exception handling if exception object present.

* src/vm/jit/patcher-common.h [__ALPHA__]: Enabled new patcher stuff.

* src/vm/jit/patcher.h [__ALPHA__]: Defined away old patcher stuff.

16 years ago* src/vm/jit/arm/md.c (md_get_method_patch_address): Added the replacement
michi [Thu, 5 Jul 2007 21:34:47 +0000 (21:34 +0000)]
* src/vm/jit/arm/md.c (md_get_method_patch_address): Added the replacement
magic about mptr being NULL sometimes.

16 years ago* src/vm/jit/code.c (code_get_stack_frame_size): Removed.
michi [Thu, 5 Jul 2007 21:11:01 +0000 (21:11 +0000)]
* src/vm/jit/code.c (code_get_stack_frame_size): Removed.
* src/vm/jit/code.h: Likewise.

* src/vm/jit/replace.c: Use code->stackframesize instead of above function.

16 years ago* src/vm/jit/arm/codegen.c (codegen_emit): Replacement points are created.
michi [Thu, 5 Jul 2007 20:36:16 +0000 (20:36 +0000)]
* src/vm/jit/arm/codegen.c (codegen_emit): Replacement points are created.

16 years ago* src/vm/exceptions.c (exceptions_new_hardware_exception): Stackframeinfo block
michi [Thu, 5 Jul 2007 11:13:20 +0000 (11:13 +0000)]
* src/vm/exceptions.c (exceptions_new_hardware_exception):  Stackframeinfo block
is now on the stack of the signal handler function.

* src/vm/exceptions.h (exceptions_new_hardware_exception): Changed signature.

* src/vm/jit/arm/linux/md-os.c (md_signal_handler_sigsegv): Passes sfi to
exceptions function.

* src/vm/jit/powerpc/linux/md-os.c: Likewise.
* src/vm/jit/powerpc/darwin/md-os.c: Likewise.
* src/vm/jit/sparc64/linux/md-os.c: Likewise.
* src/vm/jit/sparc64/solaris/md-os.c: Likewise.
* src/vm/jit/alpha/linux/md-os.c: Likewise.
* src/vm/jit/s390/md.c: Likewise.
* src/vm/jit/mips/linux/md-os.c: Likewise.
* src/vm/jit/mips/irix/md-os.c: Likewise.
* src/vm/jit/m68k/linux/md-os.c: Likewise.
* src/vm/jit/powerpc64/linux/md-os.c: Likewise.
* src/vm/jit/i386/darwin/md-os.c: Likewise.
* src/vm/jit/i386/linux/md-os.c: Likewise.
* src/vm/jit/x86_64/linux/md-os.c: Likewise.

16 years ago* src/native/vm/sun_misc_Unsafe.c (methods): Added unpark.
twisti [Tue, 3 Jul 2007 16:05:27 +0000 (16:05 +0000)]
* src/native/vm/sun_misc_Unsafe.c (methods): Added unpark.
(unpark): New function, but unimplemented.

16 years ago* src/vm/jit/i386/darwin/Makefile.am (AM_CPPFLAGS): Added
twisti [Tue, 3 Jul 2007 15:43:14 +0000 (15:43 +0000)]
* src/vm/jit/i386/darwin/Makefile.am (AM_CPPFLAGS): Added
-I$(top_builddir)/src.

16 years ago* src/vm/exceptions.c (exceptions_init) [!(__ARM__ && __LINUX__)]:
twisti [Mon, 2 Jul 2007 14:07:24 +0000 (14:07 +0000)]
* src/vm/exceptions.c (exceptions_init) [!(__ARM__ && __LINUX__)]:
Don't mmap page 0x0 on arm-linux.

16 years ago* src/vmcore/options.c (options_xx): Fixed warnings.
twisti [Sun, 1 Jul 2007 17:49:25 +0000 (17:49 +0000)]
* src/vmcore/options.c (options_xx): Fixed warnings.

16 years ago* src/native/vm/sun/jvm.c (JVM_Available): Fixed return value (seems
twisti [Sat, 30 Jun 2007 17:40:09 +0000 (17:40 +0000)]
* src/native/vm/sun/jvm.c (JVM_Available): Fixed return value (seems
it's a boolean value, 1 is OK, 0 is error).

16 years ago* src/native/vm/reflect.c: Added Id keyword.
twisti [Sat, 30 Jun 2007 14:14:52 +0000 (14:14 +0000)]
* src/native/vm/reflect.c: Added Id keyword.
* src/native/vm/reflect.h: Likewise.

16 years ago* src/native/vm/reflect.c: Fixed includes.
twisti [Sat, 30 Jun 2007 14:13:58 +0000 (14:13 +0000)]
* src/native/vm/reflect.c: Fixed includes.

16 years ago* src/native/jni.c [ENABLE_JAVASE] (native/vm/reflect.h): Added.
twisti [Sat, 30 Jun 2007 14:03:18 +0000 (14:03 +0000)]
* src/native/jni.c [ENABLE_JAVASE] (native/vm/reflect.h): Added.
(_Jv_JNI_ToReflectedMethod): Implemented.

* src/native/vm/java_lang_Class.c [ENABLE_JAVASE]
(native/vm/reflect.h): Added.
(getDeclaredFields): Use reflect_field_new.
(getDeclaredMethods): Use reflect_method_new.
(getDeclaredConstructors): Use reflect_constructor_new.
(getEnclosingConstructor): Use reflect_constructor_new.
(getEnclosingMethod): Use reflect_method_new.

* src/native/vm/sun/jvm.c (jio_vsnprintf): Added count check.
(jio_snprintf): Implemented.
(JVM_IsInterface): Use class_is_interface.
(JVM_IsArrayClass): Use class_is_array.
(JVM_InvokeMethod): Disabled debug output.

* src/native/vm/reflect.c: New file.
* src/native/vm/reflect.h: Likewise.

* src/native/vm/Makefile.am [ENABLE_JAVASE] (REFLECT_SOURCES): Added.
(libnativevm_la_SOURCES): Added REFLECT_SOURCES.

16 years ago* src/vmcore/class.c (class_is_array): New function.
twisti [Sat, 30 Jun 2007 12:33:50 +0000 (12:33 +0000)]
* src/vmcore/class.c (class_is_array): New function.
(class_is_interface): Likewise.
* src/vmcore/class.h: Likewise.

* src/native/vm/java_lang_Class.c (stdint.h): Added.
(isInterface): Made JNI function, use class_is_interface.
(isArray): Made JNI function, use class_is_array.
* src/native/vm/java_lang_Class.h: Likewise.

* src/native/vm/cldc1.1/java_lang_Class.c (methods): Register common
methods for isInterface and isArray.
(isInterface): Removed.
(isArray): Likewise.

* src/native/vm/gnu/java_lang_VMClass.c (isInterface): Changed to JNI
call.
(isArray): Likewise.

16 years ago* src/mm/nogc.c (vm/vm.h): Added.
twisti [Sat, 30 Jun 2007 12:20:48 +0000 (12:20 +0000)]
* src/mm/nogc.c (vm/vm.h): Added.

16 years ago* src/native/native.h (hashtable_library_name_entry): Moved up, build
twisti [Fri, 29 Jun 2007 20:27:41 +0000 (20:27 +0000)]
* src/native/native.h (hashtable_library_name_entry): Moved up, build
fix.

16 years ago* src/native/native.c: Removed wrong comment.
twisti [Fri, 29 Jun 2007 19:45:17 +0000 (19:45 +0000)]
* src/native/native.c: Removed wrong comment.

* src/native/native.h [ENABLE_LTDL && HAVE_LTDL_H] (ltdl.h): Added
#ifdef.
[ENABLE_LTDL] (hashtable_library_loader_entry): Likewise.
[ENABLE_LTDL] (hashtable_library_name_entry): Likewise.
[ENABLE_LTDL] (native_library_open, native_library_add)
(native_library_find): Likewise.

16 years ago* src/native/vm/java_lang_Runtime.c [ENABLE_LTDL && HAVE_LTDL_H]
twisti [Fri, 29 Jun 2007 19:02:08 +0000 (19:02 +0000)]
* src/native/vm/java_lang_Runtime.c [ENABLE_LTDL && HAVE_LTDL_H]
(ltdl.h): Added #ifdef.
(loadLibrary) [ENABLE_LTDL]: Likewise.

16 years ago* src/native/native.c (native_library_find): Typo.
twisti [Fri, 29 Jun 2007 18:56:08 +0000 (18:56 +0000)]
* src/native/native.c (native_library_find): Typo.

16 years ago* configure.ac (AC_CHECK_HEADERS): Added netdb.h, ucontext.h.
twisti [Fri, 29 Jun 2007 18:53:55 +0000 (18:53 +0000)]
* configure.ac (AC_CHECK_HEADERS): Added netdb.h, ucontext.h.
(AC_CHECK_FUNCS): Added gethostbyname, htons, malloc, recv, send.
(AC_CHECK_ENABLE_ZLIB): Moved code to function.
(AC_CHECK_ENABLE_LTDL): Likewise.

* m4/zlib.m4: New file.
* m4/ltdl.m4: Likewise.

* src/native/native.c [ENABLE_LTDL && HAVE_LTDL_H] (ltdl.h): Added
#ifdef.
[ENABLE_LTDL] (hashtable_library): Likewise.
(native_init) [ENABLE_LTDL]: Likewise.
[ENABLE_LTDL] (native_library_open): Likewise.
[ENABLE_LTDL] (native_library_add): Likewise.
[ENABLE_LTLD] (native_library_find): Likewise.

16 years ago* src/native/vm/sun/jvm.c: Added copyright header.
twisti [Thu, 28 Jun 2007 13:40:37 +0000 (13:40 +0000)]
* src/native/vm/sun/jvm.c: Added copyright header.

16 years ago* src/vm/global.h (ACC_CLASS_REFERENCE_MASK): Added.
twisti [Thu, 28 Jun 2007 10:30:08 +0000 (10:30 +0000)]
* src/vm/global.h (ACC_CLASS_REFERENCE_MASK): Added.
(ACC_CLASS_SOFT_REFERENCE): Renamed to ACC_CLASS_REFERENCE_SOFT.
(ACC_CLASS_WEAK_REFERENCE): Renamed to ACC_CLASS_REFERENCE_WEAK.
(ACC_CLASS_PHANTOM_REFERENCE): Renamed to ACC_CLASS_REFERENCE_PHANTOM.

* src/vmcore/class.c (class_create_classinfo): Flag soft/weak/phantom
reference classes.

* src/vmcore/linker.c (link_class_intern): Inherit the reference
flags.

16 years ago* src/vm/jit/arm/emit.c (emit_patcher_traps): Formerly known
michi [Thu, 28 Jun 2007 01:52:19 +0000 (01:52 +0000)]
* src/vm/jit/arm/emit.c (emit_patcher_traps): Formerly known
as emit_patcher_stubs, now emits traps instead of stubs.

* src/vm/jit/arm/codegen.c (codegen_emit, codegen_emit_stub_native): Call the
new patcher functions and adapted to above change.

* src/vm/jit/arm/patcher.c: Adapted patchers to new signature for traps.
(patcher_get_putfield): Fixed severe bug for long values.
(patcher_wrapper): Removed, this is obsolete.

* src/vm/jit/arm/codegen.h (M_TRAP): Added.

* src/vm/jit/arm/asmpart.S (asm_patcher_wrapper): Removed, this is obsolete.

* src/vm/jit/arm/linux/md-os.c (md_signal_handler_sigill): Only calls the
exception handling if exception object present.

* src/vm/jit/patcher-common.c: Fixed includes.

* src/vm/jit/patcher-common.h [__ARM__]: Added prototypes for patcher functions.
(patchref_t): Added datap.

* src/vm/jit/patcher.h [__ARM__]: Defined away old patcher stuff.

* src/vm/jit/codegen-common.c (codegen_finish): Resolves pr->datap as well.

16 years ago* src/vm/jit/verify/typecheck-typeinferer.c: Removed patcher.h include.
michi [Thu, 28 Jun 2007 00:31:31 +0000 (00:31 +0000)]
* src/vm/jit/verify/typecheck-typeinferer.c: Removed patcher.h include.
* src/vm/jit/verify/typecheck.c: Likewise.
* src/vm/jit/parse.c: Likewise.
* src/vm/builtin.c: Likewise.

16 years ago* src/vm/jit/sparc64/md-abi.c (md_param_alloc): Added absolute offsets for
ajordan [Thu, 28 Jun 2007 00:01:34 +0000 (00:01 +0000)]
* src/vm/jit/sparc64/md-abi.c (md_param_alloc): Added absolute offsets for
native arguments (reguse * 8).

* src/vm/jit/sparc64/codegen.c (codegen_emit_stub_native): Adapted to
change above.

16 years ago* src/vm/vm.c: Fixed messed up ifdefs introduced with M68K.
michi [Wed, 27 Jun 2007 22:12:32 +0000 (22:12 +0000)]
* src/vm/vm.c: Fixed messed up ifdefs introduced with M68K.
* src/vm/vm.h: Likewise.

16 years ago* configure.ac: Check for librt should only be done on Solaris.
ajordan [Wed, 27 Jun 2007 22:07:28 +0000 (22:07 +0000)]
* configure.ac: Check for librt should only be done on Solaris.

16 years ago* src/vm/builtin.c (builtin_f2l): Added for DISABLE_GC.
ajordan [Wed, 27 Jun 2007 21:53:44 +0000 (21:53 +0000)]
* src/vm/builtin.c (builtin_f2l): Added for DISABLE_GC.
(builtin_d2l): Likewise.

* src/native/jni.c (_Jv_jni_invokeNative): Added SPARC to defines, corrected
bitwise & for ARM.

16 years ago* configure.ac: Added librt for SPARC/Solaris.
ajordan [Wed, 27 Jun 2007 20:56:57 +0000 (20:56 +0000)]
* configure.ac: Added librt for SPARC/Solaris.

16 years ago* src/vm/jit/sparc64/md-abi.h: Removed faulty register offset
ajordan [Wed, 27 Jun 2007 20:56:03 +0000 (20:56 +0000)]
* src/vm/jit/sparc64/md-abi.h: Removed faulty register offset
multiplication from REG_WINDOW_TRANSPOSE.

* src/vm/jit/sparc64/asmpart.S: fixed offsets.h include.

* src/vm/jit/sparc64/solaris/macro_rename.h: Added include,
which renames the REG_SP defined from Solaris sys headers to
REG_SP_SOLARIS and defines mine.
* src/vm/jit/sparc64/emit.c: Used here.
* src/vm/jit/sparc64/codegen.c: Used here.
* src/vm/jit/sparc64/patcher.c: Used here.

16 years ago* src/vm/jit/s390/codegen.c (codegen_emit): Fix profiling code.
pm [Wed, 27 Jun 2007 20:37:45 +0000 (20:37 +0000)]
* src/vm/jit/s390/codegen.c (codegen_emit): Fix profiling code.

16 years ago* src/vm/jit/s390/codegen.c (codegen_emit): Replace some load/stores by a mvc.
pm [Wed, 27 Jun 2007 20:08:30 +0000 (20:08 +0000)]
* src/vm/jit/s390/codegen.c (codegen_emit): Replace some load/stores by a mvc.

16 years ago* src/mm/boehm.c (gc_init): Set GC_all_interior_pointers to 0 and call
twisti [Wed, 27 Jun 2007 18:35:40 +0000 (18:35 +0000)]
* src/mm/boehm.c (gc_init): Set GC_all_interior_pointers to 0 and call
GC_INIT very late.

* src/vm/vm.c (vm_create): Initialze the GC before all other
subsystems.

16 years ago* src/native/vm/sun_misc_Unsafe.c (putObject): New function.
twisti [Wed, 27 Jun 2007 13:26:49 +0000 (13:26 +0000)]
* src/native/vm/sun_misc_Unsafe.c (putObject): New function.
(park): New function, but not implemented.

16 years ago* src/native/vm/gnu/java_lang_VMRuntime.c (unistd.h): Added.
twisti [Wed, 27 Jun 2007 09:23:24 +0000 (09:23 +0000)]
* src/native/vm/gnu/java_lang_VMRuntime.c (unistd.h): Added.

16 years ago* src/vm/exceptions.h: Added EXCEPTION_HARDWARE_COMPILER.
michi [Wed, 27 Jun 2007 09:04:17 +0000 (09:04 +0000)]
* src/vm/exceptions.h: Added EXCEPTION_HARDWARE_COMPILER.
* src/vm/exceptions.c (exceptions_init): Made check clearer.

16 years ago* src/vm/jit/patcher-common.h: Added.
michi [Wed, 27 Jun 2007 08:54:10 +0000 (08:54 +0000)]
* src/vm/jit/patcher-common.h: Added.
* src/vm/jit/patcher-common.t: Added.
* src/vm/jit/Makefile.am: Added above two files.

* src/vm/jit/code.h (codeinfo): Added patcher list.
* src/vm/jit/code.c (code_codeinfo_new, code_codeinfo_free): Patcher list is
created and freed together with codeinfo.

* src/vm/jit/codegen-common.c (codegen_finish): Absolute PCs for patchers are
resolved.

* src/vm/jit/emit-common.h (emit_patcher_traps): Added prototype.

* src/vm/exception.c (exceptions_new_hardware_exception): Patcher handler is
called if needed.

16 years ago* src/vm/jit/s390/tests/dacapo.status: Added more dacapo eclipse results.
pm [Tue, 26 Jun 2007 21:16:35 +0000 (21:16 +0000)]
* src/vm/jit/s390/tests/dacapo.status: Added more dacapo eclipse results.

16 years ago* src/vm/jit/i386/patcher.c (patcher_builtin_multianewarray): Dont'
twisti [Tue, 26 Jun 2007 15:47:43 +0000 (15:47 +0000)]
* src/vm/jit/i386/patcher.c (patcher_builtin_multianewarray): Dont'
patch function address.

16 years ago* src/vm/jit/s390/tests/jasmin.status: Added.
pm [Mon, 25 Jun 2007 18:58:11 +0000 (18:58 +0000)]
* src/vm/jit/s390/tests/jasmin.status: Added.

16 years ago* src/vm/jit/stacktrace.c (stacktrace_print_trace): Handle
twisti [Sun, 24 Jun 2007 10:12:27 +0000 (10:12 +0000)]
* src/vm/jit/stacktrace.c (stacktrace_print_trace): Handle
WITH_CLASSPATH_SUN properly.