RFC: JamVM force -marm -g -O2 on ARM Linux.

Xerxes Rånby xerxes at zafena.se
Fri Mar 11 04:27:56 PST 2011


On 2011-03-11 12:56, Matthias Klose wrote:
> On 11.03.2011 12:52, Xerxes Rånby wrote:
>> Hi
>>
>> JamVM currently fail to run on ARM Linux systems where gcc by default optimize for Thumb2.
>> This can be fixed by overriding the JamVM CFLAGS to skip thumb by enforcing the use of -marm -g -O2 .
> would CFLAGS="$CFLAGS -marm" work too?

The idea are good!

But it will not work because running with optimization -O2 are required for the inlining JIT to operate see:
http://sourceforge.net/mailarchive/message.php?msg_id=27172598
In my patch I had to explicitly add -O2 to the CFLAGS as well because -O2 are normally only implicit added by configure when CFLAGS are undefined.

using

CFLAGS="$CFLAGS -marm -g -O2"

do work

Xerxes



More information about the distro-pkg-dev mailing list