1/* Definitions for PA_RISC with ELF format on 64-bit Linux
2   Copyright (C) 1999, 2000, 2002 Free Software Foundation, Inc.
3
4This file is part of GCC.
5
6GCC is free software; you can redistribute it and/or modify
7it under the terms of the GNU General Public License as published by
8the Free Software Foundation; either version 2, or (at your option)
9any later version.
10
11GCC is distributed in the hope that it will be useful,
12but WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14GNU General Public License for more details.
15
16You should have received a copy of the GNU General Public License
17along with GCC; see the file COPYING.  If not, write to
18the Free Software Foundation, 51 Franklin Street, Fifth Floor,
19Boston, MA 02110-1301, USA.  */
20
21#if 0 /* needs some work :-( */
22/* If defined, this macro specifies a table of register pairs used to
23   eliminate unneeded registers that point into the stack frame.  */
24
25#define ELIMINABLE_REGS							\
26{									\
27  {FRAME_POINTER_REGNUM, STACK_POINTER_REGNUM},				\
28  {ARG_POINTER_REGNUM,	 STACK_POINTER_REGNUM},				\
29  {ARG_POINTER_REGNUM,	 FRAME_POINTER_REGNUM},				\
30}
31
32/* A C expression that returns nonzero if the compiler is allowed to try to
33   replace register number FROM with register number TO.  The frame pointer
34   is automatically handled.  */
35
36#define CAN_ELIMINATE(FROM, TO) 1
37
38/* This macro is similar to `INITIAL_FRAME_POINTER_OFFSET'.  It
39   specifies the initial difference between the specified pair of
40   registers.  This macro must be defined if `ELIMINABLE_REGS' is
41   defined.  */
42#define INITIAL_ELIMINATION_OFFSET(FROM, TO, OFFSET) \
43  do								\
44    {								\
45      int fsize;						\
46								\
47      fsize = compute_frame_size (get_frame_size (), 0);	\
48      if ((TO) == FRAME_POINTER_REGNUM				\
49	  && (FROM) == ARG_POINTER_REGNUM)			\
50	{							\
51	  (OFFSET) = -16;					\
52	  break;						\
53	}							\
54								\
55      gcc_assert ((TO) == STACK_POINTER_REGNUM);		\
56								\
57      switch (FROM)						\
58	{							\
59	case FRAME_POINTER_REGNUM:				\
60	  (OFFSET) = - fsize;					\
61	  break;						\
62								\
63	case ARG_POINTER_REGNUM:				\
64	  (OFFSET) = - fsize - 16;				\
65	  break;						\
66								\
67	default:						\
68	  gcc_unreachable ();					\
69	}							\
70    } while (0)
71#endif
72