cacao.git
16 years ago* NEWS: Added 0.99 release and some news.
twisti [Thu, 9 Aug 2007 11:28:51 +0000 (11:28 +0000)]
* NEWS: Added 0.99 release and some news.

16 years ago* src/vm/jit/alpha/linux/md-os.c
michi [Thu, 9 Aug 2007 09:36:57 +0000 (09:36 +0000)]
* src/vm/jit/alpha/linux/md-os.c
[ENABLE_REPLACEMENT] (md_replace_executionstate_read): Implemented.
[ENABLE_REPLACEMENT] (md_replace_executionstate_write): Likewise.

* src/vm/jit/alpha/asmpart.S (asm_replacement_out): Removed.
(asm_replacement_in): Likewise.

16 years ago* src/vm/jit/s390/emit.c (emit_replacement_stubs): Removed obsolete function.
michi [Wed, 8 Aug 2007 17:10:18 +0000 (17:10 +0000)]
* src/vm/jit/s390/emit.c (emit_replacement_stubs): Removed obsolete function.
* src/vm/jit/s390/codegen.c (codegen_emit): Do not create replacement stubs.
* src/vm/jit/replace.c (replace_me): No longer call asm_replacement_in.
* src/vm/jit/asmpart.h [ENABLE_REPLACEMENT]: Removed obsolete prototypes.

16 years ago* src/vmcore/linker.c (linker_compute_subclasses): Added attention notice about
michi [Wed, 8 Aug 2007 16:42:11 +0000 (16:42 +0000)]
* src/vmcore/linker.c (linker_compute_subclasses): Added attention notice about
the locking mechanism.

* src/vmcore/class.c (class_isanysubclass): Uses linker_classrenumber_lock now.

* src/vm/builtin.c (builtin_canstore): Likewise.
(builtin_canstore_onedim): Likewise.
(builtin_canstore_onedim_class): Likewise.

16 years ago* src/vm/jit/arm/asmpart.S (offsets.h): Removed.
twisti [Wed, 8 Aug 2007 16:09:14 +0000 (16:09 +0000)]
* src/vm/jit/arm/asmpart.S (offsets.h): Removed.

16 years ago* src/vm/jit/tools: Removed.
twisti [Wed, 8 Aug 2007 15:58:17 +0000 (15:58 +0000)]
* src/vm/jit/tools: Removed.

* configure.ac (AC_CONFIG_FILES): Removed src/vm/jit/tools/Makefile.
* src/vm/jit/Makefile.am (DIST_SUBDIRS): Removed tools.
(SUBDIRS): Likewise.

* src/threads/critical.c (stdint.h): Added.
(vm/jit/asmpart.h): Removed.
(critical_init): Don't call critical_register_asm_critical_sections.
(critical_register_asm_critical_sections): Removed.

* src/vm/jit/asmpart.h (ASM_GETCLASSVALUES_ATOMIC): Removed.
(asm_criticalsections): Likewise.
(asm_getclassvalues_atomic): Likewise.
(intrp_asm_getclassvalues_atomic): Likewise.

* src/vm/jit/alpha/Makefile.am,
src/vm/jit/arm/Makefile.am,
src/vm/jit/i386/Makefile.am,
src/vm/jit/m68k/Makefile.am,
src/vm/jit/mips/Makefile.am,
src/vm/jit/powerpc/Makefile.am,
src/vm/jit/powerpc64/Makefile.am,
src/vm/jit/s390/Makefile.am,
src/vm/jit/sparc64/Makefile.am,
src/vm/jit/x86_64/Makefile.am (BUILT_SOURCES): Removed
(CLEANFILES): Likewise.
(offsets.h): Likewise.

* src/vm/jit/alpha/asmpart.S,
src/vm/jit/arm/asmpart.S,
src/vm/jit/i386/asmpart.S,
src/vm/jit/m68k/asmpart.S,
src/vm/jit/mips/asmpart.S,
src/vm/jit/powerpc/asmpart.S,
src/vm/jit/powerpc64/asmpart.S,
src/vm/jit/s390/asmpart.S,
src/vm/jit/sparc64/asmpart.S,
src/vm/jit/x86_64/asmpart.S (offsets.h): Removed.
(asm_getclassvalues_atomic): Likewise.
(asm_criticalsections): Likewise.

* src/vm/jit/powerpc/darwin/md-asm.h (asm_criticalsections): Removed.
(asm_getclassvalues_atomic): Likewise.

16 years ago* src/vmcore/class.c (class_isanysubclass): Don't use
twisti [Wed, 8 Aug 2007 15:33:15 +0000 (15:33 +0000)]
* src/vmcore/class.c (class_isanysubclass): Don't use
ASM_GETCLASSVALUES_ATOMIC anymore, we will change that to use the
class-renumbering lock.

* src/vm/builtin.c (builtin_canstore): Likewise.
(builtin_canstore_onedim): Likewise.
(builtin_canstore_onedim_class): Likewise.

16 years ago* src/threads/threads-common.c (stdint.h): Added.
twisti [Wed, 8 Aug 2007 14:55:00 +0000 (14:55 +0000)]
* src/threads/threads-common.c (stdint.h): Added.
(threads_thread_free): Also save and restore the thread state (this is
required for CLDC1.1, but is generally a good idea).

* src/native/vm/java_lang_Thread.c (isAlive) [WITH_CLASSPATH_CLDC1_1]:
Check for NULL.

16 years ago* src/vm/vm.h (vm_arg): Removed.
twisti [Wed, 8 Aug 2007 14:07:56 +0000 (14:07 +0000)]
* src/vm/vm.h (vm_arg): Removed.

* src/vm/jit/tools/genoffsets.c (main): Removed sizevmarg,
offvmargtype and offvmargdata.

* src/vm/jit/m68k/md.c (md_init): Removed some obsolete checks.

16 years ago* src/vm/vm.c (vm_array_store_flt): Handle __POWERPC__ correctly.
twisti [Wed, 8 Aug 2007 13:57:12 +0000 (13:57 +0000)]
* src/vm/vm.c (vm_array_store_flt): Handle __POWERPC__ correctly.
(vm_vmargs_from_valist): Removed.
(vm_vmargs_from_jvalue): Likewise.
(vm_vmargs_from_objectarray): Likewise.
(vm_call_method_vmarg): Likewise.
(vm_call_method_int_vmarg): Likewise.
(vm_call_method_int_valist): Likewise.
(vm_call_method_int_jvalue): Likewise.
(vm_call_method_long_vmarg): Likewise.
(vm_call_method_long_valist): Likewise.
(vm_call_method_long_jvalue): Likewise.
(vm_call_method_float_vmarg): Likewise.
(vm_call_method_float_valist): Likewise.
(vm_call_method_float_jvalue): Likewise.
(vm_call_method_double_vmarg): Likewise.
(vm_call_method_double_valist): Likewise.
(vm_call_method_double_jvalue): Likewise.
(vm_call_method_valist): Removed old implementation.
(vm_call_method_jvalue): Likewise.

* src/vm/vm.h: Removed old prototypes.
* src/vm/jit/asmpart.h: Likewise.

* src/vm/exceptions.c (exceptions_handle_exception) [__POWERPC__]: Get
monitor object correctly (talk to Michi because of ARM).

* src/native/jni.c (_Jv_jni_invokeNative): Removed old implementation.

* src/vm/jit/powerpc/linux/md-abi.c (md_param_alloc): Use 8-byte
stackslots.
(md_param_alloc_native): Implemented native ABI.

* src/vm/jit/powerpc/emit.c (emit_load): Merged TYPE_FLT and TYPE_DBL.
(emit_store): Likewise
* src/vm/jit/powerpc/darwin/md-abi.c: Likewise.

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

* src/vm/jit/powerpc/codegen.c: Implemented 8-byte stackslots, always
load and store float-values as double (PowerPC's internal register
representation is the same).

* src/vm/jit/powerpc/asmpart.S (asm_vm_call_method): Use new argument
array.
(asm_handle_exception): Restore callee-saved registers from the
correct location.

16 years ago* tests/rtMissedIn0: Removed.
twisti [Tue, 7 Aug 2007 19:21:33 +0000 (19:21 +0000)]
* tests/rtMissedIn0: Removed.
* tests/rtIn: Likewise.

16 years ago* src/vmcore/field.c (mm/memory.h): Added.
twisti [Tue, 7 Aug 2007 13:24:43 +0000 (13:24 +0000)]
* src/vmcore/field.c (mm/memory.h): Added.
(vm/global.h): Likewise.
(field_load): Allocate value memory only for static and final fields.

* src/vmcore/field.h (fieldinfo): Made value a pointer.

* src/vmcore/loader.c (load_class_from_classbuffer): Allocate
fieldinfo's on the C heap.

* src/native/jni.c: fieldinfo->value is now a pointer.
* src/native/vm/sun_misc_Unsafe.c: Likewise.
* src/native/vm/gnu/java_lang_reflect_Field.c: Likewise.

* src/vm/jit/alpha/codegen.c,
src/vm/jit/alpha/patcher.c,
src/vm/jit/arm/codegen.c,
src/vm/jit/arm/patcher.c,
src/vm/jit/i386/codegen.c,
src/vm/jit/i386/patcher.c,
src/vm/jit/m68k/codegen.c,
src/vm/jit/m68k/patcher.c,
src/vm/jit/mips/codegen.c,
src/vm/jit/mips/patcher.c,
src/vm/jit/powerpc/codegen.c,
src/vm/jit/powerpc/patcher.c,
src/vm/jit/powerpc64/codegen.c,
src/vm/jit/powerpc64/patcher.c,
src/vm/jit/s390/codegen.c,
src/vm/jit/s390/patcher.c,
src/vm/jit/sparc64/codegen.c,
src/vm/jit/sparc64/patcher.c,
src/vm/jit/x86_64/codegen.c,
src/vm/jit/x86_64/patcher.c: Likewise.

16 years ago* src/vm/jit/i386/emit.c (emit_trap): New function.
twisti [Tue, 7 Aug 2007 11:07:48 +0000 (11:07 +0000)]
* src/vm/jit/i386/emit.c (emit_trap): New function.
* src/vm/jit/powerpc64/emit.c: Likewise.
* src/vm/jit/x86_64/emit.c: Likewise.

16 years ago* src/threads/threads-common.c (threads_preinit): Fixed compiler
twisti [Tue, 7 Aug 2007 08:26:38 +0000 (08:26 +0000)]
* src/threads/threads-common.c (threads_preinit): Fixed compiler
warning.

16 years ago* src/vm/jit/emit-common.c: Set Id keyword.
twisti [Mon, 6 Aug 2007 16:10:42 +0000 (16:10 +0000)]
* src/vm/jit/emit-common.c: Set Id keyword.
* src/vm/jit/emit-common.h: Likewise.

16 years ago* src/vm/jit/patcher-common.h: Added __MIPS__ for new patcher
twisti [Mon, 6 Aug 2007 16:02:28 +0000 (16:02 +0000)]
* src/vm/jit/patcher-common.h: Added __MIPS__ for new patcher
functions.

* src/vm/jit/patcher.h: Added __MIPS__ to include-check.

* src/vm/jit/mips/emit.c (vm/jit/patcher-common.h): Added.
(emit_patcher_stubs): Removed.
(emit_trap): Added.

* src/vm/jit/mips/codegen.c (vm/jit/patcher.h): Removed.
(vm/jit/patcher-common.h): Added.
(codegen_emit): Replaced codegen_add_patch_ref with
patcher_add_patch_ref, and emit_patcher_stubs with emit_patcher_traps.
(codegen_emit_stub_native): Likewise.

* src/vm/jit/mips/codegen.h (PATCHER_CALL_INSTRUCTIONS): Changed to 1.
(PATCHER_CALL_SIZE): Changed to 1*4.
(PATCHER_NOPS): Emit only one NOP.

* src/vm/jit/mips/linux/md-os.c (md_signal_handler_sigsegv): Check for
exception, set PC in trap-case.

* src/vm/jit/mips/irix/md-os.c (md_signal_handler_sigsegv): Check for
exception.

* src/vm/jit/mips/patcher.c: Renamed function to new patcher
functions, and use patcher references.
(vm/jit/patcher.h): Removed.
(vm/jit/patcher-common.h): Added
(patcher_wrapper): Removed.

* src/vm/jit/mips/asmpart.S (asm_patcher_wrapper): Removed.

16 years ago* src/vm/jit/mips/arch.h (SUPPORT_PASS_FLOATARGS_IN_INTREGS): Removed
twisti [Mon, 6 Aug 2007 14:41:05 +0000 (14:41 +0000)]
* src/vm/jit/mips/arch.h (SUPPORT_PASS_FLOATARGS_IN_INTREGS): Removed
duplicate define.

16 years ago* src/lib/gnu/java/lang/reflect/Method.java
panzi [Mon, 6 Aug 2007 12:44:01 +0000 (12:44 +0000)]
* src/lib/gnu/java/lang/reflect/Method.java
(java.lang.annotation.Annotation): Added import.
(java.util.Map): Added import.
(sun.refelct.annotation.AnnotationParser): Added import.
(declaredAnnotations): Added field (inspired by OpenJDK).
(getAnnotation): Added method.
(getDeclaredAnnotations): Added method.
(declaredAnnotations): Added method (inspired by OpenJDK).
(getParameterAnnotations): Added method.

* src/lib/gnu/java/lang/reflect/Field.java
(java.lang.annotation.Annotation): Added import.
(java.util.Map): Added import.
(sun.refelct.annotation.AnnotationParser): Added import.
(declaredAnnotations): Added field (inspired by OpenJDK).
(getAnnotation): Added method.
(getDeclaredAnnotations): Added method.
(declaredAnnotations): Added method (inspired by OpenJDK).

* src/lib/gnu/java/lang/reflect/Constructor.java:
Copied file from GNU Classpath.
(java.lang.annotation.Annotation): Added import.
(java.util.Map): Added import.
(sun.refelct.annotation.AnnotationParser): Added import.
(declaredAnnotations): Added field (inspired by OpenJDK).
(getAnnotation): Added method.
(getDeclaredAnnotations): Added method.
(declaredAnnotations): Added method (inspired by OpenJDK).
(getParameterAnnotations): Added method.

* src/lib/gnu/sun/reflect/generics/parser/SignatureFormatError.java:
Removed.

* src/lib/gnu/sun/reflect/generics/parser/SignatureParser.java:
Removed. I figured out which class of GNU Classpath to use to replace
this self written class.

* src/lib/gnu/sun/reflect/annotation/AnnotationParser.java:
Added a few comments.
(sun.reflect.generics.parser.SignatureParser): Removed import.
(sun.reflect.generics.parser.SignatureFormatError): Removed import.
(gnu.java.lang.reflect.FieldSignatureParser): Added import.
(parseParameterAnnotations): Added method.
(parseSig): Changed method so it uses GNU Classpaths FieldSignatureParser.

* src/lib/Makefile.am
(VM_JAVA_FILES): Added $(top_srcdir)/src/lib/gnu/java/lang/reflect/Constructor.java
(VM_CLASS_FILES): Added classes/java/lang/reflect/Constructor.class

* src/native/vm/java_lang_Class.c
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS]
(_Jv_java_lang_Class_getDeclaredAnnotations): Cache methodinfo for
sun.reflect.annotation.AnnotationParser.parseAnnotationsIntoArray.

* src/native/vm/gnu/java_lang_reflect_Method.c
[ENABLE_ANNOTATIONS] (native/vm/reflect.h): Added include.
[ENABLE_ANNOTATIONS] (declaredAnnotations): Added method.
[ENABLE_ANNOTATIONS] (getParameterAnnotations): Added method.
[ENABLE_ANNOTATIONS] (Java_java_lang_reflect_Method_getDefaultValue):
Cache methodinfo for sun.reflect.annotation.AnnotationParser.parseDefaultValue.
[ENABLE_ANNOTATIONS] (Java_java_lang_reflect_Method_declaredAnnotations): Added.
[ENABLE_ANNOTATIONS] (Java_java_lang_reflect_Method_getParameterAnnotations): Added.

* src/native/vm/gnu/java_lang_reflect_Field.c
[ENABLE_ANNOTATIONS] (native/include/sun_reflect_ConstantPool.h): Added include.
[ENABLE_ANNOTATIONS] (native/vm/reflect.h): Added include.
[ENABLE_ANNOTATIONS] (declaredAnnotations): Added method.
[ENABLE_ANNOTATIONS] (Java_java_lang_reflect_Field_declaredAnnotations): Added.

* src/native/vm/gnu/java_lang_reflect_Constructor.c
[ENABLE_ANNOTATIONS] (vm/vm.h): Added include.
[ENABLE_ANNOTATIONS] (native/include/sun_reflect_ConstantPool.h): Added include.
[ENABLE_ANNOTATIONS] (native/vm/reflect.h): Added include.
[ENABLE_ANNOTATIONS] (declaredAnnotations): Added method.
[ENABLE_ANNOTATIONS] (getParameterAnnotations): Added method.
[ENABLE_ANNOTATIONS] (Java_java_lang_reflect_Constructor_declaredAnnotations): Added.
[ENABLE_ANNOTATIONS] (Java_java_lang_reflect_Constructor_getParameterAnnotations): Added.

* src/native/vm/reflect.c
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (vm/vm.h): Added include.
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (native/include/sun_reflect_ConstantPool.h): Added include.
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (reflect_get_declaredannotatios): Added.
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (reflect_get_parameterannotations): Added.

* src/native/vm/reflect.h
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (reflect_get_declaredannotatios): Added.
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (reflect_get_parameterannotations): Added.

* src/native/vm/sun/jvm.c
(JVM_GetDeclaredClasses): Implemented (needed by a testcase of mine).

* src/vmcore/method.c (method_get_parametercount): Added.
This function gets the parameter count of a method (not counting the
this pointer of non-static methods). Returns -1 in case of an error.

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

16 years ago* src/vm/jit/codegen-common.c (codegen_add_patch_ref): Removed obsolete code
michi [Mon, 6 Aug 2007 12:42:31 +0000 (12:42 +0000)]
* src/vm/jit/codegen-common.c (codegen_add_patch_ref): Removed obsolete code
about PATCHER_LONGBRANCHES_NOPS.

16 years ago* src/vm/jit/emit-common.c (emit_patcher_traps): Added.
michi [Mon, 6 Aug 2007 12:19:01 +0000 (12:19 +0000)]
* src/vm/jit/emit-common.c (emit_patcher_traps): Added.

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

* src/vm/jit/alpha/emit.c (emit_patcher_traps): Removed (moved to emit-common).
(emit_trap): Implemented.

* src/vm/jit/arm/emit.c: Likewise.

* src/vm/jit/powerpc/emit.c: Likewise.

* src/vm/jit/s390/emit.c: Likewise.

16 years ago* src/vm/jit/replace.c (replace_read_executionstate): Improved comments.
edwin [Sun, 5 Aug 2007 20:41:25 +0000 (20:41 +0000)]
* src/vm/jit/replace.c (replace_read_executionstate): Improved comments.
(replace_write_executionstate): Likewise.

16 years ago* src/vm/jit/replace.c (replace_new_sourceframe): Fixed documentation.
edwin [Sun, 5 Aug 2007 20:15:27 +0000 (20:15 +0000)]
* src/vm/jit/replace.c (replace_new_sourceframe): Fixed documentation.

16 years ago* src/vm/jit/patcher-common.c (stdint.h): Added.
twisti [Sun, 5 Aug 2007 11:04:21 +0000 (11:04 +0000)]
* src/vm/jit/patcher-common.c (stdint.h): Added.
(patcher_list_free): Removed unused variable pr.
(patcher_add_patch_ref): Fixed warning.

16 years ago* src/native/vm/sun/jvm.c (JVM_Available) [FIONREAD]: Use
twisti [Sun, 5 Aug 2007 10:58:21 +0000 (10:58 +0000)]
* src/native/vm/sun/jvm.c (JVM_Available) [FIONREAD]: Use
HotSpot-compatible code.

16 years ago* src/vm/jit/patcher-common.c (patcher_list_reset): Added.
michi [Fri, 3 Aug 2007 19:06:37 +0000 (19:06 +0000)]
* src/vm/jit/patcher-common.c (patcher_list_reset): Added.
(patcher_add_patch_ref) [!NDEBUG]: Added sanity check.

* src/vm/jit/patcher-common.h (patcher_list_reset): Added.

* src/vm/jit/codegen-common.c (codegen_reset): Resets the patcher list.

16 years ago* src/vm/jit/patcher-common.c (patcher_handler): Call LOCK_MONITOR_EXIT instead of...
pm [Fri, 3 Aug 2007 18:43:30 +0000 (18:43 +0000)]
* src/vm/jit/patcher-common.c (patcher_handler): Call LOCK_MONITOR_EXIT instead of LOCK_MONITOR_ENTER in double-patching handler code.

16 years ago* src/native/vm/sun/jvm.c (JVM_RaiseSignal): New function.
twisti [Thu, 2 Aug 2007 14:46:00 +0000 (14:46 +0000)]
* src/native/vm/sun/jvm.c (JVM_RaiseSignal): New function.

16 years ago* m4/ac_prog_javac.m4 (AC_PROG_JAVAC): Removed -1.5 from ecj.
twisti [Wed, 1 Aug 2007 22:47:17 +0000 (22:47 +0000)]
* m4/ac_prog_javac.m4 (AC_PROG_JAVAC): Removed -1.5 from ecj.

* src/lib/Makefile.am (vm.zip): Added -source 1.5 -target 1.5. Thanks
to Mark Wielaard.

16 years ago* jit/patcher.h: Added #error if included on s390.
pm [Wed, 1 Aug 2007 15:26:59 +0000 (15:26 +0000)]
* jit/patcher.h: Added #error if included on s390.
* jit/patcher-common.h: Made declarations visible on s390.
* jit/s390/asmpart.S (asm_patcher_wrapper): removed.
* jit/s390/emit.c (emit_patcher_stubs): removed, (emit_patcher_traps): added.
* jit/s390/codegen.h (PATCHER_LONGBRANCHES_NOPS_SKIP, PATCHER_LONGBRANCHES_NOPS): removed, (PATCHER_CALL_SIZE, PATCHER_NOPS, PATCHER_NOPS_SKIP) adapted to patching via signals.
* jit/s390/codegen.c (codegen_emit, codegen_emit_stub_native): Adapted to paching via signals.
* jit/s390/md.c (md_signal_handler_sigill, md_signal_handler_sigsegv): added support for exceptions_new_hardware_exception returning NULL.
* jit/s390/patcher.c: Adapted to paching via signals.

16 years ago* m4/annotations.m4: New file.
twisti [Tue, 31 Jul 2007 13:16:43 +0000 (13:16 +0000)]
* m4/annotations.m4: New file.
* configure.ac: Use AC_CHECK_ENABLE_ANNOTATIONS.

16 years ago* src/lib/gnu/java/lang/reflect/Method.java
panzi [Tue, 31 Jul 2007 12:59:03 +0000 (12:59 +0000)]
* src/lib/gnu/java/lang/reflect/Method.java
(annotations): Added.
(parameterAnnotations): Added.
(annotationDefault): Added.

* src/lib/gnu/java/lang/reflect/Field.java
(annotations): Added.

* src/lib/gnu/sun/reflect: New directory.
* src/lib/gnu/sun/reflect/generics: New directory.
* src/lib/gnu/sun/reflect/generics/parser: New directory.
* src/lib/gnu/sun/reflect/generics/parser/SignatureFormatError.java:
New file.

* src/lib/gnu/sun/reflect/generics/parser/SignatureParser.java:
New file. This class parses type signatures and returns the acording type
as a java.lang.Class instance.

* src/lib/gnu/sun/reflect/ConstantPool.java [WITH_CLASSPATH_GNU]:
New file.

* src/lib/gnu/sun/reflect/annotation: New directory.
* src/lib/gnu/sun/reflect/annotation/AnnotationTypeMismatchExceptionProxy.java
[WITH_CLASSPATH_GNU]: Copied file from OpenJDK.

* src/lib/gnu/sun/reflect/annotation/TypeNotPresentExceptionProxy.java
[WITH_CLASSPATH_GNU]: Copied file from OpenJDK.

* src/lib/gnu/sun/reflect/annotation/AnnotationParser.java
[WITH_CLASSPATH_GNU]: Copied file from OpenJDK and changed a bit so
it can be used with GNU Classpath.
[WITH_CLASSPATH_GNU] (parseAnnotationsIntoArray): Added for
convenience.
[WITH_CLASSPATH_GNU] (parseAnnotationDefault): Added for convenience.

* src/lib/gnu/sun/reflect/annotation/AnnotationType.java
[WITH_CLASSPATH_GNU]: Copied file from OpenJDK and changed a bit so
it can be used with GNU Classpath.
[WITH_CLASSPATH_GNU] (annotationTypes): Added to emulate
sun.misc.SharedSecrets.getJavaLangAccess().getAnnotationType() and
sun.misc.SharedSecrets.getJavaLangAccess().setAnnotationType().

* src/lib/Makefile.am [WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS]: Added
classes needed by annotations support.

* src/native/vm/nativevm.h
[ENABLE_ANNOTATIONS] (_Jv_sun_reflect_ConstantPool_init): Added.

* src/native/vm/java_lang_Class.c
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (vmcore/annotation.h):
Include added.
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS]
(native/include/sun_reflect_ConstantPool.h): Include added.
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS]
(_Jv_java_lang_Class_getDeclaredAnnotations): Implemented.

* src/native/vm/gnu/java_lang_VMClass.c
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS]
(Java_java_lang_VMClass_getDeclaredAnnotations): Implemented.

* src/native/vm/gnu/sun_reflect_ConstantPool.c [ENABLE_ANNOTATIONS]:
Added implementation of sun.reflect.ConstantPool class. This is an copy
of the according functions from src/native/vm/sun/jvm.c for I don't know
how to unify it better (needs to be discussed).

* src/native/vm/gnu/java_lang_reflect_Method.c
[ENABLE_ANNOTATIONS] (vm/vm.h): Added include.
[ENABLE_ANNOTATIONS] (native/include/sun_reflect_ConstantPool.h):
Added include.
[ENABLE_ANNOTATIONS] (Java_java_lang_reflect_Method_getDefaultValue):
Implemented.

* src/native/vm/gnu/Makefile.am
[ENABLE_ANNOTATIONS] (SUN_REFLECT_SOURCES): Added sun_reflect_ConstantPool.c

* src/native/vm/java_lang_Class.h
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS]
(_Jv_java_lang_Class_getDeclaredAnnotations): Added.

* src/native/vm/sun/jvm.c
(assert.h): Added include.
(native/include/java_lang_Integer.h): Added include.
(native/include/java_lang_Long.h): Added include.
(native/include/java_lang_Short.h): Added include.
(native/include/java_lang_Byte.h): Added include.
(native/include/java_lang_Character.h): Added include.
(native/include/java_lang_Boolean.h): Added include.
(native/include/java_lang_Float.h): Added include.
(native/include/java_lang_Double.h): Added include.
[ENABLE_ANNOTATIONS] (native/include/sun_reflect_ConstantPool.h):
Added include.
(JVM_GetDeclaringClass): Implemented.
(JVM_GetClassAnnotations) [ENABLE_ANNOTATIONS]: Implemented.
(JVM_GetFieldAnnotations): Implemented.
(JVM_GetMethodAnnotations): Implemented.
(JVM_GetMethodDefaultAnnotationValue): Implemented.
(JVM_GetMethodParameterAnnotations): Implemented.
[ENABLE_ANNOTATIONS] (JVM_GetClassConstantPool): Implemented.
(JVM_ConstantPoolGetSize): Implemented.
(JVM_ConstantPoolGetClassAt): Implemented.
(JVM_ConstantPoolGetClassAtIfLoaded): Implemented.
(JVM_ConstantPoolGetMethodAt): Implemented.
(JVM_ConstantPoolGetMethodAtIfLoaded): Implemented.
(JVM_ConstantPoolGetFieldAt): Implemented.
(JVM_ConstantPoolGetFieldAtIfLoaded): Implemented.
(JVM_ConstantPoolGetIntAt): Implemented.
(JVM_ConstantPoolGetLongAt): Implemented.
(JVM_ConstantPoolGetFloatAt): Implemented.
(JVM_ConstantPoolGetDoubleAt): Implemented.
(JVM_ConstantPoolGetStringAt): Implemented.
(JVM_ConstantPoolGetUTF8At): Implemented.
(JVM_GetArrayElement): Quickly implemented (will be rewritten by
twisti). I needed this function in a testcase and not directly for
annotations support.

* src/native/vm/reflect.c
[ENABLE_ANNOTATIONS] (mm/memmory.h): Added include.
(reflect_constructor_new) [ENABLE_ANNOTATIONS]: Load annotations and
parameter annotations.
(reflect_field_new) [ENABLE_ANNOTATIONS]: Load annotations.
(reflect_method_new) [ENABLE_ANNOTATIONS]: Load annotations, parameter
annotations and annotation default value.

* src/native/vm/nativevm.c [WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS]
(_Jv_sun_reflect_ConstantPool_init): Added call.

* src/native/include/Makefile.am
[WITH_CLASSPATH_GNU] [ENABLE_ANNOTATIONS] (JAVASE_HEADER_FILES):
Added sun_reflect_ConstantPool.h

* src/vmcore/class.c
[ENABLE_ANNOTATIONS] (class_sun_reflect_ConstantPool): Added.
[ENABLE_ANNOTATIONS] (class_sun_reflect_annotation_AnnotationParser):
Added.
(class_load_attributes) [ENABLE_ANNOTATIONS]: Load annotations.
(class_free) [ENABLE_ANNOTATIONS]: Free annotations.

* src/vmcore/loader.c
(loader_init) [ENABLE_ANNOTATIONS]: Load
class_sun_reflect_ConstantPool.
(loader_init) [ENABLE_ANNOTATIONS] [WITH_CLASSPATH_GNU]: Load
class_sun_reflect_annotation_AnnotationParser.

* src/vmcore/annotation.c [!ENABLE_ANNOTATIONS]: Error: annotation
support has to be enabled when compling this file.
(assert.h): Added include.
(toolbox/logging.h): Added include.
(annotation_bytearray_new): Added.
(annotation_bytearray_free): Added.
(annotation_bytearrays_new): Added.
(annotation_bytearrays_resize): Added.
(annotation_bytearrays_insert): Added.
(annotation_bytearrays_free): Added.
(annotation_load_attribute_body): Added. Maybe this function should be
called loader_load_attribute_body and located in vmcore/loader.c?
(annotation_load_method_attribute_annotationdefault): Added.
(annotation_load_method_attribute_runtimevisibleparameterannotations):
Added.
(annotation_load_method_attribute_runtimeinvisibleparameterannotations):
Added.
(annotation_load_class_attribute_runtimevisibleannotations): Added.
(annotation_load_class_attribute_runtimeinvisibleannotations): Added.
(annotation_load_method_attribute_runtimevisibleannotations): Added.
(annotation_load_method_attribute_runtimeinvisibleannotations): Added.
(annotation_load_field_attribute_runtimevisibleannotations): Added.
(annotation_load_field_attribute_runtimeinvisibleannotations): Added.

* src/vmcore/class.h
[ENABLE_ANNOTATIONS] (runtimevisibleannotationscount): Removed.
[ENABLE_ANNOTATIONS] (runtimevisibleannotations): Removed.
[ENABLE_ANNOTATIONS] (annotations): Added. Bytearray of the unparsed
annotations or NULL if none.
[ENABLE_ANNOTATIONS] (method_annotations): Added. Array of bytearrays
of method annotations. This Array is only as big as needed or NULL if
there are no method annotations at all.
[ENABLE_ANNOTATIONS] (method_parameterannotations): Added. Array of bytearrays
of method parameter annotations. This Array is only as big as needed
or NULL if there are no method parameter annotations at all.
[ENABLE_ANNOTATIONS] (method_annotationdefaults): Added. Array of bytearrays
of method annotation default values. This Array is only as big as
needed or NULL if there are no method annotation default values at all.
[ENABLE_ANNOTATIONS] (field_annotations): Added. Array of bytearrays
of field annotations. This Array is only as big as needed or NULL if
there are no field annotations at all.
[ENABLE_ANNOTATIONS] (class_sun_reflect_ConstantPool): Added.
[ENABLE_ANNOTATIONS] [WITH_CLASSPATH_GNU]
(class_sun_reflect_annotation_AnnotationParser): Added.

* src/vmcore/annotation.h
(annotation_bytearray_t): Added. Used to store unparsed (parameter-) annotations or
unparsed annotation default values in.
(annotation_bytearrays_t): Added. Array of bytearrays.
(annotation_bytearray_new): Added.
(annotation_bytearray_free): Added.
(annotation_bytearrays_new): Added.
(annotation_bytearrays_resize): Added.
(annotation_bytearrays_insert): Added.
(annotation_bytearrays_free): Added.
(annotation_load_class_attribute_runtimeinvisibleannotations): Added.
(annotation_load_method_attribute_runtimevisibleannotations): Added.
(annotation_load_method_attribute_runtimeinvisibleannotations): Added.
(annotation_load_field_attribute_runtimevisibleannotations): Added.
(annotation_load_field_attribute_runtimeinvisibleannotations): Added.
(annotation_load_method_attribute_annotationdefault): Added.
(annotation_load_method_attribute_runtimevisibleparameterannotations):
Added.
(annotation_load_method_attribute_runtimeinvisibleparameterannotations):
Added.

* src/vmcore/method.c
(method_load) [ENABLE_ANNOTATIONS]: Load annotations, parameter
annotations and annotation default values.
[ENABLE_ANNOTATIONS] (method_get_annotations): Added.
[ENABLE_ANNOTATIONS] (method_get_parameterannotations): Added.
[ENABLE_ANNOTATIONS] (method_get_annotationdefault): Added.

* src/vmcore/method.h
[ENABLE_ANNOTATIONS] (method_get_annotations): Added.
[ENABLE_ANNOTATIONS] (method_get_parameterannotations): Added.
[ENABLE_ANNOTATIONS] (method_get_annotationdefault): Added.

* src/vmcore/field.c
(mm/memory.h): Added include.
(vmcore/annotations.h): Added include.
(field_load) [ENABLE_ANNOTATIONS]: Laod annotations.
[ENABLE_ANNOTATIONS] (field_get_annotations): Added.

* src/vmcore/utf8.c
[ENABLE_ANNOTATIONS] (utf_sun_reflect_ConstantPool): Added.
[ENABLE_ANNOTATIONS] (utf_RuntimeInvisibleAnnotations): Added.
[ENABLE_ANNOTATIONS] (utf_RuntimeVisibleParameterAnnotations): Added.
[ENABLE_ANNOTATIONS] (utf_RuntimeInvisibleParameterAnnotations):
Added.
[ENABLE_ANNOTATIONS] (utf_AnnotationDefault): Added.
[ENABLE_ANNOTATIONS] [WITH_CLASSPATH_GNU]
(utf_sun_reflect_annotation_AnnotationParser): Added.

* src/vmcore/field.h
[ENABLE_ANNOTATIONS] (field_get_annotations): Added.

* src/vmcore/Makefile.am
[ENABLE_ANNOTATIONS] (ANNOTATION_SOURCES): Only compile annotations
sources when annotations are enabled.

* src/vmcore/utf8.h
[ENABLE_ANNOTATIONS] (utf_sun_reflect_ConstantPool): Added.
[ENABLE_ANNOTATIONS] (utf_RuntimeInvisibleAnnotations): Added.
[ENABLE_ANNOTATIONS] (utf_RuntimeVisibleParameterAnnotations): Added.
[ENABLE_ANNOTATIONS] (utf_RuntimeInvisibleParameterAnnotations):
Added.
[ENABLE_ANNOTATIONS] (utf_AnnotationDefault): Added.
[ENABLE_ANNOTATIONS] [WITH_CLASSPATH_GNU]
(utf_sun_reflect_annotation_AnnotationParser): Added.

* configure.ac (ENABLE_ANNOTATIONS): Added configure option --enable-annotations.

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).