[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] Firebee Coldfire MiNT Kernel and NFS

On 04/09/2014 19:14, Andreas Schwab wrote:
By chance, "BSET.B #7" is a totally standard user mode instruction, and
does exactly the same job as TAS on monoprocessor systems.

No, it sets different condition codes.

Andreas, Thomas, thanks for your hints.
I was not aware of the condition codes details.

In our case, the next instruction is BEQ, which means that only the Z flag is important. And fortunately, that one is set identically by both instructions. So in our special case, both instructions are interchangeable.

Next time I will face the TAS instruction, I will not dumbly replace it by BSET.B, I will also check the condition codes.

Vincent Rivière