From ed2181fc2a3ff3a0f65110c906093d5ce0d8e048 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Tue, 12 Nov 2019 11:39:47 +1030 Subject: [PATCH] [RS6000] Remove TARGET_TLS_MARKERS and require binutils 2.20 This patch removes !TARGET_TLS_MARKERS support. -mtls-markers (and -mno-tls-markers) disappear as valid options too, because I figure they haven't been used too much except by people testing the compiler. * config/rs6000/rs6000.opt (mtls-markers): Delete. * config/rs6000/rs6000.h (TARGET_TLS_MARKERS): Don't define. (IS_NOMARK_TLSGETADDR): Likewise. * config/rs6000/rs6000-protos.h (rs6000_output_tlsargs): Delete. * config/rs6000/rs6000.c (rs6000_output_tlsargs): Delete. (rs6000_legitimize_tls_address): Remove !TARGET_TLS_MARKERS code. (rs6000_call_template_1): Delete TARGET_TLS_MARKERS test and allow other UNSPECs besides UNSPEC_TLSGD and UNSPEC_TLSLD. (rs6000_indirect_call_template_1): Likewise. (rs6000_pltseq_template): Likewise. (rs6000_opt_vars): Remove "tls-markers" entry. * config/rs6000/rs6000.md (tls_gd): Replace TARGET_TLS_MARKERS with TARGET_ELF. (tls_gd_high, tls_gd_low): Likewise. (tls_ld, tls_ld_high, tls_ld_low): Likewise. (pltseq_plt_pcrel): Likewise. (call_value_local32): Remove IS_NOMARK_TLSGETADDR predicate test. (call_value_local64): Likewise. (call_value_indirect_nonlocal_sysv): Remove IS_NOMARK_TLSGETADDR output and length attribute sub-expression. (call_value_nonlocal_sysv), (call_value_nonlocal_sysv_secure), (call_value_local_aix, call_value_nonlocal_aix), (call_value_indirect_aix, call_value_indirect_elfv2), (call_value_indirect_pcrel): Likewise. * doc/install.texi (powerpc-*-*): Require binutils-2.20. * configure.ac (HAVE_AS_TLS_MARKERS): Delete test. * configure: Regenerate. * config.in: Regenerate. From-SVN: r278075 --- gcc/ChangeLog | 32 +++++++++ gcc/config.in | 6 -- gcc/config/rs6000/rs6000-protos.h | 1 - gcc/config/rs6000/rs6000.c | 74 +++------------------ gcc/config/rs6000/rs6000.h | 16 ----- gcc/config/rs6000/rs6000.md | 106 ++++++++---------------------- gcc/config/rs6000/rs6000.opt | 4 -- gcc/configure | 36 ---------- gcc/configure.ac | 6 -- gcc/doc/install.texi | 2 +- 10 files changed, 70 insertions(+), 213 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9852383d8e8..4fdb911ab8b 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,35 @@ +2019-11-12 Alan Modra + + * config/rs6000/rs6000.opt (mtls-markers): Delete. + * config/rs6000/rs6000.h (TARGET_TLS_MARKERS): Don't define. + (IS_NOMARK_TLSGETADDR): Likewise. + * config/rs6000/rs6000-protos.h (rs6000_output_tlsargs): Delete. + * config/rs6000/rs6000.c (rs6000_output_tlsargs): Delete. + (rs6000_legitimize_tls_address): Remove !TARGET_TLS_MARKERS code. + (rs6000_call_template_1): Delete TARGET_TLS_MARKERS test and + allow other UNSPECs besides UNSPEC_TLSGD and UNSPEC_TLSLD. + (rs6000_indirect_call_template_1): Likewise. + (rs6000_pltseq_template): Likewise. + (rs6000_opt_vars): Remove "tls-markers" entry. + * config/rs6000/rs6000.md (tls_gd): Replace TARGET_TLS_MARKERS + with TARGET_ELF. + (tls_gd_high, tls_gd_low): Likewise. + (tls_ld, tls_ld_high, tls_ld_low): Likewise. + (pltseq_plt_pcrel): Likewise. + (call_value_local32): Remove IS_NOMARK_TLSGETADDR predicate test. + (call_value_local64): Likewise. + (call_value_indirect_nonlocal_sysv): Remove IS_NOMARK_TLSGETADDR + output and length attribute sub-expression. + (call_value_nonlocal_sysv), + (call_value_nonlocal_sysv_secure), + (call_value_local_aix, call_value_nonlocal_aix), + (call_value_indirect_aix, call_value_indirect_elfv2), + (call_value_indirect_pcrel): Likewise. + * doc/install.texi (powerpc-*-*): Require binutils-2.20. + * configure.ac (HAVE_AS_TLS_MARKERS): Delete test. + * configure: Regenerate. + * config.in: Regenerate. + 2019-11-11 Michael Meissner * config/rs6000/predicates.md (prefixed_memory): New predicate. diff --git a/gcc/config.in b/gcc/config.in index e2afcbc8940..e2542ad8ff5 100644 --- a/gcc/config.in +++ b/gcc/config.in @@ -669,12 +669,6 @@ #endif -/* Define if your assembler supports arg info for __tls_get_addr. */ -#ifndef USED_FOR_TARGET -#undef HAVE_AS_TLS_MARKERS -#endif - - /* Define if your assembler supports vl/vst/vlm/vstm with an optional alignment hint argument. */ #ifndef USED_FOR_TARGET diff --git a/gcc/config/rs6000/rs6000-protos.h b/gcc/config/rs6000/rs6000-protos.h index 6b27d73023a..0dddb4017ee 100644 --- a/gcc/config/rs6000/rs6000-protos.h +++ b/gcc/config/rs6000/rs6000-protos.h @@ -139,7 +139,6 @@ extern bool valid_sf_si_move (rtx, rtx, machine_mode); extern void rs6000_emit_move (rtx, rtx, machine_mode); extern bool rs6000_legitimate_offset_address_p (machine_mode, rtx, bool, bool); -extern void rs6000_output_tlsargs (rtx *); extern rtx rs6000_find_base_term (rtx); extern rtx rs6000_return_addr (int, rtx); extern void rs6000_output_symbol_ref (FILE*, rtx); diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 5f776f87e49..892ee94032f 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -8500,41 +8500,6 @@ rs6000_legitimize_tls_address_aix (rtx addr, enum tls_model model) return dest; } -/* Output arg setup instructions for a !TARGET_TLS_MARKERS - __tls_get_addr call. */ - -void -rs6000_output_tlsargs (rtx *operands) -{ - /* Set up operands for output_asm_insn, without modifying OPERANDS. */ - rtx op[3]; - - /* The set dest of the call, ie. r3, which is also the first arg reg. */ - op[0] = operands[0]; - /* The TLS symbol from global_tlsarg stashed as CALL operand 2. */ - op[1] = XVECEXP (operands[2], 0, 0); - if (XINT (operands[2], 1) == UNSPEC_TLSGD) - { - /* The GOT register. */ - op[2] = XVECEXP (operands[2], 0, 1); - if (TARGET_CMODEL != CMODEL_SMALL) - output_asm_insn ("addis %0,%2,%1@got@tlsgd@ha\n\t" - "addi %0,%0,%1@got@tlsgd@l", op); - else - output_asm_insn ("addi %0,%2,%1@got@tlsgd", op); - } - else if (XINT (operands[2], 1) == UNSPEC_TLSLD) - { - if (TARGET_CMODEL != CMODEL_SMALL) - output_asm_insn ("addis %0,%1,%&@got@tlsld@ha\n\t" - "addi %0,%0,%&@got@tlsld@l", op); - else - output_asm_insn ("addi %0,%1,%&@got@tlsld", op); - } - else - gcc_unreachable (); -} - /* Passes the tls arg value for global dynamic and local dynamic emit_library_call_value in rs6000_legitimize_tls_address to rs6000_call_aix and rs6000_call_sysv. This is used to emit the @@ -8636,16 +8601,10 @@ rs6000_legitimize_tls_address (rtx addr, enum tls_model model) rtx arg = gen_rtx_UNSPEC (Pmode, gen_rtvec (2, addr, got), UNSPEC_TLSGD); tga = rs6000_tls_get_addr (); + rtx argreg = gen_rtx_REG (Pmode, 3); + emit_insn (gen_rtx_SET (argreg, arg)); global_tlsarg = arg; - if (TARGET_TLS_MARKERS) - { - rtx argreg = gen_rtx_REG (Pmode, 3); - emit_insn (gen_rtx_SET (argreg, arg)); - emit_library_call_value (tga, dest, LCT_CONST, Pmode, - argreg, Pmode); - } - else - emit_library_call_value (tga, dest, LCT_CONST, Pmode); + emit_library_call_value (tga, dest, LCT_CONST, Pmode, argreg, Pmode); global_tlsarg = NULL_RTX; /* Make a note so that the result of this call can be CSEd. */ @@ -8658,16 +8617,10 @@ rs6000_legitimize_tls_address (rtx addr, enum tls_model model) rtx arg = gen_rtx_UNSPEC (Pmode, gen_rtvec (1, got), UNSPEC_TLSLD); tga = rs6000_tls_get_addr (); tmp1 = gen_reg_rtx (Pmode); + rtx argreg = gen_rtx_REG (Pmode, 3); + emit_insn (gen_rtx_SET (argreg, arg)); global_tlsarg = arg; - if (TARGET_TLS_MARKERS) - { - rtx argreg = gen_rtx_REG (Pmode, 3); - emit_insn (gen_rtx_SET (argreg, arg)); - emit_library_call_value (tga, tmp1, LCT_CONST, Pmode, - argreg, Pmode); - } - else - emit_library_call_value (tga, tmp1, LCT_CONST, Pmode); + emit_library_call_value (tga, tmp1, LCT_CONST, Pmode, argreg, Pmode); global_tlsarg = NULL_RTX; /* Make a note so that the result of this call can be CSEd. */ @@ -13455,14 +13408,12 @@ rs6000_call_template_1 (rtx *operands, unsigned int funop, bool sibcall) char arg[12]; arg[0] = 0; - if (TARGET_TLS_MARKERS && GET_CODE (operands[funop + 1]) == UNSPEC) + if (GET_CODE (operands[funop + 1]) == UNSPEC) { if (XINT (operands[funop + 1], 1) == UNSPEC_TLSGD) sprintf (arg, "(%%%u@tlsgd)", funop + 1); else if (XINT (operands[funop + 1], 1) == UNSPEC_TLSLD) sprintf (arg, "(%%&@tlsld)"); - else - gcc_unreachable (); } /* The magic 32768 offset here corresponds to the offset of @@ -13603,7 +13554,7 @@ rs6000_indirect_call_template_1 (rtx *operands, unsigned int funop, const char *rel64 = TARGET_64BIT ? "64" : ""; char tls[29]; tls[0] = 0; - if (TARGET_TLS_MARKERS && GET_CODE (operands[funop + 1]) == UNSPEC) + if (GET_CODE (operands[funop + 1]) == UNSPEC) { if (XINT (operands[funop + 1], 1) == UNSPEC_TLSGD) sprintf (tls, ".reloc .,R_PPC%s_TLSGD,%%%u\n\t", @@ -13611,8 +13562,6 @@ rs6000_indirect_call_template_1 (rtx *operands, unsigned int funop, else if (XINT (operands[funop + 1], 1) == UNSPEC_TLSLD) sprintf (tls, ".reloc .,R_PPC%s_TLSLD,%%&\n\t", rel64); - else - gcc_unreachable (); } const char *notoc = rs6000_pcrel_p (cfun) ? "_NOTOC" : ""; @@ -13699,7 +13648,7 @@ rs6000_pltseq_template (rtx *operands, int which) const char *rel64 = TARGET_64BIT ? "64" : ""; char tls[30]; tls[0] = 0; - if (TARGET_TLS_MARKERS && GET_CODE (operands[3]) == UNSPEC) + if (GET_CODE (operands[3]) == UNSPEC) { char off = which == RS6000_PLTSEQ_PLT_PCREL34 ? '8' : '4'; if (XINT (operands[3], 1) == UNSPEC_TLSGD) @@ -13708,8 +13657,6 @@ rs6000_pltseq_template (rtx *operands, int which) else if (XINT (operands[3], 1) == UNSPEC_TLSLD) sprintf (tls, ".reloc .-%c,R_PPC%s_TLSLD,%%&\n\t", off, rel64); - else - gcc_unreachable (); } gcc_assert (DEFAULT_ABI == ABI_ELFv2 || DEFAULT_ABI == ABI_V4); @@ -22976,9 +22923,6 @@ static struct rs6000_opt_var const rs6000_opt_vars[] = { "align-branch-targets", offsetof (struct gcc_options, x_TARGET_ALIGN_BRANCH_TARGETS), offsetof (struct cl_target_option, x_TARGET_ALIGN_BRANCH_TARGETS), }, - { "tls-markers", - offsetof (struct gcc_options, x_tls_markers), - offsetof (struct cl_target_option, x_tls_markers), }, { "sched-prolog", offsetof (struct gcc_options, x_TARGET_SCHED_PROLOG), offsetof (struct cl_target_option, x_TARGET_SCHED_PROLOG), }, diff --git a/gcc/config/rs6000/rs6000.h b/gcc/config/rs6000/rs6000.h index a4ad3f8fc3e..7f9cb1ce2e3 100644 --- a/gcc/config/rs6000/rs6000.h +++ b/gcc/config/rs6000/rs6000.h @@ -228,15 +228,6 @@ extern const char *host_detect_local_cpu (int argc, const char **argv); #define TARGET_MFCRF 0 #endif -/* Define TARGET_TLS_MARKERS if the target assembler does not support - arg markers for __tls_get_addr calls. */ -#ifndef HAVE_AS_TLS_MARKERS -#undef TARGET_TLS_MARKERS -#define TARGET_TLS_MARKERS 0 -#else -#define TARGET_TLS_MARKERS tls_markers -#endif - #ifndef TARGET_SECURE_PLT #define TARGET_SECURE_PLT 0 #endif @@ -1488,13 +1479,6 @@ enum rs6000_pltseq_enum { #define IS_V4_FP_ARGS(OP) \ ((INTVAL (OP) & (CALL_V4_CLEAR_FP_ARGS | CALL_V4_SET_FP_ARGS)) != 0) -/* Whether OP is an UNSPEC used in !TARGET_TLS_MARKER calls. */ -#define IS_NOMARK_TLSGETADDR(OP) \ - (!TARGET_TLS_MARKERS \ - && GET_CODE (OP) == UNSPEC \ - && (XINT (OP, 1) == UNSPEC_TLSGD \ - || XINT (OP, 1) == UNSPEC_TLSLD)) - /* We don't have prologue and epilogue functions to save/restore everything for most ABIs. */ #define WORLD_SAVE_P(INFO) 0 diff --git a/gcc/config/rs6000/rs6000.md b/gcc/config/rs6000/rs6000.md index e1db6ad2f45..0fc0f952611 100644 --- a/gcc/config/rs6000/rs6000.md +++ b/gcc/config/rs6000/rs6000.md @@ -9500,7 +9500,7 @@ (unspec:P [(match_operand:P 1 "rs6000_tls_symbol_ref" "") (match_operand:P 2 "gpc_reg_operand" "b")] UNSPEC_TLSGD))] - "HAVE_AS_TLS && TARGET_TLS_MARKERS" + "HAVE_AS_TLS && TARGET_ELF" "addi %0,%2,%1@got@tlsgd" "&& TARGET_CMODEL != CMODEL_SMALL" [(set (match_dup 3) @@ -9523,7 +9523,7 @@ (unspec:P [(match_operand:P 1 "rs6000_tls_symbol_ref" "") (match_operand:P 2 "gpc_reg_operand" "b")] UNSPEC_TLSGD)))] - "HAVE_AS_TLS && TARGET_TLS_MARKERS && TARGET_CMODEL != CMODEL_SMALL" + "HAVE_AS_TLS && TARGET_ELF && TARGET_CMODEL != CMODEL_SMALL" "addis %0,%2,%1@got@tlsgd@ha") (define_insn "*tls_gd_low" @@ -9532,14 +9532,14 @@ (unspec:P [(match_operand:P 2 "rs6000_tls_symbol_ref" "") (match_operand:P 3 "gpc_reg_operand" "b")] UNSPEC_TLSGD)))] - "HAVE_AS_TLS && TARGET_TLS_MARKERS && TARGET_CMODEL != CMODEL_SMALL" + "HAVE_AS_TLS && TARGET_ELF && TARGET_CMODEL != CMODEL_SMALL" "addi %0,%1,%2@got@tlsgd@l") (define_insn_and_split "*tls_ld" [(set (match_operand:P 0 "gpc_reg_operand" "=b") (unspec:P [(match_operand:P 1 "gpc_reg_operand" "b")] UNSPEC_TLSLD))] - "HAVE_AS_TLS && TARGET_TLS_MARKERS" + "HAVE_AS_TLS && TARGET_ELF" "addi %0,%1,%&@got@tlsld" "&& TARGET_CMODEL != CMODEL_SMALL" [(set (match_dup 2) @@ -9561,7 +9561,7 @@ (high:P (unspec:P [(match_operand:P 1 "gpc_reg_operand" "b")] UNSPEC_TLSLD)))] - "HAVE_AS_TLS && TARGET_TLS_MARKERS && TARGET_CMODEL != CMODEL_SMALL" + "HAVE_AS_TLS && TARGET_ELF && TARGET_CMODEL != CMODEL_SMALL" "addis %0,%1,%&@got@tlsld@ha") (define_insn "*tls_ld_low" @@ -9569,7 +9569,7 @@ (lo_sum:P (match_operand:P 1 "gpc_reg_operand" "b") (unspec:P [(match_operand:P 2 "gpc_reg_operand" "b")] UNSPEC_TLSLD)))] - "HAVE_AS_TLS && TARGET_TLS_MARKERS && TARGET_CMODEL != CMODEL_SMALL" + "HAVE_AS_TLS && TARGET_ELF && TARGET_CMODEL != CMODEL_SMALL" "addi %0,%1,%&@got@tlsld@l") (define_insn "tls_dtprel_" @@ -10303,7 +10303,7 @@ (match_operand:P 2 "symbol_ref_operand" "s") (match_operand:P 3 "" "")] UNSPEC_PLT_PCREL))] - "HAVE_AS_PLTSEQ && TARGET_TLS_MARKERS + "HAVE_AS_PLTSEQ && TARGET_ELF && rs6000_pcrel_p (cfun)" { return rs6000_pltseq_template (operands, RS6000_PLTSEQ_PLT_PCREL34); @@ -10418,8 +10418,7 @@ (match_operand 2))) (use (match_operand:SI 3 "immediate_operand" "O,n")) (clobber (reg:SI LR_REGNO))] - "(INTVAL (operands[3]) & CALL_LONG) == 0 - && !IS_NOMARK_TLSGETADDR (operands[2])" + "(INTVAL (operands[3]) & CALL_LONG) == 0" { if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) output_asm_insn ("crxor 6,6,6", operands); @@ -10439,8 +10438,7 @@ (match_operand 2))) (use (match_operand:SI 3 "immediate_operand" "O,n")) (clobber (reg:DI LR_REGNO))] - "TARGET_64BIT && (INTVAL (operands[3]) & CALL_LONG) == 0 - && !IS_NOMARK_TLSGETADDR (operands[2])" + "TARGET_64BIT && (INTVAL (operands[3]) & CALL_LONG) == 0" { if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) output_asm_insn ("crxor 6,6,6", operands); @@ -10538,10 +10536,7 @@ "DEFAULT_ABI == ABI_V4 || DEFAULT_ABI == ABI_DARWIN" { - if (IS_NOMARK_TLSGETADDR (operands[2])) - rs6000_output_tlsargs (operands); - - else if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) + if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) output_asm_insn ("crxor 6,6,6", operands); else if (INTVAL (operands[3]) & CALL_V4_CLEAR_FP_ARGS) @@ -10552,8 +10547,7 @@ [(set_attr "type" "jmpreg") (set (attr "length") (plus - (if_then_else (ior (match_test "IS_NOMARK_TLSGETADDR (operands[2])") - (match_test "IS_V4_FP_ARGS (operands[3])")) + (if_then_else (match_test "IS_V4_FP_ARGS (operands[3])") (const_int 4) (const_int 0)) (if_then_else (and (match_test "!rs6000_speculate_indirect_jumps") @@ -10571,10 +10565,7 @@ || (DEFAULT_ABI == ABI_V4 && (INTVAL (operands[3]) & CALL_LONG) == 0))" { - if (IS_NOMARK_TLSGETADDR (operands[2])) - rs6000_output_tlsargs (operands); - - else if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) + if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) output_asm_insn ("crxor 6,6,6", operands); else if (INTVAL (operands[3]) & CALL_V4_CLEAR_FP_ARGS) @@ -10584,8 +10575,7 @@ } [(set_attr "type" "branch") (set (attr "length") - (if_then_else (ior (match_test "IS_NOMARK_TLSGETADDR (operands[2])") - (match_test "IS_V4_FP_ARGS (operands[3])")) + (if_then_else (match_test "IS_V4_FP_ARGS (operands[3])") (const_int 8) (const_int 4)))]) @@ -10600,10 +10590,7 @@ && TARGET_SECURE_PLT && flag_pic && !SYMBOL_REF_LOCAL_P (operands[1]) && (INTVAL (operands[3]) & CALL_LONG) == 0)" { - if (IS_NOMARK_TLSGETADDR (operands[2])) - rs6000_output_tlsargs (operands); - - else if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) + if (INTVAL (operands[3]) & CALL_V4_SET_FP_ARGS) output_asm_insn ("crxor 6,6,6", operands); else if (INTVAL (operands[3]) & CALL_V4_CLEAR_FP_ARGS) @@ -10613,8 +10600,7 @@ } [(set_attr "type" "branch") (set (attr "length") - (if_then_else (ior (match_test "IS_NOMARK_TLSGETADDR (operands[2])") - (match_test "IS_V4_FP_ARGS (operands[3])")) + (if_then_else (match_test "IS_V4_FP_ARGS (operands[3])") (const_int 8) (const_int 4)))]) @@ -10637,8 +10623,7 @@ (call (mem:SI (match_operand:P 1 "current_file_function_operand" "s")) (match_operand 2))) (clobber (reg:P LR_REGNO))] - "(DEFAULT_ABI == ABI_AIX || DEFAULT_ABI == ABI_ELFv2) - && !IS_NOMARK_TLSGETADDR (operands[2])" + "DEFAULT_ABI == ABI_AIX || DEFAULT_ABI == ABI_ELFv2" { if (rs6000_pcrel_p (cfun)) return "bl %z1@notoc"; @@ -10670,21 +10655,13 @@ (clobber (reg:P LR_REGNO))] "DEFAULT_ABI == ABI_AIX || DEFAULT_ABI == ABI_ELFv2" { - if (IS_NOMARK_TLSGETADDR (operands[2])) - rs6000_output_tlsargs (operands); - return rs6000_call_template (operands, 1); } [(set_attr "type" "branch") (set (attr "length") - (plus (if_then_else (match_test "IS_NOMARK_TLSGETADDR (operands[2])") - (if_then_else (match_test "TARGET_CMODEL != CMODEL_SMALL") - (const_int 8) - (const_int 4)) - (const_int 0)) - (if_then_else (match_test "rs6000_pcrel_p (cfun)") - (const_int 4) - (const_int 8))))]) + (if_then_else (match_test "rs6000_pcrel_p (cfun)") + (const_int 4) + (const_int 8)))]) ;; Call to indirect functions with the AIX abi using a 3 word descriptor. ;; Operand0 is the addresss of the function to call @@ -10719,23 +10696,14 @@ (clobber (reg:P LR_REGNO))] "DEFAULT_ABI == ABI_AIX" { - if (IS_NOMARK_TLSGETADDR (operands[2])) - rs6000_output_tlsargs (operands); - return rs6000_indirect_call_template (operands, 1); } [(set_attr "type" "jmpreg") (set (attr "length") - (plus - (if_then_else (match_test "IS_NOMARK_TLSGETADDR (operands[2])") - (if_then_else (match_test "TARGET_CMODEL != CMODEL_SMALL") - (const_int 8) - (const_int 4)) - (const_int 0)) - (if_then_else (and (match_test "!rs6000_speculate_indirect_jumps") - (match_test "which_alternative != 1")) + (if_then_else (and (match_test "!rs6000_speculate_indirect_jumps") + (match_test "which_alternative != 1")) (const_string "16") - (const_string "12"))))]) + (const_string "12")))]) ;; Call to indirect functions with the ELFv2 ABI. ;; Operand0 is the addresss of the function to call @@ -10782,23 +10750,14 @@ (clobber (reg:P LR_REGNO))] "DEFAULT_ABI == ABI_ELFv2" { - if (IS_NOMARK_TLSGETADDR (operands[2])) - rs6000_output_tlsargs (operands); - return rs6000_indirect_call_template (operands, 1); } [(set_attr "type" "jmpreg") (set (attr "length") - (plus - (if_then_else (match_test "IS_NOMARK_TLSGETADDR (operands[2])") - (if_then_else (match_test "TARGET_CMODEL != CMODEL_SMALL") - (const_int 8) - (const_int 4)) - (const_int 0)) - (if_then_else (and (match_test "!rs6000_speculate_indirect_jumps") - (match_test "which_alternative != 1")) + (if_then_else (and (match_test "!rs6000_speculate_indirect_jumps") + (match_test "which_alternative != 1")) (const_string "12") - (const_string "8"))))]) + (const_string "8")))]) (define_insn "*call_value_indirect_pcrel" [(set (match_operand 0 "" "") @@ -10807,23 +10766,14 @@ (clobber (reg:P LR_REGNO))] "rs6000_pcrel_p (cfun)" { - if (IS_NOMARK_TLSGETADDR (operands[2])) - rs6000_output_tlsargs (operands); - return rs6000_indirect_call_template (operands, 1); } [(set_attr "type" "jmpreg") (set (attr "length") - (plus - (if_then_else (match_test "IS_NOMARK_TLSGETADDR (operands[2])") - (if_then_else (match_test "TARGET_CMODEL != CMODEL_SMALL") - (const_int 8) - (const_int 4)) - (const_int 0)) - (if_then_else (and (match_test "!rs6000_speculate_indirect_jumps") - (match_test "which_alternative != 1")) + (if_then_else (and (match_test "!rs6000_speculate_indirect_jumps") + (match_test "which_alternative != 1")) (const_string "8") - (const_string "4"))))]) + (const_string "4")))]) ;; Call subroutine returning any type. (define_expand "untyped_call" diff --git a/gcc/config/rs6000/rs6000.opt b/gcc/config/rs6000/rs6000.opt index 387d3cfd377..9ee7c0af3ee 100644 --- a/gcc/config/rs6000/rs6000.opt +++ b/gcc/config/rs6000/rs6000.opt @@ -246,10 +246,6 @@ mavoid-indexed-addresses Target Report Var(TARGET_AVOID_XFORM) Init(-1) Save Avoid generation of indexed load/store instructions when possible. -mtls-markers -Target Report Var(tls_markers) Init(1) Save -Mark __tls_get_addr calls with argument info. - msched-epilog Target Undocumented Var(TARGET_SCHED_PROLOG) Init(1) Save diff --git a/gcc/configure b/gcc/configure index be58e1a4d5f..b60458e2192 100755 --- a/gcc/configure +++ b/gcc/configure @@ -27314,42 +27314,6 @@ if test $gcc_cv_as_powerpc_gnu_attribute = yes; then $as_echo "#define HAVE_AS_GNU_ATTRIBUTE 1" >>confdefs.h -fi - - - { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for tls marker support" >&5 -$as_echo_n "checking assembler for tls marker support... " >&6; } -if ${gcc_cv_as_powerpc_tls_markers+:} false; then : - $as_echo_n "(cached) " >&6 -else - gcc_cv_as_powerpc_tls_markers=no - if test $in_tree_gas = yes; then - if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 20 \) \* 1000 + 0` - then gcc_cv_as_powerpc_tls_markers=yes -fi - elif test x$gcc_cv_as != x; then - $as_echo ' bl __tls_get_addr(x@tlsgd)' > conftest.s - if { ac_try='$gcc_cv_as $gcc_cv_as_flags -o conftest.o conftest.s >&5' - { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 - (eval $ac_try) 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; } - then - gcc_cv_as_powerpc_tls_markers=yes - else - echo "configure: failed program was" >&5 - cat conftest.s >&5 - fi - rm -f conftest.o conftest.s - fi -fi -{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_tls_markers" >&5 -$as_echo "$gcc_cv_as_powerpc_tls_markers" >&6; } -if test $gcc_cv_as_powerpc_tls_markers = yes; then - -$as_echo "#define HAVE_AS_TLS_MARKERS 1" >>confdefs.h - fi diff --git a/gcc/configure.ac b/gcc/configure.ac index 6bce1e3b6d9..b9cc2435cdf 100644 --- a/gcc/configure.ac +++ b/gcc/configure.ac @@ -4811,12 +4811,6 @@ LCF0: [AC_DEFINE(HAVE_AS_GNU_ATTRIBUTE, 1, [Define if your assembler supports .gnu_attribute.])]) - gcc_GAS_CHECK_FEATURE([tls marker support], - gcc_cv_as_powerpc_tls_markers, [2,20,0],, - [ bl __tls_get_addr(x@tlsgd)],, - [AC_DEFINE(HAVE_AS_TLS_MARKERS, 1, - [Define if your assembler supports arg info for __tls_get_addr.])]) - gcc_GAS_CHECK_FEATURE([prologue entry point marker support], gcc_cv_as_powerpc_entry_markers, [2,26,0],-a64 --fatal-warnings, [ .reloc .,R_PPC64_ENTRY; nop],, diff --git a/gcc/doc/install.texi b/gcc/doc/install.texi index 93b01ff7971..215a6fa38ff 100644 --- a/gcc/doc/install.texi +++ b/gcc/doc/install.texi @@ -4390,7 +4390,7 @@ The OpenRISC 1000 32-bit processor with delay slots. You can specify a default version for the @option{-mcpu=@var{cpu_type}} switch by using the configure option @option{--with-cpu-@var{cpu_type}}. -You will need GNU binutils 2.15 or newer. +You will need GNU binutils 2.20 or newer. @html
-- 2.30.2