[kaffe] compiling kaffe CVS on linux with gcc 2.95.x issue: undefined reference to `__builtin_expect'
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all, if I compile (it's a cross-compilation, but it doesn't matter) kaffe Cvs on linux with a gcc 2.95.3, I take - arm-unknown-linux-gnu-gcc -g -O2 -Wchar-subscripts -Wcomment -Wformat=2 - -Wimplicit-function-declaration -Wimplicit-int -Wmain -Wmissing-braces - -Wparentheses -Wreturn-type -Wswitch -Wtrigraphs -Wunknown-pragmas -W - -Wundef -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual - -Wcast-align -Wwrite-strings -Wconversion -Wsign-compare - -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes - -Wmissing-declarations -Wmissing-noreturn -Wredundant-decls - -Wnested-externs -Winline -Wlong-long -fsigned-char - -fno-omit-frame-pointer -pthread -DENABLE_BINRELOC -o .libs/kaffe-bin main.o version.o .libs/kaffe-binS.o -Wl,--export-dynamic ../kaffevm/.libs/libkaffevm.so /home/gpciceri/works/cvsroot/kaffe-arm-crosstool-glibc213/kaffe/kaffevm/verifier/.libs/libkaffeverifier.so /home/gpciceri/works/cvsroot/kaffe-arm-crosstool-glibc213/kaffe/kaffevm/kaffe-gc/.libs/libkaffegc.so - -lm ../../replace/.libs/libreplace.so ../../libltdl/.libs/libltdlc.a - -ldl -Wl,--rpath - -Wl,/usr/local/kaffe-arm-cvs-X-crosstool-glibc213/jre/lib/arm ../kaffevm/.libs/libkaffevm.so: undefined reference to `__builtin_expect' collect2: ld returned 1 exit status make[2]: *** [kaffe-bin] Error 1 - it seems that it's a rather known issue, for example see http://boudicca.tux.org/hypermail/linux-kernel/2001week17/0009.html in linux/compiler.h there's the #define that it's needed. Of course, I've no idea where to actually put such a kind of fix in kaffe sources. I suppose something in config/katomic.h: at least, if I add the #include, it builds succesfully. Regards /gp - -- gian paolo ciceri - japanman suddenthinks, excellence through refactoring ++39 340 7218101 [EMAIL PROTECTED] [EMAIL PROTECTED] -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.6 (GNU/Linux) Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org iD8DBQFCTQQH5CXmEF0gaHgRAvCuAKCuP1u+VraeQPCpNSb3nqttI5q8hwCfeQFV CBT+3D5HZOb/vIg/advIC3M= =+Ubb -END PGP SIGNATURE- ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] jit failure on MIPS
Hey, I'm trying JIT on linux/mips, using jthreads 'since pthreads are broken with intrp already). the jitBasic regression fails with: Success field: test_0x0001__long_method_long = 0x Success field: test_0xdeadbeefd0decade__long_method_long = 0x Success deadbeef field: test_0__float_method_float = 0x callinfo = 0x7fff6a38 Method: ParameterizedMethods.float_method_float(F)F L0: 1 @0: fload 0 @1: freturn 0: prologue: 18: mov i1,fp 18: mov fp,sp 18: addiu sp,sp,-framesize 18: sw ra,-4(fp) 18: sw i1,-8(fp) 18: sw gp,-12(fp) 20: movegp,i25 20: sw gp,-16(fp) 24: sw i16,-16(fp) 28: sw i17,-20(fp) 2c: sw i18,-24(fp) 30: sw i19,-28(fp) 34: sw i20,-32(fp) 38: sw i21,-36(fp) 3c: sw i22,-40(fp) 40: sw i23,-44(fp) 40: check_stack_limit: 48: sgtui25,i5,sp 48: bne i25,zero,+3 4c: nop 54: call [soft_stackoverflow] 58: nop /bin/sh: line 1: 15443 Aborted env TEST_ CLASSES=ConstMethods.class ConstMathMethods.class ParameterizedMethods. class ParameterizedMathMethods.class ParameterizedLogicalMethods.class ParameterizedBitwiseMethods.class ControlFlowMethods.class StaticMethodCall.class TypeConversion.class StaticFields.class PrimitiveArrays.class ObjectFields.class MethodOptimizations.class NativeMethodCall.class Exceptions.class `BOOTCLASSPATH=.; export BOOTCLASSPATH; . ../../BUILD_ENVIRONMENT; sed 's/.*export \(.*\)/echo \ 1=$\1/' ../../BUILD_ENVIRONMENT | sh` ${dir}$tst FAIL: jitBasic 1 of 1 tests failed Please report to kaffe@kaffe.org Ideas ? -R ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] building with gcc 2.95 (variadic macro issue in config/katomic.h)
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello all, there's still an issue to build kaffe cvs with gcc 2.95.x: the variadic macro syntax is changed (thanks dalibor for the analysis). So in config/katomic.h, at least, there's something to change. so here's my trivial fix: - #if __GNUC__ == 2 #define __atomic_val_bysize(pre, post, mem, args...)\ ~ ({ \ ~__typeof (*mem) __result;\ ~if (sizeof (*mem) == 1) \ ~ __result = pre##_8_##post (mem, args...); \ ~else if (sizeof (*mem) == 2) \ ~ __result = pre##_16_##post (mem, args...); \ ~else if (sizeof (*mem) == 4) \ ~ __result = pre##_32_##post (mem, args...);\ ~else if (sizeof (*mem) == 8) \ ~ __result = pre##_64_##post (mem, args...); \ ~else \ ~ abort (); \ ~__result;\ ~ }) #define __atomic_bool_bysize(pre, post, mem, args...) \ ~ ({ \ ~int __result;\ ~if (sizeof (*mem) == 1)\ ~ __result = pre##_8_##post (mem, args...); \ ~else if (sizeof (*mem) == 2) \ ~ __result = pre##_16_##post (mem, args...); \ ~else if (sizeof (*mem) == 4) \ ~ __result = pre##_32_##post (mem, args...); \ ~else if (sizeof (*mem) == 8)\ ~ __result = pre##_64_##post (mem, args...); \ ~else \ ~ abort (); \ ~__result;\ ~ }) #else ... the actual macro definitions #endif - regards /gp - -- gian paolo ciceri - japanman suddenthinks, excellence through refactoring ++39 340 7218101 [EMAIL PROTECTED] [EMAIL PROTECTED] -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.6 (GNU/Linux) Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org iD8DBQFCTStI5CXmEF0gaHgRAiAfAJ0cpspYWB7CFpsv6XhzOsBpNqW/2gCfdaC0 YfHvuMGvOyKlMfDpUHMOdks= =sSxg -END PGP SIGNATURE- ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] Assertions
Hi, Here are two annoyances with assertions on kaffe. I don't think either is critical, but it would be nice to have them fixed eventually. Here is the testcase: public class Test { public static void main(String[] args) { assert false; } } 1) kaffe always evaluates assertions. I don't see a way to disable them. (For reference, they are off by default in the JDK) 2) when compiling this with JDK1.5, the generated bytecode crashes kaffe. According to Dalibor this is because of the new ldc bytecode for loading class literals. I attach the generated class, for people who don't have jdk1.5 at all. Daniel Test.class Description: application/java-vm ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
Re: [kaffe] CVS kaffe (robilad): Added workaround for missing __builtin_expect from gcc
This seems to have broken most of the tinderbox. gmake[1]: *** No rule to make target `gccbuiltin.h', needed by `all-am'. Stop. On Apr 1, 2005 12:17 AM, Kaffe CVS [EMAIL PROTECTED] wrote: PatchSet 5633 Date: 2005/04/01 05:12:40 Author: robilad Branch: HEAD Tag: (none) Log: Added workaround for missing __builtin_expect from gcc 2005-04-01 Dalibor Topic [EMAIL PROTECTED] Define __builtin_expected away on gcc 3.0 * include/Makefile.am (noinst_HEADERS): Added gccbuiltin.h. * include/defs.h: Include gccbuiltin.h. * include/gccbuiltin.h: New file. Taken from gcc CVS file gcc/gcc/system.h. Reported by: Riccardo Mottola [EMAIL PROTECTED] ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
Re: [kaffe] CVS kaffe (robilad): Added workaround for missing __builtin_expect from gcc
Michael Franz wrote: This seems to have broken most of the tinderbox. gmake[1]: *** No rule to make target `gccbuiltin.h', needed by `all-am'. Stop. Yeah, I forgot to add the file. And it wasn't even intended as a bad April 1st joke :( cheers, dalibor topic ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] CVS kaffe (guilhem): Recursive lock fix.
PatchSet 5635 Date: 2005/04/01 17:00:51 Author: guilhem Branch: HEAD Tag: (none) Log: Recursive lock fix. Members: ChangeLog:1.3806-1.3807 kaffe/kaffevm/locks.c:1.60-1.61 Index: kaffe/ChangeLog diff -u kaffe/ChangeLog:1.3806 kaffe/ChangeLog:1.3807 --- kaffe/ChangeLog:1.3806 Fri Apr 1 06:22:11 2005 +++ kaffe/ChangeLog Fri Apr 1 17:00:51 2005 @@ -1,3 +1,8 @@ +2005-04-01 Guilhem Lavaux [EMAIL PROTECTED] + + * kaffe/kaffevm/locks.c + (waitCond): Unlock completely the mutex (the lock may be recursive). + 2005-04-01 Dalibor Topic [EMAIL PROTECTED] * libraries/javalib/Makefile.am.in (clean-local): Index: kaffe/kaffe/kaffevm/locks.c diff -u kaffe/kaffe/kaffevm/locks.c:1.60 kaffe/kaffe/kaffevm/locks.c:1.61 --- kaffe/kaffe/kaffevm/locks.c:1.60Sun Mar 20 20:30:43 2005 +++ kaffe/kaffe/kaffevm/locks.c Fri Apr 1 17:00:55 2005 @@ -366,6 +366,7 @@ volatile jthread_t *ptr; jboolean r; threadData *tdata; + unsigned int oldLockCount; DBG(SLOWLOCKS, dprintf(_waitCond(lk=%p, timeout=%ld, th=%p)\n, @@ -384,6 +385,11 @@ tdata = KTHREAD(get_data)(cur); tdata-nextlk = lk-cv; lk-cv = cur; + /* Here we need to reduce the lock count to 1 to be sure + * the lock is completely released when we invoke slowUnlockMutex. + */ + oldLockCount = lk-lockCount; + lk-lockCount = 1; putHeavyLock(lk); slowUnlockMutex((volatile iLock *volatile *)lkp, heavyLock); @@ -417,6 +423,10 @@ } slowLockMutex((volatile iLock *volatile *)lkp, heavyLock); + /* This is safe as no other thread touches the lockcount if it is not + * owning the lock. + */ + lk-lockCount = oldLockCount; return (r); } ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] CVS kaffe (guilhem): Check for thread subsystem initialization in jthread_*suspendall
PatchSet 5636 Date: 2005/04/01 17:21:50 Author: guilhem Branch: HEAD Tag: (none) Log: Check for thread subsystem initialization in jthread_*suspendall Members: ChangeLog:1.3807-1.3808 kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.78-1.79 Index: kaffe/ChangeLog diff -u kaffe/ChangeLog:1.3807 kaffe/ChangeLog:1.3808 --- kaffe/ChangeLog:1.3807 Fri Apr 1 17:00:51 2005 +++ kaffe/ChangeLog Fri Apr 1 17:21:50 2005 @@ -1,5 +1,12 @@ 2005-04-01 Guilhem Lavaux [EMAIL PROTECTED] + * kaffe/kaffevm/systems/unix-pthreads/thread-impl.c + (jthread_suspendall, jthread_unsuspendall): Check whether the thread + subsystem has been initialized as some architecture needs to invoke it + for compare and exchange. + +2005-04-01 Guilhem Lavaux [EMAIL PROTECTED] + * kaffe/kaffevm/locks.c (waitCond): Unlock completely the mutex (the lock may be recursive). Index: kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c diff -u kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.78 kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.79 --- kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c:1.78Mon Mar 28 19:32:52 2005 +++ kaffe/kaffe/kaffevm/systems/unix-pthreads/thread-impl.c Fri Apr 1 17:21:52 2005 @@ -1345,6 +1345,9 @@ int status; jthread_tcur = jthread_current(); volatile jthread_t t; + + if (!jthreadInitialized) +return; /* don't allow any new thread to be created or recycled until this is done */ protectThreadList(cur); @@ -1442,7 +1445,7 @@ jthread_tt; int status; - if ( !critSection ) + if ( !jthreadInitialized || !critSection ) return; if ( --critSection == 0 ){ ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] CVS kaffe (robilad): Foolishly missed to add file
PatchSet 5637 Date: 2005/04/01 18:31:42 Author: robilad Branch: HEAD Tag: (none) Log: Foolishly missed to add file Members: include/gccbuiltin.h:INITIAL-1.1 === Checking out kaffe/include/gccbuiltin.h RCS: /home/cvs/kaffe/kaffe/include/gccbuiltin.h,v VERS: 1.1 *** --- /dev/null Sun Aug 4 19:57:58 2002 +++ kaffe/include/gccbuiltin.h Fri Apr 1 18:36:17 2005 @@ -0,0 +1,33 @@ +/* Get common system includes and various definitions and declarations based + on autoconf macros. + Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 + Free Software Foundation, Inc. + +This file is part of GCC. + +GCC is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 2, or (at your option) any later +version. + +GCC is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License +along with GCC; see the file COPYING. If not, write to the Free +Software Foundation, 59 Temple Place - Suite 330, Boston, MA +02111-1307, USA. */ + +#ifndef GCCBUILTIN_H +#define GCCBUILTIN_H + +/* __builtin_expect(A, B) evaluates to A, but notifies the compiler that + the most likely value of A is B. This feature was added at some point + between 2.95 and 3.0. Let's use 3.0 as the lower bound for now. */ +#if (GCC_VERSION 3000) +#define __builtin_expect(a, b) (a) +#endif + +#endif ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] Porting Kaffe on uclinux
Hello , Have someone ported kaffe on uclinux , if you have information contact me please, Thanks, Best regards, ZAK ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
Re: [kaffe] patch for freebsd 4.x to config/i386/atomic.h
Am Freitag, den 01.04.2005, 12:30 +0530 schrieb Supreet Sethi: patch for issues in config/i386/atomic.h. specifically needed for freebsd 4.x Thank you very much for your patch, Supreet! I've checked it in. cheers, dalibor topic ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] CVS kaffe (robilad): FreeBSD 4.8 build fix
PatchSet 5638 Date: 2005/04/01 20:15:26 Author: robilad Branch: HEAD Tag: (none) Log: FreeBSD 4.8 build fix 2005-04-01 Supreet Sethi [EMAIL PROTECTED] * configure.ac: Check for uintmax_t and intmax_t. * config/i386/atomic.h: Only use uintmax_t and intmax_t if the types are available. Members: ChangeLog:1.3808-1.3809 configure:1.441-1.442 configure.ac:1.131-1.132 config/config.h.in:1.140-1.141 config/i386/atomic.h:1.2-1.3 Index: kaffe/ChangeLog diff -u kaffe/ChangeLog:1.3808 kaffe/ChangeLog:1.3809 --- kaffe/ChangeLog:1.3808 Fri Apr 1 17:21:50 2005 +++ kaffe/ChangeLog Fri Apr 1 20:15:26 2005 @@ -1,3 +1,10 @@ +2005-04-01 Supreet Sethi [EMAIL PROTECTED] + + * configure.ac: Check for uintmax_t and intmax_t. + + * config/i386/atomic.h: Only use uintmax_t and intmax_t if + the types are available. + 2005-04-01 Guilhem Lavaux [EMAIL PROTECTED] * kaffe/kaffevm/systems/unix-pthreads/thread-impl.c Index: kaffe/configure diff -u kaffe/configure:1.441 kaffe/configure:1.442 --- kaffe/configure:1.441 Thu Mar 31 11:55:09 2005 +++ kaffe/configure Fri Apr 1 20:15:29 2005 @@ -34367,6 +34367,134 @@ _ACEOF fi +echo $as_me:$LINENO: checking for uintmax_t 5 +echo $ECHO_N checking for uintmax_t... $ECHO_C 6 +if test ${ac_cv_type_uintmax_t+set} = set; then + echo $ECHO_N (cached) $ECHO_C 6 +else + cat conftest.$ac_ext _ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h conftest.$ac_ext +cat conftest.$ac_ext _ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +if ((uintmax_t *) 0) + return 0; +if (sizeof (uintmax_t)) + return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo $as_me:$LINENO: \$ac_compile\) 5 + (eval $ac_compile) 2conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 conftest.err + rm -f conftest.er1 + cat conftest.err 5 + echo $as_me:$LINENO: \$? = $ac_status 5 + (exit $ac_status); } +{ ac_try='test -z $ac_c_werror_flag +|| test ! -s conftest.err' + { (eval echo $as_me:$LINENO: \$ac_try\) 5 + (eval $ac_try) 25 + ac_status=$? + echo $as_me:$LINENO: \$? = $ac_status 5 + (exit $ac_status); }; } +{ ac_try='test -s conftest.$ac_objext' + { (eval echo $as_me:$LINENO: \$ac_try\) 5 + (eval $ac_try) 25 + ac_status=$? + echo $as_me:$LINENO: \$? = $ac_status 5 + (exit $ac_status); }; }; then + ac_cv_type_uintmax_t=yes +else + echo $as_me: failed program was: 5 +sed 's/^/| /' conftest.$ac_ext 5 + +ac_cv_type_uintmax_t=no +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +fi +echo $as_me:$LINENO: result: $ac_cv_type_uintmax_t 5 +echo ${ECHO_T}$ac_cv_type_uintmax_t 6 +if test $ac_cv_type_uintmax_t = yes; then + +cat confdefs.h _ACEOF +#define HAVE_UINTMAX_T 1 +_ACEOF + + +fi +echo $as_me:$LINENO: checking for intmax_t 5 +echo $ECHO_N checking for intmax_t... $ECHO_C 6 +if test ${ac_cv_type_intmax_t+set} = set; then + echo $ECHO_N (cached) $ECHO_C 6 +else + cat conftest.$ac_ext _ACEOF +/* confdefs.h. */ +_ACEOF +cat confdefs.h conftest.$ac_ext +cat conftest.$ac_ext _ACEOF +/* end confdefs.h. */ +$ac_includes_default +int +main () +{ +if ((intmax_t *) 0) + return 0; +if (sizeof (intmax_t)) + return 0; + ; + return 0; +} +_ACEOF +rm -f conftest.$ac_objext +if { (eval echo $as_me:$LINENO: \$ac_compile\) 5 + (eval $ac_compile) 2conftest.er1 + ac_status=$? + grep -v '^ *+' conftest.er1 conftest.err + rm -f conftest.er1 + cat conftest.err 5 + echo $as_me:$LINENO: \$? = $ac_status 5 + (exit $ac_status); } +{ ac_try='test -z $ac_c_werror_flag +|| test ! -s conftest.err' + { (eval echo $as_me:$LINENO: \$ac_try\) 5 + (eval $ac_try) 25 + ac_status=$? + echo $as_me:$LINENO: \$? = $ac_status 5 + (exit $ac_status); }; } +{ ac_try='test -s conftest.$ac_objext' + { (eval echo $as_me:$LINENO: \$ac_try\) 5 + (eval $ac_try) 25 + ac_status=$? + echo $as_me:$LINENO: \$? = $ac_status 5 + (exit $ac_status); }; }; then + ac_cv_type_intmax_t=yes +else + echo $as_me: failed program was: 5 +sed 's/^/| /' conftest.$ac_ext 5 + +ac_cv_type_intmax_t=no +fi +rm -f conftest.err conftest.$ac_objext conftest.$ac_ext +fi +echo $as_me:$LINENO: result: $ac_cv_type_intmax_t 5 +echo ${ECHO_T}$ac_cv_type_intmax_t 6 +if test $ac_cv_type_intmax_t = yes; then + +cat confdefs.h _ACEOF +#define HAVE_INTMAX_T 1 +_ACEOF + + +fi echo $as_me:$LINENO: checking for uint_fast8_t 5 echo $ECHO_N checking for uint_fast8_t... $ECHO_C 6 Index: kaffe/configure.ac diff -u kaffe/configure.ac:1.131 kaffe/configure.ac:1.132 --- kaffe/configure.ac:1.131Thu Mar 31 11:55:15 2005 +++ kaffe/configure.ac Fri Apr 1 20:15:34 2005 @@ -1279,7 +1279,7 @@ if test x$ac_cv_typedef_bool = xyes; then AC_DEFINE(HAVE_BOOL, 1, [Do we have bool]) fi - +AC_CHECK_TYPES([uintmax_t, intmax_t]) AC_CHECK_TYPES([uint_fast8_t,int_fast8_t,uint_fast16_t,int_fast16_t])
[kaffe] CVS kaffe (guilhem): Fixlet for java/awt/image
PatchSet 5639 Date: 2005/04/01 20:37:33 Author: guilhem Branch: HEAD Tag: (none) Log: Fixlet for java/awt/image Members: ChangeLog:1.3809-1.3810 libraries/javalib/java/awt/image/IndexColorModel.java:1.7-1.8 Index: kaffe/ChangeLog diff -u kaffe/ChangeLog:1.3809 kaffe/ChangeLog:1.3810 --- kaffe/ChangeLog:1.3809 Fri Apr 1 20:15:26 2005 +++ kaffe/ChangeLog Fri Apr 1 20:37:33 2005 @@ -7,6 +7,11 @@ 2005-04-01 Guilhem Lavaux [EMAIL PROTECTED] + * java/awt/image/IndexColorModel.java + (getRGB): Check if pixel is negative. + +2005-04-01 Guilhem Lavaux [EMAIL PROTECTED] + * kaffe/kaffevm/systems/unix-pthreads/thread-impl.c (jthread_suspendall, jthread_unsuspendall): Check whether the thread subsystem has been initialized as some architecture needs to invoke it Index: kaffe/libraries/javalib/java/awt/image/IndexColorModel.java diff -u kaffe/libraries/javalib/java/awt/image/IndexColorModel.java:1.7 kaffe/libraries/javalib/java/awt/image/IndexColorModel.java:1.8 --- kaffe/libraries/javalib/java/awt/image/IndexColorModel.java:1.7 Fri Dec 3 09:16:02 2004 +++ kaffe/libraries/javalib/java/awt/image/IndexColorModel.java Fri Apr 1 20:37:37 2005 @@ -432,7 +432,7 @@ */ public final int getRGB (int pixel) { -if (pixel map_size) +if (pixel = 0 pixel map_size) return rgb[pixel]; return 0; ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] katomic.h patch to compile with gcc 2.95.x (varadic macro syntax)
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 in attach /gp - -- gian paolo ciceri - japanman suddenthinks, excellence through refactoring ++39 340 7218101 [EMAIL PROTECTED] [EMAIL PROTECTED] -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.6 (GNU/Linux) Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org iD8DBQFCTbJ/5CXmEF0gaHgRAm8XAKCvajRIIZT4826W3j9EnNMLC3zFtwCghmiN 4SlVXpwCIZRpfeZBxfgKanQ= =oeZA -END PGP SIGNATURE- -- gian paolo ciceri - japanman suddenthinks, excellence through refactoring ++39 340 7218101 [EMAIL PROTECTED] [EMAIL PROTECTED] --- katomic.h.orig 2005-04-01 11:59:34.0 +0200 +++ katomic.h 2005-04-01 13:00:44.0 +0200 @@ -27,6 +27,43 @@ /* Wrapper macros to call pre_NN_post (mem, ...) where NN is the bit width of *MEM. The calling macro puts parens around MEM and following args. */ + + +#if __GNUC__ == 2 + +#define __atomic_val_bysize(pre, post, mem, args...) \ + ({ \ +__typeof (*mem) __result; \ +if (sizeof (*mem) == 1) \ + __result = pre##_8_##post (mem, args...); \ +else if (sizeof (*mem) == 2) \ + __result = pre##_16_##post (mem, args...); \ +else if (sizeof (*mem) == 4) \ + __result = pre##_32_##post (mem, args...); \ +else if (sizeof (*mem) == 8) \ + __result = pre##_64_##post (mem, args...); \ +else \ + abort (); \ +__result; \ + }) +#define __atomic_bool_bysize(pre, post, mem, args...) \ + ({ \ +int __result; \ +if (sizeof (*mem) == 1) \ + __result = pre##_8_##post (mem, args...); \ +else if (sizeof (*mem) == 2) \ + __result = pre##_16_##post (mem, args...); \ +else if (sizeof (*mem) == 4) \ + __result = pre##_32_##post (mem, args...); \ +else if (sizeof (*mem) == 8) \ + __result = pre##_64_##post (mem, args...); \ +else \ + abort (); \ +__result; \ + }) + +#else + #define __atomic_val_bysize(pre, post, mem, ...) \ ({ \ __typeof (*mem) __result; \ @@ -57,7 +94,10 @@ abort (); \ __result; \ }) - + + +#endif + /* Atomically store NEWVAL in *MEM if *MEM is equal to OLDVAL. Return the old *MEM value. */ ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
Re: [kaffe] katomic.h patch to compile with gcc 2.95.x (varadic macro syntax)
Am Freitag, den 01.04.2005, 22:44 +0200 schrieb gian paolo ciceri: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 in attach Thanks a lot gian paolo, I've checked your patch in. cheers, dalibor topic ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] CVS kaffe (robilad): Fixlet for gcc 2.9x
PatchSet 5640 Date: 2005/04/01 21:32:19 Author: robilad Branch: HEAD Tag: (none) Log: Fixlet for gcc 2.9x 2005-04-01 gian paolo ciceri [EMAIL PROTECTED] * config/katomic.h (__atomic_val_bysize, __atomic_bool_bysize): Added versions for gcc 2.x variadic macro format. Members: ChangeLog:1.3810-1.3811 config/katomic.h:1.1-1.2 Index: kaffe/ChangeLog diff -u kaffe/ChangeLog:1.3810 kaffe/ChangeLog:1.3811 --- kaffe/ChangeLog:1.3810 Fri Apr 1 20:37:33 2005 +++ kaffe/ChangeLog Fri Apr 1 21:32:19 2005 @@ -1,3 +1,8 @@ +2005-04-01 gian paolo ciceri [EMAIL PROTECTED] + + * config/katomic.h (__atomic_val_bysize, __atomic_bool_bysize): + Added versions for gcc 2.x variadic macro format. + 2005-04-01 Supreet Sethi [EMAIL PROTECTED] * configure.ac: Check for uintmax_t and intmax_t. Index: kaffe/config/katomic.h diff -u kaffe/config/katomic.h:1.1 kaffe/config/katomic.h:1.2 --- kaffe/config/katomic.h:1.1 Sun Mar 20 20:30:37 2005 +++ kaffe/config/katomic.h Fri Apr 1 21:32:21 2005 @@ -26,6 +26,43 @@ /* Wrapper macros to call pre_NN_post (mem, ...) where NN is the bit width of *MEM. The calling macro puts parens around MEM and following args. */ + + +#if __GNUC__ == 2 + +#define __atomic_val_bysize(pre, post, mem, args...) \ + ({ \ +__typeof (*mem) __result;\ +if (sizeof (*mem) == 1) \ + __result = pre##_8_##post (mem, args...); \ +else if (sizeof (*mem) == 2) \ + __result = pre##_16_##post (mem, args...); \ +else if (sizeof (*mem) == 4) \ + __result = pre##_32_##post (mem, args...); \ +else if (sizeof (*mem) == 8) \ + __result = pre##_64_##post (mem, args...); \ +else \ + abort (); \ +__result;\ + }) +#define __atomic_bool_bysize(pre, post, mem, args...)\ + ({ \ +int __result;\ +if (sizeof (*mem) == 1) \ + __result = pre##_8_##post (mem, args...); \ +else if (sizeof (*mem) == 2) \ + __result = pre##_16_##post (mem, args...); \ +else if (sizeof (*mem) == 4) \ + __result = pre##_32_##post (mem, args...); \ +else if (sizeof (*mem) == 8) \ + __result = pre##_64_##post (mem, args...); \ +else \ + abort (); \ +__result;\ + }) + +#else + #define __atomic_val_bysize(pre, post, mem, ...) \ ({ \ __typeof (*mem) __result;\ @@ -56,7 +93,10 @@ abort (); \ __result;\ }) - + + +#endif + /* Atomically store NEWVAL in *MEM if *MEM is equal to OLDVAL. Return the old *MEM value. */ ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] build problms with prebuild rt.jar
Hey to track this. My configure flags are: $ ../kaffe/configure -C --with-includes=/usr/pkg/include --with- libraries=/usr /pkg/lib --without-classpath-gtk-awt --without-kaffe-qt-awt --with- threads=unix- jthreads --enable-debug --with-rt-jar=/home/multix/kaffe-cvs/rt.jar but still, kaffe insists rebuilding: cp /home/multix/kaffe-cvs/rt.jar rt.jar rm -rf lib mkdir lib if test default = default; then \ /usr/pkg/bin/bash ./rebuildLib @all.files `CDPATH=: cd lib pwd`/../gnu/classpath/Configuration.java; \ else \ /usr/pkg/bin/bash ./rebuildLib @default `CDPATH=: cd lib pwd`/../gnu/classpath/Configuration.java; \ fi Compiling classes from @all.files /home/multix/kaffe-cvs/netbsd-sparc/ libraries/javalib/lib/../gnu/classpath/Configuration.java using jikes +Pno-switchcheck +Pno-shadow +E -d /home/multix/kaffe-cvs/netbsd-sparc/ libraries/javalib/lib ***System Failure: Out of memory with bad results, with ONLY 96mb of ram 256MB of swap ! (jikes is hungry, too hungry) -R ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] darwin6 problems
Hey, make check acts strangely PASS: wc.java PASS: FileTest.java FAIL: FileChecks.java FAIL: finalexc.java FAIL: finaltest.java FAIL: finaltest2.java FAIL: forNameTest.java FAIL: LoaderTest.java FAIL: ArrayForName.java FAIL: KaffeVerifyBug.java FAIL: Schtum.java FAIL: Reflect.java FAIL: MethodBug.java /bin/sh: fork: Resource temporarily unavailable /bin/sh: fork: Resource temporarily unavailable FAIL: Bean.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: SortTest.java expr: syntax error expr: syntax error FAIL: ArraysTest.java expr: syntax error expr: syntax error FAIL: SubListTest.java expr: syntax error expr: syntax error FAIL: HashTest.java expr: syntax error expr: syntax error FAIL: SecureRandomTest.java expr: syntax error expr: syntax error FAIL: MapTest.java expr: syntax error expr: syntax error FAIL: URLTest.java expr: syntax error expr: syntax error FAIL: PropertiesTest.java expr: syntax error expr: syntax error FAIL: ReaderTest.java expr: syntax error expr: syntax error FAIL: CharArrayReaderTest.java expr: syntax error expr: syntax error FAIL: LineNumberReaderTest.java expr: syntax error expr: syntax error FAIL: BufferedReaderTest.java expr: syntax error expr: syntax error FAIL: ReaderReadVoidTest.java expr: syntax error PASS: InputStreamTest.java expr: syntax error expr: syntax error FAIL: PipeTest.java expr: syntax error expr: syntax error FAIL: DateFormatTest.java expr: syntax error expr: syntax error FAIL: GetField.java expr: syntax error expr: syntax error FAIL: LostTrampolineFrame.java expr: syntax error expr: syntax error FAIL: NetworkInterfaceTest.java expr: syntax error expr: syntax error FAIL: InetAddressTest.java expr: syntax error expr: syntax error FAIL: InetSocketAddressTest.java expr: syntax error expr: syntax error FAIL: ShutdownHookTest.java expr: syntax error expr: syntax error FAIL: TestMessageFormat.java expr: syntax error expr: syntax error FAIL: ReflectInvoke.java expr: syntax error expr: syntax error FAIL: InvTarExcTest.java expr: syntax error expr: syntax error FAIL: DeleteFile.java expr: syntax error expr: syntax error FAIL: PrimordialLoaderTest.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error FAIL: SystemLoaderTest.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: NoClassDefTest.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: CLTest.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: CLTestConc.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: CLTestJLock.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: CLTestLie.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: CLTestFindLoaded.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: ClassDeadLock.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error PASS: ExceptionTest.java /bin/sh: fork: Resource temporarily unavailable /bin/sh: fork: Resource temporarily unavailable FAIL: ExceptionTestClassLoader.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: ExceptionTestClassLoader2.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: TestClassRef.java expr: syntax error expr: syntax error FAIL: ClassGC.java expr: syntax error expr: syntax error FAIL: GCTest.java expr: syntax error expr: syntax error FAIL: ThreadLocalTest.java expr: syntax error expr: syntax error FAIL: BeanBug.java /bin/sh: fork: Resource temporarily unavailable /bin/sh: fork: Resource temporarily unavailable FAIL: BitSetTest.java /bin/sh: fork: Resource temporarily unavailable expr: syntax error expr: syntax error FAIL: ExceptionInInitializerTest.java expr: syntax error expr: syntax error FAIL: InitTest.java expr: syntax error expr: syntax error FAIL: CLInitThrow.java expr: syntax error expr: syntax error FAIL: ProcessClassTest.java expr: syntax error expr: syntax error FAIL: ProcessClassInst.java expr: syntax error expr: syntax error FAIL: ProcessClassStop.java expr: syntax error expr: syntax error FAIL: FindSystemClass.java expr: syntax error expr: syntax error FAIL: ProcessClassLockTest.java expr: syntax error expr: syntax error FAIL: DoubleBug.java expr: syntax error expr: syntax error FAIL: TestUnlock.java expr: syntax error expr: syntax error FAIL: MarkResetTest.java expr: syntax error expr: syntax error FAIL: HashtableTest1.java expr: syntax error PASS: ReflectMultiArray.java expr: syntax error expr: syntax error FAIL: ExecTest.java expr: syntax error expr: syntax error FAIL: BadClassVersion.java expr: syntax error expr: syntax error FAIL: InterfaceSuperClass.java expr: syntax error expr: syntax error FAIL: ImplementClass.java expr: syntax error expr: syntax
[kaffe] irix-pthreads
Hey, irix-pthreads./ This is mainly for guilhem who did some fixing there. I rerun the make tests, they are deadly slow, probably continuous deadlocks and timeouts. After hours the tests were not finished and Interrupted it. It got as far as: PASS: HelloWorldApp.class.save PASS: HelloWorldApp.java PASS: MultiArray.java FAIL: RefTest.java PASS: TestIntLong.java PASS: TestFloatDouble.java FAIL: DoubleCvt.java FAIL: DoubleNeg.java PASS: DoubleConst.java FAIL: DoublePrint.java FAIL: DoubleComp.java PASS: ModuloTest.java PASS: LongNeg.java FAIL: FPUStack.java PASS: NegativeDivideConst.java PASS: divtest.java PASS: Str.java PASS: Str2.java FAIL: InternHog.java PASS: IndexTest.java PASS: StackDump.java PASS: CatchLimits.class.save PASS: tname.java FAIL: ttest.java FAIL: ThreadInterrupt.java FAIL: ThreadState.java FAIL: UncaughtException.java PASS: IllegalWait.java FAIL: WaitTest.java FAIL: Preempt.java PASS: TestSerializable.java PASS: TestSerializable2.java PASS: SerializationCompatibility.java PASS: SerialPersistentFields.java PASS: TestSerialVersions.java PASS: TestSerialPersistent.java FAIL: TestSerialFields.java PASS: TestObjectStreamField.java PASS: ReflectInterfaces.java PASS: InnerTest.java PASS: SerialUID.java PASS: TestCasts.java PASS: Alias.java PASS: NullPointerTest.java PASS: NullInvoke.java PASS: TableSwitch.java PASS: LostFrame.java PASS: ConstructorTest.java PASS: burford.java PASS: IllegalInterface.java PASS: GetInterfaces.java FAIL: IntfTest.java PASS: SignedShort.java PASS: CharCvt.java FAIL: BadFloatTest.java FAIL: ProcessTest.java PASS: UDPTest.java FAIL: SoTimeout.java PASS: wc.java PASS: FileTest.java PASS: FileChecks.java FAIL: finalexc.java PASS: finaltest.java PASS: finaltest2.java PASS: forNameTest.java PASS: LoaderTest.java PASS: ArrayForName.java PASS: KaffeVerifyBug.java PASS: Schtum.java PASS: Reflect.java PASS: MethodBug.java PASS: Bean.java PASS: SortTest.java PASS: ArraysTest.java PASS: SubListTest.java PASS: HashTest.java PASS: SecureRandomTest.java PASS: MapTest.java PASS: URLTest.java FAIL: PropertiesTest.java PASS: ReaderTest.java PASS: CharArrayReaderTest.java PASS: LineNumberReaderTest.java FAIL: BufferedReaderTest.java PASS: ReaderReadVoidTest.java PASS: InputStreamTest.java FAIL: PipeTest.java FAIL: DateFormatTest.java PASS: GetField.java PASS: LostTrampolineFrame.java FAIL: NetworkInterfaceTest.java PASS: InetAddressTest.java PASS: InetSocketAddressTest.java FAIL: ShutdownHookTest.java FAIL: TestMessageFormat.java PASS: ReflectInvoke.java PASS: InvTarExcTest.java PASS: DeleteFile.java PASS: PrimordialLoaderTest.java PASS: SystemLoaderTest.java PASS: NoClassDefTest.java PASS: CLTest.java -R ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] Re: darwin6 problems
In [EMAIL PROTECTED] Riccardo wrote: /bin/sh: test: : integer expression expected /bin/sh: test: : integer expression expected /bin/sh: fork: Resource temporarily unavailable of tests failed /bin/sh: test: : integer expression expected make[6]: *** [check-TESTS] Error 2 and since the rest of the machine is almost idle, I wonder something is sucking up resources in kaffe? top showed dozens of sleep processes that died slowly away -R ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] java control of xen
In an effort to push xen into more parts of the computing world, I am announcing the start of a brand new project here at Brainfood. Our plans are to port Xen to run *inside* a JVM(Kaffe), so that we can make use of the write-one-run-anywhere mantra. The magic piece of code that will enable this is Mips2Java. Unfortunately, at this time, Xen does not yet run on mips. So, we are looking for volunteers to port Xen to mips, so that then we can have Xen run under Kaffe, which will then let us run it on the final platform, mobile phones. ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
Re: [kaffe] java control of xen
Adam Heath wrote: In an effort to push xen into more parts of the computing world, I am announcing the start of a brand new project here at Brainfood. Our plans are to port Xen to run *inside* a JVM(Kaffe), so that we can make use of the write-one-run-anywhere mantra. The magic piece of code that will enable this is Mips2Java. Unfortunately, at this time, Xen does not yet run on mips. So, we are looking for volunteers to port Xen to mips, so that then we can have Xen run under Kaffe, which will then let us run it on the final platform, mobile phones. Sounds crazy. It's got some hack value, I guess. :-) How about x86 to Java? Here's a starting point: http://emulin.netfort.gr.jp/ I bookmarked it a long time ago, and I'm mildly intrigued, but not enough to actually try it out, I guess. Of course, since you'd have to emulate the x86 platform anyways, I'm not sure what running Xen on top of it provides... I can't imagine anyway that it's going to be fast. I'm imagining that it would be like running Xen on Bochs, but much slower. You'd have to emulate physical memory and the MMU using garbage collection. BTW -- I'm still working on moving the Kaffe server over to a Xen session on my new server. I'm a bit slow - I'll get it done someday. :-) Cheers, - Jim ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe
[kaffe] Re: [Xen-devel] java control of xen
On Fri, 1 Apr 2005, Jacob Gorm Hansen wrote: Adam Heath wrote: In an effort to push xen into more parts of the computing world, I am announcing the start of a brand new project here at Brainfood. Our plans are to port Xen to run *inside* a JVM(Kaffe), so that we can make use of the write-one-run-anywhere mantra. The magic piece of code that will enable this is Mips2Java. Unfortunately, at this time, Xen does not yet run on mips. So, we are looking for volunteers to port Xen to mips, so that then we can have Xen run under Kaffe, which will then let us run it on the final platform, mobile phones. I am all for that, I also think you guys should consider porting the Jython Java/Python runtime to run inside Xen, so that in the longer term we will be able take advantage of the Twisted libraries in Xen, for instance I imagine the scheduler could be rewritten on top of Twisted's excellent async programming framework. This would also make room for more use of SOAP and XML, so that security policies for sHype could be fetched on-demand from a centralized web-service. Talk about an agile, service-oriented VMM! Actually, with everything running in java, we will be able to levage lots of existing java apis. Think networking done RMI. Or shared-memory in xen implemented thru JDBC. And linux IPC done with JNDI. The possibilities are endless. ___ kaffe mailing list kaffe@kaffe.org http://kaffe.org/cgi-bin/mailman/listinfo/kaffe