Re: Coldfire 5282 TAS instruction code

Greg Ungerer <[email protected]> Fri, 18 Jul 2008 14:09:12 +1000
Newsgroups gmane.comp.hardware.motorola.microcontrollers.coldfire
Message-ID <[email protected]>
Hi Phil,

Phil Roets wrote:
> I am developing a multitask application on a MFC5282 board and intended 
> to create a semaphore type method to control access to some of the 
> common variables.  Replacing the 'tst.b' with 'tas.b' in the snippet :
>        move.l   4(%sp),%a0
>        move.l   #128,%d0
>        tas.b     (%a0)
>        jbne     .L4
>        move.b #-128,(%a0)
>        clr.b      %d0
> ..L4:
>        rts
> causes a 'invalid instruction for the architecture ... ' during 
> compilation with the m68k-uclinux-tools-20061214 tool set.
> 
> Can anybody suggest a way around the problem ?

What CPU specifier option did you pass to gcc?

 From memory you need a -m528x with that compiler.

Regards
Greg


------------------------------------------------------------------------
Greg Ungerer  --  Chief Software Dude       EMAIL:     [email protected]
Secure Computing Corporation                PHONE:       +61 7 3435 2888
825 Stanley St,                             FAX:         +61 7 3891 3630
Woolloongabba, QLD, 4102, Australia         WEB: http://www.SnapGear.com
---
[email protected]              Send a post to the list.
[email protected]        Join the list.
[email protected]    Join the list in digest mode.
[email protected]     Leave the list.