From c3d4f633e6de30191fc1d3db778df83915a9bfdf Mon Sep 17 00:00:00 2001 From: Jeff Law Date: Thu, 29 Feb 1996 11:17:35 -0700 Subject: [PATCH] pa.h (TARGET_SWITCHES): Add new flags "-mlong-load-store" and "-mno-long-load-store". * pa.h (TARGET_SWITCHES): Add new flags "-mlong-load-store" and "-mno-long-load-store". (TARGET_LONG_LOAD_STORE): Define. * pa.md (symbolic high part): Handle TARGET_LONG_LOAD_STORE. From-SVN: r11384 --- gcc/config/pa/pa.h | 6 ++++++ gcc/config/pa/pa.md | 14 ++++++++++++-- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/gcc/config/pa/pa.h b/gcc/config/pa/pa.h index 28984bec538..89697db8c82 100644 --- a/gcc/config/pa/pa.h +++ b/gcc/config/pa/pa.h @@ -101,6 +101,10 @@ extern int target_flags; #define TARGET_SOFT_FLOAT (target_flags & 256) +/* Use 3-insn load/store sequences for access to large data segments + in shared libraries on hpux10. */ +#define TARGET_LONG_LOAD_STORE (target_flags & 512) + /* Macro to define tables used to set the flags. This is a list in braces of pairs in braces, each pair being { "NAME", VALUE } @@ -126,6 +130,8 @@ extern int target_flags; {"no-gas", -128}, \ {"soft-float", 256}, \ {"no-soft-float", -256}, \ + {"long-load-store", 512}, \ + {"no-long-load-store", -512},\ {"linker-opt", 0}, \ { "", TARGET_DEFAULT}} diff --git a/gcc/config/pa/pa.md b/gcc/config/pa/pa.md index 724ad13fcfb..1aeeb61ff48 100644 --- a/gcc/config/pa/pa.md +++ b/gcc/config/pa/pa.md @@ -1693,9 +1693,19 @@ && ! function_label_operand (operands[1]) && ! read_only_operand (operands[1]) && ! flag_pic" - "addil LR'%H1,%%r27" + "* +{ + if (TARGET_LONG_LOAD_STORE) + return \"addil NLR'%H1,%%r27\;ldo N'%H1(%%r1),%%r1\"; + else + return \"addil LR'%H1,%%r27\"; +}" [(set_attr "type" "binary") - (set_attr "length" "4")]) + (set (attr "length") + (if_then_else (eq (symbol_ref "TARGET_LONG_LOAD_STORE") (const_int 0)) + (const_int 4) + (const_int 8)))]) + ;; This is for use in the prologue/epilogue code. We need it ;; to add large constants to a stack pointer or frame pointer. -- 2.30.2