qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] Add ARM920T to ARM emulation


From: Paul Brook
Subject: Re: [Qemu-devel] Add ARM920T to ARM emulation
Date: Mon, 1 Jun 2009 13:13:48 +0100
User-agent: KMail/1.11.2 (Linux/2.6.29-2-amd64; KDE/4.2.2; x86_64; ; )

> I notice that ARMv4T adds the BX instruction, implying that B isn't
> able to switch to Thumb mode although it can in later architectures (I
> never saw the point in BX, and I guess ARM ended up the same :-)
>
> Is the behaviour defined to _not_ switch to Thumb when using B to an
> address with the low order bit set, or does it trap, or is it
> unpredictable?

You need to look again at the B instruction. Hopefully then you'll realise why 
you're talking nonsense.

B is a direct branch that never changes mode. BX is an indirect branch that 
mode switches based on the low address bit.
BL and BLX(register) are exactly the same as B/BX except they also set LR.
BLX(immediate) is a direct mode switching call.
loads into the PC either ignore(v4t) or mode switch (v5) on the low address 
bit.
ALU writes to the PC always ignore the low bit in Thumb mode. In ARM mode the 
low bit is either ignored(v6) or used to mode switch (v7).

BX was introduced in v4t, BLX was introduced in v5.

Paul






reply via email to

[Prev in Thread] Current Thread [Next in Thread]