summaryrefslogtreecommitdiff
path: root/gcc/config/sparc/sysv4.h
diff options
context:
space:
mode:
authorwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>1994-03-18 20:47:03 +0000
committerwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>1994-03-18 20:47:03 +0000
commitc91231298e057852e3f2a35101ab457c12a7bedf (patch)
tree03fce459c78c7ccbb5b4c047afc7742dc4a4386a /gcc/config/sparc/sysv4.h
parentbfc8fc2517e8b5a60f155c00e5138f43eca04a96 (diff)
downloadgcc-c91231298e057852e3f2a35101ab457c12a7bedf.tar.gz
(SELECT_RTX_SECTION): Add.
(ASM_SPEC): Pass -K to assembler when PIC. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@6815 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/config/sparc/sysv4.h')
-rw-r--r--gcc/config/sparc/sysv4.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/config/sparc/sysv4.h b/gcc/config/sparc/sysv4.h
index e331c9d2974..5c3ae6fe701 100644
--- a/gcc/config/sparc/sysv4.h
+++ b/gcc/config/sparc/sysv4.h
@@ -61,6 +61,22 @@ the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
text section. */
#define JUMP_TABLES_IN_TEXT_SECTION 1
+/* Pass -K to the assembler when PIC. */
+#undef ASM_SPEC
+#define ASM_SPEC \
+ "%{V} %{v:%{!V:-V}} %{Qy:} %{!Qn:-Qy} %{n} %{T} %{Ym,*} %{Yd,*} %{Wa,*:%*} \
+ %{fpic:-K PIC} %{fPIC:-K PIC}"
+
+/* Must use data section for relocatable constants when pic. */
+#undef SELECT_RTX_SECTION
+#define SELECT_RTX_SECTION(MODE,RTX) \
+{ \
+ if (flag_pic && symbolic_operand (RTX)) \
+ data_section (); \
+ else \
+ const_section (); \
+}
+
/* The specialized code which needs to appear in the .init section prior
to the prologue code for `__do_global_ctors' (see crtstuff.c).