From: H.J. Lu Date: Mon, 15 Jan 2018 22:29:41 +0000 (+0000) Subject: i386: Rename to ix86_indirect_branch_register X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e71cf74a5d61ce3dc228bcad1abfeb911d48430d;p=gcc.git i386: Rename to ix86_indirect_branch_register Rename the variable for -mindirect-branch-register to ix86_indirect_branch_register to match the command-line option name. * config/i386/constraints.md (Bs): Replace ix86_indirect_branch_thunk_register with ix86_indirect_branch_register. (Bw): Likewise. * config/i386/i386.md (indirect_jump): Likewise. (tablejump): Likewise. (*sibcall_memory): Likewise. (*sibcall_value_memory): Likewise. Peepholes of indirect call and jump via memory: Likewise. * config/i386/i386.opt: Likewise. * config/i386/predicates.md (indirect_branch_operand): Likewise. (GOT_memory_operand): Likewise. (call_insn_operand): Likewise. (sibcall_insn_operand): Likewise. (GOT32_symbol_operand): Likewise. From-SVN: r256712 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index bfaea13b33b..6500ed3821d 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,21 @@ +2018-01-15 H.J. Lu + + * config/i386/constraints.md (Bs): Replace + ix86_indirect_branch_thunk_register with + ix86_indirect_branch_register. + (Bw): Likewise. + * config/i386/i386.md (indirect_jump): Likewise. + (tablejump): Likewise. + (*sibcall_memory): Likewise. + (*sibcall_value_memory): Likewise. + Peepholes of indirect call and jump via memory: Likewise. + * config/i386/i386.opt: Likewise. + * config/i386/predicates.md (indirect_branch_operand): Likewise. + (GOT_memory_operand): Likewise. + (call_insn_operand): Likewise. + (sibcall_insn_operand): Likewise. + (GOT32_symbol_operand): Likewise. + 2018-01-15 Jakub Jelinek PR middle-end/83837 diff --git a/gcc/config/i386/constraints.md b/gcc/config/i386/constraints.md index 5592c43073e..d6072b9bcd9 100644 --- a/gcc/config/i386/constraints.md +++ b/gcc/config/i386/constraints.md @@ -226,19 +226,19 @@ (define_constraint "Bs" "@internal Sibcall memory operand." (ior (and (not (match_test "TARGET_X32 - || ix86_indirect_branch_thunk_register")) + || ix86_indirect_branch_register")) (match_operand 0 "sibcall_memory_operand")) (and (match_test "TARGET_X32 && Pmode == DImode - && !ix86_indirect_branch_thunk_register") + && !ix86_indirect_branch_register") (match_operand 0 "GOT_memory_operand")))) (define_constraint "Bw" "@internal Call memory operand." (ior (and (not (match_test "TARGET_X32 - || ix86_indirect_branch_thunk_register")) + || ix86_indirect_branch_register")) (match_operand 0 "memory_operand")) (and (match_test "TARGET_X32 && Pmode == DImode - && !ix86_indirect_branch_thunk_register") + && !ix86_indirect_branch_register") (match_operand 0 "GOT_memory_operand")))) (define_constraint "Bz" diff --git a/gcc/config/i386/i386.md b/gcc/config/i386/i386.md index fff73fe18e0..5cd3ec093cd 100644 --- a/gcc/config/i386/i386.md +++ b/gcc/config/i386/i386.md @@ -12311,7 +12311,7 @@ [(set (pc) (match_operand 0 "indirect_branch_operand"))] "" { - if (TARGET_X32 || ix86_indirect_branch_thunk_register) + if (TARGET_X32 || ix86_indirect_branch_register) operands[0] = convert_memory_address (word_mode, operands[0]); cfun->machine->has_local_indirect_jump = true; }) @@ -12365,7 +12365,7 @@ OPTAB_DIRECT); } - if (TARGET_X32 || ix86_indirect_branch_thunk_register) + if (TARGET_X32 || ix86_indirect_branch_register) operands[0] = convert_memory_address (word_mode, operands[0]); cfun->machine->has_local_indirect_jump = true; }) @@ -12614,7 +12614,7 @@ [(call (mem:QI (match_operand:W 0 "memory_operand" "m")) (match_operand 1)) (unspec [(const_int 0)] UNSPEC_PEEPSIB)] - "!TARGET_X32 && !ix86_indirect_branch_thunk_register" + "!TARGET_X32 && !ix86_indirect_branch_register" "* return ix86_output_call_insn (insn, operands[0]);" [(set_attr "type" "call")]) @@ -12624,7 +12624,7 @@ (call (mem:QI (match_dup 0)) (match_operand 3))] "!TARGET_X32 - && !ix86_indirect_branch_thunk_register + && !ix86_indirect_branch_register && SIBLING_CALL_P (peep2_next_insn (1)) && !reg_mentioned_p (operands[0], CALL_INSN_FUNCTION_USAGE (peep2_next_insn (1)))" @@ -12639,7 +12639,7 @@ (call (mem:QI (match_dup 0)) (match_operand 3))] "!TARGET_X32 - && !ix86_indirect_branch_thunk_register + && !ix86_indirect_branch_register && SIBLING_CALL_P (peep2_next_insn (2)) && !reg_mentioned_p (operands[0], CALL_INSN_FUNCTION_USAGE (peep2_next_insn (2)))" @@ -12737,7 +12737,7 @@ (match_operand:W 1 "memory_operand")) (set (pc) (match_dup 0))] "!TARGET_X32 - && !ix86_indirect_branch_thunk_register + && !ix86_indirect_branch_register && peep2_reg_dead_p (2, operands[0])" [(set (pc) (match_dup 1))]) @@ -12819,7 +12819,7 @@ (call (mem:QI (match_operand:W 1 "memory_operand" "m")) (match_operand 2))) (unspec [(const_int 0)] UNSPEC_PEEPSIB)] - "!TARGET_X32 && !ix86_indirect_branch_thunk_register" + "!TARGET_X32 && !ix86_indirect_branch_register" "* return ix86_output_call_insn (insn, operands[1]);" [(set_attr "type" "callv")]) @@ -12830,7 +12830,7 @@ (call (mem:QI (match_dup 0)) (match_operand 3)))] "!TARGET_X32 - && !ix86_indirect_branch_thunk_register + && !ix86_indirect_branch_register && SIBLING_CALL_P (peep2_next_insn (1)) && !reg_mentioned_p (operands[0], CALL_INSN_FUNCTION_USAGE (peep2_next_insn (1)))" @@ -12847,7 +12847,7 @@ (call (mem:QI (match_dup 0)) (match_operand 3)))] "!TARGET_X32 - && !ix86_indirect_branch_thunk_register + && !ix86_indirect_branch_register && SIBLING_CALL_P (peep2_next_insn (2)) && !reg_mentioned_p (operands[0], CALL_INSN_FUNCTION_USAGE (peep2_next_insn (2)))" diff --git a/gcc/config/i386/i386.opt b/gcc/config/i386/i386.opt index c6be5f94773..3a306bbd73f 100644 --- a/gcc/config/i386/i386.opt +++ b/gcc/config/i386/i386.opt @@ -1047,5 +1047,5 @@ EnumValue Enum(indirect_branch) String(thunk-extern) Value(indirect_branch_thunk_extern) mindirect-branch-register -Target Report Var(ix86_indirect_branch_thunk_register) Init(0) +Target Report Var(ix86_indirect_branch_register) Init(0) Force indirect call and jump via register. diff --git a/gcc/config/i386/predicates.md b/gcc/config/i386/predicates.md index 5ae443231b8..64f13a01326 100644 --- a/gcc/config/i386/predicates.md +++ b/gcc/config/i386/predicates.md @@ -666,7 +666,7 @@ (define_predicate "indirect_branch_operand" (ior (match_operand 0 "register_operand") (and (not (match_test "TARGET_X32 - || ix86_indirect_branch_thunk_register")) + || ix86_indirect_branch_register")) (match_operand 0 "memory_operand")))) ;; Return true if OP is a memory operands that can be used in sibcalls. @@ -695,7 +695,7 @@ ;; Return true if OP is a GOT memory operand. (define_predicate "GOT_memory_operand" - (and (match_test "!ix86_indirect_branch_thunk_register") + (and (match_test "!ix86_indirect_branch_register") (match_operand 0 "memory_operand")) { op = XEXP (op, 0); @@ -711,10 +711,10 @@ (op, mode == VOIDmode ? mode : Pmode)") (match_operand 0 "call_register_no_elim_operand") (ior (and (not (match_test "TARGET_X32 - || ix86_indirect_branch_thunk_register")) + || ix86_indirect_branch_register")) (match_operand 0 "memory_operand")) (and (match_test "TARGET_X32 && Pmode == DImode - && !ix86_indirect_branch_thunk_register") + && !ix86_indirect_branch_register") (match_operand 0 "GOT_memory_operand"))))) ;; Similarly, but for tail calls, in which we cannot allow memory references. @@ -723,15 +723,15 @@ (op, mode == VOIDmode ? mode : Pmode)") (match_operand 0 "register_no_elim_operand") (ior (and (not (match_test "TARGET_X32 - || ix86_indirect_branch_thunk_register")) + || ix86_indirect_branch_register")) (match_operand 0 "sibcall_memory_operand")) (and (match_test "TARGET_X32 && Pmode == DImode - && !ix86_indirect_branch_thunk_register") + && !ix86_indirect_branch_register") (match_operand 0 "GOT_memory_operand"))))) ;; Return true if OP is a 32-bit GOT symbol operand. (define_predicate "GOT32_symbol_operand" - (match_test "!ix86_indirect_branch_thunk_register + (match_test "!ix86_indirect_branch_register && GET_CODE (op) == CONST && GET_CODE (XEXP (op, 0)) == UNSPEC && XINT (XEXP (op, 0), 1) == UNSPEC_GOT"))