This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: stack-protection vs alloca vs dwarf2


> Also, is that rule true if we *don't* have a frame pointer?  That is,
> when we add a constant to the stack to allocate the frame, should that
> function be marked as frame-related?  Or is it just the fp->sp move
> (or potentially an add, if there's outgoing args) that shouldn't be
> marked?

The prologue expansion code needs to know what it is doing, in the sense that 
it needs to know what register is the CFA register and what insn sets it up.
Once the CFA register is set up, insns modifying other registers, including sp 
if sp is not the CFA register, must not be marked; of course, if sp is the CFA 
register throughout the function because there is no frame pointer, then all 
insns modifying sp must be marked.

-- 
Eric Botcazou


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]