Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
gcc/ada/ChangeLog:
* gcc-interface/misc.c (gnat_post_options): Use new macro
OPTION_SET_P.
(gnat_init_gcc_eh): Likewise.
(gnat_init_gcc_fp): Likewise.
gcc/c-family/ChangeLog:
* c-opts.c (c_common_post_options): Use new macro
OPTION_SET_P.
gcc/ChangeLog:
* config/alpha/alpha.c (alpha_option_override): Use new macro
OPTION_SET_P.
* config/arc/arc.c (arc_override_options): Likewise.
* config/arm/arm.c (arm_option_override): Likewise.
* config/bfin/bfin.c (bfin_load_pic_reg): Likewise.
* config/c6x/c6x.c (c6x_option_override): Likewise.
* config/csky/csky.c: Likewise.
* config/darwin.c (darwin_override_options): Likewise.
* config/frv/frv.c (frv_option_override): Likewise.
* config/i386/djgpp.h: Likewise.
* config/i386/i386.c (ix86_stack_protect_guard): Likewise.
(ix86_max_noce_ifcvt_seq_cost): Likewise.
* config/ia64/ia64.c (ia64_option_override): Likewise.
(ia64_override_options_after_change): Likewise.
* config/m32c/m32c.c (m32c_option_override): Likewise.
* config/m32r/m32r.c (m32r_init): Likewise.
* config/m68k/m68k.c (m68k_option_override): Likewise.
* config/microblaze/microblaze.c (microblaze_option_override): Likewise.
* config/mips/mips.c (mips_option_override): Likewise.
* config/nios2/nios2.c (nios2_option_override): Likewise.
* config/nvptx/nvptx.c (nvptx_option_override): Likewise.
* config/pa/pa.c (pa_option_override): Likewise.
* config/riscv/riscv.c (riscv_option_override): Likewise.
* config/rs6000/aix71.h: Likewise.
* config/rs6000/aix72.h: Likewise.
* config/rs6000/aix73.h: Likewise.
* config/rs6000/rs6000.c (darwin_rs6000_override_options): Likewise.
(rs6000_override_options_after_change): Likewise.
(rs6000_linux64_override_options): Likewise.
(glibc_supports_ieee_128bit): Likewise.
(rs6000_option_override_internal): Likewise.
(rs6000_file_start): Likewise.
(rs6000_darwin_file_start): Likewise.
* config/rs6000/rtems.h: Likewise.
* config/rs6000/sysv4.h: Likewise.
* config/rs6000/vxworks.h (SUB3TARGET_OVERRIDE_OPTIONS): Likewise.
* config/s390/s390.c (s390_option_override): Likewise.
* config/sh/linux.h: Likewise.
* config/sh/netbsd-elf.h (while): Likewise.
* config/sh/sh.c (sh_option_override): Likewise.
* config/sol2.c (solaris_override_options): Likewise.
* config/sparc/sparc.c (sparc_option_override): Likewise.
* config/tilegx/tilegx.c (tilegx_option_override): Likewise.
* config/visium/visium.c (visium_option_override): Likewise.
* config/vxworks.c (vxworks_override_options): Likewise.
* lto-opts.c (lto_write_options): Likewise.
* omp-expand.c (expand_omp_simd): Likewise.
* omp-general.c (omp_max_vf): Likewise.
* omp-offload.c (oacc_xform_loop): Likewise.
* opts.h (OPTION_SET_P): Likewise.
* targhooks.c (default_max_noce_ifcvt_seq_cost): Likewise.
* toplev.c (process_options): Likewise.
* tree-predcom.c: Likewise.
* tree-sra.c (analyze_all_variable_accesses): Likewise.
gcc/cp/ChangeLog:
* constexpr.c (maybe_warn_about_constant_value): Use new macro
OPTION_SET_P.
* decl.c (redeclaration_error_message): Likewise.
(cxx_init_decl_processing): Likewise.
gcc/d/ChangeLog:
* d-lang.cc (d_post_options): Use new macro
OPTION_SET_P.
gcc/fortran/ChangeLog:
* options.c (gfc_post_options): Use new macro
OPTION_SET_P.
gcc/objc/ChangeLog:
* objc-next-runtime-abi-01.c: Use new macro
OPTION_SET_P.
* objc-next-runtime-abi-02.c (objc_next_runtime_abi_02_init): Likewise.
|
|
|
|
gcc/brig/ChangeLog:
* lang.opt: Remove usage of Report.
gcc/c-family/ChangeLog:
* c.opt: Remove usage of Report.
gcc/ChangeLog:
* common.opt: Remove usage of Report.
* config/aarch64/aarch64.opt: Ditto.
* config/alpha/alpha.opt: Ditto.
* config/arc/arc.opt: Ditto.
* config/arm/arm.opt: Ditto.
* config/avr/avr.opt: Ditto.
* config/bfin/bfin.opt: Ditto.
* config/bpf/bpf.opt: Ditto.
* config/c6x/c6x.opt: Ditto.
* config/cr16/cr16.opt: Ditto.
* config/cris/cris.opt: Ditto.
* config/cris/elf.opt: Ditto.
* config/csky/csky.opt: Ditto.
* config/darwin.opt: Ditto.
* config/fr30/fr30.opt: Ditto.
* config/frv/frv.opt: Ditto.
* config/ft32/ft32.opt: Ditto.
* config/gcn/gcn.opt: Ditto.
* config/i386/cygming.opt: Ditto.
* config/i386/i386.opt: Ditto.
* config/ia64/ia64.opt: Ditto.
* config/ia64/ilp32.opt: Ditto.
* config/linux-android.opt: Ditto.
* config/linux.opt: Ditto.
* config/lm32/lm32.opt: Ditto.
* config/m32r/m32r.opt: Ditto.
* config/m68k/m68k.opt: Ditto.
* config/mcore/mcore.opt: Ditto.
* config/microblaze/microblaze.opt: Ditto.
* config/mips/mips.opt: Ditto.
* config/mmix/mmix.opt: Ditto.
* config/mn10300/mn10300.opt: Ditto.
* config/moxie/moxie.opt: Ditto.
* config/msp430/msp430.opt: Ditto.
* config/nds32/nds32.opt: Ditto.
* config/nios2/elf.opt: Ditto.
* config/nios2/nios2.opt: Ditto.
* config/nvptx/nvptx.opt: Ditto.
* config/pa/pa.opt: Ditto.
* config/pdp11/pdp11.opt: Ditto.
* config/pru/pru.opt: Ditto.
* config/riscv/riscv.opt: Ditto.
* config/rl78/rl78.opt: Ditto.
* config/rs6000/aix64.opt: Ditto.
* config/rs6000/linux64.opt: Ditto.
* config/rs6000/rs6000.opt: Ditto.
* config/rs6000/sysv4.opt: Ditto.
* config/rx/elf.opt: Ditto.
* config/rx/rx.opt: Ditto.
* config/s390/s390.opt: Ditto.
* config/s390/tpf.opt: Ditto.
* config/sh/sh.opt: Ditto.
* config/sol2.opt: Ditto.
* config/sparc/long-double-switch.opt: Ditto.
* config/sparc/sparc.opt: Ditto.
* config/tilegx/tilegx.opt: Ditto.
* config/tilepro/tilepro.opt: Ditto.
* config/v850/v850.opt: Ditto.
* config/visium/visium.opt: Ditto.
* config/vms/vms.opt: Ditto.
* config/vxworks.opt: Ditto.
* config/xtensa/xtensa.opt: Ditto.
gcc/lto/ChangeLog:
* lang.opt: Remove usage of Report.
|
|
This patch introduces maybe_emit_call_builtin___clear_cache for the
builtin expander machinery and the trampoline initializers to use to
clear the instruction cache, removing a source of inconsistencies and
subtle errors in low-level machinery.
I've adjusted all trampoline_init implementations that used to issue
explicit calls to __clear_cache or similar to use this new primitive.
Specifically on vxworks targets, we needed to drop the __clear_cache
symbol in libgcc, for reasons related with linking that I didn't need
to understand, and we wanted to call cacheTextUpdate directly, despite
the different calling conventions: the second argument is a length
rather than the end address.
So I introduced a target hook to enable target OS-level overriding of
builtin __clear_cache call emission, retaining nearly (*) the same
logic to govern the decision on whether to emit a call (or nothing, or
a machine-dependent insn) but enabling a call to a target
system-defined function with different calling conventions to be
issued, without having to modify .md files of the various
architectures supported by the target system to introduce or modify
clear_cache insns.
(*) I write "nearly" mainly because, when not optimizing, we'd issue a
call regardless, but since the call may now be overridden, I added it
to the set of builtins that are not directly turned into calls when
not optimizing, following the normal expansion path instead. It
wouldn't be hard to skip the emission of cache-clearing insns when not
optimizing, but it didn't seem very important, especially for the new
uses from trampoline init.
Another difference that might be relevant is that now we expand
the begin and end arguments unconditionally. This might make a
difference if they have side effects. That's prettty much impossible
at expand time, but I thought I'd mention it.
I have NOT modified targets that did not issue cache-clearing calls in
trampoline init to use the new clear_cache-calling infrastructure even
if it would expand to nothing. I have considered doing so, to have
__builtin___clear_cache and trampoline init call cacheTextUpdate on
all vxworks targets, but decided not to, since on targets that don't
do any cache clearing, cacheTextUpdate ought to be a no-op, even
though rs6000 seems to use icbi and dcbf instructions in the function
called to initialize a trampoline, but AFAICT not in the __clear_cache
builtin. Hopefully target maintainers will have a look and take
advantage of this new piece of infrastructure to remove such
(apparent?) inconsistencies. Not rs6000 and other that call asm-coded
trampoline setup instructions, for sure, but they might wish to
introduce a CLEAR_INSN_CACHE macro or a clear_cache expander if they
don't have one.
for gcc/ChangeLog
* builtins.c (default_emit_call_builtin___clear_cache): New.
(maybe_emit_call_builtin___clear_cache): New.
(expand_builtin___clear_cache): Split into the above.
(expand_builtin): Do not issue clear_cache call any more.
* builtins.h (maybe_emit_call_builtin___clear_cache): Declare.
* config/aarch64/aarch64.c (aarch64_trampoline_init): Use
maybe_emit_call_builtin___clear_cache.
* config/arc/arc.c (arc_trampoline_init): Likewise.
* config/arm/arm.c (arm_trampoline_init): Likewise.
* config/c6x/c6x.c (c6x_initialize_trampoline): Likewise.
* config/csky/csky.c (csky_trampoline_init): Likewise.
* config/m68k/linux.h (FInALIZE_TRAMPOLINE): Likewise.
* config/tilegx/tilegx.c (tilegx_trampoline_init): Likewise.
* config/tilepro/tilepro.c (tilepro_trampoline_init): Ditto.
* config/vxworks.c: Include rtl.h, memmodel.h, and optabs.h.
(vxworks_emit_call_builtin___clear_cache): New.
* config/vxworks.h (CLEAR_INSN_CACHE): Drop.
(TARGET_EMIT_CALL_BUILTIN___CLEAR_CACHE): Define.
* target.def (trampoline_init): In the documentation, refer to
maybe_emit_call_builtin___clear_cache.
(emit_call_builtin___clear_cache): New.
* doc/tm.texi.in: Add new hook point.
(CLEAR_CACHE_INSN): Remove duplicate 'both'.
* doc/tm.texi: Rebuilt.
* targhooks.h (default_meit_call_builtin___clear_cache):
Declare.
* tree.h (BUILTIN_ASM_NAME_PTR): New.
for libgcc/ChangeLog
* config/t-vxworks (LIB2ADD): Drop.
* config/t-vxworks7 (LIB2ADD): Likewise.
* config/vxcache.c: Remove.
|
|
../../gcc/config/tilegx/tilegx.md:4109:1: ambiguous attribute 'n'; could be '1' (via 'I124MODE:n') or '4' (via 'I48MODE:n')
../../gcc/config/tilegx/tilegx.md:4109:1: ambiguous attribute 'n'; could be '1' (via 'I124MODE:n') or '' (via 'I48MODE:n')
../../gcc/config/tilegx/tilegx.md:4109:1: ambiguous attribute 'n'; could be '2' (via 'I124MODE:n') or '4' (via 'I48MODE:n')
../../gcc/config/tilegx/tilegx.md:4109:1: ambiguous attribute 'n'; could be '2' (via 'I124MODE:n') or '' (via 'I48MODE:n')
../../gcc/config/tilegx/tilegx.md:4109:1: ambiguous attribute 'n'; could be '4' (via 'I124MODE:n') or '' (via 'I48MODE:n')
The insn name already uses <I124MODE:n> explicitly, just the preparation
stmts don't, and as it creates a I124MODE lowpart subreg of a word mode
register, <I124MODE:n> seems obviously correct.
2020-05-02 Jakub Jelinek <jakub@redhat.com>
* config/tilegx/tilegx.md
(insn_stnt<I124MODE:n>_add<I48MODE:bitsuffix>): Use <I124MODE:n>
rather than just <n>.
|
|
From-SVN: r279813
|
|
After previous patches, it's now possible for call_used_regs to be
the "real" set of call-clobbered registers, without any special
handling for fixed registers. This patch therefore removes the
separate call_really_used_regs and updates the targets that define
CALL_REALLY_USED_REGISTERS so that they handle call_used_regs in
the same way that they used to handle call_really_used_regs.
With this change, it's no longer necessary for targets that define
CALL_REALLY_USED_REGISTERS to define CALL_USED_REGISTER as well.
2019-09-10 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* doc/tm.texi.in: Document that exactly one of CALL_USED_REGISTERS
and CALL_REALLY_USED_REGISTERS must be defined, and that
CALL_REALLY_USED_REGISTERS is preferred.
* doc/tm.texi: Regenerate.
* hard-reg-set.h (target_hard_regs::x_call_really_used_regs): Delete.
(call_really_used_regs): Likewise.
* reginfo.c: Raise an #error if both CALL_USED_REGISTERS and
CALL_REALLY_USED_REGISTERS are defined.
(initial_call_used_regs): Use CALL_REALLY_USED_REGISTERS as the
initial value if defined.
(initial_call_really_used_regs): Delete.
(saved_call_really_used_regs): Likewise.
(CALL_REALLY_USED_REGNO_P): Likewise.
(init_reg_sets): Remove handling of call_really_used_regs.
(save_register_info, restore_register_info, globalize_reg): Likewise.
(init_reg_sets_1): Likewise. Use call_used_regs instead of
CALL_REALLY_USED_REGNO_P. Don't set call_used_regs for registers
outside operand_reg_set.
(fix_register): Don't change call_used_regs if
CALL_REALLY_USED_REGISTERS is defined.
* config/csky/csky.h (CALL_USED_REGISTERS): Delete.
* config/csky/csky.c (get_csky_live_regs): Use call_used_regs
instead of call_really_used_regs.
(csky_conditional_register_usage): Remove the old handling of
call_used_regs and change the handling of call_really_used_regs
to use call_used_regs instead.
* config/ia64/ia64.h (CALL_USED_REGISTERS): Delete.
* config/ia64/ia64.c (fix_range): Don't set call_used_regs when
making a register fixed.
* config/m32r/m32r.h (CALL_USED_REGISTERS): Delete.
* config/m32r/m32r.c (MUST_SAVE_REGISTER): Use call_used_regs
instead of call_really_used_regs.
(m32r_conditional_register_usage): Don't set call_used_regs when
making a register fixed.
* config/mips/mips.h (CALL_USED_REGISTERS): Delete.
* config/mips/mips.c (mips_global_pointer): Use call_used_regs
instead of call_really_used_regs.
(mips_interrupt_extra_call_saved_reg_p): Likewise.
(mips_cfun_call_saved_reg_p): Likewise.
(mips_swap_registers): Remove the old handling of call_used_regs
and change the handling of call_really_used_regs to use call_used_regs
instead.
(mips_conditional_register_usage): Likewise.
* config/mn10300/mn10300.h (CALL_USED_REGISTERS): Delete.
* config/mn10300/mn10300.c (fp_regs_to_save): Use call_used_regs
instead of call_really_used_regs.
(mn10300_get_live_callee_saved_regs): Likewise.
(mn10300_expand_prologue, mn10300_expand_epilogue): Likewise.
(mn10300_conditional_register_usage): Don't set call_used_regs when
making a register fixed.
* config/rs6000/rs6000.h (CALL_USED_REGISTERS): Delete.
* config/rs6000/rs6000.c (rs6000_conditional_register_usage):
Remove the old handling of call_used_regs and change the handling
of call_really_used_regs to use call_used_regs instead.
* config/s390/s390.h (CALL_USED_REGISTERS): Delete.
* config/s390/s390.c (s390_regs_ever_clobbered): Use call_used_regs
instead of call_really_used_regs.
(s390_register_info_gprtofpr, s390_register_info): Likewise.
(s390_hard_regno_rename_ok, s390_hard_regno_scratch_ok): Likewise.
(s390_emit_prologue, s300_set_up_by_prologue): Likewise.
(s390_can_use_return_insn, s390_optimize_prologue): Likewise.
(s390_conditional_register_usage): Remove the old handling of
call_used_regs and change the handling of call_really_used_regs
to use call_used_regs instead.
* config/sh/sh.h (CALL_USED_REGISTERS): Delete.
* config/sh/sh.c (output_stack_adjust, calc_live_regs): Likewise.
(sh_fix_range, reg_unused_after): Likewise.
(sh_conditional_register_usage): Remove the old handling of
call_used_regs and change the handling of call_really_used_regs
to use call_used_regs instead.
* config/sparc/sparc.h (CALL_USED_REGISTERS): Delete.
* config/sparc/sparc.c (sparc_conditional_register_usage): Don't set
call_used_regs when making a register fixed.
* config/tilegx/tilegx.h (CALL_USED_REGISTERS): Delete.
* config/tilegx/tilegx.c (tilegx_conditional_register_usage): Don't set
call_used_regs when making a register fixed.
* config/tilepro/tilepro.h (CALL_USED_REGISTERS): Delete.
* config/tilepro/tilepro.c (tilepro_conditional_register_usage): Don't
set call_used_regs when making a register fixed.
* config/visium/visium.h (CALL_USED_REGISTERS): Delete.
* config/visium/visium.c (visium_conditional_register_usage): Remove
the old handling of call_used_regs and change the handling of
call_really_used_regs to use call_used_regs instead.
From-SVN: r275605
|
|
This patch removes redundant fixed_regs tests in things like:
!fixed_regs[i] && !call_used_or_fixed_reg_p (i)
2019-09-10 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* config/alpha/alpha.c (alpha_compute_frame_layout): Remove redundant
fixed_regs test.
* config/bpf/bpf.c (bpf_compute_frame_layout, bpf_expand_prologue)
(bpf_expand_epilogue): Likewise.
* config/c6x/c6x.c (c6x_save_reg): Likewise.
* config/ft32/ft32.c (ft32_expand_prologue): Likewise.
(ft32_expand_epilogue): Likewise.
* config/i386/i386.c (ix86_save_reg): Likewise.
* config/moxie/moxie.c (moxie_expand_prologue): Likewise.
(moxie_expand_epilogue): Likewise.
* config/tilegx/tilegx.c (need_to_save_reg): Likewise.
* config/tilepro/tilepro.c (need_to_save_reg): Likewise.
* config/xtensa/xtensa.c (xtensa_call_save_reg): Likewise.
From-SVN: r275603
|
|
Similarly to the call_used_or_fixed_regs patch, this one replaces
tests of call_used_regs[i] with call_used_or_fixed_reg_p (i).
The only remaining direct uses of call_used_regs are in reginfo.c
and in the conditional register usage hooks.
Again, this is purely mechanical. A later patch will clear up the
oddities in config/ code.
2019-09-10 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* hard-reg-set.h (call_used_or_fixed_reg_p): New macro.
* cfgloopanal.c (init_set_costs): Use call_used_or_fixed_reg_p
instead of testing call_used_regs directly.
* config/aarch64/aarch64.c (aarch64_layout_frame): Likewise.
(aarch64_components_for_bb): Likewise.
* config/alpha/alpha.c (alpha_compute_frame_layout): Likewise.
* config/arc/arc.c (arc_must_save_register): Likewise.
(arc_epilogue_uses): Likewise.
* config/arm/arm.c (arm_option_override, use_return_insn): Likewise.
(legitimize_pic_address, callee_saved_reg_p): Likewise.
(arm_compute_save_reg0_reg12_mask): Likewise.
(arm_compute_save_core_reg_mask): Likewise.
(arm_get_vfp_saved_size, arm_compute_frame_layout): Likewise.
(arm_save_coproc_regs, thumb1_extra_regs_pushed): Likewise.
(cmse_nonsecure_entry_clear_before_return): Likewise.
(thumb1_expand_epilogue, arm_expand_epilogue_apcs_frame): Likewise.
(arm_expand_epilogue): Likewise.
* config/avr/avr.c (avr_regs_to_save, sequent_regs_live): Likewise.
(avr_function_arg_advance, avr_find_unused_d_reg): Likewise.
(_reg_unused_after): Likewise.
* config/bfin/bfin.c (must_save_p, expand_prologue_reg_save): Likewise.
(expand_epilogue_reg_restore, n_regs_saved_by_prologue): Likewise.
(add_to_reg, hwloop_optimize): Likewise.
* config/bpf/bpf.c (bpf_compute_frame_layout, bpf_expand_prologue)
(bpf_expand_epilogue): Likewise.
* config/c6x/c6x.c (c6x_save_reg, c6x_regno_reg_class): Likewise.
* config/cr16/cr16.c (cr16_compute_save_regs): Likewise.
* config/cris/cris.c (cris_reg_saved_in_regsave_area): Likewise.
* config/epiphany/epiphany.c (epiphany_init_reg_tables): Likewise.
(epiphany_compute_function_type, MUST_SAVE_REGISTER): Likewise.
(epiphany_output_mi_thunk, epiphany_start_function): Likewise.
* config/fr30/fr30.c (fr30_num_arg_regs): Likewise.
* config/frv/frv.c (frv_stack_info): Likewise.
* config/ft32/ft32.c (ft32_compute_frame): Likewise.
(ft32_expand_prologue, ft32_expand_epilogue): Likewise.
* config/gcn/gcn.c (gcn_compute_frame_offsets): Likewise.
(move_callee_saved_registers): Likewise.
* config/h8300/h8300.c (byte_reg): Likewise.
* config/i386/i386-options.c (ix86_set_current_function): Likewise.
* config/i386/i386.c (ix86_save_reg, ix86_expand_prologue): Likewise.
(ix86_expand_epilogue, x86_order_regs_for_local_alloc): Likewise.
* config/i386/predicates.md (sibcall_memory_operand): Likewise.
* config/ia64/ia64.c (emit_safe_across_calls, find_gr_spill): Likewise.
(next_scratch_gr_reg, ia64_compute_frame_size): Likewise.
* config/iq2000/iq2000.h (MUST_SAVE_REGISTER): Likewise.
* config/lm32/lm32.c (lm32_compute_frame_size): Likewise.
* config/m32c/m32c.c (need_to_save): Likewise.
* config/m68k/m68k.c (m68k_save_reg): Likewise.
* config/mcore/mcore.c (calc_live_regs): Likewise.
* config/microblaze/microblaze.c (microblaze_must_save_register):
Likewise.
* config/mmix/mmix.c (mmix_local_regno): Likewise.
(mmix_initial_elimination_offset, mmix_reorg): Likewise.
(mmix_use_simple_return, mmix_expand_prologue): Likewise.
(mmix_expand_epilogue): Likewise.
* config/moxie/moxie.c (moxie_compute_frame): Likewise.
(moxie_expand_prologue, moxie_expand_epilogue): Likewise.
* config/msp430/msp430.c (msp430_preserve_reg_p): Likewise.
* config/nds32/nds32.h (nds32_16bit_address_type): Likewise.
(NDS32_REQUIRED_CALLEE_SAVED_P): Likewise.
* config/nios2/nios2.c (prologue_saved_reg_p): Likewise.
* config/or1k/or1k.c (callee_saved_regno_p): Likewise.
* config/pa/pa.c (pa_expand_prologue, pa_expand_epilogue): Likewise.
* config/pdp11/pdp11.c (pdp11_saved_regno): Likewise.
* config/pru/pru.c (prologue_saved_reg_p): Likewise.
* config/riscv/riscv.c (riscv_save_reg_p): Likewise.
(riscv_epilogue_uses, riscv_hard_regno_mode_ok): Likewise.
* config/rl78/rl78.c (need_to_save): Likewise.
* config/rs6000/rs6000-logue.c (save_reg_p): Likewise.
(rs6000_stack_info, generate_set_vrsave): Likewise.
(rs6000_emit_prologue, rs6000_emit_epilogue): Likewise.
* config/rs6000/rs6000.c (rs6000_debug_reg_print): Likewise.
* config/rx/rx.c (rx_get_stack_layout): Likewise.
* config/s390/s390.c (s390_call_saved_register_used): Likewise.
* config/sh/sh.c (calc_live_regs, sh_output_mi_thunk): Likewise.
* config/sparc/sparc.c (save_global_or_fp_reg_p): Likewise.
(save_local_or_in_reg_p): Likewise.
* config/stormy16/stormy16.c (REG_NEEDS_SAVE): Likewise.
(xstormy16_epilogue_uses): Likewise.
* config/tilegx/tilegx.c (need_to_save_reg): Likewise.
* config/tilepro/tilepro.c (need_to_save_reg): Likewise.
* config/v850/v850.c (compute_register_save_size): Likewise.
* config/vax/vax.c (vax_expand_prologue): Likewise.
* config/visium/visium.c (visium_save_reg_p): Likewise.
* config/xtensa/xtensa.c (xtensa_call_save_reg): Likewise.
* cselib.c (cselib_process_insn): Likewise.
* df-scan.c (df_get_entry_block_def_set): Likewise.
* function.c (aggregate_value_p): Likewise.
* haifa-sched.c (alloc_global_sched_pressure_data): Likewise.
* ira-lives.c (process_bb_node_lives): Likewise.
* ira.c (do_reload): Likewise.
* lra-lives.c (process_bb_lives): Likewise.
* lra-remat.c (lra_remat): Likewise.
* lra.c (lra): Likewise.
* postreload.c (reload_combine_recognize_pattern): Likewise.
(reload_cse_move2add): Likewise.
* recog.c (peep2_find_free_register): Likewise.
* regrename.c (check_new_reg_p): Likewise.
* reload.c (find_equiv_reg): Likewise.
* reload1.c (reload, find_reg): Likewise.
* sel-sched.c (init_hard_regs_data): Likewise.
From-SVN: r275602
|
|
There seems to be a bit of confusion around this one. Almost all
callers pass the same arguments as TARGET_FUNCTION_ARG, meaning
that the mode is the promoted mode rather than the type mode.
But the calls.c handling for normal typed arguments instead passes
the unpromoted TYPE_MODE (despite passing the promoted mode to
TARGET_FUNCTION_ARG). I've kept this behaviour with a ??? comment.
(The calls.c handling of libgcc functions does pass the promoted
mode though, as does the function.c handling of incoming arguments.)
Also, a couple of the arm callers don't seem to be using the hook
correctly. Again I kept the current choices and added a ??? comment.
2019-08-20 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* target.def (function_arg_advance): Take a function_arg_info instead
of a mode, type and named flag.
* doc/tm.texi: Regenerate.
* targhooks.h (default_function_arg_advance): Take a function_arg_info
instead of a mode, type and named flag.
* targhooks.c (default_function_arg_advance): Likewise.
* calls.c (initialize_argument_information): Update call to
targetm.calls.function_arg_advance.
(emit_library_call_value_1): Likewise.
* dse.c (get_call_args): Likewise.
* expr.c (block_move_libcall_safe_for_call_parm): Likewise.
* function.c (assign_parms, gimplify_parameters): Likewise.
* var-tracking.c (prepare_call_arguments): Likewise.
* config/aarch64/aarch64.c (aarch64_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(aarch64_setup_incoming_varargs): Update call accordingly.
* config/alpha/alpha.c (alpha_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(alpha_setup_incoming_varargs): Update call accordingly.
* config/arc/arc.c (arc_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(arc_setup_incoming_varargs): Update call accordingly.
* config/arm/arm.c (arm_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(cmse_func_args_or_return_in_stack): Update call accordingly.
(arm_function_ok_for_sibcall): Likewise.
(cmse_nonsecure_call_clear_caller_saved): Likewise.
* config/avr/avr.c (avr_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/bfin/bfin.c (bfin_function_arg_advance): Likewise.
* config/c6x/c6x.c (c6x_function_arg_advance): Likewise.
(c6x_call_saved_register_used): Update call accordingly.
* config/cr16/cr16.c (cr16_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/cris/cris.c (cris_function_arg_advance): Likewise.
* config/csky/csky.c (csky_function_arg_advance): Likewise.
(csky_setup_incoming_varargs): Update call accordingly.
* config/epiphany/epiphany.c (epiphany_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/fr30/fr30.c (fr30_function_arg_advance): Likewise.
* config/frv/frv.c (frv_function_arg_advance): Likewise.
* config/ft32/ft32.c (ft32_function_arg_advance): Likewise.
* config/gcn/gcn.c (gcn_function_arg_advance): Likewise.
* config/h8300/h8300.c (h8300_function_arg_advance): Likewise.
* config/i386/i386.c (ix86_function_arg_advance): Likewise.
(ix86_setup_incoming_varargs): Update call accordingly.
* config/ia64/ia64.c (ia64_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(ia64_setup_incoming_varargs): Update call accordingly.
* config/iq2000/iq2000.c (iq2000_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(iq2000_expand_prologue): Update call accordingly.
* config/lm32/lm32.c (lm32_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/m32c/m32c.c (m32c_function_arg_advance): Likewise.
* config/m32r/m32r.c (m32r_function_arg_advance): Likewise.
* config/m68k/m68k.c (m68k_function_arg_advance): Likewise.
* config/mcore/mcore.c (mcore_function_arg_advance): Likewise.
* config/microblaze/microblaze.c (microblaze_function_arg_advance):
Likewise.
(microblaze_expand_prologue): Update call accordingly.
* config/mips/mips.c (mips_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(mips_setup_incoming_varargs): Update call accordingly.
(mips_output_args_xfer): Likewise.
* config/mmix/mmix.c (mmix_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/mn10300/mn10300.c (mn10300_function_arg_advance): Likewise.
* config/moxie/moxie.c (moxie_function_arg_advance): Likewise.
* config/msp430/msp430.c (msp430_function_arg_advance): Likewise.
* config/nds32/nds32.c (nds32_function_arg_advance): Likewise.
* config/nios2/nios2.c (nios2_function_arg_advance): Likewise.
(nios2_setup_incoming_varargs): Update call accordingly.
* config/nvptx/nvptx.c (nvptx_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/or1k/or1k.c (or1k_function_arg_advance): Likewise.
* config/pa/pa.c (pa_function_arg_advance): Likewise.
* config/pdp11/pdp11.c (pdp11_function_arg_advance): Likewise.
* config/pru/pru.c (pru_function_arg_advance): Likewise.
* config/riscv/riscv.c (riscv_function_arg_advance): Likewise.
(riscv_setup_incoming_varargs): Update call accordingly.
* config/rl78/rl78.c (rl78_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/rs6000/rs6000-internal.h (rs6000_function_arg_advance):
Likewise.
* config/rs6000/rs6000-call.c (rs6000_function_arg_advance): Likewise.
(rs6000_parm_needs_stack): Update call accordingly.
* config/rx/rx.c (rx_function_arg_advance): Take a function_arg_info
instead of a mode, type and named flag.
* config/s390/s390.c (s390_function_arg_advance): Likewise.
(s390_call_saved_register_used): Update call accordingly.
* config/sh/sh.c (sh_function_arg_advance): Take a function_arg_info
instead of a mode, type and named flag.
(sh_output_mi_thunk): Update call accordingly.
* config/sparc/sparc.c (sparc_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/spu/spu.c (spu_function_arg_advance): Likewise.
(spu_setup_incoming_varargs): Update call accordingly.
* config/stormy16/stormy16.c (xstormy16_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/tilegx/tilegx.c (tilegx_function_arg_advance): Likewise.
(tilegx_setup_incoming_varargs): Update call accordingly.
* config/tilepro/tilepro.c (tilepro_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
(tilegx_setup_incoming_varargs): Update call accordingly.
* config/v850/v850.c (v850_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
* config/vax/vax.c (vax_function_arg_advance): Likewise.
* config/visium/visium.c (visium_function_arg_advance): Likewise.
(visium_setup_incoming_varargs): Update call accordingly.
* config/xtensa/xtensa.c (xtensa_function_arg_advance): Take a
function_arg_info instead of a mode, type and named flag.
From-SVN: r274701
|
|
This patch makes both TARGET_FUNCTION_ARG and
TARGET_FUNCTION_INCOMING_ARG take a function_arg_info.
They have to be done together since many targets use the
same function for both.
The hooks are passed the promoted mode instead of the original type mode.
2019-08-20 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* target.def (function_arg, function_incoming_arg): Take a
function_arg_info instead of a mode, tree and named flag.
* doc/tm.texi: Regenerate.
* targhooks.h (default_function_arg): Take a function_arg_info
instead of a mode, tree and named flag.
(default_function_incoming_arg): Likewise.
* targhooks.c (default_function_arg): Likewise.
(default_function_incoming_arg): Likewise.
* calls.h (function_arg_info::end_marker_p): New function.
(function_arg_info::end_marker): Likewise.
* calls.c (prepare_call_address, initialize_argument_information)
(expand_call, emit_library_call_value_1): Update calls to
targetm.calls.function_arg and targetm.calls.function_incoming_arg.
* dse.c: Include calls.h.
(get_call_args): Update call to targetm.calls.function_arg.
* expr.c (block_move_libcall_safe_for_call_parm): Likewise.
* var-tracking.c (prepare_call_arguments): Likewise.
* function.c (assign_parm_find_entry_rtl): Update call to
targetm.calls.function_incoming_arg.
* config/aarch64/aarch64.c (aarch64_function_arg): Take a
function_arg_info instead of a mode, tree and named flag.
* config/alpha/alpha.c (alpha_function_arg): Likewise.
* config/arc/arc.c (arc_function_arg): Likewise.
* config/arm/arm.c (arm_function_arg): Likewise.
(cmse_func_args_or_return_in_stack): Update call accordingly.
(arm_function_ok_for_sibcall): Likewise.
(cmse_nonsecure_call_clear_caller_saved): Likewise.
* config/avr/avr.c (avr_function_arg): Take a function_arg_info
instead of a mode, tree and named flag.
* config/bfin/bfin.c (bfin_function_arg): Likewise.
* config/c6x/c6x.c (c6x_function_arg): Likewise.
(c6x_call_saved_register_used): Update call accordingly.
* config/cr16/cr16.c (cr16_function_arg): Take a function_arg_info
instead of a mode, tree and named flag.
* config/cris/cris.c (cris_function_arg, cris_function_incoming_arg)
(cris_function_arg_1): Likewise.
* config/csky/csky.c (csky_function_arg): Likewise.
* config/epiphany/epiphany.c (epiphany_function_arg): Likewise.
* config/fr30/fr30.c (fr30_function_arg): Likewise.
* config/frv/frv.c (frv_function_arg, frv_function_incoming_arg)
(frv_function_arg_1): Likewise.
* config/ft32/ft32.c (ft32_function_arg): Likewise.
* config/gcn/gcn.c (gcn_function_arg): Likewise.
* config/h8300/h8300.c (h8300_function_arg): Likewise.
* config/i386/i386.c (ix86_function_arg): Likewise.
* config/ia64/ia64.c (ia64_function_arg, ia64_function_incoming_arg)
(ia64_function_arg_1): Likewise.
* config/iq2000/iq2000.c (iq2000_function_arg): Likewise.
(iq2000_expand_prologue, iq2000_pass_by_reference): Update call
accordingly.
* config/lm32/lm32.c (lm32_function_arg): Take a function_arg_info
instead of a mode, tree and named flag.
* config/m32c/m32c.c (m32c_function_arg): Likewise.
* config/m32r/m32r.c (m32r_function_arg): Likewise.
* config/m68k/m68k.c (m68k_function_arg): Likewise.
* config/mcore/mcore.c (mcore_function_arg): Likewise.
* config/microblaze/microblaze.c (microblaze_function_arg): Likewise.
(microblaze_expand_prologue): Update call accordingly.
* config/mips/mips.c (mips_function_arg): Take a function_arg_info
instead of a mode, tree and named flag.
* config/mmix/mmix.c (mmix_function_incoming_arg, mmix_function_arg)
(mmix_function_arg_1): Likewise.
* config/mn10300/mn10300.c (mn10300_function_arg): Likewise.
* config/moxie/moxie.c (moxie_function_arg): Likewise.
* config/msp430/msp430.c (msp430_function_arg): Likewise.
* config/nds32/nds32.c (nds32_function_arg): Likewise.
* config/nios2/nios2.c (nios2_function_arg): Likewise.
* config/nvptx/nvptx.c (nvptx_function_arg): Likewise.
(nvptx_function_incoming_arg): Likewise.
* config/or1k/or1k.c (or1k_function_arg): Likewise.
* config/pa/pa.c (pa_function_arg): Likewise.
* config/pdp11/pdp11.c (pdp11_function_arg): Likewise.
* config/pru/pru.c (pru_function_arg): Likewise.
* config/riscv/riscv.c (riscv_function_arg): Likewise.
* config/rl78/rl78.c (rl78_function_arg): Likewise.
* config/rs6000/rs6000-internal.h (rs6000_function_arg): Likewise.
* config/rs6000/rs6000-call.c (rs6000_function_arg): Likewise.
(rs6000_parm_needs_stack): Update call accordingly.
* config/rx/rx.c (rx_function_arg): Take a function_arg_info
instead of a mode, tree and named flag.
* config/s390/s390.c (s390_function_arg): Likewise.
(s390_call_saved_register_used): Update call accordingly.
* config/sh/sh.c (sh_function_arg): Take a function_arg_info
instead of a mode, tree and named flag.
(sh_output_mi_thunk): Update call accordingly.
* config/sparc/sparc.c (sparc_function_arg_1, sparc_function_arg)
(sparc_function_incoming_arg): Take a function_arg_info instead of
a mode, tree and named flag.
* config/spu/spu.c (spu_function_arg): Likewise.
* config/stormy16/stormy16.c (xstormy16_function_arg): Likewise.
* config/tilegx/tilegx.c (tilegx_function_arg): Likewise.
* config/tilepro/tilepro.c (tilepro_function_arg): Likewise.
* config/v850/v850.c (v850_function_arg): Likewise.
* config/vax/vax.c (vax_function_arg): Likewise.
* config/visium/visium.c (visium_function_arg): Likewise.
* config/xtensa/xtensa.c (xtensa_function_arg_1, xtensa_function_arg)
(xtensa_function_incoming_arg): Likewise.
From-SVN: r274700
|
|
The hook is passed the promoted mode instead of the original type mode.
2019-08-20 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* target.def (setup_incoming_varargs): Take a function_arg_info
instead of a mode and tree.
* doc/tm.texi: Regenerate.
* targhooks.h (default_setup_incoming_varargs): Take a
function_arg_info instead of a mode and tree.
* targhooks.c (default_setup_incoming_varargs): Likewise.
* config/aarch64/aarch64.c (aarch64_setup_incoming_varargs): Likewise.
* config/alpha/alpha.c (alpha_setup_incoming_varargs): Likewise.
* config/arc/arc.c (arc_setup_incoming_varargs): Likewise.
* config/arm/arm.c (arm_setup_incoming_varargs): Likewise.
* config/bfin/bfin.c (setup_incoming_varargs): Likewise.
* config/cris/cris.c (cris_setup_incoming_varargs): Likewise.
* config/csky/csky.c (csky_setup_incoming_varargs): Likewise.
* config/epiphany/epiphany.c (epiphany_setup_incoming_varargs):
Likewise.
* config/fr30/fr30.c (fr30_setup_incoming_varargs): Likewise.
* config/frv/frv.c (frv_setup_incoming_varargs): Likewise.
* config/ft32/ft32.c (ft32_setup_incoming_varargs): Likewise.
* config/i386/i386.c (ix86_setup_incoming_varargs): Likewise.
* config/ia64/ia64.c (ia64_setup_incoming_varargs): Likewise.
* config/iq2000/iq2000.c (iq2000_setup_incoming_varargs): Likewise.
* config/lm32/lm32.c (lm32_setup_incoming_varargs): Likewise.
* config/m32r/m32r.c (m32r_setup_incoming_varargs): Likewise.
* config/mcore/mcore.c (mcore_setup_incoming_varargs): Likewise.
* config/mips/mips.c (mips_setup_incoming_varargs): Likewise.
* config/mmix/mmix.c (mmix_setup_incoming_varargs): Likewise.
* config/moxie/moxie.c (moxie_setup_incoming_varargs): Likewise.
* config/nds32/nds32.c (nds32_setup_incoming_varargs): Likewise.
* config/nios2/nios2.c (nios2_setup_incoming_varargs): Likewise.
* config/riscv/riscv.c (riscv_setup_incoming_varargs): Likewise.
* config/rs6000/rs6000-internal.h (setup_incoming_varargs): Likewise.
* config/rs6000/rs6000-call.c (setup_incoming_varargs): Likewise.
* config/sh/sh.c (sh_setup_incoming_varargs): Likewise.
* config/spu/spu.c (spu_setup_incoming_varargs): Likewise.
* config/tilegx/tilegx.c (tilegx_setup_incoming_varargs): Likewise.
* config/tilepro/tilepro.c (tilepro_setup_incoming_varargs): Likewise.
* config/visium/visium.c (visium_setup_incoming_varargs): Likewise.
* function.c (assign_parms_setup_varargs): Update call to
targetm.calls.setup_incoming_varargs.
From-SVN: r274699
|
|
The hook is passed the unpromoted type mode instead of the promoted mode.
2019-08-20 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* target.def (pass_by_reference): Take a function_arg_info instead
of a mode, type and named flag.
* doc/tm.texi: Regenerate.
* targhooks.h (hook_pass_by_reference_must_pass_in_stack): Update
accordingly.
(hook_bool_CUMULATIVE_ARGS_arg_info_false): Declare.
* targhooks.c (hook_pass_by_reference_must_pass_in_stack): Take a
function_arg_info instead of a mode, type and named flag.
(hook_bool_CUMULATIVE_ARGS_arg_info_false): New function.
* calls.h (pass_by_reference): Take a function_arg_info instead of a
mode, type and named flag.
* calls.c (pass_by_reference): Likewise.
(pass_va_arg_by_reference): Update call accordingly.
(initialize_argument_information): Likewise.
(emit_library_call_value_1): Likewise.
* function.c (assign_parm_find_data_types): Likewise.
* var-tracking.c (prepare_call_arguments): Likewise.
* stor-layout.c: Include calls.h.
(compute_record_mode): Update call to targetm.calls.pass_by_reference.
* config/aarch64/aarch64.c (aarch64_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
* config/alpha/alpha.c (alpha_pass_by_reference): Likewise.
* config/arc/arc.c (arc_pass_by_reference): Likewise.
* config/arm/arm.c (arm_pass_by_reference): Likewise.
* config/bfin/bfin.c (bfin_pass_by_reference): Likewise.
* config/c6x/c6x.c (c6x_pass_by_reference): Likewise.
(c6x_call_saved_register_used): Update call to pass_by_reference.
* config/cris/cris.c (cris_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
* config/epiphany/epiphany.c (epiphany_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
(epiphany_arg_partial_bytes): Update call accordingly.
* config/ft32/ft32.c (ft32_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
(ft32_arg_partial_bytes): Update call accordingly.
* config/i386/i386.c (ix86_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
* config/iq2000/iq2000.c (iq2000_pass_by_reference): Likewise.
* config/m32c/m32c.c (m32c_pass_by_reference): Likewise.
* config/m32r/m32r.c (m32r_pass_by_reference): Likewise.
(m32r_return_in_memory): Update call accordingly.
* config/mips/mips.c (mips_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
* config/mmix/mmix.c (mmix_pass_by_reference): Likewise.
* config/mn10300/mn10300.c (mn10300_pass_by_reference): Likewise.
* config/moxie/moxie.c (moxie_pass_by_reference): Likewise.
(moxie_arg_partial_bytes): Update call accordingly.
* config/msp430/msp430.c (msp430_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
* config/nvptx/nvptx.c (nvptx_pass_by_reference): Likewise.
* config/or1k/or1k.c (or1k_pass_by_reference): Likewise.
* config/pa/pa.c (pa_pass_by_reference): Likewise.
* config/riscv/riscv.c (riscv_pass_by_reference): Likewise.
(riscv_return_in_memory): Update call accordingly.
* config/rs6000/rs6000-internal.h (rs6000_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
* config/rs6000/rs6000-call.c (rs6000_pass_by_reference): Likewise.
(rs6000_parm_needs_stack): Update call to pass_by_reference.
* config/s390/s390.c (s390_pass_by_reference): Take a
function_arg_info instead of a mode, type and named flag.
(s390_call_saved_register_used): Update call accordingly.
* config/sh/sh.c (sh_pass_by_reference): Take a function_arg_info
instead of a mode, type and named flag.
* config/sparc/sparc.c (sparc_pass_by_reference): Likewise.
* config/spu/spu.c (spu_pass_by_reference): Likewise.
* config/tilegx/tilegx.c (tilegx_pass_by_reference): Likewise.
* config/tilepro/tilepro.c (tilepro_pass_by_reference): Likewise.
* config/v850/v850.c (v850_pass_by_reference): Likewise.
* config/visium/visium.c (visium_pass_by_reference): Likewise.
gcc/ada/
* gcc-interface/misc.c (default_pass_by_ref): Update call to
pass_by_reference.
From-SVN: r274698
|
|
This patch splits out a common idiom from the va_arg gimplification
routines, so that there's only one place to update later.
2019-08-20 Richard Sandiford <richard.sandiford@arm.com>
gcc/
* calls.h (pass_va_arg_by_reference): Declare.
* calls.c (pass_va_arg_by_reference): New function.
* config/aarch64/aarch64.c (aarch64_gimplify_va_arg_expr): Use it.
* config/alpha/alpha.c (alpha_gimplify_va_arg): Likewise.
* config/gcn/gcn.c (gcn_gimplify_va_arg_expr): Likewise.
* config/i386/i386.c (ix86_gimplify_va_arg): Likewise.
* config/ia64/ia64.c (ia64_gimplify_va_arg): Likewise.
* config/mips/mips.c (mips_std_gimplify_va_arg_expr): Likewise.
(mips_gimplify_va_arg_expr): Likewise.
* config/msp430/msp430.c (msp430_gimplify_va_arg_expr): Likewise.
* config/pa/pa.c (hppa_gimplify_va_arg_expr): Likewise.
* config/rs6000/rs6000-call.c (rs6000_gimplify_va_arg): Likewise.
* config/s390/s390.c (s390_gimplify_va_arg): Likewise.
* config/sparc/sparc.c (sparc_gimplify_va_arg): Likewise.
* config/spu/spu.c (spu_gimplify_va_arg_expr): Likewise.
* config/tilegx/tilegx.c (tilegx_gimplify_va_arg_expr): Likewise.
* config/tilepro/tilepro.c (tilepro_gimplify_va_arg_expr): Likewise.
* config/visium/visium.c (visium_gimplify_va_arg): Likewise.
* config/xtensa/xtensa.c (xtensa_gimplify_va_arg_expr): Likewise.
* targhooks.c (std_gimplify_va_arg_expr): Likewise.
From-SVN: r274695
|
|
We were shoe-horning all built-in enumerations (including frontend
and target-specific ones) into a field of type built_in_function. This
was accessed as either an lvalue or an rvalue using DECL_FUNCTION_CODE.
The obvious danger with this (as was noted by several ??? comments)
is that the ranges have nothing to do with each other, and targets can
easily have more built-in functions than generic code. But my patch to
make the field bigger was the straw that finally made the problem visible.
This patch therefore:
- replaces the field with a plain unsigned int
- turns DECL_FUNCTION_CODE into an rvalue-only accessor that checks
that the function really is BUILT_IN_NORMAL
- adds corresponding DECL_MD_FUNCTION_CODE and DECL_FE_FUNCTION_CODE
accessors for BUILT_IN_MD and BUILT_IN_FRONTEND respectively
- adds DECL_UNCHECKED_FUNCTION_CODE for places that need to access the
underlying field (should be low-level code only)
- adds new helpers for setting the built-in class and function code
- makes DECL_BUILT_IN_CLASS an rvalue-only accessor too, since all
assignments should go through the new helpers
2019-08-13 Richard Sandiford <richard.sandiford@arm.com>
gcc/
PR middle-end/91421
* tree-core.h (function_decl::function_code): Change type to
unsigned int.
* tree.h (DECL_FUNCTION_CODE): Rename old definition to...
(DECL_UNCHECKED_FUNCTION_CODE): ...this.
(DECL_BUILT_IN_CLASS): Make an rvalue macro only.
(DECL_FUNCTION_CODE): New function. Assert that the built-in class
is BUILT_IN_NORMAL.
(DECL_MD_FUNCTION_CODE, DECL_FE_FUNCTION_CODE): New functions.
(set_decl_built_in_function, copy_decl_built_in_function): Likewise.
(fndecl_built_in_p): Change the type of the "name" argument to
unsigned int.
* builtins.c (expand_builtin): Move DECL_FUNCTION_CODE use
after check for DECL_BUILT_IN_CLASS.
* cgraphclones.c (build_function_decl_skip_args): Use
set_decl_built_in_function.
* ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
* ipa-split.c (split_function): Likewise.
* langhooks.c (add_builtin_function_common): Likewise.
* omp-simd-clone.c (simd_clone_create): Likewise.
* tree-streamer-in.c (unpack_ts_function_decl_value_fields): Likewise.
* config/darwin.c (darwin_init_cfstring_builtins): Likewise.
(darwin_fold_builtin): Use DECL_MD_FUNCTION_CODE instead of
DECL_FUNCTION_CODE.
* fold-const.c (operand_equal_p): Compare DECL_UNCHECKED_FUNCTION_CODE
instead of DECL_FUNCTION_CODE.
* lto-streamer-out.c (hash_tree): Use DECL_UNCHECKED_FUNCTION_CODE
instead of DECL_FUNCTION_CODE.
* tree-streamer-out.c (pack_ts_function_decl_value_fields): Likewise.
* print-tree.c (print_node): Use DECL_MD_FUNCTION_CODE when
printing DECL_BUILT_IN_MD. Handle DECL_BUILT_IN_FRONTEND.
* config/aarch64/aarch64-builtins.c (aarch64_expand_builtin)
(aarch64_fold_builtin, aarch64_gimple_fold_builtin): Use
DECL_MD_FUNCTION_CODE instead of DECL_FUNCTION_CODE.
* config/aarch64/aarch64.c (aarch64_builtin_reciprocal): Likewise.
* config/alpha/alpha.c (alpha_expand_builtin, alpha_fold_builtin):
(alpha_gimple_fold_builtin): Likewise.
* config/arc/arc.c (arc_expand_builtin): Likewise.
* config/arm/arm-builtins.c (arm_expand_builtin): Likewise.
* config/avr/avr-c.c (avr_resolve_overloaded_builtin): Likewise.
* config/avr/avr.c (avr_expand_builtin, avr_fold_builtin): Likewise.
* config/bfin/bfin.c (bfin_expand_builtin): Likewise.
* config/c6x/c6x.c (c6x_expand_builtin): Likewise.
* config/frv/frv.c (frv_expand_builtin): Likewise.
* config/gcn/gcn.c (gcn_expand_builtin_1): Likewise.
(gcn_expand_builtin): Likewise.
* config/i386/i386-builtins.c (ix86_builtin_reciprocal): Likewise.
(fold_builtin_cpu): Likewise.
* config/i386/i386-expand.c (ix86_expand_builtin): Likewise.
* config/i386/i386.c (ix86_fold_builtin): Likewise.
(ix86_gimple_fold_builtin): Likewise.
* config/ia64/ia64.c (ia64_fold_builtin): Likewise.
(ia64_expand_builtin): Likewise.
* config/iq2000/iq2000.c (iq2000_expand_builtin): Likewise.
* config/mips/mips.c (mips_expand_builtin): Likewise.
* config/msp430/msp430.c (msp430_expand_builtin): Likewise.
* config/nds32/nds32-intrinsic.c (nds32_expand_builtin_impl): Likewise.
* config/nios2/nios2.c (nios2_expand_builtin): Likewise.
* config/nvptx/nvptx.c (nvptx_expand_builtin): Likewise.
* config/pa/pa.c (pa_expand_builtin): Likewise.
* config/pru/pru.c (pru_expand_builtin): Likewise.
* config/riscv/riscv-builtins.c (riscv_expand_builtin): Likewise.
* config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
Likewise.
* config/rs6000/rs6000-call.c (htm_expand_builtin): Likewise.
(altivec_expand_dst_builtin, altivec_expand_builtin): Likewise.
(rs6000_gimple_fold_builtin, rs6000_expand_builtin): Likewise.
* config/rs6000/rs6000.c (rs6000_builtin_md_vectorized_function)
(rs6000_builtin_reciprocal): Likewise.
* config/rx/rx.c (rx_expand_builtin): Likewise.
* config/s390/s390-c.c (s390_resolve_overloaded_builtin): Likewise.
* config/s390/s390.c (s390_expand_builtin): Likewise.
* config/sh/sh.c (sh_expand_builtin): Likewise.
* config/sparc/sparc.c (sparc_expand_builtin): Likewise.
(sparc_fold_builtin): Likewise.
* config/spu/spu-c.c (spu_resolve_overloaded_builtin): Likewise.
* config/spu/spu.c (spu_expand_builtin): Likewise.
* config/stormy16/stormy16.c (xstormy16_expand_builtin): Likewise.
* config/tilegx/tilegx.c (tilegx_expand_builtin): Likewise.
* config/tilepro/tilepro.c (tilepro_expand_builtin): Likewise.
* config/xtensa/xtensa.c (xtensa_fold_builtin): Likewise.
(xtensa_expand_builtin): Likewise.
gcc/ada/
PR middle-end/91421
* gcc-interface/trans.c (gigi): Call set_decl_buillt_in_function.
(Call_to_gnu): Use DECL_FE_FUNCTION_CODE instead of DECL_FUNCTION_CODE.
gcc/c/
PR middle-end/91421
* c-decl.c (merge_decls): Use copy_decl_built_in_function.
gcc/c-family/
PR middle-end/91421
* c-common.c (resolve_overloaded_builtin): Use
copy_decl_built_in_function.
gcc/cp/
PR middle-end/91421
* decl.c (duplicate_decls): Use copy_decl_built_in_function.
* pt.c (declare_integer_pack): Use set_decl_built_in_function.
gcc/d/
PR middle-end/91421
* intrinsics.cc (maybe_set_intrinsic): Use set_decl_built_in_function.
gcc/jit/
PR middle-end/91421
* jit-playback.c (new_function): Use set_decl_built_in_function.
gcc/lto/
PR middle-end/91421
* lto-common.c (compare_tree_sccs_1): Use DECL_UNCHECKED_FUNCTION_CODE
instead of DECL_FUNCTION_CODE.
* lto-symtab.c (lto_symtab_merge_p): Likewise.
From-SVN: r274404
|
|
* config/alpha/alpha.c [TARGET_ABI_OSF] (alpha_output_mi_thunk_osf):
Remove obsolete use_thunk reference.
* config/i386/i386.c (x86_output_mi_thunk): Likewise.
* config/ia64/ia64.c (ia64_output_mi_thunk): Likewise.
* config/nios2/nios2.c (nios2_asm_output_mi_thunk): Likewise.
* config/or1k/or1k.c (or1k_output_mi_thunk): Likewise.
* config/rs6000/rs6000.c (rs6000_output_mi_thunk): Likewise.
* config/sh/sh.c (sh_output_mi_thunk): Likewise.
* config/sparc/sparc.c (sparc_output_mi_thunk): Likewise.
* config/tilegx/tilegx.c (tilegx_output_mi_thunk): Likewise.
* config/tilepro/tilepro.c (tilepro_asm_output_mi_thunk): Likewise.
From-SVN: r271703
|
|
Let backends call assemble_start_function after they have generated
thunk function body so that a constant pool could be output if it is
required. This may help backends to avoid implementing custom constant
loading code specifically for the MI thunk and reuse existing
functionality.
gcc/
2019-05-16 Max Filippov <jcmvbkbc@gmail.com>
* cgraphunit.c (cgraph_node::expand_thunk): Remove
assemble_start_function and assemble_end_function calls.
* config/alpha/alpha.c (alpha_output_mi_thunk_osf): Call
assemble_start_function and assemble_end_function.
* config/arc/arc.c (arc_output_mi_thunk): Likewise.
* config/arm/arm.c (arm_output_mi_thunk): Likewise.
* config/bfin/bfin.c (bfin_output_mi_thunk): Likewise.
* config/c6x/c6x.c (c6x_output_mi_thunk): Likewise.
* config/cris/cris.c (cris_asm_output_mi_thunk): Likewise.
* config/csky/csky.c (csky_output_mi_thunk): Likewise.
* config/epiphany/epiphany.c (epiphany_output_mi_thunk): Likewise.
* config/frv/frv.c (frv_asm_output_mi_thunk): Likewise.
* config/i386/i386.c (x86_output_mi_thunk): Likewise.
* config/ia64/ia64.c (ia64_output_mi_thunk): Likewise.
* config/m68k/m68k.c (m68k_output_mi_thunk): Likewise.
* config/microblaze/microblaze.c (microblaze_asm_output_mi_thunk):
Likewise.
* config/mips/mips.c (mips_output_mi_thunk): Likewise.
* config/mmix/mmix.c (mmix_asm_output_mi_thunk): Likewise.
* config/mn10300/mn10300.c (mn10300_asm_output_mi_thunk): Likewise.
* config/nds32/nds32.c (nds32_asm_output_mi_thunk): Likewise.
* config/nios2/nios2.c (nios2_asm_output_mi_thunk): Likewise.
* config/or1k/or1k.c (or1k_output_mi_thunk): Likewise.
* config/pa/pa.c (pa_asm_output_mi_thunk): Likewise.
* config/riscv/riscv.c (riscv_output_mi_thunk): Likewise.
* config/rs6000/rs6000.c (rs6000_output_mi_thunk): Likewise.
* config/s390/s390.c (s390_output_mi_thunk): Likewise.
* config/sh/sh.c (sh_output_mi_thunk): Likewise.
* config/sparc/sparc.c (sparc_output_mi_thunk): Likewise.
* config/spu/spu.c (spu_output_mi_thunk): Likewise.
* config/stormy16/stormy16.c (xstormy16_asm_output_mi_thunk):
Likewise.
* config/tilegx/tilegx.c (tilegx_output_mi_thunk): Likewise.
* config/tilepro/tilepro.c (tilepro_asm_output_mi_thunk): Likewise.
* config/vax/vax.c (vax_output_mi_thunk): Likewise.
From-SVN: r271293
|
|
From-SVN: r267494
|
|
From-SVN: r256169
|
|
This patch makes TRULY_NOOP_TRUNCATION take the mode sizes as
poly_uint64s instead of unsigned ints. The function bodies
don't need to change.
2017-12-20 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* target.def (truly_noop_truncation): Take poly_uint64s instead of
unsigned ints. Change default to hook_bool_puint64_puint64_true.
* doc/tm.texi: Regenerate.
* hooks.h (hook_bool_uint_uint_true): Delete.
(hook_bool_puint64_puint64_true): Declare.
* hooks.c (hook_bool_uint_uint_true): Delete.
(hook_bool_puint64_puint64_true): New function.
* config/mips/mips.c (mips_truly_noop_truncation): Take poly_uint64s
instead of unsigned ints.
* config/spu/spu.c (spu_truly_noop_truncation): Likewise.
* config/tilegx/tilegx.c (tilegx_truly_noop_truncation): Likewise.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r255866
|
|
This patch makes each target-specifc TU define an IN_TARGET_CODE macro,
which is used to decide whether poly_int<1, C> should convert to C.
2017-12-16 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* doc/sourcebuild.texi: Document IN_TARGET_CODE.
* genattrtab.c (write_header): Define IN_TARGET_CODE to 1 in the
target C file.
* genautomata.c (main): Likewise.
* genconditions.c (write_header): Likewise.
* genemit.c (main): Likewise.
* genextract.c (print_header): Likewise.
* genopinit.c (main): Likewise.
* genoutput.c (output_prologue): Likewise.
* genpeep.c (main): Likewise.
* genpreds.c (write_insn_preds_c): Likewise.
* genrecog.c (writer_header): Likewise.
* config/aarch64/aarch64-builtins.c (IN_TARGET_CODE): Define.
* config/aarch64/aarch64-c.c (IN_TARGET_CODE): Likewise.
* config/aarch64/aarch64.c (IN_TARGET_CODE): Likewise.
* config/aarch64/cortex-a57-fma-steering.c (IN_TARGET_CODE): Likewise.
* config/aarch64/driver-aarch64.c (IN_TARGET_CODE): Likewise.
* config/alpha/alpha.c (IN_TARGET_CODE): Likewise.
* config/alpha/driver-alpha.c (IN_TARGET_CODE): Likewise.
* config/arc/arc-c.c (IN_TARGET_CODE): Likewise.
* config/arc/arc.c (IN_TARGET_CODE): Likewise.
* config/arc/driver-arc.c (IN_TARGET_CODE): Likewise.
* config/arm/aarch-common.c (IN_TARGET_CODE): Likewise.
* config/arm/arm-builtins.c (IN_TARGET_CODE): Likewise.
* config/arm/arm-c.c (IN_TARGET_CODE): Likewise.
* config/arm/arm.c (IN_TARGET_CODE): Likewise.
* config/arm/driver-arm.c (IN_TARGET_CODE): Likewise.
* config/avr/avr-c.c (IN_TARGET_CODE): Likewise.
* config/avr/avr-devices.c (IN_TARGET_CODE): Likewise.
* config/avr/avr-log.c (IN_TARGET_CODE): Likewise.
* config/avr/avr.c (IN_TARGET_CODE): Likewise.
* config/avr/driver-avr.c (IN_TARGET_CODE): Likewise.
* config/avr/gen-avr-mmcu-specs.c (IN_TARGET_CODE): Likewise.
* config/bfin/bfin.c (IN_TARGET_CODE): Likewise.
* config/c6x/c6x.c (IN_TARGET_CODE): Likewise.
* config/cr16/cr16.c (IN_TARGET_CODE): Likewise.
* config/cris/cris.c (IN_TARGET_CODE): Likewise.
* config/darwin.c (IN_TARGET_CODE): Likewise.
* config/epiphany/epiphany.c (IN_TARGET_CODE): Likewise.
* config/epiphany/mode-switch-use.c (IN_TARGET_CODE): Likewise.
* config/epiphany/resolve-sw-modes.c (IN_TARGET_CODE): Likewise.
* config/fr30/fr30.c (IN_TARGET_CODE): Likewise.
* config/frv/frv.c (IN_TARGET_CODE): Likewise.
* config/ft32/ft32.c (IN_TARGET_CODE): Likewise.
* config/h8300/h8300.c (IN_TARGET_CODE): Likewise.
* config/i386/djgpp.c (IN_TARGET_CODE): Likewise.
* config/i386/driver-i386.c (IN_TARGET_CODE): Likewise.
* config/i386/driver-mingw32.c (IN_TARGET_CODE): Likewise.
* config/i386/host-cygwin.c (IN_TARGET_CODE): Likewise.
* config/i386/host-i386-darwin.c (IN_TARGET_CODE): Likewise.
* config/i386/host-mingw32.c (IN_TARGET_CODE): Likewise.
* config/i386/i386-c.c (IN_TARGET_CODE): Likewise.
* config/i386/i386.c (IN_TARGET_CODE): Likewise.
* config/i386/intelmic-mkoffload.c (IN_TARGET_CODE): Likewise.
* config/i386/msformat-c.c (IN_TARGET_CODE): Likewise.
* config/i386/winnt-cxx.c (IN_TARGET_CODE): Likewise.
* config/i386/winnt-stubs.c (IN_TARGET_CODE): Likewise.
* config/i386/winnt.c (IN_TARGET_CODE): Likewise.
* config/i386/x86-tune-sched-atom.c (IN_TARGET_CODE): Likewise.
* config/i386/x86-tune-sched-bd.c (IN_TARGET_CODE): Likewise.
* config/i386/x86-tune-sched-core.c (IN_TARGET_CODE): Likewise.
* config/i386/x86-tune-sched.c (IN_TARGET_CODE): Likewise.
* config/ia64/ia64-c.c (IN_TARGET_CODE): Likewise.
* config/ia64/ia64.c (IN_TARGET_CODE): Likewise.
* config/iq2000/iq2000.c (IN_TARGET_CODE): Likewise.
* config/lm32/lm32.c (IN_TARGET_CODE): Likewise.
* config/m32c/m32c-pragma.c (IN_TARGET_CODE): Likewise.
* config/m32c/m32c.c (IN_TARGET_CODE): Likewise.
* config/m32r/m32r.c (IN_TARGET_CODE): Likewise.
* config/m68k/m68k.c (IN_TARGET_CODE): Likewise.
* config/mcore/mcore.c (IN_TARGET_CODE): Likewise.
* config/microblaze/microblaze-c.c (IN_TARGET_CODE): Likewise.
* config/microblaze/microblaze.c (IN_TARGET_CODE): Likewise.
* config/mips/driver-native.c (IN_TARGET_CODE): Likewise.
* config/mips/frame-header-opt.c (IN_TARGET_CODE): Likewise.
* config/mips/mips.c (IN_TARGET_CODE): Likewise.
* config/mmix/mmix.c (IN_TARGET_CODE): Likewise.
* config/mn10300/mn10300.c (IN_TARGET_CODE): Likewise.
* config/moxie/moxie.c (IN_TARGET_CODE): Likewise.
* config/msp430/driver-msp430.c (IN_TARGET_CODE): Likewise.
* config/msp430/msp430-c.c (IN_TARGET_CODE): Likewise.
* config/msp430/msp430.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-cost.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-fp-as-gp.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-intrinsic.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-isr.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-md-auxiliary.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-memory-manipulation.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-pipelines-auxiliary.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32-predicates.c (IN_TARGET_CODE): Likewise.
* config/nds32/nds32.c (IN_TARGET_CODE): Likewise.
* config/nios2/nios2.c (IN_TARGET_CODE): Likewise.
* config/nvptx/mkoffload.c (IN_TARGET_CODE): Likewise.
* config/nvptx/nvptx.c (IN_TARGET_CODE): Likewise.
* config/pa/pa.c (IN_TARGET_CODE): Likewise.
* config/pdp11/pdp11.c (IN_TARGET_CODE): Likewise.
* config/powerpcspe/driver-powerpcspe.c (IN_TARGET_CODE): Likewise.
* config/powerpcspe/host-darwin.c (IN_TARGET_CODE): Likewise.
* config/powerpcspe/host-ppc64-darwin.c (IN_TARGET_CODE): Likewise.
* config/powerpcspe/powerpcspe-c.c (IN_TARGET_CODE): Likewise.
* config/powerpcspe/powerpcspe-linux.c (IN_TARGET_CODE): Likewise.
* config/powerpcspe/powerpcspe.c (IN_TARGET_CODE): Likewise.
* config/riscv/riscv-builtins.c (IN_TARGET_CODE): Likewise.
* config/riscv/riscv-c.c (IN_TARGET_CODE): Likewise.
* config/riscv/riscv.c (IN_TARGET_CODE): Likewise.
* config/rl78/rl78-c.c (IN_TARGET_CODE): Likewise.
* config/rl78/rl78.c (IN_TARGET_CODE): Likewise.
* config/rs6000/driver-rs6000.c (IN_TARGET_CODE): Likewise.
* config/rs6000/host-darwin.c (IN_TARGET_CODE): Likewise.
* config/rs6000/host-ppc64-darwin.c (IN_TARGET_CODE): Likewise.
* config/rs6000/rs6000-c.c (IN_TARGET_CODE): Likewise.
* config/rs6000/rs6000-linux.c (IN_TARGET_CODE): Likewise.
* config/rs6000/rs6000-p8swap.c (IN_TARGET_CODE): Likewise.
* config/rs6000/rs6000-string.c (IN_TARGET_CODE): Likewise.
* config/rs6000/rs6000.c (IN_TARGET_CODE): Likewise.
* config/rx/rx.c (IN_TARGET_CODE): Likewise.
* config/s390/driver-native.c (IN_TARGET_CODE): Likewise.
* config/s390/s390-c.c (IN_TARGET_CODE): Likewise.
* config/s390/s390.c (IN_TARGET_CODE): Likewise.
* config/sh/sh-c.c (IN_TARGET_CODE): Likewise.
* config/sh/sh-mem.cc (IN_TARGET_CODE): Likewise.
* config/sh/sh.c (IN_TARGET_CODE): Likewise.
* config/sh/sh_optimize_sett_clrt.cc (IN_TARGET_CODE): Likewise.
* config/sh/sh_treg_combine.cc (IN_TARGET_CODE): Likewise.
* config/sparc/driver-sparc.c (IN_TARGET_CODE): Likewise.
* config/sparc/sparc-c.c (IN_TARGET_CODE): Likewise.
* config/sparc/sparc.c (IN_TARGET_CODE): Likewise.
* config/spu/spu-c.c (IN_TARGET_CODE): Likewise.
* config/spu/spu.c (IN_TARGET_CODE): Likewise.
* config/stormy16/stormy16.c (IN_TARGET_CODE): Likewise.
* config/tilegx/mul-tables.c (IN_TARGET_CODE): Likewise.
* config/tilegx/tilegx-c.c (IN_TARGET_CODE): Likewise.
* config/tilegx/tilegx.c (IN_TARGET_CODE): Likewise.
* config/tilepro/mul-tables.c (IN_TARGET_CODE): Likewise.
* config/tilepro/tilepro-c.c (IN_TARGET_CODE): Likewise.
* config/tilepro/tilepro.c (IN_TARGET_CODE): Likewise.
* config/v850/v850-c.c (IN_TARGET_CODE): Likewise.
* config/v850/v850.c (IN_TARGET_CODE): Likewise.
* config/vax/vax.c (IN_TARGET_CODE): Likewise.
* config/visium/visium.c (IN_TARGET_CODE): Likewise.
* config/vms/vms-c.c (IN_TARGET_CODE): Likewise.
* config/vms/vms-f.c (IN_TARGET_CODE): Likewise.
* config/vms/vms.c (IN_TARGET_CODE): Likewise.
* config/xtensa/xtensa.c (IN_TARGET_CODE): Likewise.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r255743
|
|
I took the documentation of the FRAME_GROWS_DOWNWARD behaviour from the
version that was in most header files, since the one in the manual seemed
less clear.
The patch deliberately keeps FIRST_PARM_OFFSET(FNDECL) in
microblaze_starting_frame_offset; this seems to be a port-local
convention and takes advantage of the fact that FIRST_PARM_OFFSET
doesn't read FNDECL.
2017-10-23 Richard Sandiford <richard.sandiford@linaro.org>
gcc/
* target.def (starting_frame_offset): New hook.
* doc/tm.texi (STARTING_FRAME_OFFSET): Remove in favor of...
(TARGET_STARTING_FRAME_OFFSET): ...this new hook.
* doc/tm.texi.in: Regenerate.
* hooks.h (hook_hwi_void_0): Declare.
* hooks.c (hook_hwi_void_0): New function.
* doc/rtl.texi: Refer to TARGET_STARTING_FRAME_OFFSET instead of
STARTING_FRAME_OFFSET.
* builtins.c (expand_builtin_setjmp_receiver): Likewise.
* reload1.c (reload): Likewise.
* cfgexpand.c (expand_used_vars): Use targetm.starting_frame_offset
instead of STARTING_FRAME_OFFSET.
* function.c (try_fit_stack_local): Likewise.
(assign_stack_local_1): Likewise
(instantiate_virtual_regs): Likewise.
* rtlanal.c (rtx_addr_can_trap_p_1): Likewise.
* config/avr/avr.md (nonlocal_goto_receiver): Likewise.
* config/aarch64/aarch64.h (STARTING_FRAME_OFFSET): Delete.
* config/alpha/alpha.h (STARTING_FRAME_OFFSET): Likewise.
* config/arc/arc.h (STARTING_FRAME_OFFSET): Likewise.
* config/arm/arm.h (STARTING_FRAME_OFFSET): Likewise.
* config/bfin/bfin.h (STARTING_FRAME_OFFSET): Likewise.
* config/c6x/c6x.h (STARTING_FRAME_OFFSET): Likewise.
* config/cr16/cr16.h (STARTING_FRAME_OFFSET): Likewise.
* config/cris/cris.h (STARTING_FRAME_OFFSET): Likewise.
* config/fr30/fr30.h (STARTING_FRAME_OFFSET): Likewise.
* config/frv/frv.h (STARTING_FRAME_OFFSET): Likewise.
* config/ft32/ft32.h (STARTING_FRAME_OFFSET): Likewise.
* config/h8300/h8300.h (STARTING_FRAME_OFFSET): Likewise.
* config/i386/i386.h (STARTING_FRAME_OFFSET): Likewise.
* config/ia64/ia64.h (STARTING_FRAME_OFFSET): Likewise.
* config/m32c/m32c.h (STARTING_FRAME_OFFSET): Likewise.
* config/m68k/m68k.h (STARTING_FRAME_OFFSET): Likewise.
* config/mcore/mcore.h (STARTING_FRAME_OFFSET): Likewise.
* config/mn10300/mn10300.h (STARTING_FRAME_OFFSET): Likewise.
* config/moxie/moxie.h (STARTING_FRAME_OFFSET): Likewise.
* config/msp430/msp430.h (STARTING_FRAME_OFFSET): Likewise.
* config/nds32/nds32.h (STARTING_FRAME_OFFSET): Likewise.
* config/nios2/nios2.h (STARTING_FRAME_OFFSET): Likewise.
* config/nvptx/nvptx.h (STARTING_FRAME_OFFSET): Likewise.
* config/pdp11/pdp11.h (STARTING_FRAME_OFFSET): Likewise.
* config/riscv/riscv.h (STARTING_FRAME_OFFSET): Likewise.
* config/rl78/rl78.h (STARTING_FRAME_OFFSET): Likewise.
* config/rx/rx.h (STARTING_FRAME_OFFSET): Likewise.
* config/s390/s390.h (STARTING_FRAME_OFFSET): Likewise.
* config/sh/sh.h (STARTING_FRAME_OFFSET): Likewise.
* config/sparc/sparc.c (sparc_compute_frame_size): Likewise.
* config/sparc/sparc.h (STARTING_FRAME_OFFSET): Likewise.
* config/spu/spu.h (STARTING_FRAME_OFFSET): Likewise.
* config/stormy16/stormy16.h (STARTING_FRAME_OFFSET): Likewise.
* config/tilegx/tilegx.h (STARTING_FRAME_OFFSET): Likewise.
* config/tilepro/tilepro.h (STARTING_FRAME_OFFSET): Likewise.
* config/v850/v850.h (STARTING_FRAME_OFFSET): Likewise.
* config/visium/visium.h (STARTING_FRAME_OFFSET): Likewise.
* config/avr/avr.h (STARTING_FRAME_OFFSET): Likewise.
* config/avr/avr-protos.h (avr_starting_frame_offset): Likewise.
* config/avr/avr.c (avr_starting_frame_offset): Make static and
return a HOST_WIDE_INT.
(avr_builtin_setjmp_frame_value): Use it instead of
STARTING_FRAME_OFFSET.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/epiphany/epiphany.h (STARTING_FRAME_OFFSET): Delete.
* config/epiphany/epiphany.c (epiphany_starting_frame_offset):
New function.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/iq2000/iq2000.h (STARTING_FRAME_OFFSET): Delete.
* config/iq2000/iq2000.c (iq2000_starting_frame_offset): New function.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/lm32/lm32.h (STARTING_FRAME_OFFSET): Delete.
* config/lm32/lm32.c (lm32_starting_frame_offset): New function.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/m32r/m32r.h (STARTING_FRAME_OFFSET): Delete.
* config/m32r/m32r.c (m32r_starting_frame_offset): New function.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/microblaze/microblaze.h (STARTING_FRAME_OFFSET): Delete.
* config/microblaze/microblaze.c (microblaze_starting_frame_offset):
New function.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/mips/mips.h (STARTING_FRAME_OFFSET): Delete.
* config/mips/mips.c (mips_compute_frame_info): Refer to
TARGET_STARTING_FRAME_OFFSET instead of STARTING_FRAME_OFFSET.
(mips_starting_frame_offset): New function.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/mmix/mmix.h (STARTING_FRAME_OFFSET): Delete.
* config/mmix/mmix-protos.h (mmix_starting_frame_offset): Delete.
* config/mmix/mmix.c (mmix_starting_frame_offset): Make static
and return a HOST_WIDE_INT.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
(mmix_initial_elimination_offset): Refer to
TARGET_STARTING_FRAME_OFFSET instead of STARTING_FRAME_OFFSET.
* config/pa/pa.h (STARTING_FRAME_OFFSET): Delete.
* config/pa/pa.c (pa_starting_frame_offset): New function.
(pa_compute_frame_size): Use it instead of STARTING_FRAME_OFFSET.
(pa_expand_prologue): Likewise.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/powerpcspe/aix.h (STARTING_FRAME_OFFSET): Split out
!FRAME_GROWS_DOWNWARD handling to...
(RS6000_STARTING_FRAME_OFFSET): ...this new macro.
* config/powerpcspe/darwin.h (STARTING_FRAME_OFFSET): Split out
!FRAME_GROWS_DOWNWARD handling to...
(RS6000_STARTING_FRAME_OFFSET): ...this new macro.
* config/powerpcspe/powerpcspe.h (STARTING_FRAME_OFFSET): Split out
!FRAME_GROWS_DOWNWARD handling to...
(RS6000_STARTING_FRAME_OFFSET): ...this new macro.
* config/powerpcspe/powerpcspe.c (TARGET_STARTING_FRAME_OFFSET):
Redefine.
(rs6000_starting_frame_offset): New function.
* config/rs6000/aix.h (STARTING_FRAME_OFFSET): Split out
!FRAME_GROWS_DOWNWARD handling to...
(RS6000_STARTING_FRAME_OFFSET): ...this new macro.
* config/rs6000/darwin.h (STARTING_FRAME_OFFSET): Split out
!FRAME_GROWS_DOWNWARD handling to...
(RS6000_STARTING_FRAME_OFFSET): ...this new macro.
* config/rs6000/rs6000.h (STARTING_FRAME_OFFSET): Split out
!FRAME_GROWS_DOWNWARD handling to...
(RS6000_STARTING_FRAME_OFFSET): ...this new macro.
* config/rs6000/rs6000.c (TARGET_STARTING_FRAME_OFFSET): Refine.
(rs6000_starting_frame_offset): New function.
* config/vax/elf.h (STARTING_FRAME_OFFSET): Delete.
* config/vax/vax.h (STARTING_FRAME_OFFSET): Delete.
* config/vax/vax.c (vax_starting_frame_offset): New function.
(vax_expand_prologue): Use it instead of STARTING_FRAME_OFFSET.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* config/xtensa/xtensa.h (STARTING_FRAME_OFFSET): Delete.
* config/xtensa/xtensa.c (xtensa_starting_frame_offset): New function.
(TARGET_STARTING_FRAME_OFFSET): Redefine.
* system.h (STARTING_FRAME_OFFSET): Poison.
From-SVN: r254003
|
|
The definition:
#define CONSTANT_ALIGNMENT(EXP, ALIGN) \
(TREE_CODE (EXP) == STRING_CST \
&& (ALIGN) < BITS_PER_WORD ? BITS_PER_WORD : (ALIGN))
was very common, so the patch adds a canned definition for that,
called constant_alignment_word_strings. Some ports had a variation
that used a port-local FASTEST_ALIGNMENT instead of BITS_PER_WORD;
the patch uses constant_alignment_word_strings if FASTEST_ALIGNMENT
was always BITS_PER_WORD and a port-local hook function otherwise.
2017-09-25 Richard Sandiford <richard.sandiford@linaro.org>
gcc/
* target.def (constant_alignment): New hook.
* defaults.h (CONSTANT_ALIGNMENT): Delete.
* doc/tm.texi.in (CONSTANT_ALIGNMENT): Replace with...
(TARGET_CONSTANT_ALIGNMENT): ...this new hook.
* doc/tm.texi: Regenerate.
* targhooks.h (default_constant_alignment): Declare.
(constant_alignment_word_strings): Likewise.
* targhooks.c (default_constant_alignment): New function.
(constant_alignment_word_strings): Likewise.
* builtins.c (get_object_alignment_2): Use targetm.constant_alignment
instead of CONSTANT_ALIGNMENT.
* varasm.c (align_variable, get_variable_align, build_constant_desc)
(force_const_mem): Likewise.
* config/aarch64/aarch64.h (CONSTANT_ALIGNMENT): Delete.
* config/aarch64/aarch64.c (aarch64_constant_alignment): New function.
(aarch64_classify_address): Call it instead of CONSTANT_ALIGNMENT.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/alpha/alpha.h (CONSTANT_ALIGNMENT): Delete commented-out
definition.
* config/arc/arc.h (CONSTANT_ALIGNMENT): Delete.
* config/arc/arc.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/arm/arm.h (CONSTANT_ALIGNMENT_FACTOR): Delete.
(CONSTANT_ALIGNMENT): Likewise.
* config/arm/arm.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(arm_constant_alignment): New function.
* config/bfin/bfin.h (CONSTANT_ALIGNMENT): Delete.
* config/bfin/bfin.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/cr16/cr16.h (CONSTANT_ALIGNMENT): Delete.
* config/cr16/cr16.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/cris/cris.h (CONSTANT_ALIGNMENT): Delete.
* config/cris/cris.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(cris_constant_alignment): New function.
* config/epiphany/epiphany.h (CONSTANT_ALIGNMENT): Delete.
* config/epiphany/epiphany.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(epiphany_constant_alignment): New function.
* config/fr30/fr30.h (CONSTANT_ALIGNMENT): Delete.
* config/fr30/fr30.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/frv/frv.h (CONSTANT_ALIGNMENT): Delete.
* config/frv/frv.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/ft32/ft32.h (CONSTANT_ALIGNMENT): Delete.
* config/ft32/ft32.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/i386/i386.h (CONSTANT_ALIGNMENT): Delete.
* config/i386/i386-protos.h (ix86_constant_alignment): Delete.
* config/i386/i386.c (ix86_constant_alignment): Make static.
Use the same interface as the target hook.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/ia64/ia64.h (CONSTANT_ALIGNMENT): Delete.
* config/ia64/ia64.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/iq2000/iq2000.h (CONSTANT_ALIGNMENT): Delete.
* config/iq2000/iq2000.c (iq2000_constant_alignment): New function.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/lm32/lm32.h (CONSTANT_ALIGNMENT): Delete.
* config/lm32/lm32.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/m32r/m32r.h (CONSTANT_ALIGNMENT): Delete.
* config/m32r/m32r.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/mcore/mcore.h (CONSTANT_ALIGNMENT): Delete.
* config/mcore/mcore.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/microblaze/microblaze.h (CONSTANT_ALIGNMENT): Delete.
* config/microblaze/microblaze.c (microblaze_constant_alignment):
New function.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/mips/mips.h (CONSTANT_ALIGNMENT): Delete.
* config/mips/mips.c (mips_constant_alignment): New function.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/mmix/mmix.h (CONSTANT_ALIGNMENT): Delete.
* config/mmix/mmix-protos.h (mmix_constant_alignment): Delete.
* config/mmix/mmix.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(mmix_constant_alignment): Make static. Use the same interface
as the target hook.
* config/moxie/moxie.h (CONSTANT_ALIGNMENT): Delete.
* config/moxie/moxie.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/nios2/nios2.h (CONSTANT_ALIGNMENT): Delete.
* config/nios2/nios2.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/pa/pa.h (CONSTANT_ALIGNMENT): Delete.
* config/pa/pa.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/powerpcspe/powerpcspe.h (CONSTANT_ALIGNMENT): Delete.
* config/powerpcspe/powerpcspe.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(rs6000_constant_alignment): New function.
* config/riscv/riscv.h (CONSTANT_ALIGNMENT): Delete.
* config/riscv/riscv.c (riscv_constant_alignment): New function.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/rs6000/rs6000.h (CONSTANT_ALIGNMENT): Delete.
* config/rs6000/rs6000.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(rs6000_constant_alignment): New function.
* config/s390/s390.h (CONSTANT_ALIGNMENT): Delete.
* config/s390/s390.c (s390_constant_alignment): New function.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/sh/sh.h (CONSTANT_ALIGNMENT): Delete.
* config/sh/sh.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/sparc/sparc.h (CONSTANT_ALIGNMENT): Delete.
* config/sparc/sparc.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(sparc_constant_alignment): New function.
* config/spu/spu.h (CONSTANT_ALIGNMENT): Delete.
* config/spu/spu.c (spu_constant_alignment): New function.
(TARGET_CONSTANT_ALIGNMENT): Redefine.
* config/stormy16/stormy16.h (CONSTANT_ALIGNMENT): Delete.
* config/stormy16/stormy16.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/tilegx/tilegx.h (CONSTANT_ALIGNMENT): Delete.
* config/tilegx/tilegx.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/tilepro/tilepro.h (CONSTANT_ALIGNMENT): Delete.
* config/tilepro/tilepro.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
constant_alignment_word_strings.
* config/visium/visium.h (CONSTANT_ALIGNMENT): Delete.
* config/visium/visium.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(visium_constant_alignment): New function.
* config/xtensa/xtensa.h (CONSTANT_ALIGNMENT): Delete.
* config/xtensa/xtensa.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
(xtensa_constant_alignment): New function.
* system.h (CONSTANT_ALIGNMENT): Poison.
From-SVN: r253154
|
|
I'm not sure the documentation is correct that outprec is always less
than inprec, and each non-default implementation tested for the case
in which it wasn't, but the patch leaves it as-is.
The SH port had a couple of TRULY_NOOP_TRUNCATION tests that were left
over from the old shmedia port.
2017-09-13 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayard <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* target.def (truly_noop_truncation): New hook.
(mode_rep_extended): Refer to TARGET_TRULY_NOOP_TRUNCATION rather
than TRULY_NOOP_TRUNCATION.
* hooks.h (hook_bool_uint_uint_true): Declare.
* hooks.c (hook_bool_uint_uint_true): New function.
* doc/tm.texi.in (TRULY_NOOP_TRUNCATION): Replace with...
(TARGET_TRULY_NOOP_TRUNCATION): ...this.
* doc/tm.texi: Regenerate.
* combine.c (make_extraction): Refer to TARGET_TRULY_NOOP_TRUNCATION
rather than TRULY_NOOP_TRUNCATION in comments.
(simplify_comparison): Likewise.
(record_truncated_value): Likewise.
* expmed.c (extract_bit_field_1): Likewise.
(extract_split_bit_field): Likewise.
* convert.c (convert_to_integer_1): Use targetm.truly_noop_truncation
instead of TRULY_NOOP_TRUNCATION.
* function.c (assign_parm_setup_block): Likewise.
* machmode.h (TRULY_NOOP_TRUNCATION_MODES_P): Likewise.
* rtlhooks.c: Include target.h.
* config/aarch64/aarch64.h (TRULY_NOOP_TRUNCATION): Delete.
* config/alpha/alpha.h (TRULY_NOOP_TRUNCATION): Delete.
* config/arc/arc.h (TRULY_NOOP_TRUNCATION): Delete.
* config/arm/arm.h (TRULY_NOOP_TRUNCATION): Delete.
* config/avr/avr.h (TRULY_NOOP_TRUNCATION): Delete.
* config/bfin/bfin.h (TRULY_NOOP_TRUNCATION): Delete.
* config/c6x/c6x.h (TRULY_NOOP_TRUNCATION): Delete.
* config/cr16/cr16.h (TRULY_NOOP_TRUNCATION): Delete.
* config/cris/cris.h (TRULY_NOOP_TRUNCATION): Delete.
* config/epiphany/epiphany.h (TRULY_NOOP_TRUNCATION): Delete.
* config/fr30/fr30.h (TRULY_NOOP_TRUNCATION): Delete.
* config/frv/frv.h (TRULY_NOOP_TRUNCATION): Delete.
* config/ft32/ft32.h (TRULY_NOOP_TRUNCATION): Delete.
* config/h8300/h8300.h (TRULY_NOOP_TRUNCATION): Delete.
* config/i386/i386.h (TRULY_NOOP_TRUNCATION): Delete.
* config/ia64/ia64.h (TRULY_NOOP_TRUNCATION): Delete.
* config/iq2000/iq2000.h (TRULY_NOOP_TRUNCATION): Delete.
* config/lm32/lm32.h (TRULY_NOOP_TRUNCATION): Delete.
* config/m32c/m32c.h (TRULY_NOOP_TRUNCATION): Delete.
* config/m32r/m32r.h (TRULY_NOOP_TRUNCATION): Delete.
* config/m68k/m68k.h (TRULY_NOOP_TRUNCATION): Delete.
* config/mcore/mcore.h (TRULY_NOOP_TRUNCATION): Delete.
* config/microblaze/microblaze.h (TRULY_NOOP_TRUNCATION): Delete.
* config/mips/mips.h (TRULY_NOOP_TRUNCATION): Delete.
* config/mips/mips.c (mips_truly_noop_truncation): New function.
(TARGET_TRULY_NOOP_TRUNCATION): Redefine.
* config/mips/mips.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
rather than TRULY_NOOP_TRUNCATION in comments.
* config/mmix/mmix.h (TRULY_NOOP_TRUNCATION): Delete.
* config/mn10300/mn10300.h (TRULY_NOOP_TRUNCATION): Delete.
* config/moxie/moxie.h (TRULY_NOOP_TRUNCATION): Delete.
* config/msp430/msp430.h (TRULY_NOOP_TRUNCATION): Delete.
* config/nds32/nds32.h (TRULY_NOOP_TRUNCATION): Delete.
* config/nios2/nios2.h (TRULY_NOOP_TRUNCATION): Delete.
* config/nvptx/nvptx.h (TRULY_NOOP_TRUNCATION): Delete.
* config/pa/pa.h (TRULY_NOOP_TRUNCATION): Delete.
* config/pdp11/pdp11.h (TRULY_NOOP_TRUNCATION): Delete.
* config/powerpcspe/powerpcspe.h (TRULY_NOOP_TRUNCATION): Delete.
* config/riscv/riscv.h (TRULY_NOOP_TRUNCATION): Delete.
* config/riscv/riscv.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
rather than TRULY_NOOP_TRUNCATION in comments.
* config/rl78/rl78.h (TRULY_NOOP_TRUNCATION): Delete.
* config/rs6000/rs6000.h (TRULY_NOOP_TRUNCATION): Delete.
* config/rx/rx.h (TRULY_NOOP_TRUNCATION): Delete.
* config/s390/s390.h (TRULY_NOOP_TRUNCATION): Delete.
* config/sh/sh.h (MAYBE_BASE_REGISTER_RTX_P): Remove
TRULY_NOOP_TRUNCATION condition.
(MAYBE_INDEX_REGISTER_RTX_P): Likewise.
(TRULY_NOOP_TRUNCATION): Delete.
* config/sparc/sparc.h (TRULY_NOOP_TRUNCATION): Delete.
* config/spu/spu.h (TRULY_NOOP_TRUNCATION): Delete.
* config/spu/spu.c (spu_truly_noop_truncation): New function.
(TARGET_TRULY_NOOP_TRUNCATION): Redefine.
* config/stormy16/stormy16.h (TRULY_NOOP_TRUNCATION): Delete.
* config/tilegx/tilegx.h (TRULY_NOOP_TRUNCATION): Delete.
* config/tilegx/tilegx.c (tilegx_truly_noop_truncation): New fuction.
(TARGET_TRULY_NOOP_TRUNCATION): Redefine.
* config/tilegx/tilegx.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
rather than TRULY_NOOP_TRUNCATION in comments.
* config/tilepro/tilepro.h (TRULY_NOOP_TRUNCATION): Delete.
* config/v850/v850.h (TRULY_NOOP_TRUNCATION): Delete.
* config/vax/vax.h (TRULY_NOOP_TRUNCATION): Delete.
* config/visium/visium.h (TRULY_NOOP_TRUNCATION): Delete.
* config/xtensa/xtensa.h (TRULY_NOOP_TRUNCATION): Delete.
* system.h (TRULY_NOOP_TRUNCATION): Poison.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r252818
|
|
2017-09-12 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* target.def (hard_regno_nregs): New hook.
(class_max_nregs): Refer to it instead of HARD_REGNO_NREGS.
* targhooks.h (default_hard_regno_nregs): Declare.
* targhooks.c (default_hard_regno_nregs): New function.
* doc/tm.texi.in (HARD_REGNO_NREGS): Replace with...
(TARGET_HARD_REGNO_NREGS): ...this hook.
(HARD_REGNO_NREGS_HAS_PADDING): Update accordingly.
(CLASS_MAX_NREGS): Likewise.
* doc/tm.texi: Regenerate.
* reginfo.c (init_reg_modes_target): Use targetm.hard_regno_nregs
instead of HARD_REGNO_NREGS.
* rtl.h (REG_NREGS): Refer to TARGET_HARD_REGNO_NREGS rather than
HARD_REGNO_NREGS in the comment.
* config/aarch64/aarch64.h (HARD_REGNO_NREGS): Delete.
* config/aarch64/aarch64-protos.h (aarch64_hard_regno_nregs): Delete.
* config/aarch64/aarch64.c (aarch64_hard_regno_nregs): Make static.
Return an unsigned int.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/alpha/alpha.h (HARD_REGNO_NREGS): Delete.
* config/arc/arc.h (HARD_REGNO_NREGS): Delete.
* config/arc/arc.c (TARGET_HARD_REGNO_NREGS): Redefine.
(arc_hard_regno_nregs): New function.
* config/arm/arm.h (HARD_REGNO_NREGS): Delete.
* config/arm/arm.c (TARGET_HARD_REGNO_NREGS): Redefine.
(arm_hard_regno_nregs): New function.
* config/avr/avr.h (HARD_REGNO_NREGS): Delete.
* config/bfin/bfin.h (HARD_REGNO_NREGS): Delete.
* config/bfin/bfin.c (bfin_hard_regno_nregs): New function.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/c6x/c6x.h (HARD_REGNO_NREGS): Delete.
* config/cr16/cr16.h (LONG_REG_P): Use targetm.hard_regno_nregs.
(HARD_REGNO_NREGS): Delete.
* config/cr16/cr16.c (TARGET_HARD_REGNO_NREGS): Redefine.
(cr16_hard_regno_nregs): New function.
(cr16_memory_move_cost): Use it instead of HARD_REGNO_NREGS.
* config/cris/cris.h (HARD_REGNO_NREGS): Delete.
* config/cris/cris.c (TARGET_HARD_REGNO_NREGS): Redefine.
(cris_hard_regno_nregs): New function.
* config/epiphany/epiphany.h (HARD_REGNO_NREGS): Delete.
* config/fr30/fr30.h (HARD_REGNO_NREGS): Delete.
(CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
* config/frv/frv.h (HARD_REGNO_NREGS): Delete.
(CLASS_MAX_NREGS): Remove outdated copy of documentation.
* config/frv/frv-protos.h (frv_hard_regno_nregs): Delete.
* config/frv/frv.c (TARGET_HARD_REGNO_NREGS): Redefine.
(frv_hard_regno_nregs): Make static. Take and return an
unsigned int.
(frv_class_max_nregs): Remove outdated copy of documentation.
* config/ft32/ft32.h (HARD_REGNO_NREGS): Delete.
* config/h8300/h8300.h (HARD_REGNO_NREGS): Delete.
* config/h8300/h8300-protos.h (h8300_hard_regno_nregs): Delete.
* config/h8300/h8300.c (h8300_hard_regno_nregs): Delete.
* config/i386/i386.h (HARD_REGNO_NREGS): Delete.
* config/i386/i386.c (ix86_hard_regno_nregs): New function.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/ia64/ia64.h (HARD_REGNO_NREGS): Delete.
(CLASS_MAX_NREGS): Update comment.
* config/ia64/ia64.c (TARGET_HARD_REGNO_NREGS): Redefine.
(ia64_hard_regno_nregs): New function.
* config/iq2000/iq2000.h (HARD_REGNO_NREGS): Delete.
* config/lm32/lm32.h (HARD_REGNO_NREGS): Delete.
* config/m32c/m32c.h (HARD_REGNO_NREGS): Delete.
* config/m32c/m32c-protos.h (m32c_hard_regno_nregs): Delete.
* config/m32c/m32c.c (m32c_hard_regno_nregs_1): Take and return
an unsigned int.
(m32c_hard_regno_nregs): Likewise. Make static.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/m32r/m32r.h (HARD_REGNO_NREGS): Delete.
* config/m68k/m68k.h (HARD_REGNO_NREGS): Delete.
* config/m68k/m68k.c (TARGET_HARD_REGNO_NREGS): Redefine.
(m68k_hard_regno_nregs): New function.
* config/mcore/mcore.h (HARD_REGNO_NREGS): Delete.
* config/microblaze/microblaze.h (HARD_REGNO_NREGS): Delete.
* config/mips/mips.h (HARD_REGNO_NREGS): Delete.
* config/mips/mips-protos.h (mips_hard_regno_nregs): Delete.
* config/mips/mips.c (mips_hard_regno_nregs): Make static.
Take and return an unsigned int.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/mmix/mmix.h (HARD_REGNO_NREGS): Delete.
(CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
* config/mn10300/mn10300.h (HARD_REGNO_NREGS): Delete.
* config/moxie/moxie.h (HARD_REGNO_NREGS): Delete.
* config/msp430/msp430.h (HARD_REGNO_NREGS): Delete.
* config/msp430/msp430-protos.h (msp430_hard_regno_nregs): Delete.
* config/msp430/msp430.c (TARGET_HARD_REGNO_NREGS): Redefine.
(msp430_hard_regno_nregs): Make static. Take and return an
unsigned int.
* config/nds32/nds32.h (HARD_REGNO_NREGS): Delete.
* config/nds32/nds32-protos.h (nds32_hard_regno_nregs): Delete.
* config/nds32/nds32.c (nds32_hard_regno_nregs): Delete.
(nds32_hard_regno_mode_ok): Use targetm.hard_regno_nregs.
* config/nios2/nios2.h (HARD_REGNO_NREGS): Delete.
* config/nvptx/nvptx.h (HARD_REGNO_NREGS): Delete.
* config/nvptx/nvptx.c (nvptx_hard_regno_nregs): New function.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/pa/pa32-regs.h (HARD_REGNO_NREGS): Rename to...
(PA_HARD_REGNO_NREGS): ...this.
* config/pa/pa64-regs.h (HARD_REGNO_NREGS): Rename to...
(PA_HARD_REGNO_NREGS): ...this.
* config/pa/pa.c (TARGET_HARD_REGNO_NREGS): Redefine.
(pa_hard_regno_nregs): New function.
* config/pdp11/pdp11.h (HARD_REGNO_NREGS): Delete.
* config/pdp11/pdp11.c (TARGET_HARD_REGNO_NREGS): Redefine.
(pdp11_hard_regno_nregs): New function.
* config/powerpcspe/powerpcspe.h (HARD_REGNO_NREGS): Delete.
* config/powerpcspe/powerpcspe.c (TARGET_HARD_REGNO_NREGS): Redefine.
(rs6000_hard_regno_nregs_hook): New function.
* config/riscv/riscv.h (HARD_REGNO_NREGS): Delete.
* config/riscv/riscv-protos.h (riscv_hard_regno_nregs): Delete.
* config/riscv/riscv.c (riscv_hard_regno_nregs): Make static.
Take and return an unsigned int. Move earlier in file.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/rl78/rl78.h (HARD_REGNO_NREGS): Delete.
* config/rl78/rl78-protos.h (rl78_hard_regno_nregs): Delete.
* config/rl78/rl78.c (TARGET_HARD_REGNO_NREGS): Reefine.
(rl78_hard_regno_nregs): Make static. Take and return an
unsigned int.
* config/rs6000/rs6000.h (HARD_REGNO_NREGS): Delete.
* config/rs6000/rs6000.c (TARGET_HARD_REGNO_NREGS): Redefine.
(rs6000_hard_regno_nregs_hook): New function.
* config/rx/rx.h (HARD_REGNO_NREGS): Delete.
* config/rx/rx.c (rx_hard_regno_nregs): New function.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/s390/s390.h (HARD_REGNO_NREGS): Delete.
* config/s390/s390.c (REGNO_PAIR_OK): Use s390_hard_regno_nregs
instead of HARD_REGNO_NREGS.
(s390_hard_regno_nregs): New function.
(s390_hard_regno_mode_ok): Add comment from s390.h.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/sh/sh.h (HARD_REGNO_NREGS): Delete.
* config/sh/sh.c (TARGET_HARD_REGNO_NREGS): Redefine.
(sh_hard_regno_nregs): New function.
(sh_pass_in_reg_p): Use it.
* config/sparc/sparc.h (HARD_REGNO_NREGS): Delete.
* config/sparc/sparc.c (TARGET_HARD_REGNO_NREGS): Redefine.
(sparc_hard_regno_nregs): New function.
* config/spu/spu.h (HARD_REGNO_NREGS): Delete.
* config/spu/spu.c (spu_hard_regno_nregs): New function.
(spu_function_arg_advance): Use it, supplying a valid register number.
(TARGET_HARD_REGNO_NREGS): Redefine.
* config/stormy16/stormy16.h (HARD_REGNO_NREGS): Delete.
* config/tilegx/tilegx.h (HARD_REGNO_NREGS): Delete.
* config/tilepro/tilepro.h (HARD_REGNO_NREGS): Delete.
* config/v850/v850.h (HARD_REGNO_NREGS): Delete.
* config/vax/vax.h (HARD_REGNO_NREGS): Delete.
* config/visium/visium.h (HARD_REGNO_NREGS): Delete.
(CLASS_MAX_NREGS): Remove copy of old documentation.
* config/visium/visium.c (TARGET_HARD_REGNO_NREGS): Redefine.
(visium_hard_regno_nregs): New function.
(visium_hard_regno_mode_ok): Use it instead of HARD_REGNO_NREGS.
* config/xtensa/xtensa.h (HARD_REGNO_NREGS): Delete.
* config/xtensa/xtensa.c (TARGET_HARD_REGNO_NREGS): Redefine.
xtensa_hard_regno_nregs): New function.
* system.h (HARD_REGNO_NREGS): Poison.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r252016
|
|
2017-09-12 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* defaults.h (SLOW_UNALIGNED_ACCESS): Delete.
* target.def (slow_unaligned_access): New hook.
* targhooks.h (default_slow_unaligned_access): Declare.
* targhooks.c (default_slow_unaligned_access): New function.
* doc/tm.texi.in (SLOW_UNALIGNED_ACCESS): Replace with...
(TARGET_SLOW_UNALIGNED_ACCESS): ...this.
* doc/tm.texi: Regenerate.
* config/alpha/alpha.h (SLOW_UNALIGNED_ACCESS): Delete.
* config/arm/arm.h (SLOW_UNALIGNED_ACCESS): Delete.
* config/i386/i386.h (SLOW_UNALIGNED_ACCESS): Delete commented-out
definition.
* config/powerpcspe/powerpcspe.h (SLOW_UNALIGNED_ACCESS): Delete.
* config/powerpcspe/powerpcspe.c (TARGET_SLOW_UNALIGNED_ACCESS):
Redefine.
(rs6000_slow_unaligned_access): New function.
(rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
(expand_block_compare): Likewise.
(expand_strn_compare): Likewise.
(rs6000_rtx_costs): Likewise.
* config/riscv/riscv.h (SLOW_UNALIGNED_ACCESS): Delete.
(riscv_slow_unaligned_access): Likewise.
* config/riscv/riscv.c (riscv_slow_unaligned_access): Rename to...
(riscv_slow_unaligned_access_p): ...this and make static.
(riscv_option_override): Update accordingly.
(riscv_slow_unaligned_access): New function.
(TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
* config/rs6000/rs6000.h (SLOW_UNALIGNED_ACCESS): Delete.
* config/rs6000/rs6000.c (TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
(rs6000_slow_unaligned_access): New function.
(rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
(rs6000_rtx_costs): Likewise.
* config/rs6000/rs6000-string.c (expand_block_compare)
(expand_strn_compare): Use targetm.slow_unaligned_access instead
of SLOW_UNALIGNED_ACCESS.
* config/tilegx/tilegx.h (SLOW_UNALIGNED_ACCESS): Delete.
* config/tilepro/tilepro.h (SLOW_UNALIGNED_ACCESS): Delete.
* calls.c (expand_call): Use targetm.slow_unaligned_access instead
of SLOW_UNALIGNED_ACCESS.
* expmed.c (simple_mem_bitfield_p): Likewise.
* expr.c (alignment_for_piecewise_move): Likewise.
(emit_group_load_1): Likewise.
(emit_group_store): Likewise.
(copy_blkmode_from_reg): Likewise.
(emit_push_insn): Likewise.
(expand_assignment): Likewise.
(store_field): Likewise.
(expand_expr_real_1): Likewise.
* gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
* lra-constraints.c (simplify_operand_subreg): Likewise.
* stor-layout.c (bit_field_mode_iterator::next_mode): Likewise.
* gimple-ssa-store-merging.c: Likewise in block comment at start
of file.
* tree-ssa-strlen.c: Include target.h.
(handle_builtin_memcmp): Use targetm.slow_unaligned_access instead
of SLOW_UNALIGNED_ACCESS.
* system.h (SLOW_UNALIGNED_ACCESS): Poison.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r252009
|
|
2017-09-04 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* target.def (modes_tieable_p): New hook.
* doc/tm.texi (MODES_TIEABLE_P): Replace with...
(TARGET_MODES_TIEABLE_P): ...this.
* doc/tm.texi.in: Regenerate.
* hooks.h (hook_bool_mode_mode_true): Declare.
* hooks.c (hook_bool_mode_mode_true): New function.
* combine.c (subst): Use targetm.modes_tieable_p instead of
MODES_TIEABLE_P.
* dse.c (find_shift_sequence): Likewise.
* expmed.c (extract_low_bits): Likewise.
* lower-subreg.c: Include target.h.
(find_decomposable_subregs): Use targetm.modes_tieable_p instead of
MODES_TIEABLE_P.
* rtlanal.c (rtx_cost): Likewise.
* config/aarch64/aarch64.h (MODES_TIEABLE_P): Delete.
* config/aarch64/aarch64-protos.h (aarch64_modes_tieable_p): Delete.
* config/aarch64/aarch64.c (aarch64_modes_tieable_p): Make static.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/alpha/alpha.h (MODES_TIEABLE_P): Delete.
* config/alpha/alpha.c (alpha_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/arc/arc.h (MODES_TIEABLE_P): Delete.
* config/arc/arc.c (TARGET_MODES_TIEABLE_P): Redefine.
(arc_modes_tieable_p): New function.
* config/arm/arm.h (MODES_TIEABLE_P): Delete.
* config/arm/arm-protos.h (arm_modes_tieable_p): Delete.
* config/arm/arm.c (TARGET_MODES_TIEABLE_P): Redefine.
(arm_modes_tieable_p): Make static.
* config/avr/avr.h (MODES_TIEABLE_P): Delete.
* config/bfin/bfin.h (MODES_TIEABLE_P): Delete.
* config/bfin/bfin.c (bfin_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/c6x/c6x.h (MODES_TIEABLE_P): Delete.
* config/c6x/c6x.c (c6x_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/cr16/cr16.h (MODES_TIEABLE_P): Delete.
* config/cr16/cr16.c (TARGET_MODES_TIEABLE_P): Redefine.
(cr16_modes_tieable_p): New function.
* config/cris/cris.h (MODES_TIEABLE_P): Delete.
* config/epiphany/epiphany.h (MODES_TIEABLE_P): Delete.
* config/fr30/fr30.h (MODES_TIEABLE_P): Delete.
(TRULY_NOOP_TRUNCATION): Update comment.
* config/frv/frv.h (MODES_TIEABLE_P): Delete.
(TRULY_NOOP_TRUNCATION): Update comment.
* config/frv/frv.c (TARGET_MODES_TIEABLE_P): Redefine.
(frv_modes_tieable_p): New function.
* config/ft32/ft32.h (MODES_TIEABLE_P): Delete.
* config/h8300/h8300.h (MODES_TIEABLE_P): Delete.
* config/h8300/h8300.c (h8300_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/i386/i386.h (MODES_TIEABLE_P): Delete.
* config/i386/i386-protos.h (ix86_modes_tieable_p): Delete.
* config/i386/i386.c (ix86_modes_tieable_p): Make static.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/ia64/ia64.h (MODES_TIEABLE_P): Delete.
* config/ia64/ia64.c (TARGET_MODES_TIEABLE_P): Redefine.
(ia64_modes_tieable_p): New function.
* config/iq2000/iq2000.h (MODES_TIEABLE_P): Delete.
* config/iq2000/iq2000.c (TARGET_MODES_TIEABLE_P): Redefine.
(iq2000_modes_tieable_p): New function.
* config/lm32/lm32.h (MODES_TIEABLE_P): Delete.
* config/lm32/lm32.c (TARGET_MODES_TIEABLE_P): Redefine.
(lm32_modes_tieable_p): New function.
* config/m32c/m32c.h (MODES_TIEABLE_P): Delete.
* config/m32c/m32c-protos.h (m32c_modes_tieable_p): Delete.
* config/m32c/m32c.c (m32c_modes_tieable_p): Make static.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/m32r/m32r.h (MODES_TIEABLE_P): Delete.
* config/m32r/m32r.c (TARGET_MODES_TIEABLE_P): Redefine.
(m32r_modes_tieable_p): New function.
* config/m68k/m68k.h (MODES_TIEABLE_P): Delete.
* config/m68k/m68k.c (TARGET_MODES_TIEABLE_P): Redefine.
(m68k_modes_tieable_p): New function.
* config/mcore/mcore.h (MODES_TIEABLE_P): Delete.
* config/mcore/mcore.c (TARGET_MODES_TIEABLE_P): Redefine.
(mcore_modes_tieable_p): New function.
* config/microblaze/microblaze.h (MODES_TIEABLE_P): Delete.
* config/microblaze/microblaze.c (microblaze_modes_tieable_p): New
function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/mips/mips.h (MODES_TIEABLE_P): Delete.
* config/mips/mips-protos.h (mips_modes_tieable_p): Delete.
* config/mips/mips.c (mips_modes_tieable_p): Make static.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/mmix/mmix.h (MODES_TIEABLE_P): Delete.
* config/mn10300/mn10300.h (MODES_TIEABLE_P): Delete.
* config/mn10300/mn10300-protos.h (mn10300_modes_tieable): Delete.
* config/mn10300/mn10300.c (mn10300_modes_tieable): Rename to...
(mn10300_modes_tieable_p): ...this and make static.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/moxie/moxie.h (MODES_TIEABLE_P): Delete.
* config/msp430/msp430.h (MODES_TIEABLE_P): Delete.
* config/msp430/msp430-protos.h (msp430_modes_tieable_p): Delete.
* config/msp430/msp430.c (TARGET_MODES_TIEABLE_P): Redefine.
(msp430_modes_tieable_p): Make static.
* config/nds32/nds32.h (MODES_TIEABLE_P): Delete.
* config/nds32/nds32.c (nds32_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/nios2/nios2.h (MODES_TIEABLE_P): Delete.
* config/nvptx/nvptx.h (MODES_TIEABLE_P): Delete.
* config/nvptx/nvptx.c (nvptx_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/pa/pa.h (MODES_TIEABLE_P): Delete.
* config/pa/pa-protos.h (pa_modes_tieable_p): Delete.
* config/pa/pa.c (pa_modes_tieable_p): Make static.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/pdp11/pdp11.h (MODES_TIEABLE_P): Delete.
* config/pdp11/pdp11.c (TARGET_MODES_TIEABLE_P): Redefine.
(pdp11_modes_tieable_p): New function.
* config/powerpcspe/powerpcspe.h (MODES_TIEABLE_P): Delete.
* config/powerpcspe/powerpcspe.c (TARGET_MODES_TIEABLE_P): Redefine.
(rs6000_modes_tieable_p): New function.
(rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
* config/powerpcspe/powerpcspe.md: Update comment.
* config/riscv/riscv.h (MODES_TIEABLE_P): Delete.
* config/riscv/riscv.c (riscv_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/rl78/rl78.h (MODES_TIEABLE_P): Delete.
* config/rl78/rl78.c (TARGET_MODES_TIEABLE_P): Redefine.
(rl78_modes_tieable_p): New function.
* config/rs6000/rs6000.h (MODES_TIEABLE_P): Delete.
* config/rs6000/rs6000.c (TARGET_MODES_TIEABLE_P): Redefine.
(rs6000_modes_tieable_p): New function.
(rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
* config/rs6000/rs6000.md: Update comment.
* config/rx/rx.h (MODES_TIEABLE_P): Delete.
* config/rx/rx.c (rx_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/s390/s390.h (MODES_TIEABLE_P): Delete.
* config/s390/s390.c (s390_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/sh/sh.h (MODES_TIEABLE_P): Delete.
* config/sh/sh.c (TARGET_MODES_TIEABLE_P): Redefine.
(sh_modes_tieable_p): New function.
* config/sparc/sparc.h (MODES_TIEABLE_P): Delete.
* config/sparc/sparc-protos.h (sparc_modes_tieable_p): Delete.
* config/sparc/sparc.c (TARGET_MODES_TIEABLE_P): Redefine.
(sparc_modes_tieable_p): Make static.
* config/spu/spu.h (MODES_TIEABLE_P): Delete.
* config/spu/spu.c (spu_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/stormy16/stormy16.h (MODES_TIEABLE_P): Delete.
* config/stormy16/stormy16.c (xstormy16_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/tilegx/tilegx.h (MODES_TIEABLE_P): Delete.
* config/tilepro/tilepro.h (MODES_TIEABLE_P): Delete.
* config/v850/v850.h (MODES_TIEABLE_P): Delete.
* config/v850/v850.c (v850_modes_tieable_p): New function.
(TARGET_MODES_TIEABLE_P): Redefine.
* config/vax/vax.h (MODES_TIEABLE_P): Delete.
* config/visium/visium.h (MODES_TIEABLE_P): Delete.
* config/visium/visium.c (TARGET_MODES_TIEABLE_P): Redefine.
(visium_modes_tieable_p): New function.
* config/xtensa/xtensa.h (MODES_TIEABLE_P): Delete.
* config/xtensa/xtensa.c (TARGET_MODES_TIEABLE_P): Redefine.
(xtensa_modes_tieable_p): New function.
* system.h (MODES_TIEABLE_P): Poison.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r251647
|
|
2017-09-04 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* target.def (hard_regno_mode_ok): New hook.
* doc/tm.texi (HARD_REGNO_MODE_OK): Replace with...
(TARGET_HARD_REGNO_MODE_OK): ...this.
* doc/tm.texi.in: Regenerate.
* hooks.h (hook_bool_uint_mode_true): Declare.
* hooks.c (hook_bool_uint_mode_true): New function.
* doc/md.texi: Refer to targetm.hard_regno_mode_ok instead of
HARD_REGNO_MODE_OK.
* genpreds.c (write_insn_preds_c): Add an include of target.h.
* alias.c (init_alias_target): Use targetm.hard_regno_mode_ok
instead of HARD_REGNO_MODE_OK.
* caller-save.c: Include target.h.
(reg_save_code): Use targetm.hard_regno_mode_ok instead of
HARD_REGNO_MODE_OK.
* combine.c (can_combine_p): Likewise.
(combinable_i3pat): Likewise.
(can_change_dest_mode): Likewise.
* expr.c (init_expr_target): Likewise.
(convert_move): Likewise.
(convert_modes): Likewise.
* ira.c (setup_prohibited_class_mode_regs): Likewise.
(setup_prohibited_mode_move_regs): Likewise.
* ira.h (target_ira): Likewise.
* lra-assigns.c (find_hard_regno_for_1): Likewise.
* lra-constraints.c (process_alt_operands): Likewise.
(split_reg): Likewise.
* recog.c (peep2_find_free_register): Likewise.
* ree.c (combine_reaching_defs): Likewise.
* regcprop.c (maybe_mode_change): Likewise.
* reginfo.c (init_reg_sets_1): Likewise.
(choose_hard_reg_mode): Likewise.
(simplifiable_subregs): Likewise.
* regrename.c (check_new_reg_p): Likewise.
* reload.c (find_valid_class): Likewise.
(find_valid_class_1): Likewise.
(reload_inner_reg_of_subreg): Likewise.
(push_reload): Likewise.
(combine_reloads): Likewise.
(find_dummy_reload): Likewise.
(find_reloads): Likewise.
* reload1.c (find_reg): Likewise.
(set_reload_reg): Likewise.
(allocate_reload_reg): Likewise.
(choose_reload_regs): Likewise.
(reload_adjust_reg_for_temp): Likewise.
* rtlanal.c (subreg_size_offset_from_lsb): Likewise.
(simplify_subreg_regno): Likewise.
* sel-sched.c (init_regs_for_mode): Likewise.
* varasm.c (make_decl_rtl): Likewise.
* config/aarch64/aarch64.h (HARD_REGNO_MODE_OK): Delete.
(MODES_TIEABLE_P): Use targetm.hard_regno_mode_ok instead of
HARD_REGNO_MODE_OK.
* config/aarch64/aarch64-protos.h (aarch64_hard_regno_mode_ok): Delete.
* config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Make static.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/alpha/alpha.h (HARD_REGNO_MODE_OK): Delete.
* config/alpha/alpha.c (alpha_hard_regno_mode_ok): New function.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/arc/arc.h (arc_hard_regno_mode_ok): Delete.
(arc_mode_class): Delete.
(HARD_REGNO_MODE_OK): Delete.
* config/arc/arc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(arc_hard_regno_mode_ok): Rename old array to...
(arc_hard_regno_mode_ok_modes): ...this.
(arc_conditional_register_usage): Update accordingly.
(arc_mode_class): Make static.
(arc_hard_regno_mode_ok): New function.
* config/arm/arm.h (HARD_REGNO_MODE_OK): Delete.
* config/arm/arm-protos.h (arm_hard_regno_mode_ok): Delete.
* config/arm/arm.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(arm_hard_regno_mode_ok): Make static.
* config/arm/arm.md (movdi): Use targetm.hard_regno_mode_ok instead of
HARD_REGNO_MODE_OK.
* config/avr/avr-protos.h (avr_hard_regno_mode_ok): Delete.
* config/avr/avr.h (HARD_REGNO_MODE_OK): Delete.
* config/avr/avr.c (avr_hard_regno_mode_ok): Make static and
return a bool.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/bfin/bfin-protos.h (hard_regno_mode_ok): Delete.
* config/bfin/bfin.h (HARD_REGNO_MODE_OK): Delete.
* config/bfin/bfin.c (hard_regno_mode_ok): Rename to...
(bfin_hard_regno_mode_ok): ...this. Make static and return a bool.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/bfin/predicates.md (valid_reg_operand): Use
targetm.hard_regno_mode_ok instead of HARD_REGNO_MODE_OK.
* config/c6x/c6x.h (HARD_REGNO_MODE_OK): Delete.
* config/c6x/c6x.c (c6x_hard_regno_mode_ok): New function.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/cr16/cr16.h (HARD_REGNO_MODE_OK): Delete.
* config/cr16/cr16-protos.h (cr16_hard_regno_mode_ok): Delete.
* config/cr16/cr16.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(cr16_hard_regno_mode_ok): Make static and return a bool.
* config/cris/cris.h (HARD_REGNO_MODE_OK): Delete.
* config/cris/cris.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(cris_hard_regno_mode_ok): New function.
* config/epiphany/epiphany.h (epiphany_hard_regno_mode_ok): Delete.
(epiphany_mode_class): Delete.
(HARD_REGNO_MODE_OK): Delete.
* config/epiphany/epiphany-protos.h (hard_regno_mode_ok): Delete.
* config/epiphany/epiphany.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(hard_regno_mode_ok): Rename to...
(epiphany_hard_regno_mode_ok): ...this. Make static and return a bool.
* config/fr30/fr30.h (HARD_REGNO_MODE_OK): Delete.
* config/fr30/fr30.md: Refer to targetm.hard_regno_mode_ok instead of
HARD_REGNO_MODE_OK.
* config/frv/frv.h (HARD_REGNO_MODE_OK): Delete.
* config/frv/frv-protos.h (frv_hard_regno_mode_ok): Delete.
* config/frv/frv.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(frv_hard_regno_mode_ok): Make static and return a bool.
* config/frv/frv.md: Refer to targetm.hard_regno_mode_ok instead of
HARD_REGNO_MODE_OK.
* config/ft32/ft32.h (HARD_REGNO_MODE_OK): Delete.
* config/h8300/h8300.h (HARD_REGNO_MODE_OK): Delete.
* config/h8300/h8300-protos.h (h8300_hard_regno_mode_ok): Delete.
* config/h8300/h8300.c (h8300_hard_regno_mode_ok): Make static
and return a bool.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/i386/i386.h (HARD_REGNO_MODE_OK): Delete.
* config/i386/i386-protos.h (ix86_hard_regno_mode_ok): Delete.
* config/i386/i386.c (ix86_hard_regno_mode_ok): Make static and
return a bool.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/ia64/ia64.h (HARD_REGNO_MODE_OK): Delete.
* config/ia64/ia64.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(ia64_hard_regno_mode_ok): New function.
* config/iq2000/iq2000.h (HARD_REGNO_MODE_OK): Delete.
* config/iq2000/iq2000.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(iq2000_hard_regno_mode_ok): New function.
* config/lm32/lm32.h (HARD_REGNO_MODE_OK): Delete.
* config/lm32/lm32.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(lm32_hard_regno_mode_ok): New function.
* config/m32c/m32c.h (HARD_REGNO_MODE_OK): Delete.
* config/m32c/m32c-protos.h (m32c_hard_regno_ok): Delete.
* config/m32c/m32c.c (class_can_hold_mode): Use m32c_hard_regno_mode_ok
instead of HARD_REGNO_MODE_OK.
(m32c_hard_regno_ok): Rename to...
(m32c_hard_regno_mode_ok): ...this. Make static and return a bool.
(m32c_cannot_change_mode_class): Update accordingly.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/m32r/m32r.h (m32r_hard_regno_mode_ok): Delete.
(m32r_mode_class): Delete.
(HARD_REGNO_MODE_OK): Delete.
* config/m32r/m32r.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(m32r_hard_regno_mode_ok): Rename to...
(m32r_hard_regno_modes): ...this.
(m32r_mode_class): Make static.
(m32r_hard_regno_mode_ok): New function.
* config/m68k/m68k.h (HARD_REGNO_MODE_OK): Delete.
* config/m68k/m68k-protos.h (m68k_regno_mode_ok): Delete.
* config/m68k/m68k.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(m68k_hard_regno_mode_ok): Make static.
* config/mcore/mcore.h (HARD_REGNO_MODE_OK): Delete.
* config/mcore/mcore.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(mcore_hard_regno_mode_ok): New function.
* config/microblaze/microblaze.h (microblaze_hard_regno_mode_ok)
(HARD_REGNO_MODE_OK): Delete.
* config/microblaze/microblaze.c (microblaze_hard_regno_mode_ok):
Rename to...
(microblaze_hard_regno_mode_ok_p): ...this and make static.
(microblaze_hard_regno_mode_ok): New function.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/mips/mips.h (HARD_REGNO_MODE_OK): Delete.
(mips_hard_regno_mode_ok): Delete.
* config/mips/mips.c (mips_hard_regno_mode_ok): Rename to...
(mips_hard_regno_mode_ok_p): ...this and make static.
(mips_hard_regno_mode_ok_p): Rename to...
(mips_hard_regno_mode_ok_uncached): ...this.
(mips_hard_regno_mode_ok): New function.
(mips_class_max_nregs): Use mips_hard_regno_mode_ok instead
of HARD_REGNO_MODE_OK.
(mips_option_override): Update after above name changes.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/mmix/mmix.h (HARD_REGNO_MODE_OK): Delete.
* config/mn10300/mn10300.h (HARD_REGNO_MODE_OK): Delete.
* config/mn10300/mn10300-protos.h (mn10300_hard_regno_mode_ok): Delete.
* config/mn10300/mn10300.c (mn10300_hard_regno_mode_ok): Make static.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/moxie/moxie.h (HARD_REGNO_MODE_OK): Delete.
* config/msp430/msp430.h (HARD_REGNO_MODE_OK): Delete.
* config/msp430/msp430-protos.h (msp430_hard_regno_mode_ok): Delete.
* config/msp430/msp430.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(msp430_hard_regno_mode_ok): Make static and return a bool.
* config/nds32/nds32.h (HARD_REGNO_MODE_OK): Delete.
* config/nds32/nds32-protos.h (nds32_hard_regno_mode_ok): Delete.
* config/nds32/nds32.c (nds32_hard_regno_mode_ok): Make static
and return a bool.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/nios2/nios2.h (HARD_REGNO_MODE_OK): Delete.
* config/nvptx/nvptx.h (HARD_REGNO_MODE_OK): Delete.
* config/pa/pa.h (MODES_TIEABLE_P): Update commentary.
* config/pa/pa32-regs.h (HARD_REGNO_MODE_OK): Rename to...
(PA_HARD_REGNO_MODE_OK): ...this
* config/pa/pa64-regs.h (HARD_REGNO_MODE_OK): Rename to...
(PA_HARD_REGNO_MODE_OK): ...this.
* config/pa/pa.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(pa_hard_regno_mode_ok): New function.
* config/pdp11/pdp11.h (HARD_REGNO_MODE_OK): Delete.
* config/pdp11/pdp11.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(pdp11_hard_regno_mode_ok): New function.
* config/powerpcspe/powerpcspe.h (HARD_REGNO_MODE_OK): Delete.
* config/powerpcspe/powerpcspe-protos.h (rs6000_hard_regno_mode_ok_p):
Delete.
* config/powerpcspe/powerpcspe.c (rs6000_hard_regno_mode_ok_p):
Make static.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
(rs6000_hard_regno_mode_ok): Rename to...
(rs6000_hard_regno_mode_ok_uncached): ...this.
(rs6000_init_hard_regno_mode_ok): Update accordingly.
(rs6000_hard_regno_mode_ok): New function.
* config/riscv/riscv.h (HARD_REGNO_MODE_OK): Delete.
* config/riscv/riscv-protos.h (riscv_hard_regno_mode_ok_p): Delete.
* config/riscv/riscv.c (riscv_hard_regno_mode_ok_p): Rename to...
(riscv_hard_regno_mode_ok): ...this and make static.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/rl78/rl78.h (HARD_REGNO_MODE_OK): Delete.
* config/rl78/rl78-protos.h (rl78_hard_regno_mode_ok): Delete.
* config/rl78/rl78.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(rl78_hard_regno_mode_ok): Make static and return bool.
* config/rs6000/rs6000.h (HARD_REGNO_MODE_OK): Delete.
* config/rs6000/rs6000-protos.h (rs6000_hard_regno_mode_ok_p):
Delete.
* config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok_p): Make static.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
(rs6000_hard_regno_mode_ok): Rename to...
(rs6000_hard_regno_mode_ok_uncached): ...this.
(rs6000_init_hard_regno_mode_ok): Update accordingly.
(rs6000_hard_regno_mode_ok): New function.
* config/rx/rx.h (HARD_REGNO_MODE_OK): Delete.
* config/rx/rx.c (rx_hard_regno_mode_ok): New function.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/s390/s390.h (HARD_REGNO_MODE_OK): Delete.
* config/s390/s390-protos.h (s390_hard_regno_mode_ok): Delete.
* config/s390/s390.c (s390_hard_regno_mode_ok): Make static.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/sh/sh.h (HARD_REGNO_MODE_OK): Delete.
* config/sh/sh-protos.h (sh_hard_regno_mode_ok): Delete.
* config/sh/sh.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(sh_hard_regno_mode_ok): Make static.
* config/sparc/constraints.md: Refer to targetm.hard_regno_mode_ok
instead of HARD_REGNO_MODE_OK.
* config/sparc/sparc.h (hard_regno_mode_classes): Delete.
(sparc_mode_class): Delete.
(HARD_REGNO_MODE_OK): Delete.
* config/sparc/sparc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(hard_regno_mode_classes): Make static.
(sparc_mode_class): Likewise.
(sparc_hard_regno_mode_ok): New function.
* config/spu/spu.h (HARD_REGNO_MODE_OK): Delete.
* config/stormy16/stormy16.h (HARD_REGNO_MODE_OK): Delete.
* config/stormy16/stormy16.c (xstormy16_hard_regno_mode_ok): New
function.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/tilegx/tilegx.h (HARD_REGNO_MODE_OK): Delete.
* config/tilepro/tilepro.h (HARD_REGNO_MODE_OK): Delete.
* config/v850/v850.h (HARD_REGNO_MODE_OK): Delete.
* config/v850/v850.c (v850_hard_regno_mode_ok): New function.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
* config/vax/vax.h (HARD_REGNO_MODE_OK): Delete.
* config/visium/visium.h (HARD_REGNO_MODE_OK): Delete.
* config/visium/visium.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
(visium_hard_regno_mode_ok): New function.
* config/visium/visium.md: Refer to targetm.hard_regno_mode_ok
instead of HARD_REGNO_MODE_OK.
* config/xtensa/xtensa.h (xtensa_hard_regno_mode_ok): Delete.
(HARD_REGNO_MODE_OK): Delete.
* config/xtensa/xtensa.c (xtensa_hard_regno_mode_ok): Rename to...
(xtensa_hard_regno_mode_ok_p): ...this and make static.
(xtensa_option_override): Update accordingly.
(TARGET_HARD_REGNO_MODE_OK): Redefine.
(xtensa_hard_regno_mode_ok): New function.
* system.h (HARD_REGNO_MODE_OK): Poison.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r251646
|
|
PR82045 is about a bootstrap failure on sparc-sun-solaris2.11.
The problem was that we were passing the new machine_mode wrapper
classes through "..." to emit_library_call(_value), which then
read them back as ints instead.
The simplest fix seemed to be replace "..." with an array of
rtx_mode_ts, then provide wrappers for the common cases. This
bulks out rtl.h a bit, but it does make things a bit more typesafe.
2017-09-04 Richard Sandiford <richard.sandiford@linaro.org>
gcc/
PR bootstrap/82045
* rtl.h (emit_library_call_value_1): Declare.
(emit_library_call): Replace declaration with a series of overloads.
Remove the parameter count argument.
(emit_library_call_value): Likewise.
* calls.c (emit_library_call_value_1): Make global. Replace varargs
with an "rtx_mode_t *".
(emit_library_call_value): Delete.
(emit_library_call): Likewise.
* asan.c (asan_emit_stack_protection): Update calls accordingly.
(asan_emit_allocas_unpoison): Likewise.
* builtins.c (expand_builtin_powi): Likewise.
(expand_asan_emit_allocas_unpoison): Likewise.
* cfgexpand.c (expand_main_function): Likewise.
* config/aarch64/aarch64.c (aarch64_trampoline_init): Likewise.
* config/aarch64/aarch64.h (PROFILE_HOOK): Likewise.
* config/alpha/alpha.c (alpha_trampoline_init): Likewise.
* config/arm/arm.c (arm_trampoline_init): Likewise.
(arm_call_tls_get_addr): Likewise.
(arm_expand_divmod_libfunc): Likewise.
* config/bfin/bfin.md (umulsi3_highpart): Likewise.
(smulsi3_highpart): Likewise.
* config/c6x/c6x.c (c6x_initialize_trampoline): Likewise.
(c6x_expand_compare): Likewise.
(c6x_expand_movmem): Likewise.
* config/frv/frv.c (frv_trampoline_init): Likewise.
* config/i386/i386.c (ix86_trampoline_init): Likewise.
(ix86_expand_divmod_libfunc): Likewise.
* config/ia64/ia64.c (ia64_expand_tls_address): Likewise.
(ia64_expand_compare): Likewise.
(ia64_profile_hook): Likewise.
* config/ia64/ia64.md (save_stack_nonlocal): Likewise.
(nonlocal_goto): Likewise.
(restore_stack_nonlocal): Likewise.
* config/m32r/m32r.c (block_move_call): Likewise.
(m32r_trampoline_init): Likewise.
* config/m68k/linux.h (FINALIZE_TRAMPOLINE): Likewise.
* config/m68k/m68k.c (m68k_call_tls_get_addr): Likewise.
(m68k_call_m68k_read_tp): Likewise.
* config/microblaze/microblaze.c (microblaze_call_tls_get_addr)
(microblaze_expand_divide): Likewise.
* config/mips/mips.h (mips_args): Likewise.
* config/mips/sdemtk.h (mips_sync_icache): Likewise.
(MIPS_ICACHE_SYNC): Likewise.
* config/nios2/nios2.c (nios2_emit_expensive_div): Likewise.
(nios2_trampoline_init): Likewise.
* config/pa/pa.c (hppa_tls_call): Likewise.
(pa_trampoline_init): Likewise.
* config/pa/pa.md (canonicalize_funcptr_for_compare): Likewise.
* config/powerpcspe/powerpcspe.c (rs6000_legitimize_tls_address)
(expand_strn_compare): Likewise.
(rs6000_generate_compare): Likewise.
(rs6000_expand_float128_convert): Likewise.
(output_profile_hook): Likewise.
(rs6000_trampoline_init): Likewise.
* config/powerpcspe/powerpcspe.md (neg<mode>2): Likewise.
* config/riscv/riscv.h (PROFILE_HOOK): Likewise.
* config/rs6000/rs6000-string.c (expand_strn_compare): Likewise.
* config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Likewise.
(rs6000_generate_compare): Likewise.
(rs6000_expand_float128_convert): Likewise.
(output_profile_hook): Likewise.
(rs6000_trampoline_init): Likewise.
* config/rs6000/rs6000.md (neg<mode>2): Likewise.
* config/sh/sh.c (sh_trampoline_init): Likewise.
* config/sparc/sparc.c (emit_soft_tfmode_libcall): Likewise.
(sparc_emit_float_lib_cmp): Likewise.
(sparc32_initialize_trampoline): Likewise.
(sparc64_initialize_trampoline): Likewise.
(sparc_profile_hook): Likewise.
* config/spu/spu.c (ea_load_store): Likewise.
* config/spu/spu.md (floatunssidf2): Likewise.
* config/tilegx/tilegx.c (tilegx_trampoline_init): Likewise.
* config/tilepro/tilepro.c (tilepro_trampoline_init): Likewise.
* config/visium/visium.c (expand_block_move_4): Likewise.
(expand_block_move_2): Likewise.
(expand_block_move_1): Likewise.
(expand_block_set_4): Likewise.
(expand_block_set_2): Likewise.
(expand_block_set_1): Likewise.
(visium_trampoline_init): Likewise.
(visium_profile_hook): Likewise.
* config/xtensa/xtensa.c (xtensa_expand_nonlocal_goto): Likewise.
(xtensa_setup_frame_addresses): Likewise.
(xtensa_trampoline_init): Likewise.
* except.c (sjlj_emit_function_enter): Likewise.
(sjlj_emit_function_exit): Likewise.
* explow.c (allocate_dynamic_stack_space): Likewise.
(probe_stack_range): Likewise.
* expr.c (convert_mode_scalar): Likewise.
* optabs.c (expand_binop): Likewise.
(expand_twoval_binop_libfunc): Likewise.
(expand_unop): Likewise.
(prepare_cmp_insn): Likewise.
(prepare_float_lib_cmp): Likewise.
(expand_float): Likewise.
(expand_fix): Likewise.
(expand_fixed_convert): Likewise.
(maybe_emit_sync_lock_test_and_set): Likewise.
(expand_atomic_compare_and_swap): Likewise.
(expand_mem_thread_fence): Likewise.
(expand_atomic_fetch_op): Likewise.
From-SVN: r251637
|
|
This patch makes the scalar_mode_supported_p target hook take a
scalar_mode rather than a machine_mode.
2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* target.def (scalar_mode_supported_p): Take a scalar_mode
instead of a machine_mode.
* targhooks.h (default_scalar_mode_supported_p): Likewise.
* targhooks.c (default_scalar_mode_supported_p): Likewise.
* config/aarch64/aarch64.c (aarch64_scalar_mode_supported_p): Likewise.
* config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
* config/arm/arm.c (arm_scalar_mode_supported_p): Likewise.
* config/avr/avr.c (avr_scalar_mode_supported_p): Likewise.
* config/c6x/c6x.c (c6x_scalar_mode_supported_p): Likewise.
* config/i386/i386.c (ix86_scalar_mode_supported_p): Likewise.
* config/ia64/ia64.c (ia64_scalar_mode_supported_p): Likewise.
* config/mips/mips.c (mips_scalar_mode_supported_p): Likewise.
* config/msp430/msp430.c (msp430_scalar_mode_supported_p): Likewise.
* config/pa/pa.c (pa_scalar_mode_supported_p): Likewise.
* config/pdp11/pdp11.c (pdp11_scalar_mode_supported_p): Likewise.
* config/powerpcspe/powerpcspe.c (rs6000_scalar_mode_supported_p):
Likewise.
* config/rs6000/rs6000.c (rs6000_scalar_mode_supported_p): Likewise.
* config/s390/s390.c (s390_scalar_mode_supported_p): Likewise.
* config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
* config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
* config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p):
Likewise.
* doc/tm.texi: Regenerate.
gcc/c-family/
* c-attribs.c (vector_mode_valid_p) Fold GET_MODE_INNER call
into scalar_mode_supported_p call.
(handle_mode_attribute): Update call to scalar_mode_supported_p.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r251523
|
|
This patch changes the types of various things from machine_mode
to scalar_int_mode, in cases where (after previous patches)
simply changing the type is enough on its own. The patch does
nothing other than that.
2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* builtins.h (builtin_strncpy_read_str): Take a scalar_int_mode
instead of a machine_mode.
(builtin_memset_read_str): Likewise.
* builtins.c (c_readstr): Likewise.
(builtin_memcpy_read_str): Likewise.
(builtin_strncpy_read_str): Likewise.
(builtin_memset_read_str): Likewise.
(builtin_memset_gen_str): Likewise.
(expand_builtin_signbit): Use scalar_int_mode for local variables.
* cfgexpand.c (convert_debug_memory_address): Take a scalar_int_mode
instead of a machine_mode.
* combine.c (simplify_if_then_else): Use scalar_int_mode for local
variables.
(make_extraction): Likewise.
(try_widen_shift_mode): Take and return scalar_int_modes instead
of machine_modes.
* config/aarch64/aarch64.c (aarch64_libgcc_cmp_return_mode): Return
a scalar_int_mode instead of a machine_mode.
* config/avr/avr.c (avr_addr_space_address_mode): Likewise.
(avr_addr_space_pointer_mode): Likewise.
* config/cr16/cr16.c (cr16_unwind_word_mode): Likewise.
* config/msp430/msp430.c (msp430_addr_space_pointer_mode): Likewise.
(msp430_unwind_word_mode): Likewise.
* config/spu/spu.c (spu_unwind_word_mode): Likewise.
(spu_addr_space_pointer_mode): Likewise.
(spu_addr_space_address_mode): Likewise.
(spu_libgcc_cmp_return_mode): Likewise.
(spu_libgcc_shift_count_mode): Likewise.
* config/rl78/rl78.c (rl78_addr_space_address_mode): Likewise.
(rl78_addr_space_pointer_mode): Likewise.
(fl78_unwind_word_mode): Likewise.
(rl78_valid_pointer_mode): Take a scalar_int_mode instead of a
machine_mode.
* config/alpha/alpha.c (vms_valid_pointer_mode): Likewise.
* config/ia64/ia64.c (ia64_vms_valid_pointer_mode): Likewise.
* config/mips/mips.c (mips_mode_rep_extended): Likewise.
(mips_valid_pointer_mode): Likewise.
* config/tilegx/tilegx.c (tilegx_mode_rep_extended): Likewise.
* config/ft32/ft32.c (ft32_valid_pointer_mode): Likewise.
(ft32_addr_space_pointer_mode): Return a scalar_int_mode instead
of a machine_mode.
(ft32_addr_space_address_mode): Likewise.
* config/m32c/m32c.c (m32c_valid_pointer_mode): Take a
scalar_int_mode instead of a machine_mode.
(m32c_addr_space_pointer_mode): Return a scalar_int_mode instead
of a machine_mode.
(m32c_addr_space_address_mode): Likewise.
* config/powerpcspe/powerpcspe.c (rs6000_abi_word_mode): Likewise.
(rs6000_eh_return_filter_mode): Likewise.
* config/rs6000/rs6000.c (rs6000_abi_word_mode): Likewise.
(rs6000_eh_return_filter_mode): Likewise.
* config/s390/s390.c (s390_libgcc_cmp_return_mode): Likewise.
(s390_libgcc_shift_count_mode): Likewise.
(s390_unwind_word_mode): Likewise.
(s390_valid_pointer_mode): Take a scalar_int_mode rather than a
machine_mode.
* target.def (mode_rep_extended): Likewise.
(valid_pointer_mode): Likewise.
(addr_space.valid_pointer_mode): Likewise.
(eh_return_filter_mode): Return a scalar_int_mode rather than
a machine_mode.
(libgcc_cmp_return_mode): Likewise.
(libgcc_shift_count_mode): Likewise.
(unwind_word_mode): Likewise.
(addr_space.pointer_mode): Likewise.
(addr_space.address_mode): Likewise.
* doc/tm.texi: Regenerate.
* dojump.c (prefer_and_bit_test): Take a scalar_int_mode rather than
a machine_mode.
(do_jump): Use scalar_int_mode for local variables.
* dwarf2cfi.c (init_return_column_size): Take a scalar_int_mode
rather than a machine_mode.
* dwarf2out.c (convert_descriptor_to_mode): Likewise.
(scompare_loc_descriptor_wide): Likewise.
(scompare_loc_descriptor_narrow): Likewise.
* emit-rtl.c (adjust_address_1): Use scalar_int_mode for local
variables.
* except.c (sjlj_emit_dispatch_table): Likewise.
(expand_builtin_eh_copy_values): Likewise.
* explow.c (convert_memory_address_addr_space_1): Likewise.
Take a scalar_int_mode rather than a machine_mode.
(convert_memory_address_addr_space): Take a scalar_int_mode rather
than a machine_mode.
(memory_address_addr_space): Use scalar_int_mode for local variables.
* expmed.h (expand_mult_highpart_adjust): Take a scalar_int_mode
rather than a machine_mode.
* expmed.c (mask_rtx): Likewise.
(init_expmed_one_conv): Likewise.
(expand_mult_highpart_adjust): Likewise.
(extract_high_half): Likewise.
(expmed_mult_highpart_optab): Likewise.
(expmed_mult_highpart): Likewise.
(expand_smod_pow2): Likewise.
(expand_sdiv_pow2): Likewise.
(emit_store_flag_int): Likewise.
(adjust_bit_field_mem_for_reg): Use scalar_int_mode for local
variables.
(extract_low_bits): Likewise.
* expr.h (by_pieces_constfn): Take a scalar_int_mode rather than
a machine_mode.
* expr.c (pieces_addr::adjust): Likewise.
(can_store_by_pieces): Likewise.
(store_by_pieces): Likewise.
(clear_by_pieces_1): Likewise.
(expand_expr_addr_expr_1): Likewise.
(expand_expr_addr_expr): Use scalar_int_mode for local variables.
(expand_expr_real_1): Likewise.
(try_casesi): Likewise.
* final.c (shorten_branches): Likewise.
* fold-const.c (fold_convert_const_int_from_fixed): Change the
type of "mode" to machine_mode.
* internal-fn.c (expand_arith_overflow_result_store): Take a
scalar_int_mode rather than a machine_mode.
(expand_mul_overflow): Use scalar_int_mode for local variables.
* loop-doloop.c (doloop_modify): Likewise.
(doloop_optimize): Likewise.
* optabs.c (expand_subword_shift): Take a scalar_int_mode rather
than a machine_mode.
(expand_doubleword_shift_condmove): Likewise.
(expand_doubleword_shift): Likewise.
(expand_doubleword_clz): Likewise.
(expand_doubleword_popcount): Likewise.
(expand_doubleword_parity): Likewise.
(expand_absneg_bit): Use scalar_int_mode for local variables.
(prepare_float_lib_cmp): Likewise.
* rtl.h (convert_memory_address_addr_space_1): Take a scalar_int_mode
rather than a machine_mode.
(convert_memory_address_addr_space): Likewise.
(get_mode_bounds): Likewise.
(get_address_mode): Return a scalar_int_mode rather than a
machine_mode.
* rtlanal.c (get_address_mode): Likewise.
* stor-layout.c (get_mode_bounds): Take a scalar_int_mode rather
than a machine_mode.
* targhooks.c (default_mode_rep_extended): Likewise.
(default_valid_pointer_mode): Likewise.
(default_addr_space_valid_pointer_mode): Likewise.
(default_eh_return_filter_mode): Return a scalar_int_mode rather
than a machine_mode.
(default_libgcc_cmp_return_mode): Likewise.
(default_libgcc_shift_count_mode): Likewise.
(default_unwind_word_mode): Likewise.
(default_addr_space_pointer_mode): Likewise.
(default_addr_space_address_mode): Likewise.
* targhooks.h (default_eh_return_filter_mode): Likewise.
(default_libgcc_cmp_return_mode): Likewise.
(default_libgcc_shift_count_mode): Likewise.
(default_unwind_word_mode): Likewise.
(default_addr_space_pointer_mode): Likewise.
(default_addr_space_address_mode): Likewise.
(default_mode_rep_extended): Take a scalar_int_mode rather than
a machine_mode.
(default_valid_pointer_mode): Likewise.
(default_addr_space_valid_pointer_mode): Likewise.
* tree-ssa-address.c (addr_for_mem_ref): Use scalar_int_mode for
local variables.
* tree-ssa-loop-ivopts.c (get_shiftadd_cost): Take a scalar_int_mode
rather than a machine_mode.
* tree-switch-conversion.c (array_value_type): Use scalar_int_mode
for local variables.
* tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
* var-tracking.c (use_narrower_mode): Take a scalar_int_mode rather
than a machine_mode.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r251513
|
|
All case statements need to be updated to use the prefixed names,
since the unprefixed names will eventually not be integer constant
expressions. This patch does a mechanical substitution over the whole
codebase.
2017-08-30 Richard Sandiford <richard.sandiford@linaro.org>
Alan Hayward <alan.hayward@arm.com>
David Sherwood <david.sherwood@arm.com>
gcc/
* config/aarch64/aarch64-builtins.c (aarch64_simd_builtin_std_type):
Prefix mode names with E_ in case statements.
* config/aarch64/aarch64-elf.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
* config/aarch64/aarch64.c (aarch64_split_simd_combine): Likewise.
(aarch64_split_simd_move): Likewise.
(aarch64_gen_storewb_pair): Likewise.
(aarch64_gen_loadwb_pair): Likewise.
(aarch64_gen_store_pair): Likewise.
(aarch64_gen_load_pair): Likewise.
(aarch64_get_condition_code_1): Likewise.
(aarch64_constant_pool_reload_icode): Likewise.
(get_rsqrte_type): Likewise.
(get_rsqrts_type): Likewise.
(get_recpe_type): Likewise.
(get_recps_type): Likewise.
(aarch64_gimplify_va_arg_expr): Likewise.
(aarch64_simd_container_mode): Likewise.
(aarch64_emit_load_exclusive): Likewise.
(aarch64_emit_store_exclusive): Likewise.
(aarch64_expand_compare_and_swap): Likewise.
(aarch64_gen_atomic_cas): Likewise.
(aarch64_emit_bic): Likewise.
(aarch64_emit_atomic_swap): Likewise.
(aarch64_emit_atomic_load_op): Likewise.
(aarch64_evpc_trn): Likewise.
(aarch64_evpc_uzp): Likewise.
(aarch64_evpc_zip): Likewise.
(aarch64_evpc_ext): Likewise.
(aarch64_evpc_rev): Likewise.
(aarch64_evpc_dup): Likewise.
(aarch64_gen_ccmp_first): Likewise.
(aarch64_gen_ccmp_next): Likewise.
* config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
(alpha_emit_xfloating_libcall): Likewise.
(emit_insxl): Likewise.
(alpha_arg_type): Likewise.
* config/arc/arc.c (arc_vector_mode_supported_p): Likewise.
(arc_preferred_simd_mode): Likewise.
(arc_secondary_reload): Likewise.
(get_arc_condition_code): Likewise.
(arc_print_operand): Likewise.
(arc_legitimate_constant_p): Likewise.
* config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
* config/arc/arc.md (casesi_load): Likewise.
(casesi_compact_jump): Likewise.
* config/arc/predicates.md (proper_comparison_operator): Likewise.
(cc_use_register): Likewise.
* config/arm/aout.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
* config/arm/arm-builtins.c (arm_simd_builtin_std_type): Likewise.
(arm_init_iwmmxt_builtins): Likewise.
* config/arm/arm.c (thumb1_size_rtx_costs): Likewise.
(neon_expand_vector_init): Likewise.
(arm_attr_length_move_neon): Likewise.
(maybe_get_arm_condition_code): Likewise.
(arm_emit_vector_const): Likewise.
(arm_preferred_simd_mode): Likewise.
(arm_output_iwmmxt_tinsr): Likewise.
(thumb1_output_casesi): Likewise.
(thumb2_output_casesi): Likewise.
(arm_emit_load_exclusive): Likewise.
(arm_emit_store_exclusive): Likewise.
(arm_expand_compare_and_swap): Likewise.
(arm_evpc_neon_vuzp): Likewise.
(arm_evpc_neon_vzip): Likewise.
(arm_evpc_neon_vrev): Likewise.
(arm_evpc_neon_vtrn): Likewise.
(arm_evpc_neon_vext): Likewise.
(arm_validize_comparison): Likewise.
* config/arm/neon.md (neon_vc<cmp_op><mode>): Likewise.
* config/avr/avr-c.c (avr_resolve_overloaded_builtin): Likewise.
* config/avr/avr.c (avr_rtx_costs_1): Likewise.
* config/c6x/c6x.c (c6x_vector_mode_supported_p): Likewise.
(c6x_preferred_simd_mode): Likewise.
* config/epiphany/epiphany.c (get_epiphany_condition_code): Likewise.
(epiphany_rtx_costs): Likewise.
* config/epiphany/predicates.md (proper_comparison_operator):
Likewise.
* config/frv/frv.c (condexec_memory_operand): Likewise.
(frv_emit_move): Likewise.
(output_move_single): Likewise.
(output_condmove_single): Likewise.
(frv_hard_regno_mode_ok): Likewise.
(frv_matching_accg_mode): Likewise.
* config/h8300/h8300.c (split_adds_subs): Likewise.
(h8300_rtx_costs): Likewise.
(h8300_print_operand): Likewise.
(compute_mov_length): Likewise.
(output_logical_op): Likewise.
(compute_logical_op_length): Likewise.
(compute_logical_op_cc): Likewise.
(h8300_shift_needs_scratch_p): Likewise.
(output_a_shift): Likewise.
(compute_a_shift_length): Likewise.
(compute_a_shift_cc): Likewise.
(expand_a_rotate): Likewise.
(output_a_rotate): Likewise.
* config/i386/i386.c (classify_argument): Likewise.
(function_arg_advance_32): Likewise.
(function_arg_32): Likewise.
(function_arg_64): Likewise.
(function_value_64): Likewise.
(ix86_gimplify_va_arg): Likewise.
(ix86_legitimate_constant_p): Likewise.
(put_condition_code): Likewise.
(split_double_mode): Likewise.
(ix86_avx256_split_vector_move_misalign): Likewise.
(ix86_expand_vector_logical_operator): Likewise.
(ix86_split_idivmod): Likewise.
(ix86_expand_adjust_ufix_to_sfix_si): Likewise.
(ix86_build_const_vector): Likewise.
(ix86_build_signbit_mask): Likewise.
(ix86_match_ccmode): Likewise.
(ix86_cc_modes_compatible): Likewise.
(ix86_expand_branch): Likewise.
(ix86_expand_sse_cmp): Likewise.
(ix86_expand_sse_movcc): Likewise.
(ix86_expand_int_sse_cmp): Likewise.
(ix86_expand_vec_perm_vpermi2): Likewise.
(ix86_expand_vec_perm): Likewise.
(ix86_expand_sse_unpack): Likewise.
(ix86_expand_int_addcc): Likewise.
(ix86_split_to_parts): Likewise.
(ix86_vectorize_builtin_gather): Likewise.
(ix86_vectorize_builtin_scatter): Likewise.
(avx_vpermilp_parallel): Likewise.
(inline_memory_move_cost): Likewise.
(ix86_tieable_integer_mode_p): Likewise.
(x86_maybe_negate_const_int): Likewise.
(ix86_expand_vector_init_duplicate): Likewise.
(ix86_expand_vector_init_one_nonzero): Likewise.
(ix86_expand_vector_init_one_var): Likewise.
(ix86_expand_vector_init_concat): Likewise.
(ix86_expand_vector_init_interleave): Likewise.
(ix86_expand_vector_init_general): Likewise.
(ix86_expand_vector_set): Likewise.
(ix86_expand_vector_extract): Likewise.
(emit_reduc_half): Likewise.
(ix86_emit_i387_round): Likewise.
(ix86_mangle_type): Likewise.
(ix86_expand_round_sse4): Likewise.
(expand_vec_perm_blend): Likewise.
(canonicalize_vector_int_perm): Likewise.
(ix86_expand_vec_one_operand_perm_avx512): Likewise.
(expand_vec_perm_1): Likewise.
(expand_vec_perm_interleave3): Likewise.
(expand_vec_perm_even_odd_pack): Likewise.
(expand_vec_perm_even_odd_1): Likewise.
(expand_vec_perm_broadcast_1): Likewise.
(ix86_vectorize_vec_perm_const_ok): Likewise.
(ix86_expand_vecop_qihi): Likewise.
(ix86_expand_mul_widen_hilo): Likewise.
(ix86_expand_sse2_abs): Likewise.
(ix86_expand_pextr): Likewise.
(ix86_expand_pinsr): Likewise.
(ix86_preferred_simd_mode): Likewise.
(ix86_simd_clone_compute_vecsize_and_simdlen): Likewise.
* config/i386/sse.md (*andnot<mode>3): Likewise.
(<mask_codefor><code><mode>3<mask_name>): Likewise.
(*<code><mode>3): Likewise.
* config/ia64/ia64.c (ia64_expand_vecint_compare): Likewise.
(ia64_expand_atomic_op): Likewise.
(ia64_arg_type): Likewise.
(ia64_mode_to_int): Likewise.
(ia64_scalar_mode_supported_p): Likewise.
(ia64_vector_mode_supported_p): Likewise.
(expand_vec_perm_broadcast): Likewise.
* config/iq2000/iq2000.c (iq2000_move_1word): Likewise.
(iq2000_function_arg_advance): Likewise.
(iq2000_function_arg): Likewise.
* config/m32c/m32c.c (m32c_preferred_reload_class): Likewise.
* config/m68k/m68k.c (output_dbcc_and_branch): Likewise.
(m68k_libcall_value): Likewise.
(m68k_function_value): Likewise.
(sched_attr_op_type): Likewise.
* config/mcore/mcore.c (mcore_output_move): Likewise.
* config/microblaze/microblaze.c (microblaze_function_arg_advance):
Likewise.
(microblaze_function_arg): Likewise.
* config/mips/mips.c (mips16_build_call_stub): Likewise.
(mips_print_operand): Likewise.
(mips_mode_ok_for_mov_fmt_p): Likewise.
(mips_vector_mode_supported_p): Likewise.
(mips_preferred_simd_mode): Likewise.
(mips_expand_vpc_loongson_even_odd): Likewise.
(mips_expand_vec_unpack): Likewise.
(mips_expand_vi_broadcast): Likewise.
(mips_expand_vector_init): Likewise.
(mips_expand_vec_reduc): Likewise.
(mips_expand_msa_cmp): Likewise.
* config/mips/mips.md (casesi_internal_mips16_<mode>): Likewise.
* config/mn10300/mn10300.c (mn10300_print_operand): Likewise.
(cc_flags_for_mode): Likewise.
* config/msp430/msp430.c (msp430_print_operand): Likewise.
* config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Likewise.
(nds32_output_casesi_pc_relative): Likewise.
* config/nds32/nds32.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
* config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Likewise.
(nvptx_gen_unpack): Likewise.
(nvptx_gen_pack): Likewise.
(nvptx_gen_shuffle): Likewise.
(nvptx_gen_wcast): Likewise.
(nvptx_preferred_simd_mode): Likewise.
* config/pa/pa.c (pa_secondary_reload): Likewise.
* config/pa/predicates.md (base14_operand): Likewise.
* config/powerpcspe/powerpcspe-c.c
(altivec_resolve_overloaded_builtin): Likewise.
* config/powerpcspe/powerpcspe.c (rs6000_setup_reg_addr_masks):
Likewise.
(rs6000_preferred_simd_mode): Likewise.
(output_vec_const_move): Likewise.
(rs6000_expand_vector_extract): Likewise.
(rs6000_split_vec_extract_var): Likewise.
(reg_offset_addressing_ok_p): Likewise.
(rs6000_legitimate_offset_address_p): Likewise.
(rs6000_legitimize_address): Likewise.
(rs6000_emit_set_const): Likewise.
(rs6000_const_vec): Likewise.
(rs6000_emit_move): Likewise.
(spe_build_register_parallel): Likewise.
(rs6000_darwin64_record_arg_recurse): Likewise.
(swap_selector_for_mode): Likewise.
(spe_init_builtins): Likewise.
(paired_init_builtins): Likewise.
(altivec_init_builtins): Likewise.
(do_load_for_compare): Likewise.
(rs6000_generate_compare): Likewise.
(rs6000_expand_float128_convert): Likewise.
(emit_load_locked): Likewise.
(emit_store_conditional): Likewise.
(rs6000_output_function_epilogue): Likewise.
(rs6000_handle_altivec_attribute): Likewise.
(rs6000_function_value): Likewise.
(emit_fusion_gpr_load): Likewise.
(emit_fusion_p9_load): Likewise.
(emit_fusion_p9_store): Likewise.
* config/powerpcspe/predicates.md (easy_fp_constant): Likewise.
(fusion_gpr_mem_load): Likewise.
(fusion_addis_mem_combo_load): Likewise.
(fusion_addis_mem_combo_store): Likewise.
* config/rs6000/predicates.md (easy_fp_constant): Likewise.
(fusion_gpr_mem_load): Likewise.
(fusion_addis_mem_combo_load): Likewise.
(fusion_addis_mem_combo_store): Likewise.
* config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
Likewise.
* config/rs6000/rs6000-string.c (do_load_for_compare): Likewise.
* config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Likewise.
(rs6000_preferred_simd_mode): Likewise.
(output_vec_const_move): Likewise.
(rs6000_expand_vector_extract): Likewise.
(rs6000_split_vec_extract_var): Likewise.
(reg_offset_addressing_ok_p): Likewise.
(rs6000_legitimate_offset_address_p): Likewise.
(rs6000_legitimize_address): Likewise.
(rs6000_emit_set_const): Likewise.
(rs6000_const_vec): Likewise.
(rs6000_emit_move): Likewise.
(rs6000_darwin64_record_arg_recurse): Likewise.
(swap_selector_for_mode): Likewise.
(paired_init_builtins): Likewise.
(altivec_init_builtins): Likewise.
(rs6000_expand_float128_convert): Likewise.
(emit_load_locked): Likewise.
(emit_store_conditional): Likewise.
(rs6000_output_function_epilogue): Likewise.
(rs6000_handle_altivec_attribute): Likewise.
(rs6000_function_value): Likewise.
(emit_fusion_gpr_load): Likewise.
(emit_fusion_p9_load): Likewise.
(emit_fusion_p9_store): Likewise.
* config/rx/rx.c (rx_gen_move_template): Likewise.
(flags_from_mode): Likewise.
* config/s390/predicates.md (s390_alc_comparison): Likewise.
(s390_slb_comparison): Likewise.
* config/s390/s390.c (s390_handle_vectorbool_attribute): Likewise.
(s390_vector_mode_supported_p): Likewise.
(s390_cc_modes_compatible): Likewise.
(s390_match_ccmode_set): Likewise.
(s390_canonicalize_comparison): Likewise.
(s390_emit_compare_and_swap): Likewise.
(s390_branch_condition_mask): Likewise.
(s390_rtx_costs): Likewise.
(s390_secondary_reload): Likewise.
(__SECONDARY_RELOAD_CASE): Likewise.
(s390_expand_cs): Likewise.
(s390_preferred_simd_mode): Likewise.
* config/s390/vx-builtins.md (vec_packsu_u<mode>): Likewise.
* config/sh/sh.c (sh_print_operand): Likewise.
(dump_table): Likewise.
(sh_secondary_reload): Likewise.
* config/sh/sh.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
* config/sh/sh.md (casesi_worker_1): Likewise.
(casesi_worker_2): Likewise.
* config/sparc/predicates.md (icc_comparison_operator): Likewise.
(fcc_comparison_operator): Likewise.
* config/sparc/sparc.c (sparc_expand_move): Likewise.
(emit_soft_tfmode_cvt): Likewise.
(sparc_preferred_simd_mode): Likewise.
(output_cbranch): Likewise.
(sparc_print_operand): Likewise.
(sparc_expand_vec_perm_bmask): Likewise.
(vector_init_bshuffle): Likewise.
* config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
(spu_vector_mode_supported_p): Likewise.
(spu_expand_insv): Likewise.
(spu_emit_branch_or_set): Likewise.
(spu_handle_vector_attribute): Likewise.
(spu_builtin_splats): Likewise.
(spu_builtin_extract): Likewise.
(spu_builtin_promote): Likewise.
(spu_expand_sign_extend): Likewise.
* config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
(tilegx_simd_int): Likewise.
* config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p): Likewise.
(tilepro_simd_int): Likewise.
* config/v850/v850.c (const_double_split): Likewise.
(v850_print_operand): Likewise.
(ep_memory_offset): Likewise.
* config/vax/vax.c (vax_rtx_costs): Likewise.
(vax_output_int_move): Likewise.
(vax_output_int_add): Likewise.
(vax_output_int_subtract): Likewise.
* config/visium/predicates.md (visium_branch_operator): Likewise.
* config/visium/visium.c (rtx_ok_for_offset_p): Likewise.
(visium_print_operand_address): Likewise.
* config/visium/visium.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
* config/xtensa/xtensa.c (xtensa_mem_offset): Likewise.
(xtensa_expand_conditional_branch): Likewise.
(xtensa_copy_incoming_a7): Likewise.
(xtensa_output_literal): Likewise.
* dfp.c (decimal_real_maxval): Likewise.
* targhooks.c (default_libgcc_floating_mode_supported_p): Likewise.
gcc/c-family/
* c-cppbuiltin.c (mode_has_fma): Prefix mode names with E_ in
case statements.
gcc/objc/
* objc-encoding.c (encode_gnu_bitfield): Prefix mode names with E_ in
case statements.
libobjc/
* encoding.c (_darwin_rs6000_special_round_type_align): Prefix mode
names with E_ in case statements.
Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r251453
|
|
.
2017-08-08 Martin Liska <mliska@suse.cz>
* gcc-interface/trans.c: Include header files.
2017-08-08 Martin Liska <mliska@suse.cz>
* objc-gnu-runtime-abi-01.c: Include header files.
* objc-next-runtime-abi-01.c: Likewise.
* objc-next-runtime-abi-02.c: Likewise.
2017-08-08 Martin Liska <mliska@suse.cz>
* asan.c: Include header files.
* attribs.c (build_decl_attribute_variant): New function moved
from tree.[ch].
(build_type_attribute_qual_variant): Likewise.
(cmp_attrib_identifiers): Likewise.
(simple_cst_list_equal): Likewise.
(omp_declare_simd_clauses_equal): Likewise.
(attribute_value_equal): Likewise.
(comp_type_attributes): Likewise.
(build_type_attribute_variant): Likewise.
(lookup_ident_attribute): Likewise.
(remove_attribute): Likewise.
(merge_attributes): Likewise.
(merge_type_attributes): Likewise.
(merge_decl_attributes): Likewise.
(merge_dllimport_decl_attributes): Likewise.
(handle_dll_attribute): Likewise.
(attribute_list_equal): Likewise.
(attribute_list_contained): Likewise.
* attribs.h (lookup_attribute): New function moved from tree.[ch].
(lookup_attribute_by_prefix): Likewise.
* bb-reorder.c: Include header files.
* builtins.c: Likewise.
* calls.c: Likewise.
* cfgexpand.c: Likewise.
* cgraph.c: Likewise.
* cgraphunit.c: Likewise.
* convert.c: Likewise.
* dwarf2out.c: Likewise.
* final.c: Likewise.
* fold-const.c: Likewise.
* function.c: Likewise.
* gimple-expr.c: Likewise.
* gimple-fold.c: Likewise.
* gimple-pretty-print.c: Likewise.
* gimple.c: Likewise.
* gimplify.c: Likewise.
* hsa-common.c: Likewise.
* hsa-gen.c: Likewise.
* internal-fn.c: Likewise.
* ipa-chkp.c: Likewise.
* ipa-cp.c: Likewise.
* ipa-devirt.c: Likewise.
* ipa-fnsummary.c: Likewise.
* ipa-inline.c: Likewise.
* ipa-visibility.c: Likewise.
* ipa.c: Likewise.
* lto-cgraph.c: Likewise.
* omp-expand.c: Likewise.
* omp-general.c: Likewise.
* omp-low.c: Likewise.
* omp-offload.c: Likewise.
* omp-simd-clone.c: Likewise.
* opts-global.c: Likewise.
* passes.c: Likewise.
* predict.c: Likewise.
* sancov.c: Likewise.
* sanopt.c: Likewise.
* symtab.c: Likewise.
* toplev.c: Likewise.
* trans-mem.c: Likewise.
* tree-chkp.c: Likewise.
* tree-eh.c: Likewise.
* tree-into-ssa.c: Likewise.
* tree-object-size.c: Likewise.
* tree-parloops.c: Likewise.
* tree-profile.c: Likewise.
* tree-ssa-ccp.c: Likewise.
* tree-ssa-live.c: Likewise.
* tree-ssa-loop.c: Likewise.
* tree-ssa-sccvn.c: Likewise.
* tree-ssa-structalias.c: Likewise.
* tree-ssa.c: Likewise.
* tree-streamer-in.c: Likewise.
* tree-vectorizer.c: Likewise.
* tree-vrp.c: Likewise.
* tsan.c: Likewise.
* ubsan.c: Likewise.
* varasm.c: Likewise.
* varpool.c: Likewise.
* tree.c: Remove functions moved to attribs.[ch].
* tree.h: Likewise.
* config/aarch64/aarch64.c: Add attrs.h header file.
* config/alpha/alpha.c: Likewise.
* config/arc/arc.c: Likewise.
* config/arm/arm.c: Likewise.
* config/avr/avr.c: Likewise.
* config/bfin/bfin.c: Likewise.
* config/c6x/c6x.c: Likewise.
* config/cr16/cr16.c: Likewise.
* config/cris/cris.c: Likewise.
* config/darwin.c: Likewise.
* config/epiphany/epiphany.c: Likewise.
* config/fr30/fr30.c: Likewise.
* config/frv/frv.c: Likewise.
* config/ft32/ft32.c: Likewise.
* config/h8300/h8300.c: Likewise.
* config/i386/winnt.c: Likewise.
* config/ia64/ia64.c: Likewise.
* config/iq2000/iq2000.c: Likewise.
* config/lm32/lm32.c: Likewise.
* config/m32c/m32c.c: Likewise.
* config/m32r/m32r.c: Likewise.
* config/m68k/m68k.c: Likewise.
* config/mcore/mcore.c: Likewise.
* config/microblaze/microblaze.c: Likewise.
* config/mips/mips.c: Likewise.
* config/mmix/mmix.c: Likewise.
* config/mn10300/mn10300.c: Likewise.
* config/moxie/moxie.c: Likewise.
* config/msp430/msp430.c: Likewise.
* config/nds32/nds32-isr.c: Likewise.
* config/nds32/nds32.c: Likewise.
* config/nios2/nios2.c: Likewise.
* config/nvptx/nvptx.c: Likewise.
* config/pa/pa.c: Likewise.
* config/pdp11/pdp11.c: Likewise.
* config/powerpcspe/powerpcspe.c: Likewise.
* config/riscv/riscv.c: Likewise.
* config/rl78/rl78.c: Likewise.
* config/rx/rx.c: Likewise.
* config/s390/s390.c: Likewise.
* config/sh/sh.c: Likewise.
* config/sol2.c: Likewise.
* config/sparc/sparc.c: Likewise.
* config/spu/spu.c: Likewise.
* config/stormy16/stormy16.c: Likewise.
* config/tilegx/tilegx.c: Likewise.
* config/tilepro/tilepro.c: Likewise.
* config/v850/v850.c: Likewise.
* config/vax/vax.c: Likewise.
* config/visium/visium.c: Likewise.
* config/xtensa/xtensa.c: Likewise.
2017-08-08 Martin Liska <mliska@suse.cz>
* call.c: Include header files.
* cp-gimplify.c: Likewise.
* cp-ubsan.c: Likewise.
* cvt.c: Likewise.
* init.c: Likewise.
* search.c: Likewise.
* semantics.c: Likewise.
* typeck.c: Likewise.
2017-08-08 Martin Liska <mliska@suse.cz>
* lto-lang.c: Include header files.
* lto-symtab.c: Likewise.
2017-08-08 Martin Liska <mliska@suse.cz>
* c-convert.c: Include header files.
* c-typeck.c: Likewise.
2017-08-08 Martin Liska <mliska@suse.cz>
* c-ada-spec.c: Include header files.
* c-ubsan.c: Likewise.
* c-warn.c: Likewise.
2017-08-08 Martin Liska <mliska@suse.cz>
* trans-types.c: Include header files.
From-SVN: r250946
|
|
functions.
* profile-count.h (profile_probability::from_reg_br_prob_note,
profile_probability::to_reg_br_prob_note): New functions.
* doc/rtl.texi (REG_BR_PROB_NOTE): Update documentation.
* reg-notes.h (REG_BR_PROB, REG_BR_PRED): Update docs.
* predict.c (probability_reliable_p): Update.
(edge_probability_reliable_p): Update.
(br_prob_note_reliable_p): Update.
(invert_br_probabilities): Update.
(add_reg_br_prob_note): New function.
(combine_predictions_for_insn): Update.
* asan.c (asan_clear_shadow): Update.
* cfgbuild.c (compute_outgoing_frequencies): Update.
* cfgrtl.c (force_nonfallthru_and_redirect): Update.
(update_br_prob_note): Update.
(rtl_verify_edges): Update.
(purge_dead_edges): Update.
(fixup_reorder_chain): Update.
* emit-rtl.c (try_split): Update.
* ifcvt.c (cond_exec_process_insns): Update.
(cond_exec_process_if_block): Update.
(dead_or_predicable): Update.
* internal-fn.c (expand_addsub_overflow): Update.
(expand_neg_overflow): Update.
(expand_mul_overflow): Update.
* loop-doloop.c (doloop_modify): Update.
* loop-unroll.c (compare_and_jump_seq): Update.
* optabs.c (emit_cmp_and_jump_insn_1): Update.
* predict.h: Update.
* reorg.c (mostly_true_jump): Update.
* rtl.h: Update.
* config/aarch64/aarch64.c (aarch64_emit_unlikely_jump): Update.
* config/alpha/alpha.c (emit_unlikely_jump): Update.
* config/arc/arc.c: (emit_unlikely_jump): Update.
* config/arm/arm.c: (emit_unlikely_jump): Update.
* config/bfin/bfin.c (cbranch_predicted_taken_p): Update.
* config/frv/frv.c (frv_print_operand_jump_hint): Update.
* config/i386/i386.c (ix86_expand_split_stack_prologue): Update.
(ix86_print_operand): Update.
(ix86_split_fp_branch): Update.
(predict_jump): Update.
* config/ia64/ia64.c (ia64_print_operand): Update.
* config/mmix/mmix.c (mmix_print_operand): Update.
* config/powerpcspe/powerpcspe.c (output_cbranch): Update.
(rs6000_expand_split_stack_prologue): Update.
* config/rs6000/rs6000.c: Update.
* config/s390/s390.c (s390_expand_vec_strlen): Update.
(s390_expand_vec_movstr): Update.
(s390_expand_cs_tdsi): Update.
(s390_expand_split_stack_prologue): Update.
* config/sh/sh.c (sh_print_operand): Update.
(expand_cbranchsi4): Update.
(expand_cbranchdi4): Update.
* config/sparc/sparc.c (output_v9branch): Update.
* config/spu/spu.c (get_branch_target): Update.
(ea_load_store_inline): Update.
* config/tilegx/tilegx.c (cbranch_predicted_p): Update.
* config/tilepro/tilepro.c: Update.
* gcc.dg/predict-8.c: Update.
From-SVN: r250239
|
|
extract_bit_field call.
* config/tilegx/tilegx.c (tilegx_expand_unaligned_load): Add
missing argument to extract_bit_field call.
* config/tilepro/tilepro.c (tilepro_expand_unaligned_load): Likewise.
From-SVN: r248066
|
|
PR target/78862
* config/tilegx/tilegx.md (tilegx_expand_prologue): Add blockage
after initial stackframe link reg save.
* config/tilepro/tilepro.md (tilepro_expand_prologue): Likewise.
From-SVN: r245159
|
|
From-SVN: r243994
|
|
which is both in function frame and in parameter.)
PR target/71331
* config/tilegx/tilegx.c (tilegx_function_profiler): Save r10
to stack before call mcount.
(tilegx_can_use_return_insn_p): Clean up code.
From-SVN: r242969
|
|
* config/tilegx/tilegx.md (trap): New pattern.
* config/tilepro/tilepro.md (trap): Likewise.
From-SVN: r242735
|
|
TILE-Gx: fixes the zero_extract/sign_extract patterns so that they
properly handle the case when pos + size > number of bits in a word.
* config/tilegx/tilegx.md (*zero_extract): Use
define_insn_and_split instead of define_insn; Handle pos +
size > 64.
(*sign_extract): Likewise.
From-SVN: r242734
|
|
gcc/ChangeLog:
2016-11-21 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
* config/arm/arm.c (legitimize_pic_address): Change to use
rtx_insn * as the type of variables.
(arm_pic_static_addr): Likewise.
(arm_emit_movpair): Likewise.
* config/c6x/c6x.c (reorg_split_calls): Likewise.
* config/darwin.c (machopic_legitimize_pic_address): Likewise.
* config/frv/frv.c (frv_optimize_membar_local): Likewise.
* config/frv/frv.md: Likewise.
* config/i386/i386-protos.h: Likewise.
* config/i386/i386.c (ix86_expand_split_stack_prologue):
Likewise.
(ix86_split_fp_branch): Likewise.
(predict_jump): Likewise.
* config/ia64/ia64.c: Likewise.
* config/mcore/mcore.c: Likewise.
* config/rs6000/rs6000.c (rs6000_legitimize_tls_address):
Likewise.
* config/s390/s390.c: Likewise.
* config/s390/s390.md: Likewise.
* config/spu/spu.md: Likewise.
* config/tilegx/tilegx.c (tilegx_legitimize_tls_address):
Likewise.
* lower-subreg.c (resolve_simple_move): Likewise.
From-SVN: r242649
|
|
* config/tilegx/tilegx.c (tilegx_gen_bundles): Preserve
end-of-bundle marker for consecutive barriers.
From-SVN: r242617
|
|
* config/tilegx/tilegx.md (clzsi2): Fix for big-endian.
From-SVN: r242616
|
|
2016-10-13 Thomas Preud'homme <thomas.preudhomme@arm.com>
gcc/
* coretypes.h: Move MEMMODEL_* macros and enum memmodel definition
into ...
* memmodel.h: This file.
* alias.c, asan.c, auto-inc-dec.c, bb-reorder.c, bt-load.c,
caller-save.c, calls.c, ccmp.c, cfgbuild.c, cfgcleanup.c,
cfgexpand.c, cfgloopanal.c, cfgrtl.c, cilk-common.c, combine.c,
combine-stack-adj.c, common/config/aarch64/aarch64-common.c,
common/config/arm/arm-common.c, common/config/bfin/bfin-common.c,
common/config/c6x/c6x-common.c, common/config/i386/i386-common.c,
common/config/ia64/ia64-common.c, common/config/nvptx/nvptx-common.c,
compare-elim.c, config/aarch64/aarch64-builtins.c,
config/aarch64/aarch64-c.c, config/aarch64/cortex-a57-fma-steering.c,
config/arc/arc.c, config/arc/arc-c.c, config/arm/arm-builtins.c,
config/arm/arm-c.c, config/avr/avr.c, config/avr/avr-c.c,
config/avr/avr-log.c, config/bfin/bfin.c, config/c6x/c6x.c,
config/cr16/cr16.c, config/cris/cris.c, config/darwin-c.c,
config/darwin.c, config/epiphany/epiphany.c,
config/epiphany/mode-switch-use.c,
config/epiphany/resolve-sw-modes.c, config/fr30/fr30.c,
config/frv/frv.c, config/ft32/ft32.c, config/h8300/h8300.c,
config/i386/i386-c.c, config/i386/winnt.c, config/iq2000/iq2000.c,
config/lm32/lm32.c, config/m32c/m32c.c, config/m32r/m32r.c,
config/m68k/m68k.c, config/mcore/mcore.c,
config/microblaze/microblaze.c, config/mmix/mmix.c,
config/mn10300/mn10300.c, config/moxie/moxie.c,
config/msp430/msp430.c, config/nds32/nds32-cost.c,
config/nds32/nds32-intrinsic.c, config/nds32/nds32-md-auxiliary.c,
config/nds32/nds32-memory-manipulation.c,
config/nds32/nds32-predicates.c, config/nds32/nds32.c,
config/nios2/nios2.c, config/nvptx/nvptx.c, config/pa/pa.c,
config/pdp11/pdp11.c, config/rl78/rl78.c, config/rs6000/rs6000-c.c,
config/rx/rx.c, config/s390/s390-c.c, config/s390/s390.c,
config/sh/sh.c, config/sh/sh-c.c, config/sh/sh-mem.cc,
config/sh/sh_treg_combine.cc, config/sol2.c, config/spu/spu.c,
config/stormy16/stormy16.c, config/tilegx/tilegx.c,
config/tilepro/tilepro.c, config/v850/v850.c, config/vax/vax.c,
config/visium/visium.c, config/vms/vms-c.c, config/xtensa/xtensa.c,
coverage.c, cppbuiltin.c, cprop.c, cse.c, cselib.c, dbxout.c, dce.c,
df-core.c, df-problems.c, df-scan.c, dojump.c, dse.c, dwarf2asm.c,
dwarf2cfi.c, dwarf2out.c, emit-rtl.c, except.c, explow.c, expmed.c,
expr.c, final.c, fold-const.c, function.c, fwprop.c, gcse.c,
ggc-page.c, haifa-sched.c, hsa-brig.c, hsa-gen.c, hw-doloop.c,
ifcvt.c, init-regs.c, internal-fn.c, ira-build.c, ira-color.c,
ira-conflicts.c, ira-costs.c, ira-emit.c, ira-lives.c, ira.c, jump.c,
loop-doloop.c, loop-invariant.c, loop-iv.c, loop-unroll.c,
lower-subreg.c, lra.c, lra-assigns.c, lra-coalesce.c,
lra-constraints.c, lra-eliminations.c, lra-lives.c, lra-remat.c,
lra-spills.c, mode-switching.c, modulo-sched.c, omp-low.c, passes.c,
postreload-gcse.c, postreload.c, predict.c, print-rtl-function.c,
recog.c, ree.c, reg-stack.c, regcprop.c, reginfo.c, regrename.c,
reload.c, reload1.c, reorg.c, resource.c, rtl-chkp.c, rtl-tests.c,
rtlanal.c, rtlhooks.c, sched-deps.c, sched-rgn.c, sdbout.c,
sel-sched-ir.c, sel-sched.c, shrink-wrap.c, simplify-rtx.c,
stack-ptr-mod.c, stmt.c, stor-layout.c, target-globals.c,
targhooks.c, toplev.c, tree-nested.c, tree-outof-ssa.c,
tree-profile.c, tree-ssa-coalesce.c, tree-ssa-ifcombine.c,
tree-ssa-loop-ivopts.c, tree-ssa-loop.c, tree-ssa-reassoc.c,
tree-ssa-sccvn.c, tree-vect-data-refs.c, ubsan.c, valtrack.c,
var-tracking.c, varasm.c: Include memmodel.h.
* genattrtab.c (write_header): Include memmodel.h in generated file.
* genautomata.c (main): Likewise.
* gengtype.c (open_base_files): Likewise.
* genopinit.c (main): Likewise.
* genconditions.c (write_header): Include memmodel.h earlier in
generated file.
* genemit.c (main): Likewise.
* genoutput.c (output_prologue): Likewise.
* genpeep.c (main): Likewise.
* genpreds.c (write_insn_preds_c): Likewise.
* genrecog.c (write_header): Likewise.
* Makefile.in (PLUGIN_HEADERS): Include memmodel.h
gcc/ada/
* gcc-interface/utils2.c: Include memmodel.h.
gcc/c-family/
* c-cppbuiltin.c: Include memmodel.h.
* c-opts.c: Likewise.
* c-pragma.c: Likewise.
* c-warn.c: Likewise.
gcc/c/
* c-typeck.c: Include memmodel.h.
gcc/cp/
* decl2.c: Include memmodel.h.
* rtti.c: Likewise.
gcc/fortran/
* trans-intrinsic.c: Include memmodel.h.
gcc/go/
* go-backend.c: Include memmodel.h.
libgcc/
* libgcov-profiler.c: Replace MEMMODEL_* macros by their __ATOMIC_*
equivalent.
* config/tilepro/atomic.c: Likewise and stop casting model to
enum memmodel.
From-SVN: r241121
|
|
-mminimal-toc -O0 on ppc64)
PR target/77957
* hooks.h (hook_tree_void_null): Declare.
* hooks.c (hook_tree_void_null): New function.
* langhooks.c (lhd_return_null_tree_v): Remove.
* langhooks-def.h (lhd_return_null_tree_v): Remove.
* cfgexpand.c (stack_protect_prologue): If guard_decl is NULL,
set y to const0_rtx.
* function.c (stack_protect_epilogue): Likewise.
* config/tilepro/tilepro.c (TARGET_STACK_PROTECT_GUARD): Redefine
if TARGET_THREAD_SSP_OFFSET is defined.
* config/s390/s390.c (TARGET_STACK_PROTECT_GUARD): Likewise.
* config/sparc/sparc.c (TARGET_STACK_PROTECT_GUARD): Likewise.
* config/tilegx/tilegx.c (TARGET_STACK_PROTECT_GUARD): Likewise.
* config/rs6000/rs6000.c (TARGET_STACK_PROTECT_GUARD): Likewise.
* config/i386/i386.c (TARGET_STACK_PROTECT_GUARD): Likewise.
(ix86_stack_protect_guard): New function.
c/
* c-objc-common.h (LANG_HOOKS_GETDECLS): Use hook_tree_void_null
instead of lhd_return_null_tree_v.
ada/
* gcc-interface/misc.c (LANG_HOOKS_GETDECLS): Use hook_tree_void_null
instead of lhd_return_null_tree_v.
From-SVN: r241087
|
|
This patch adds a TARGET_LRA_P (defined to hook_bool_void_false) to
every target that didn't yet override the hook. No functional change.
2016-09-14 Segher Boessenkool <segher@kernel.crashing.org>
* config/alpha/alpha.c (TARGET_LRA_P): New macro, defined to
hook_bool_void_false.
* config/avr/avr.c: Ditto.
* config/bfin/bfin.c: Ditto.
* config/c6x/c6x.c: Ditto.
* config/cr16/cr16.c: Ditto.
* config/cris/cris.c: Ditto.
* config/epiphany/epiphany.c: Ditto.
* config/fr30/fr30.c: Ditto.
* config/frv/frv.c: Ditto.
* config/h8300/h8300.c: Ditto.
* config/ia64/ia64.c: Ditto.
* config/iq2000/iq2000.c: Ditto.
* config/lm32/lm32.c: Ditto.
* config/m32c/m32c.c: Ditto.
* config/m32r/m32r.c: Ditto.
* config/m68k/m68k.c: Ditto.
* config/mcore/mcore.c: Ditto.
* config/microblaze/microblaze.c: Ditto.
* config/mmix/mmix.c: Ditto.
* config/mn10300/mn10300.c: Ditto.
* config/moxie/moxie.c: Ditto.
* config/msp430/msp430.c: Ditto.
* config/nios2/nios2.c: Ditto.
* config/nvptx/nvptx.c: Ditto.
* config/pa/pa.c: Ditto.
* config/pdp11/pdp11.c: Ditto.
* config/rl78/rl78.c: Ditto.
* config/sparc/sparc.c: Ditto.
* config/spu/spu.c: Ditto.
* config/stormy16/stormy16.c: Ditto.
* config/tilegx/tilegx.c: Ditto.
* config/tilepro/tilepro.c: Ditto.
* config/v850/v850.c: Ditto.
* config/vax/vax.c: Ditto.
* config/visium/visium.c: Ditto.
* config/xtensa/xtensa.c: Ditto.
From-SVN: r240130
|
|
gcc/ChangeLog:
2016-07-28 Trevor Saunders <tbsaunde+gcc@tbsaunde.org>
* config/alpha/alpha.c (alpha_adjust_cost): Adjust.
* config/arm/arm-protos.h (struct tune_params): Likewise.
* config/arm/arm.c (xscale_sched_adjust_cost): Likewise.
(cortex_a9_sched_adjust_cost): Likewise.
(fa726te_sched_adjust_cost): Likewise.
(arm_adjust_cost): Likewise.
* config/bfin/bfin.c (bfin_adjust_cost): Likewise.
* config/c6x/c6x.c (c6x_adjust_cost): Likewise.
* config/epiphany/epiphany.c (epiphany_adjust_cost): Likewise.
* config/i386/i386.c (ix86_adjust_cost): Likewise.
* config/ia64/ia64.c: Likewise.
* config/m68k/m68k.c: Likewise.
* config/mep/mep.c (mep_adjust_cost): Likewise.
* config/microblaze/microblaze.c (microblaze_adjust_cost):
* Likewise.
* config/mips/mips.c (mips_adjust_cost): Likewise.
* config/mn10300/mn10300.c (mn10300_adjust_sched_cost):
* Likewise.
* config/pa/pa.c (pa_adjust_cost): Likewise.
* config/rs6000/rs6000.c (rs6000_adjust_cost): Likewise.
(rs6000_debug_adjust_cost): Likewise.
* config/sh/sh.c (sh_adjust_cost): Likewise.
* config/sparc/sparc.c (supersparc_adjust_cost): Likewise.
(hypersparc_adjust_cost): Likewise.
(sparc_adjust_cost): Likewise.
* config/spu/spu.c (spu_sched_adjust_cost): Likewise.
* config/tilegx/tilegx.c (tilegx_sched_adjust_cost): Likewise.
* config/tilepro/tilepro.c (tilepro_sched_adjust_cost):
* Likewise.
* config/visium/visium.c (visium_adjust_cost): Likewise.
* doc/tm.texi: Regenerate.
* haifa-sched.c (dep_cost_1): Adjust.
* target.def: Merge adjust_cost and adjust_cost_2.
From-SVN: r238814
|
|
gcc/ChangeLog
* config/tilegx/linux.h: Do not include arch/icache.h
(CLEAR_INSN_CACHE): Provide inlined definition directly.
* config/tilepro/linux.h: Do not include arch/icache.h
(CLEAR_INSN_CACHE): Provide inlined definition directly.
libgcc/ChangeLog
* config/tilepro/atomic.h: Do not include arch/spr_def.h and
asm/unistd.h.
(SPR_CMPEXCH_VALUE): Define for tilegx.
(__NR_FAST_cmpxchg): Define for tilepro.
(__NR_FAST_atomic_update): Define for tilepro.
(__NR_FAST_cmpxchg64): Define for tilepro.
From-SVN: r237824
|
|
gcc/ChangeLog:
* config/tilepro/t-tilepro: Replace CC_FOR_BUILD with
CXX_FOR_BUILD.
* config/tilegx/t-tilegx: Likewise.
From-SVN: r233390
|