[kaffe] Kaffe and MIPS CPUs

Kevin D. Kissell kevink@mips.com
Mon, 8 Jul 2002 10:14:38 +0200


Hi Jim,

Now that the "official" Kaffe 1.0.7 release is out, I've been trying
to get it running on MIPS platforms, specifically a MIPS Technologies
"Malta" development board with a contemporary 64-bit 5Kc core
running Linux 2.4.18, and a Sony Playstation 2 running the Sony
variant of Linux 2.2.1.  Neither of them will build or run using the
current distribution, so I'm working on that.  There are those who
claim to have gotten 1.0.6 working on various MIPS/Linux platforms,
but I've yet to find one that is functional and compatible with current
shared libraries, etc.  So I'm rolling up my sleeves and attacking
1.0.7.  I'm not a JVM hacker as such - mostly an OS kernel
hacker type of 20 or so years experience (BSD, System V,
Mach, Linux) who has done a moderate amount of Java programming
and who has a pretty fair, if not expert, idea of how a JVM
functions.  You won't find me on anyones maintainer lists,
but you will find my name on some of the Linux/MIPS kernel
sources.

Kaffe has seemed largely abandoned for the past couple of years,
and I'm pleased that you have stepped up to bat to maintain it
for a while.  I would assume that you'd be at least vaguely interested
in whatever patches I come up with to get things working on MIPS.
Is that correct?  Are there other people doing the same thing with
whom I should be in contact?  In general, how should I proceed?

The current state of play at my end is that I've got kaffe building
on the 2.4.18/"Red Hat 7.1" MIPS platform, with a couple of
pretty simple changes in the config/mips stuff (some stuff there
was fixed since 1.0.6, but not everything).  However, in both
purely interpretive and JIT configurations, it fails almost all
tests, mostly due to "stack overflow" errors, and sometimes
due to System.arraycopy throwing an arithmetic exception
(which it should never do!).  I'm working on hunting down
the causes of those things - if you have a clue, I'd be greatful.

The Playstation 2 is problematic.  The R5900 CPU in the PS2
supports single-precision, but not double-precision, floating point
in hardware, and Sony hacked gcc accordingly.  It will probably
be necessary to tweak the JIT implementation and configuration
to take that into account. I know that there are others who were working 
on getting a "stock" MIPS kaffe 1.0.6 running on it, and another
of my "spare time" projects has been to get the kernel FPU
emulation on the PS2 up to the same level that I managed to
get it for 2.4.x and later 2.2.x MIPS kernels, so that the JIT
code that emits double-precision FPU instructions could run.

But for the moment, getting Kaffe 1.0.7 running on a non-PS2
"standard" MIPS platform is my priority.

            Regards,

            Kevin Kissell
            MIPS Technologies European Architecture Lab