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

Re: ARM EABI port: minimum CPU choice



On Tue, 2006-06-13 at 12:14 +0100, Catalin Marinas wrote:
> On Tue, 2006-06-13 at 10:41 +0100, Phil Blundell wrote:
> > On Mon, 2006-06-12 at 23:54 +0200, Martin Guy wrote:
> > > Is there any reason not to make ldm the default for armv4 and above,
> > > since it seems to win most, among the various options?
> > 
> > Two reasons: because it requires the return address to be on the stack
> > (which often requires adding another instruction to get it there)
> 
> But isn't LR saved anyway in functions that call other functions? 

Yes, it is.  Those functions will already return either with LDMIA sp!,
{..., pc} or LDR pc, [sp], #4 depending on whether any other registers
were pushed.  Both of those sequences are already interworking-safe on
ARMv5, and will work fine in ARM-state on v4 (but, obviously, with no
interworking).

p.



Reply to: