Re: [Qemu-devel] [PATCH]: sh4 delay slot code update

2007-11-29 Thread Paul Mundt
On Thu, Nov 29, 2007 at 06:18:32PM +0900, Magnus Damm wrote: > On Nov 29, 2007 2:55 PM, Paul Mundt <[EMAIL PROTECTED]> wrote: > > The T-state check for bt/bf happens _prior_ to execution of the delay > > slot instruction, while any delay-slot resident T-bit modifier is > > executed by the time we e

Re: [Qemu-devel] [PATCH]: sh4 delay slot code update

2007-11-29 Thread Magnus Damm
On Nov 29, 2007 2:55 PM, Paul Mundt <[EMAIL PROTECTED]> wrote: > The only thing to be careful of is the ordering semantics for the T-bit > state, which is what I tried to convey in the code snippet. > > > > You can see an example in arch/sh/kernel/entry-common.S: > > > > > > syscall_exit_wo

Re: [Qemu-devel] [PATCH]: sh4 delay slot code update

2007-11-28 Thread Paul Mundt
On Thu, Nov 29, 2007 at 02:43:03PM +0900, Magnus Damm wrote: > On Nov 28, 2007 9:49 PM, Paul Mundt <[EMAIL PROTECTED]> wrote: > I was mainly wondering if I really needed to save the state of SR_T, > but I assumed so. So the code should be correct. And yes, I'm sure > there are quite a few slottable

Re: [Qemu-devel] [PATCH]: sh4 delay slot code update

2007-11-28 Thread Magnus Damm
Hi Paul, Thanks for your comments. On Nov 28, 2007 9:49 PM, Paul Mundt <[EMAIL PROTECTED]> wrote: > On Wed, Nov 28, 2007 at 06:54:20PM +0900, Magnus Damm wrote: > > +#define DELAY_SLOT_TRUE(1 << 2) > > +#define DELAY_SLOT_CLEARME (1 << 3) > > +/* The dynamic value of the DELAY_SLOT_TR

Re: [Qemu-devel] [PATCH]: sh4 delay slot code update

2007-11-28 Thread Paul Mundt
On Wed, Nov 28, 2007 at 06:54:20PM +0900, Magnus Damm wrote: > +#define DELAY_SLOT_TRUE(1 << 2) > +#define DELAY_SLOT_CLEARME (1 << 3) > +/* The dynamic value of the DELAY_SLOT_TRUE flag determines whether the jump > + * after the delay slot should be taken or not. It is calculated from

[Qemu-devel] [PATCH]: sh4 delay slot code update

2007-11-28 Thread Magnus Damm
Hi everyone, This patch updates the delay slot handling for the sh4 target. The main feature is that delay slot flags now are stored in the tlb. This is needed for signal emulation and interrupts. There are also some correctness fixes included in this patch - with this patch applied i'm able to r