[coldfire-gnu-discuss] Invalid code generated with gcc-4.2 for target m68k-rtems.

Daniel Jacobowitz dan at codesourcery.com
Mon Jun 25 17:34:13 UTC 2007

On Mon, Jun 25, 2007 at 01:18:26PM -0400, Kirspel, Kevin wrote:
> I have downloaded the coldfire-4.2 source code and I have cross-compiled it
> for the m68k-rtems target (for use with mcf5329EVB).  Everything builds and
> installs fine.  After the tools are installed I compiled my OS.  The
> compilation of the OS completes with no errors.  When I run the OS using
> GDB, the program fails in the newlib memset() function.  The PC register at
> the time of failure is at 0x400149ea.  I disassembled the application (using
> m68k-rtems-objdump) and got the following output for memset():

> 400149ea:         e8c3                 0164303

This instruction does not occur in any of the memset implementations
we ship; I suspect it is a problem with your configuration when you
rebuilt the tools.

If I'm reading the disassembler table correctly, that is bftst - an
instruction present on the 68020 but not on ColdFire.

Daniel Jacobowitz

More information about the coldfire-gnu-discuss mailing list