Dear Eric, As advised given by you ,we defind the following marcos like
#define ARG_POINTER_REGNUM 9 #define FRAME_POINTER_REGNUM 8 #define STACK_POINTER_REGNUM 10 #define ELIMINABLE_REGS \ {{ ARG_POINTER_REGNUM, STACK_POINTER_REGNUM}, \ { FRAME_POINTER_REGNUM, STACK_POINTER_REGNUM}} \ #define INITIAL_ELIMINATION_OFFSET(FROM, TO, OFFSET) \ (OFFSET) = tlcs_initial_elimination_offset (FROM, TO) #define CAN_ELIMINATE 1 #define FIRST_PARM_OFFSET 3 With -O0 or by default options the frame and arg regs are not replaced by stack reg and the same replaced with -O1 and above optimisation options. Did the macros like ELIMINABLE_REGS ,INITIAL_ELIMINATION_OFFSET and CAN_ELIMINATE are only effective when optimisation enabled ?? or do we missing something here ?? Thank you and appreciate any reply from the group. On Fri, Apr 25, 2014 at 9:58 PM, Eric Botcazou <ebotca...@adacore.com> wrote: >> #define FIRST_PARM_OFFSET(FNDECL) (get_frame_size() + >> STARTING_FRAME_OFFSET + RETURN_BYTES ) > > I don't think that you can define FIRST_PARM_OFFSET like so, you need to have > a fixed FIRST_PARM_OFFSET (for some definition of fixed) and eliminate the > argument pointer during reload. > > -- > Eric Botcazou