summaryrefslogtreecommitdiff
path: root/gcc/config/pa/pa-linux.h
diff options
context:
space:
mode:
authorJohn David Anglin <dave@hiauly1.hia.nrc.ca>2002-04-04 02:48:18 +0000
committerJohn David Anglin <danglin@gcc.gnu.org>2002-04-04 02:48:18 +0000
commit823fbbce5c867613d9a1417d77970ab0ea5f41b4 (patch)
tree581f501853359286f80b37739491cd24a96a7357 /gcc/config/pa/pa-linux.h
parent4078e2240c57c6d1ad5737de12b724f90d79a612 (diff)
downloadgcc-823fbbce5c867613d9a1417d77970ab0ea5f41b4.tar.gz
pa-linux.h (INCOMING_RETURN_ADDR_RTX): Move.
* pa-linux.h (INCOMING_RETURN_ADDR_RTX): Move. (DWARF_FRAME_RETURN_COLUMN): Move. (ASM_PREFERRED_EH_DATA_FORMAT): Define. (ASM_MAYBE_OUTPUT_ENCODED_ADDR_RTX): Define. * pa.c (except.h, predict.h): Include. (FRP): Delete. (store_reg_modify, set_reg_plus_d): Revise prototypes. (output_ascii): Add cast. (store_reg_modify): Revise to add frame notes. (set_reg_plus_d): Likewise. (compute_frame_size): Include space for eh data registers in frame if the current function calls eh_return. (hppa_expand_prologue): Ensure register %r2 is saved if the current function calls eh_return. Save eh data registers if the current function calls eh_return. Fix code to add frame notes. Emit blockage to prevent insns with frame notes being scheduled in the delay slot of calls. (hppa_expand_epilogue): Restore eh data registers and do final stack adjustment if the current function calls eh_return. Don't add frame notes. (output_call): Revise for change in length of call insn. Don't do return pointer adjustment for an unconditional jump in the delay slot of a call when using frame notes. * pa.h (EH_RETURN_DATA_REGNO): Revise for TARGET_64BIT compatibility. (EH_RETURN_HANDLER_RTX): Use saved value on stack. (ARG_POINTER_CFA_OFFSET): Define. * pa.md (return_external_pic): New pattern. (prologue): Correct formatting. Use return_external_pic if current function calls eh_return. (call_internal_symref, call_value_internal_symref, sibcall_internal_symref, sibcall_value_internal_symref): Change default lengths of short, long non-pic, and long pic calls to 8, 68, and 84, respectively. (exception_receiver): Use hppa_pic_save_rtx () to restore pic register. * configure.in ("assembler dwarf2 debug_line support"): Add hppa*-*-* to list of targets to check using "nop" insn. * configure: Rebuilt. From-SVN: r51836
Diffstat (limited to 'gcc/config/pa/pa-linux.h')
-rw-r--r--gcc/config/pa/pa-linux.h39
1 files changed, 33 insertions, 6 deletions
diff --git a/gcc/config/pa/pa-linux.h b/gcc/config/pa/pa-linux.h
index f30a187f91b..16599ef171a 100644
--- a/gcc/config/pa/pa-linux.h
+++ b/gcc/config/pa/pa-linux.h
@@ -24,6 +24,39 @@ Boston, MA 02111-1307, USA. */
#define DWARF2_ASM_LINE_DEBUG_INFO 1
#define DWARF2_UNWIND_INFO 1
+/* A C expression whose value is RTL representing the location of the
+ incoming return address at the beginning of any function, before the
+ prologue. You only need to define this macro if you want to support
+ call frame debugging information like that provided by DWARF 2. */
+#define INCOMING_RETURN_ADDR_RTX (gen_rtx_REG (word_mode, 2))
+#define DWARF_FRAME_RETURN_COLUMN (DWARF_FRAME_REGNUM (2))
+
+/* This macro chooses the encoding of pointers embedded in the exception
+ handling sections. If at all possible, this should be defined such
+ that the exception handling section will not require dynamic relocations,
+ and so may be read-only.
+
+ FIXME: We use DW_EH_PE_aligned to output a PLABEL constructor for
+ global function pointers. */
+#define ASM_PREFERRED_EH_DATA_FORMAT(CODE,GLOBAL) \
+ (CODE == 2 && GLOBAL ? DW_EH_PE_aligned : DW_EH_PE_absptr)
+
+/* Handle special EH pointer encodings. Absolute, pc-relative, and
+ indirect are handled automatically. Since pc-relative encoding is
+ not possible on the PA and we don't have the infrastructure for
+ data relative encoding, we use aligned plabels for global function
+ pointers. */
+#define ASM_MAYBE_OUTPUT_ENCODED_ADDR_RTX(FILE, ENCODING, SIZE, ADDR, DONE) \
+ do { \
+ if (((ENCODING) & 0x0F) == DW_EH_PE_aligned) \
+ { \
+ fputs (integer_asm_op (SIZE, FALSE), FILE); \
+ fputs ("P%", FILE); \
+ assemble_name (FILE, XSTR (ADDR, 0)); \
+ goto DONE; \
+ } \
+ } while (0)
+
#undef CPP_PREDEFINES
#define CPP_PREDEFINES "-D__ELF__ -Dunix -D__hppa__ -Dlinux -Asystem=unix -Asystem=posix -Acpu=hppa -Amachine=hppa -Amachine=bigendian"
@@ -64,12 +97,6 @@ Boston, MA 02111-1307, USA. */
else \
readonly_data_section ();
-/* A C expression whose value is RTL representing the location of the
- incoming return address at the beginning of any function, before the
- prologue. */
-#define INCOMING_RETURN_ADDR_RTX (gen_rtx_REG (word_mode, 2))
-#define DWARF_FRAME_RETURN_COLUMN (DWARF_FRAME_REGNUM (2))
-
/* Define the strings used for the special svr4 .type and .size directives.
These strings generally do not vary from one system running svr4 to
another, but if a given system (e.g. m88k running svr) needs to use