A crazy idea

Raffaele Sena raff at aromatic.com
Tue Nov 17 19:45:03 PST 1998

On Wed, 18 Nov 1998, Pavel Roskin wrote:

> Another project is libffi, which is a part of japhar, another open-source
> java machine (http://www.hungry.com/)
> libffi doesn't support hppa, but it does support arm. You could try make
	I know. I did the port for ARM in an effort to port
	Japhar on NetWinder (unfortunately libffi was the easiest module
	to port. Other required much more effort, so I temporary abandoned
	the project, due to lack of time).

> Kaffe use libffi if it is available. It would be very useful, since it
> would join efforts of the Open-source community in creation of GPL
> implementations of Java and other languages. On another side, it would
> give Kaffe developers more time to concentrate on platform-independent
> issues.
	Anyway, I was thinking something different. I was thinking
	to use the back-end to generate the source code that implements
	the architecture-dependent part of the JIT.

	I'm not sure I understand what you would use libffi for.
	If I got it correctly libffi has equivalent functionalities
	as JNI (and it can be probably used to implement JNI).
	I don't really understand how I can use it for the JIT.

	BTW, I just realized (I knew, but I wasn't really thinking
	about it) that gcc generates assembly code, then assembled
	by gas. For what I want to do, I should then parse the assemly
	listing to get the opcod. Maybe, if the compiler generates
	code clean enough, I don't really need to modify or play with
	gcc. I can write a C implementation of the various JIT opcodes,
	assemble it, and parse the result (try to parse it automatically,
	and resort to manual parsing for special cases). At least I
	know the opcodes I'm going to use are correct.

-- Raffaele

raff at aromatic.com           (::)           http://www.aromatic.com/~raff/

More information about the kaffe mailing list