Age | Commit message (Collapse) | Author | Files | Lines |
|
* explow.c (allocate_dynamic_stack_space): Check
MALLOC_ABI_ALIGNMENT.
From-SVN: r166393
|
|
gcc/:
PR target/46084
* explow.c (allocate_dynamic_stack_space): If flag_split_stack,
request enough additional space for alignment, and force
alignment.
testsuite/:
* gcc.target/i386/pr46084.c: New test.
From-SVN: r166383
|
|
variable)
PR rtl-opt/33721
* explow.c (allocate_dynamic_stack_space): Add REQUIRED_ALIGN parm,
remove TARGET parm, convert KNOWN_ALIGN parm to SIZE_ALIGN. Honor
required_align, tidy the code a bit. Emit split_stack code in the
right place. Mark the return value with the alignment properly.
* expr.h (allocate_dynamic_stack_space): Update decl.
* builtins.c (expand_builtin_apply): Update call to
allocate_dynamic_stack_space.
(expand_builtin_alloca): Likewise. Remove TARGET parameter.
* calls.c (initialize_argument_information): Update call to
allocate_dynamic_stack_space.
(expand_call): Likewise.
* cfgexpand.c (get_decl_align_unit): Don't limit alignment.
Don't update_stack_alignment here.
(alloc_stack_frame_space): Make ALIGN unsigned.
(stack_var_cmp): Sort by alignment too.
(partition_stack_vars): Don't merge large and small alignment vars.
(expand_one_stack_var_at): Add BASE and BASE_ALIGN parameters.
Take care when BASE is not virtual_stack_vars_rtx.
(expand_stack_vars): Allocate dynamic stack space for large
alignment variables.
(expand_one_stack_var): Update all to expand_one_stack_var_at.
(defer_stack_allocation): True for large alignment vars.
(update_stack_alignment): Merge into ...
(expand_one_var): ... here.
(gimple_expand_cfg): Place code from expand_stack_vars.
From-SVN: r165240
|
|
gcc/:
* common.opt (fsplit-stack): New option.
* opts.c (decode_options): Set flag_split_stack to final value.
* target.def (supports_split_stack): New hook.
* gcc.c (STACK_SPLIT_SPEC): Define.
(LINK_COMMAND_SPEC): Use STACK_SPLIT_SPEC.
* doc/invoke.texi (Option Summary): Mention -fsplit-stack.
(Code Gen Options): Document -fsplit-stack.
* doc/extend.texi (Function Attributes): Mention no_split_stack.
(Function Attributes): Document no_split_stack.
* doc/tm.texi.in (Stack Smashing Protection): Add @hook
TARGET_SUPPORTS_SPLIT_STACK.
* doc/tm.texi: Rebuild.
* function.c (thread_prologue_and_epilogue_insns): If
flag_split_stack, add split stack prologue.
* explow.c (allocate_dynamic_stack_space): Support -fsplit-stack.
* varasm.c (saw_no_split_stack): New static variable.
(assemble_start_function): Set saw_no_split_stack if the function
has the no_split_stack attribute.
(file_end_indicate_split_stack): New function.
* output.h (file_end_indicate_split_stack): Declare.
* libgcc-std.ver (GCC_4.6.0): Add -fsplit-stack support variables
and function.
* doc/libgcc.texi (Miscellaneous routines): Document -fsplit-stack
routines.
* config/i386/i386.c (ix86_option_override_internal): Don't set
expand_builtin_va_start to NULL if -fsplit-stack.
(ix86_function_regparm): Reduce local regparm by 1 for 32-bit
-fsplit-stack.
(ix86_va_start): If -fsplit-stack, get overflow pointer from
scratch register set by prologue.
(ix86_code_end): If -fsplit-stack, call
file_end_indicate_split_stack.
(ix86_supports_split_stack): New static function.
(SPLIT_STACK_AVAILABLE): Define.
(split_stack_prologue_scratch_regno): New static function.
(split_stack_fn): New static variable.
(ix86_expand_split_stack_prologue): New function.
(ix86_live_on_entry): New static function.
(ix86_legitimate_address_p): Handle UNSPEC_STACK_CHECK.
(output_pic_addr_const): Likewise.
(i386_asm_output_addr_const_extra): Likewise.
(ix86_expand_call): Change return type to rtx. Return the new
call instruction.
(TARGET_SUPPORTS_SPLIT_STACK): Define.
(TARGET_EXTRA_LIVE_ON_ENTRY): Define.
* config/i386/i386.md (UNSPEC_STACK_CHECK): Define.
(split_stack_prologue, split_stack_return): New insns.
(split_stack_space_check): New insn.
* config/i386/i386.h (struct machine_function): Add
split_stack_varargs_pointer field.
* config/i386/linux.h (TARGET_CAN_SPLIT_STACK): Define.
(TARGET_THREAD_SPLIT_STACK_OFFSET): Define.
* config/i386/linux64.h (TARGET_CAN_SPLIT_STACK): Define.
(TARGET_THREAD_SPLIT_STACK_OFFSET): Define.
* config/i386/i386-protos.h (ix86_expand_split_stack_prologue):
Declare.
(ix86_expand_call): Update declaration.
gcc/c-family/:
* c-common.c (c_common_attribute_table): Add no_split_stack.
(handle_no_split_stack_attribute): New static function.
gcc/testsuite/:
* lib/target-supports.exp (check_effective_target_split_stack):
New procedure.
* gcc.dg/split-1.c: New test.
* gcc.dg/split-2.c: New test.
* gcc.dg/split-3.c: New test.
* gcc.dg/split-4.c: New test.
libgcc/:
* generic-morestack.h: New file.
* generic-morestack.c: New file.
* generic-morestack-thread.c: New file.
* config/i386/morestack.S: New file.
* config/t-stack: New file.
* config/i386/t-stack-i386: New file.
* config.host (i[34567]86-*-linux* and friends): Add t-stack and
i386/t-stack-i386 to tmake_file.
From-SVN: r164661
|
|
aligned function argument from unaligned stack after alloca)
PR middle-end/45234
* rtl.h (enum global_rtl_index): Add
GR_VIRTUAL_PREFERRED_STACK_BOUNDARY.
(LAST_VIRTUAL_POINTER_REGISTER): Define.
(virtual_preferred_stack_boundary_rtx,
VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM): Define.
(LAST_VIRTUAL_REGISTER): Increase by one.
(REGNO_PTR_FRAME_P): Use LAST_VIRTUAL_POINTER_REGISTER
instead of LAST_VIRTUAL_REGISTER.
* function.c (instantiate_new_reg): Handle
virtual_preferred_stack_boundary_rtx.
* emit-rtl.c (init_virtual_regs): Handle
VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM.
(init_emit_regs): Initialize virtual_preferred_stack_boundary_rtx.
* explow.c (round_push): If crtl->preferred_stack_boundary
is smaller than MAX_SUPPORTED_STACK_ALIGNMENT, use
virtual_preferred_stack_boundary_rtx alignment instead of
crtl->preferred_stack_boundary alignment.
(allocate_dynamic_stack_space): Use CONST_INT_P and REG_P
macros. Never decrease crtl->preferred_stack_boundary,
use crtl->preferred_stack_boundary or MAX_SUPPORTED_STACK_ALIGNMENT
instead of PREFERRED_STACK_BOUNDARY. Don't modify
stack_pointer_delta in dynamic allocation, even when size
is constant.
(probe_stack_range, anti_adjust_stack_and_probe): Use CONST_INT_P
macro.
* print-rtl.c (print_rtx): Handle
VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM.
* config/alpha/alpha.h (NONSTRICT_REG_OK_FP_BASE_P): Use
LAST_VIRTUAL_POINTER_REGISTER instead of LAST_VIRTUAL_REGISTER.
* config/frv/frv.c (frv_emit_movsi): Likewise.
* config/arm/arm.c (thumb1_legitimate_address_p): Likewise.
* config/rs6000/rs6000.c (virtual_stack_registers_memory_p):
Likewise.
* gcc.dg/torture/stackalign/alloca-6.c: New test.
* gcc.target/i386/pr45234.c: New test.
Revert:
2010-09-17 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/45234
* calls.c (expand_call): Make sure that all variable sized
adjustments are multiple of preferred stack boundary after
stack alignment.
From-SVN: r164593
|
|
Stack usage support
* common.opt (-fstack-usage): New option.
* doc/invoke.texi (Debugging options): Document it.
* builtins.c (expand_builtin_apply): Pass TRUE as 4th argument to
allocate_dynamic_stack_space.
(expand_builtin_alloca): Add 4th bool parameter CANNOT_ACCUMULATE
and propagate it to allocate_dynamic_stack_space.
(expand_builtin) <BUILT_IN_ALLOCA>: Adjust for above change.
* calls.c (initialize_argument_information): Pass TRUE as 4th
argument to allocate_dynamic_stack_space.
(expand_call): Set current_function_has_unbounded_dynamic_stack_size
to 1 when pushing a variable-sized argument onto the stack. Pass
TRUE as 4th argument to allocate_dynamic_stack_space.
Update current_function_pushed_stack_size.
(emit_library_call_value_1): Likewise.
* explow.c (allocate_dynamic_stack_space): Add 4th bool parameter
CANNOT_ACCUMULATE. If flag_stack_usage, look into the size and
attempt to find an upper bound. Remove redundant code for the
SETJMP_VIA_SAVE_AREA case.
* expr.h (allocate_dynamic_stack_space): Add 4th bool parameter.
* function.h (struct stack_usage): New structure.
(current_function_static_stack_size): New macro.
(current_function_dynamic_stack_size): Likewise.
(current_function_pushed_stack_size): Likewise.
(current_function_dynamic_alloc_count): Likewise.
(current_function_has_unbounded_dynamic_stack_size): Likewise.
(current_function_allocates_dynamic_stack_space): Likewise.
(struct function): Add new field 'su'.
* function.c (instantiate_virtual_regs): If SETJMP_VIA_SAVE_AREA,
add the value of the dynamic offset to the dynamic stack usage.
(gimplify_parameters): Set ALLOCA_FOR_VAR_P on call to BUILT_IN_ALLOCA
for variable-sized objects.
(prepare_function_start): Allocate cfun->su if flag_stack_usage.
(rest_of_handle_thread_prologue_and_epilogue): Call output_stack_usage.
* gimplify.c (gimplify_decl_expr): Set ALLOCA_FOR_VAR_P on call to
BUILT_IN_ALLOCA for variable-sized objects.
* output.h (output_stack_usage): Declare.
* toplev.c (stack_usage_file): New file pointer.
(output_stack_usage): New function.
(open_auxiliary_file): Likewise.
(lang_dependent_init): Open file if flag_stack_usage is set.
(finalize): Close file if stack_usage_file is not null.
* tree.h (ALLOCA_FOR_VAR_P): New macro.
* config/alpha/alpha.c (compute_frame_size): New function.
(alpha_expand_prologue): Use it.
(alpha_start_function): Likewise.
(alpha_expand_epilogue): Likewise. Set stack usage info.
* config/i386/i386.c (ix86_expand_prologue): Likewise.
* config/ia64/ia64.c (ia64_expand_prologue): Likewise.
* config/mips/mips.c (mips_expand_prologue): Likewise.
* config/pa/pa.c (hppa_expand_prologue): Likewise.
* config/rs6000/rs6000.c (rs6000_emit_prologue): Likewise.
* config/sparc/sparc.c (sparc_expand_prologue): Likewise.
testsuite/
* lib/gcc-dg.exp (cleanup-stack-usage): New procedure.
* lib/scanasm.exp (scan-stack-usage): Likewise.
(scan-stack-usage-not): Likewise.
* gcc.dg/stack-usage-1.c: New test.
* gcc.target/i386/stack-usage-realign.c: Likewise.
From-SVN: r163660
|
|
* toplev.h (ctz_hwi, clz_hwi, ffs_hwi): New.
(floor_log2): Use clz_hwi.
(exact_log2): Use ctz_hwi.
* toplev.c (ctz_hwi, clz_hwi, ffs_hwi): New.
* builtins.c (fold_builtin_bitop): Use them.
* simplify-rtx.c (simplify_const_unary_operation): Likewise.
* combine.c (get_pos_from_mask): Use ctz_hwi.
* double-int.c (double_int_ctz): Likewise.
* explow.c (force_reg): Likewise.
* tree.h (SET_DECL_OFFSET_ALIGN): Use ffs_hwi.
From-SVN: r162920
|
|
2010-07-08 Manuel López-Ibáñez <manu@gcc.gnu.org>
* toplev.h: Do not include diagnostic-core.h.
Include diagnostic-core.h in every file that includes toplev.h.
* c-tree.h: Do not include toplev.h.
* pretty-print.h: Update comment.
* Makefile.in: Update dependencies.
* alias.c: Include diagnostic-core.h in every file that includes
toplev.h.
* attribs.c: Likewise.
* auto-inc-dec.c: Likewise.
* bb-reorder.c: Likewise.
* bt-load.c: Likewise.
* caller-save.c: Likewise.
* calls.c: Likewise.
* cfg.c: Likewise.
* cfganal.c: Likewise.
* cfgbuild.c: Likewise.
* cfgcleanup.c: Likewise.
* cfghooks.c: Likewise.
* cfgloop.c: Likewise.
* combine.c: Likewise.
* config/alpha/alpha.c: Likewise.
* config/arc/arc.c: Likewise.
* config/arm/arm.c: Likewise.
* config/arm/pe.c: Likewise.
* config/avr/avr.c: Likewise.
* config/bfin/bfin.c: Likewise.
* config/cris/cris.c: Likewise.
* config/crx/crx.c: Likewise.
* config/darwin-c.c: Likewise.
* config/darwin.c: Likewise.
* config/fr30/fr30.c: Likewise.
* config/frv/frv.c: Likewise.
* config/h8300/h8300.c: Likewise.
* config/host-darwin.c: Likewise.
* config/i386/i386.c: Likewise.
* config/i386/netware.c: Likewise.
* config/i386/nwld.c: Likewise.
* config/i386/winnt-cxx.c: Likewise.
* config/i386/winnt-stubs.c: Likewise.
* config/i386/winnt.c: Likewise.
* config/ia64/ia64-c.c: Likewise.
* config/ia64/ia64.c: Likewise.
* config/iq2000/iq2000.c: Likewise.
* config/lm32/lm32.c: Likewise.
* config/m32c/m32c-pragma.c: Likewise.
* config/m32c/m32c.c: Likewise.
* config/m32r/m32r.c: Likewise.
* config/m68hc11/m68hc11.c: Likewise.
* config/m68k/m68k.c: Likewise.
* config/mcore/mcore.c: Likewise.
* config/mep/mep-pragma.c: Likewise.
* config/mep/mep.c: Likewise.
* config/mmix/mmix.c: Likewise.
* config/mn10300/mn10300.c: Likewise.
* config/moxie/moxie.c: Likewise.
* config/pa/pa.c: Likewise.
* config/pdp11/pdp11.c: Likewise.
* config/picochip/picochip.c: Likewise.
* config/rs6000/rs6000-c.c: Likewise.
* config/rs6000/rs6000.c: Likewise.
* config/rx/rx.c: Likewise.
* config/s390/s390.c: Likewise.
* config/score/score.c: Likewise.
* config/score/score3.c: Likewise.
* config/score/score7.c: Likewise.
* config/sh/sh.c: Likewise.
* config/sh/symbian-base.c: Likewise.
* config/sh/symbian-c.c: Likewise.
* config/sh/symbian-cxx.c: Likewise.
* config/sol2-c.c: Likewise.
* config/sol2.c: Likewise.
* config/sparc/sparc.c: Likewise.
* config/spu/spu.c: Likewise.
* config/stormy16/stormy16.c: Likewise.
* config/v850/v850-c.c: Likewise.
* config/v850/v850.c: Likewise.
* config/vax/vax.c: Likewise.
* config/vxworks.c: Likewise.
* config/xtensa/xtensa.c: Likewise.
* convert.c: Likewise.
* cse.c: Likewise.
* cselib.c: Likewise.
* dbgcnt.c: Likewise.
* dbxout.c: Likewise.
* ddg.c: Likewise.
* dominance.c: Likewise.
* emit-rtl.c: Likewise.
* explow.c: Likewise.
* expmed.c: Likewise.
* fixed-value.c: Likewise.
* fold-const.c: Likewise.
* fwprop.c: Likewise.
* gcse.c: Likewise.
* ggc-common.c: Likewise.
* ggc-page.c: Likewise.
* ggc-zone.c: Likewise.
* gimple-low.c: Likewise.
* gimplify.c: Likewise.
* graph.c: Likewise.
* haifa-sched.c: Likewise.
* ifcvt.c: Likewise.
* implicit-zee.c: Likewise.
* integrate.c: Likewise.
* ira-build.c: Likewise.
* ira-color.c: Likewise.
* ira-conflicts.c: Likewise.
* ira-costs.c: Likewise.
* ira-lives.c: Likewise.
* ira.c: Likewise.
* lists.c: Likewise.
* loop-doloop.c: Likewise.
* loop-iv.c: Likewise.
* lto-opts.c: Likewise.
* lto-symtab.c: Likewise.
* main.c: Likewise.
* modulo-sched.c: Likewise.
* optabs.c: Likewise.
* params.c: Likewise.
* plugin.c: Likewise.
* postreload-gcse.c: Likewise.
* postreload.c: Likewise.
* predict.c: Likewise.
* profile.c: Likewise.
* real.c: Likewise.
* regcprop.c: Likewise.
* reginfo.c: Likewise.
* regmove.c: Likewise.
* reorg.c: Likewise.
* resource.c: Likewise.
* rtl.c: Likewise.
* rtlanal.c: Likewise.
* sched-deps.c: Likewise.
* sched-ebb.c: Likewise.
* sched-rgn.c: Likewise.
* sdbout.c: Likewise.
* sel-sched-dump.c: Likewise.
* sel-sched-ir.c: Likewise.
* simplify-rtx.c: Likewise.
* stmt.c: Likewise.
* stor-layout.c: Likewise.
* store-motion.c: Likewise.
* targhooks.c: Likewise.
* tree-cfg.c: Likewise.
* tree-cfgcleanup.c: Likewise.
* tree-dump.c: Likewise.
* tree-eh.c: Likewise.
* tree-inline.c: Likewise.
* tree-nomudflap.c: Likewise.
* tree-object-size.c: Likewise.
* tree-optimize.c: Likewise.
* tree-outof-ssa.c: Likewise.
* tree-phinodes.c: Likewise.
* tree-profile.c: Likewise.
* tree-ssa-ccp.c: Likewise.
* tree-ssa-coalesce.c: Likewise.
* tree-ssa-live.c: Likewise.
* tree-ssa-loop-niter.c: Likewise.
* tree-ssa-loop-prefetch.c: Likewise.
* tree-ssa-loop.c: Likewise.
* tree-ssa-structalias.c: Likewise.
* tree-ssa-uninit.c: Likewise.
* tree-ssa.c: Likewise.
* tree-vect-data-refs.c: Likewise.
* tree-vect-loop-manip.c: Likewise.
* tree-vect-loop.c: Likewise.
* tree-vect-patterns.c: Likewise.
* tree-vect-stmts.c: Likewise.
* tree-vrp.c: Likewise.
* varasm.c: Likewise.
* vec.c: Likewise.
* web.c: Likewise.
* xcoffout.c: Likewise.
c-family/
* c-common.h: Include diagnostic-core.h. Error if already
included.
* c-semantics.c: Do not define GCC_DIAG_STYLE here.
cp/
* cp-tree.h: Do not include toplev.h.
java/
* boehm.c: Include diagnostic-core.h in every file that includes
toplev.h.
* class.c: Likewise.
* constants.c: Likewise.
* decl.c: Likewise.
* except.c: Likewise.
* expr.c: Likewise.
* jcf-parse.c: Likewise.
* mangle.c: Likewise.
* mangle_name.c: Likewise.
* resource.c: Likewise.
* typeck.c: Likewise.
* verify-glue.c: Likewise.
ada/
* gcc-interface/utils.c: Include diagnostic-core.h in every file
that includes toplev.h.
lto/
* lto-coff.c: Include diagnostic-core.h in every file that
includes toplev.h.
* lto-elf.c: Likewise.
* lto-lang.c: Likewise.
* lto-macho.c: Likewise.
From-SVN: r161943
|
|
* expr.h (emit_stack_probe): Declare.
* explow.c (emit_stack_probe): Make global.
(anti_adjust_stack_and_probe): Fix comments.
* config/sparc/linux.h (STACK_CHECK_STATIC_BUILTIN): Define to 1.
* config/sparc/linux64.h (STACK_CHECK_STATIC_BUILTIN): Likewise.
* config/sparc/sol2.h (STACK_CHECK_STATIC_BUILTIN): Likewise.
* config/sparc/sparc.c: Include except.h.
(sparc_emit_probe_stack_range): New function.
(output_probe_stack_range): Likewise.
(sparc_expand_prologue): Invoke sparc_emit_probe_stack_range if static
built-in stack checking is enabled.
* config/sparc/sparc-protos.h (output_probe_stack_range): Declare.
* config/sparc/sparc.md (UNSPECV_PROBE_STACK_RANGE): New constant.
(probe_stack_range): New insn.
From-SVN: r161749
|
|
instead of SYMBOL_REF rtx.
gcc/ChangeLog:
* explow.c (set_stack_check_libfunc): Adjust to accept name as a
string instead of SYMBOL_REF rtx.
* rtl.h (set_stack_check_libfunc): Move prototype from here...
* libfuncs.h: ...to here. Adjust for explow.c change.
ada/ChangeLog:
* gcc-interface/trans.c: Do not include rtl.h, insclude libfuncs.h.
(gigi): Adjust call to set_stack_check_libfunc.
From-SVN: r159900
|
|
* doc/tm.texi (STACK_CHECK_PROBE_LOAD): Delete.
* expr.h (STACK_CHECK_PROBE_LOAD): Likewise.
* explow.c (emit_stack_probe): Do not test STACK_CHECK_PROBE_LOAD.
* system.h (STACK_CHECK_PROBE_LOAD): Poison.
From-SVN: r155199
|
|
PR target/10127
PR ada/20548
* expr.h (anti_adjust_stack_and_probe): Declare.
* explow.c (anti_adjust_stack_and_probe): Make global, add ADJUST_BACK
parameter and rewrite head comment.
(allocate_dynamic_stack_space): Adjust call to above function.
* function.c (expand_function_end): Handle STACK_CHECK_MOVING_SP.
* tree.h (dwarf2out_args_size): Delete.
* dwarf2out.c (dwarf2out_args_size): Make static and move around.
(dwarf2out_args_size_adjust): Delete prototype and move around.
(dwarf2out_frame_debug_expr): Do not record arg size adjustments for
ACCUMULATE_OUTGOING_ARGS targets.
From-SVN: r154079
|
|
PR ada/20548
* explow.c (probe_stack_range): Fix typo.
* config/sparc/sparc.md (probe_stack): New expander.
From-SVN: r154061
|
|
PR target/10127
PR ada/20548
* expr.h (STACK_CHECK_PROBE_INTERVAL): Delete.
(STACK_CHECK_PROBE_INTERVAL_EXP): New macro.
(STACK_CHECK_MOVING_SP): Likewise.
* system.h (STACK_CHECK_PROBE_INTERVAL): Poison it.
* doc/tm.texi (Stack Checking): Delete STACK_CHECK_PROBE_INTERVAL.
Document STACK_CHECK_PROBE_INTERVAL_EXP and STACK_CHECK_MOVING_SP.
* doc/md.texi (Standard Pattern Names): Tweak entry of CHECK_STACK.
Document PROBE_STACK.
* explow.c (anti_adjust_stack_and_probe): New function.
(allocate_dynamic_stack_space): Do not directly allocate space if
STACK_CHECK_MOVING_SP, instead invoke above function.
(emit_stack_probe): Handle probe_stack insn.
(PROBE_INTERVAL): New macro.
(STACK_GROW_OPTAB): Likewise.
(STACK_GROW_OFF): Likewise.
(probe_stack_range): Use Pmode and memory_address consistently. Fix
loop condition in the small constant case. Rewrite in the general
case to be immune to wraparounds. Make sure the address of probes
is valid. Try to use [base + disp] addressing mode if possible.
* ira.c (setup_eliminable_regset): Set frame_pointer_needed if stack
checking is enabled and STACK_CHECK_MOVING_SP.
* rtlanal.c (may_trap_p_1) <MEM>: If stack checking is enabled,
return 1 for volatile references to the stack pointer.
* tree.c (build_common_builtin_nodes): Do not set ECF_NOTHROW on
__builtin_alloca if stack checking is enabled.
* unwind-dw2.c (uw_identify_context): Take into account whether the
context is that of a signal frame or not.
* config/i386/linux.h (STACK_CHECK_MOVING_SP): Define to 1.
* config/i386/linux64.h (STACK_CHECK_MOVING_SP): Likewise.
From-SVN: r153877
|
|
2009-10-26 Ben Elliston <bje@au.ibm.com>
Michael Meissner <meissner@linux.vnet.ibm.com>
Ulrich Weigand <uweigand@de.ibm.com>
* doc/tm.texi (TARGET_ADDR_SPACE_POINTER_MODE): Document.
(TARGET_ADDR_SPACE_ADDRESS_MODE): Likewise.
(TARGET_ADDR_SPACE_VALID_POINTER_MODE): Likewise.
* target.h (struct target_def): Add pointer_mode, address_mode,
and valid_pointer_mode to addr_space substructure.
* target-def.h (TARGET_ADDR_SPACE_POINTER_MODE): Define.
(TARGET_ADDR_SPACE_ADDRESS_MODE): Likewise.
(TARGET_ADDR_SPACE_VALID_POINTER_MODE): Likewise.
(TARGET_ADDR_SPACE_HOOKS): Add them.
* targhooks.c (target_default_pointer_address_modes_p): New function.
* target.h (target_default_pointer_address_modes_p): Add prototype.
* targhooks.c (default_addr_space_pointer_mode): New function.
(default_addr_space_address_mode): Likewise.
(default_addr_space_valid_pointer_mode): Likewise.
* targhooks.h (default_addr_space_pointer_mode): Add prototype.
(default_addr_space_address_mode): Likewise.
(default_addr_space_valid_pointer_mode): Likewise.
* output.h (default_valid_pointer_mode): Move to ...
* targhooks.h (default_valid_pointer_mode): ... here.
* varasm.c (default_valid_pointer_mode): Move to ...
* targhooks.c (default_valid_pointer_mode): ... here.
* varasm.c (output_constant): Use targetm.addr_space.valid_pointer_mode
instead of targetm.valid_pointer_mode.
* fold-const.c (fit_double_type): Use int_or_pointer_precision.
* tree.c (integer_pow2p): Likewise.
(tree_log2): Likewise.
(tree_floor_log2): Likewise.
(signed_or_unsigned_type_for): Support pointer type of different size.
(int_or_pointer_precision): New function.
* tree.h (int_or_pointer_precision): Add prototype.
* stor-layout.c (layout_type): Set TYPE_PRECISION for offset types.
* varasm.c (initializer_constant_valid_p): Use TYPE_PRECISION of
incoming pointer type instead of POINTER_SIZE.
* tree.c (build_pointer_type): Use appropriate pointer mode
instead of ptr_mode.
(build_reference_type): Likewise.
* expr.c (store_expr): Likewise.
(expand_expr_addr_expr): Likewise.
* tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
* cfgexpand.c (expand_debug_expr): Likewise.
* auto-inc-dec.c: Include "target.h".
(try_merge): Use appropriate address mode instead of Pmode.
(find_inc): Likewise.
* combine.c (find_split_point): Likewise.
* cselib.c (cselib_record_sets): Likewise.
* dse.c (replace_inc_dec): Likewise.
(canon_address): Likewise.
* var-tracking.c (replace_expr_with_values): Likewise.
(count_uses): Likewise.
(add_uses): Likewise.
(add_stores): Likewise.
* emit-rtl.c: Include "target.h".
(adjust_address_1): Use appropriate address mode instead of Pmode.
(offset_address): Likewise.
* explow.c (break_out_memory_refs): Likewise.
(memory_address_addr_space): Likewise.
(promote_mode): Likewise.
* expr.c (move_by_pieces): Likewise.
(emit_block_move_via_loop): Likewise.
(store_by_pieces): Likewise.
(store_by_pieces_1): Likewise.
(expand_assignment): Likewise.
(store_constructor): Likewise.
(expand_expr_addr_expr): Likewise.
(expand_expr_real_1): Likewise.
* cfgexpand.c (expand_debug_expr): Likewise.
* ifcvt.c (noce_try_cmove_arith): Likewise.
* regcprop.c (kill_autoinc_value): Likewise.
* regmove.c (try_auto_increment): Likewise.
* reload.c (find_reloads): Likewise.
(find_reloads_address): Likewise.
(find_reloads_address_1): Likewise.
* sched-deps.c: Include "target.h".
(sched_analyze_1): Use appropriate address mode instead of Pmode.
(sched_analyze_2): Likewise.
* sel-sched-dump.c: Include "target.h".
(debug_mem_addr_value): Use appropriate address mode instead of Pmode.
* stor-layout.c (layout_type): Likewise.
* tree-ssa-loop-ivopts.c (produce_memory_decl_rtl): Likewise.
(multiplier_allowed_in_address_p): Likewise.
(get_address_cost): Likewise.
* varasm.c (make_decl_rtl): Likewise.
* expr.c (expand_assignment): Always convert offsets to appropriate
address mode.
(store_expr): Likewise.
(store_constructor): Likewise.
(expand_expr_real_1): Likewise.
* reload.h (form_sum): Add MODE argument.
* reload.c (form_sum): Add MODE argument, use it instead of Pmode.
Update recursive calls.
(subst_indexed_address): Update calls to form_sum.
* tree-flow.h (addr_for_mem_ref): Add ADDRSPACE argument.
* tree-ssa-address.c: Include "target.h".
(templates): Replace by ...
(mem_addr_template_list): ... this new vector.
(TEMPL_IDX): Handle address space numbers.
(gen_addr_rtx): Add address mode argument, use it instead of Pmode.
(addr_for_mem_ref): Add ADDRSPACE argument. Use per-address-space
instead of global cache. Update call to gen_addr_rtx.
(valid_mem_ref_p): Update call to addr_for_mem_ref.
* expr.c (expand_expr_real_1): Update call to addr_for_mem_ref.
* rtl.h (convert_memory_address_addr_space): Add prototype.
(convert_memory_address): Define as macro.
* explow.c (convert_memory_address): Rename to ...
(convert_memory_address_addr_space): ... this. Add ADDRSPACE argument.
Use appropriate pointer and address modes instead of ptr_mode / Pmode.
Update recursive calls.
(memory_address_addr_space): Call convert_memory_address_addr_space.
* expmed.c (make_tree): Likewise.
* expr.c (expand_assignment): Likewise.
(expand_expr_addr_expr_1): Likewise. Also, add ADDRSPACE argument.
(expand_expr_addr_expr): Likewise. Also, update call.
* alias.c (find_base_value): Guard pointer size optimizations.
(find_base_term): Likewise.
* rtlanal.c (nonzero_bits1): Likewise.
(num_sign_bit_copies1): Likewise.
* simplify-rtx.c (simplify_unary_operation_1): Likewise.
* Makefile.in (tree-ssa-address.o): Add $(TARGET_H) dependency.
(emit-rtl.o): Likewise.
(auto-inc-dec.o): Likewise.
(sched-deps.o): Likewise.
Co-Authored-By: Michael Meissner <meissner@linux.vnet.ibm.com>
Co-Authored-By: Ulrich Weigand <uweigand@de.ibm.com>
From-SVN: r153573
|
|
2009-10-26 Ben Elliston <bje@au.ibm.com>
Michael Meissner <meissner@linux.vnet.ibm.com>
Ulrich Weigand <uweigand@de.ibm.com>
* doc/extend.texi (Named Address Spaces): New section.
* coretypes.h (addr_space_t): New type.
(ADDR_SPACE_GENERIC): New define.
(ADDR_SPACE_GENERIC_P): New macro.
* doc/tm.texi (Named Address Spaces): New section.
(TARGET_ADDR_SPACE_LEGITIMATE_ADDRESS_P): Document.
(TARGET_ADDR_SPACE_LEGITIMIZE_ADDRESS): Document.
(TARGET_ADDR_SPACE_SUBSET_P): Document.
(TARGET_ADDR_SPACE_CONVERT): Document.
* target.h (struct gcc_target): Add addr_space substructure.
* target-def.h (TARGET_ADDR_SPACE_LEGITIMATE_ADDRESS_P): Define.
(TARGET_ADDR_SPACE_LEGITIMIZE_ADDRESS): Likewise.
(TARGET_ADDR_SPACE_SUBSET_P): Likewise.
(TARGET_ADDR_SPACE_CONVERT): Likewise.
(TARGET_ADDR_SPACE_HOOKS): Likewise.
(TARGET_INITIALIZER): Initialize addr_space hooks.
* targhooks.c (default_addr_space_legitimate_address_p): New function.
(default_addr_space_legitimize_address): Likewise.
(default_addr_space_subset_p): Likewise.
(default_addr_space_convert): Likewise.
* targhooks.h (default_addr_space_legitimate_address_p): Add prototype.
(default_addr_space_legitimize_address): Likewise.
(default_addr_space_subset_p): Likewise.
(default_addr_space_convert): Likewise.
* doc/rtl.texi (MEM_ADDR_SPACE): Document.
* rtl.h (mem_attrs): Add ADDRSPACE memory attribute.
(MEM_ADDR_SPACE): New macro.
* emit-rtl.c (get_mem_attrs): Add ADDRSPACE argument and set
address space memory attribute.
(mem_attrs_htab_hash): Handle address space memory attribute.
(mem_attrs_htab_eq): Likewise.
(set_mem_attributes_minus_bitpos): Likewise.
(set_mem_alias_set): Likewise.
(set_mem_align): Likewise.
(set_mem_expr): Likewise.
(set_mem_offset): Likewise.
(set_mem_size): Likewise.
(adjust_address_1): Likewise.
(offset_address): Likewise.
(widen_memoy_address): Likewise.
(get_spill_slot_decl): Likewise.
(set_mem_attrs_for_spill): Likewise.
(set_mem_addr_space): New function.
* emit-rtl.h (set_mem_addr_space): Add prototype.
* print-rtl.c (print_rtx): Print address space memory attribute.
* expr.c (expand_assignment): Set address space memory attribute
of generated MEM RTXes as appropriate.
(expand_expr_real_1): Likewise.
* cfgexpand.c (expand_debug_expr): Likewise.
* tree-ssa-loop-ivopts.c (produce_memory_decl_rtl): Likewise.
* tree.h (struct tree_base): Add address_space bitfield. Reduce
size of "spare" bitfield.
(TYPE_ADDR_SPACE): New macro.
(ENCODE_QUAL_ADDR_SPACE): Likewise.
(DECODE_QUAL_ADDR_SPACE): Likewise.
(CLEAR_QUAL_ADDR_SPACE): Likewise.
(KEEP_QUAL_ADDR_SPACE): Likewise.
(TYPE_QUALS): Encode type address space.
(TYPE_QUALS_NO_ADDR_SPACE): New macro.
* tree.c (set_type_quals): Set type address space.
(build_array_type): Inherit array address space from element type.
* print-tree.c (print_node_brief): Print type address space.
(print_node): Likewise.
* tree-pretty-print.c (dump_generic_node): Likewise.
* explow.c (memory_address): Rename to ...
(memory_address_addr_space): ... this. Add ADDRSPACE argument.
Use address-space aware variants of memory address routines.
* recog.c (memory_address_p): Rename to ...
(memory_address_addr_space_p): ... this. Add ADDSPACE argument.
Use address-space aware variants of memory address routines.
(offsettable_address_p): Rename to ...
(offsettable_address_addr_space_p): ... this. Add ADDRSPACE argument.
Use address-space aware variants of memory address routines.
* reload.c (strict_memory_address_p): Rename to ...
(strict_memory_address_addr_space_p): ... this. Add ADDSPACE argument.
Use address-space aware variants of memory address routines.
(maybe_memory_address_p): Rename to ...
(maybe_memory_address_addr_space_p): ... this. Add ADDSPACE argument.
Use address-space aware variants of memory address routines.
* expr.h (memory_address_addr_space): Add prototype.
(memory_address): Define as macro.
* recog.h (memory_address_addr_space_p): Add prototype.
(memory_address_p): Define as macro.
(offsettable_address_addr_space_p): Add prototype.
(offsettable_address_p): Define as macro.
(strict_memory_address_addr_space_p): Add prototype.
(strict_memory_address_p): Define as macro.
* combine.c (find_split_point): Use address-space aware variants
of memory address routines.
* emit-rtl.c (operand_subword): Likewise.
(change_address_1): Likewise.
(adjust_address_1): Likewise.
(offset_address): Likewise.
* expr.c (emit_move_insn): Likewise.
(expand_assignment): Likewise.
(expand_expr_real_1): Likewise.
* recog.c (verify_changes): Likewise.
(general_operand): Likewise.
(offsettable_memref_p): Likewise.
(offsettable_nonstrict_memref_p): Likewise.
(constrain_operands): Likewise.
* reload.c (get_secondary_mem): Likewise.
(find_reloads_toplev): Likewise.
(find_reloads_address): Likewise.
(find_reloads_subreg_address): Likewise.
* reload1.c (reload): Likewise.
* rtlhooks.c (gen_lowpart_if_possible): Likewise.
* rtl.h (address_cost): Add ADDRSPACE argument.
* rtlanal.c (address_cost): Add ADDRSPACE argument. Use address-space
aware variant of memory address routines.
* loop-invariant.c (create_new_invariant): Update address_cost call.
* tree-ssa-loop-ivopts.c (computation_cost): Likewise.
* fwprop.c (should_replace_address): Add ADDRSPACE argument.
Use address-space aware variant of memory address routines.
(propagate_rtx_1): Update call to should_replace_address.
* tree-flow.h (multiplier_allowed_in_address_p): Add ADDRSPACE
argument.
* tree-ssa-loop-ivopts.c (multiplier_allowed_in_address_p): Add
ADDRSPACE argument. Use per-address-space instead of global cache.
Use address-space aware variant of memory address routines.
(get_address_cost): Likewise.
(get_computation_cost_at): Update calls.
* tree-ssa-address.c (valid_mem_ref_p): Add ADDRSPACE argument.
Use address-space aware variant of memory address routines.
(create_mem_ref_raw): Update call to valid_mem_ref_p.
(most_expensive_mult_to_index): Update call to
multiplier_allowed_in_address_p.
* dwarf2out.c (modified_type_die): Output DW_AT_address_class
attribute to indicate named address spaces.
* varasm.c (get_variable_section): DECLs in named address spaces
cannot be "common".
* reload.c (find_reloads_address): Do not use LEGITIMIZE_RELOAD_ADDRESS
for addresses in a non-generic address space.
* expr.c (emit_block_move_hints): Do not use libcalls for
memory in non-generic address spaces.
(clear_storage_hints): Likewise.
(expand_assignment): Likewise.
* fold-const.c (operand_equal_p): Expressions refering to different
address spaces are not equivalent.
* rtl.c (rtx_equal_p_cb): MEMs refering to different address
spaces are not equivalent.
(rtx_equal_p): Likewise.
* cse.c (exp_equiv_p): Likewise.
* jump.c (rtx_renumbered_equal_p): Likewise.
* reload.c (operands_match_p): Likewise.
* alias.c (nonoverlapping_memrefs_p): MEMs refering to different
address spaces may alias.
(true_dependence): Likewise.
(canon_true_dependence): Likewise.
(write_dependence_p): Likewise.
* dse.c (canon_address): Handle named address spaces.
* ifcvt.c (noce_try_cmove_arith): Likewise.
* tree.def (ADDR_SPACE_CONVERT_EXPR): New tree code.
* expr.c (expand_expr_real_2): Expand ADDR_SPACE_CONVERT_EXPR.
* convert.c (convert_to_pointer): Generate ADDR_SPACE_CONVERT_EXPR
to handle conversions between different address spaces.
* fold-const.c (fold_convert_loc): Likewise.
(fold_unary_loc): Handle ADDR_SPACE_CONVERT_EXPR.
* tree-pretty-print.c (dump_generic_node): Likewise.
* gimple-pretty-print.c (dump_unary_rhs): Likewise.
* tree-cfg.c (verify_gimple_assign_unary): Likewise.
* tree-inline.c (estimate_operator_cost): Likewise.
* tree-ssa.c (useless_type_conversion_p): Conversions between pointers
to different address spaces are not useless.
Co-Authored-By: Michael Meissner <meissner@linux.vnet.ibm.com>
Co-Authored-By: Ulrich Weigand <uweigand@de.ibm.com>
From-SVN: r153572
|
|
2009-09-01 Richard Guenther <rguenther@suse.de>
* tree.c (tree_expr_size): New function.
* tree.h (tree_expr_size): Declare.
* rtlanal.c (rtx_addr_can_trap_p_1): Adjust comment.
* builtins.c (fold_builtin_memory_op): Use tree_expr_size.
* langhooks.c (lhd_expr_size): Remove.
* langhooks.h (struct lang_hooks): Remove expr_size.
* explow.c (expr_size): Use tree_expr_size.
(int_expr_size): Likewise.
* langhooks-def.h (lhd_expr_size): Remove.
(LANG_HOOKS_EXPR_SIZE): Likewise.
(LANG_HOOKS_INITIALIZER): Adjust.
cp/
* cp-objcp-common.c (cp_expr_size): Use tree_expr_size.
* cp-objcp-common.h (LANG_HOOKS_EXPR_SIZE): Do not define.
From-SVN: r151261
|
|
2009-08-12 Paolo Bonzini <bonzini@gnu.org>
* doc/tm.texi (TARGET_PROMOTE_FUNCTION_MODE): Add documentation
for for_return == 2.
* function.c (assign_parm_setup_reg): Use for_return == 2, improve
comments.
* calls.c (expand_call): Fix typo.
* explow.c (promote_decl_mode): Use for_return == 2 for RESULT_DECL
and PARM_DECL.
* stmt.c (expand_value_return): Use promote_function_mode to copy out
of pseudo.
* targhooks.c (default_promote_function_mode): Handle for_return == 2.
* config/cris/cris.c (cris_promote_function_mode): Likewise.
* config/mmix/mmix.c (mmix_promote_function_mode): Likewise.
* config/pa/pa.c (pa_promote_function_mode): Likewise.
From-SVN: r150700
|
|
From-SVN: r150525
|
|
2009-08-03 Andreas Krebbel <krebbel1@de.ibm.com>
* explow.c (promote_mode): Mark TYPE and PUNSIGNEDP as
possibly unused.
From-SVN: r150367
|
|
* explow.c (promote_function_mode): Remove assert.
* config/sh/sh.c (sh_promote_function_mode): Declare.
From-SVN: r150344
|
|
2009-04-17 Paolo Bonzini <bonzini@gnu.org>
* expr.c (store_constructor): Use promote_decl_mode. Remove
now write-only variable unsignedp.
(expand_expr_real_1): Use promote_decl_mode.
* expr.h (promote_function_mode, promote_decl_mode): New.
(promote_mode): Remove last argument.
* function.c (assign_temp): Drop last argument of promote_mode.
(assign_parm_find_data_types): Use promote_function_mode.
(assign_parm_setup_reg): Likewise.
(expand_function_end): Use promote_function_mode.
* calls.c (initialize_argument_information): Use promote_function_mode.
(precompute_arguments): Use promote_mode instead of checking if
only PROMOTE_FUNCTION_MODE is defined.
(expand_call): When making sibcall decisions, use promote_function_mode.
Below, remove an if for targetm.calls.promote_function_return and
and use promote_function_mode.
(emit_library_call_value_1): Use promote_function_mode, fix bug
where promote_mode was passed FOR_CALL == 0 for a return value in an
assertion.
* cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
* explow.c (promote_function_mode, promote_decl_mode): New.
(promote_mode): Keep only the FOR_CALL == 0 case.
* combine.c (setup_incoming_promotion): Remove test of
promote_function_args. Use promote_function_mode.
* stmt.c (expand_value_return): Use promote_decl_mode.
(expand_decl): Use promote_decl_mode.
* expr.c (store_constructor): Use promote_decl_mode. Remove
now write-only variable unsignedp.
(expand_expr_real_1): Use promote_decl_mode.
* expr.h (promote_function_mode, promote_decl_mode): New.
(promote_mode): Remove last argument.
* function.c (assign_temp): Drop last argument of promote_mode.
(assign_parm_find_data_types): Use promote_function_mode.
(assign_parm_setup_reg): Likewise.
(expand_function_end): Use promote_function_mode.
* calls.c (initialize_argument_information): Use promote_function_mode.
(precompute_arguments): Use promote_mode instead of checking if
only PROMOTE_FUNCTION_MODE is defined.
(expand_call): When making sibcall decisions, use promote_function_mode.
Below, remove an if for targetm.calls.promote_function_return and
and use promote_function_mode.
(emit_library_call_value_1): Use promote_function_mode, fix bug
where promote_mode was passed FOR_CALL == 0 for a return value in an
assertion.
* cfgexpand.c (expand_one_register_var): Use promote_decl_mode.
* explow.c (promote_function_mode, promote_decl_mode): New.
(promote_mode): Keep only the FOR_CALL == 0 case.
* combine.c (setup_incoming_promotion): Remove test of
promote_function_args. Use promote_function_mode.
* stmt.c (expand_value_return): Use promote_decl_mode.
(expand_decl): Use promote_decl_mode.
* explow.c (promote_function_mode): Just call the target hook.
* targhooks.c (default_promote_function_mode,
default_promote_function_mode_always_promote): New.
* targhooks.h (default_promote_function_mode,
default_promote_function_mode_always_promote): Declare.
* target.h (promote_function_args, promote_function_return): Remove.
(promote_function_mode): New.
* target-def.h (TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN): Remove.
(TARGET_PROMOTE_FUNCTION_MODE): New.
(TARGET_CALLS): Adjust.
* system.h (TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN, PROMOTE_FUNCTION_MODE): Poison.
* config/s390/s390.h (PROMOTE_FUNCTION_MODE): Move...
* config/s390/s390.c (s390_promote_function_mode): ... here,
with pointer handling.
(TARGET_PROMOTE_FUNCTION_MODE): Define.
(TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
* config/sparc/sparc.h (PROMOTE_FUNCTION_MODE): Move...
* config/sparc/sparc.c (sparc_promote_function_mode): ... here,
with pointer handling.
(TARGET_PROMOTE_FUNCTION_MODE): Define.
(TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
* config/sh/sh-protos.h (sh_promote_function_mode): New.
* config/sh/sh.c (sh_promote_function_mode): New.
(TARGET_PROMOTE_FUNCTION_MODE): Define.
(TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
* config/cris/cris.h (PROMOTE_FUNCTION_MODE): Move...
* config/cris/cris.c (cris_promote_function_mode): ... here.
(TARGET_PROMOTE_FUNCTION_MODE): Define.
(TARGET_PROMOTE_FUNCTION_ARGS): Remove.
* config/mmix/mmix.h (PROMOTE_FUNCTION_MODE): Move...
* config/mmix/mmix.c (mmix_promote_function_mode): ... here.
(TARGET_PROMOTE_FUNCTION_MODE): Define.
(TARGET_PROMOTE_FUNCTION_ARGS): Remove.
* config/arm/arm.h (PROMOTE_FUNCTION_MODE): Move...
* config/arm/arm.c (arm_promote_function_mode): ... here, without complex
type handling.
(TARGET_PROMOTE_FUNCTION_MODE): Define.
(TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN): Remove.
* config/pa/pa.c (pa_promote_function_mode): New.
(TARGET_PROMOTE_FUNCTION_MODE): Define.
(TARGET_PROMOTE_FUNCTION_RETURN): Remove.
* config/alpha/alpha.c (TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN): Remove.
(TARGET_PROMOTE_FUNCTION_MODE): Define equivalently.
* config/xtensa/xtensa.c: Likewise.
* config/stormy16/stormy16.c: Likewise.
* config/iq2000/iq2000.c: Likewise.
* config/rs6000/rs6000.c: Likewise.
* config/picochip/picochip.c: Likewise.
* config/arc/arc.c: Likewise.
* config/mcore/mcore.c: Likewise.
* config/score/score.c: Likewise.
* config/mips/mips.c: Likewise.
* config/bfin/bfin.c: Likewise.
* config/ia64/ia64.c: Likewise (disabled though).
* config/frv/frv.h: Remove pointless remark.
* doc/tm.texi (PROMOTE_FUNCTION_MODE,
TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN): Consolidate into...
(TARGET_PROMOTE_FUNCTION_MODE): ... this.
From-SVN: r150336
|
|
2009-06-22 Shujing Zhao <pearly.zhao@oracle.com>
* alias.c: Use REG_P, MEM_P, CONST_INT_P, LABEL_P, CALL_P, NOTE_P and
JUMP_TABLE_DATA_P predicates where applicable.
* auto-inc-dec.c: Ditto.
* builtins.c: Ditto.
* caller-save.c: Ditto.
* calls.c: Ditto.
* cfgcleanup.c: Ditto.
* cfglayout.c: Ditto.
* cfgrtl.c: Ditto.
* combine.c: Ditto.
* combine-stack-adj.c: Ditto.
* cse.c: Ditto.
* cselib.c: Ditto.
* dbxout.c: Ditto.
* df-scan.c: Ditto.
* dse.c: Ditto.
* dwarf2asm.c: Ditto.
* dwarf2out.c: Ditto.
* emit-rtl.c: Ditto.
* except.c: Ditto.
* explow.c: Ditto.
* expmed.c: Ditto.
* expr.c: Ditto.
* final.c: Ditto.
* function.c: Ditto.
* fwprop.c: Ditto.
* gcse.c: Ditto.
* genpreds.c: Ditto.
* genrecog.c: Ditto.
* ifcvt.c: Ditto.
* ira-costs.c: Ditto.
* ira-lives.c: Ditto.
* jump.c: Ditto.
* loop-iv.c: Ditto.
* lower-subreg.c: Ditto.
* modulo-sched.c: Ditto.
* optabs.c: Ditto.
* postreload.c: Ditto.
* print-rtl.c: Ditto.
* recog.c: Ditto.
* reginfo.c: Ditto.
* regmove.c: Ditto.
* reload1.c: Ditto.
* reload.c: Ditto.
* reorg.c: Ditto.
* rtlanal.c: Ditto.
* rtl.c: Ditto.
* sched-vis.c: Ditto.
* sdbout.c: Ditto.
* sel-sched-ir.c: Ditto.
* simplify-rtx.c: Ditto.
* targhooks.c: Ditto.
* var-tracking.c: Ditto.
* vmsdbgout.c: Ditto.
From-SVN: r148786
|
|
2009-05-04 Paolo Bonzini <bonzini@gnu.org>
* doc/tm.texi (LEGITIMIZE_ADDRESS): Revise documentation.
* gcc/defaults.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/explow.c (memory_address): Use target hook.
* gcc/targhooks.c (default_legitimize_address): New.
* gcc/targhooks.h (default_legitimize_address): New.
* gcc/target.h (legitimize_address): New.
* gcc/target-def.h (TARGET_LEGITIMIZE_ADDRESS): New.
(TARGET_INITIALIZER): Include it.
* gcc/system.h (LEGITIMIZE_ADDRESS): Poison.
* config/bfin/bfin-protos.h (legitimize_address): Remove.
* config/bfin/bfin.c (legitimize_address): Remove.
* config/bfin/bfin.h (LEGITIMIZE_ADDRESS): Remove.
* config/m68hc11/m68hc11-protos.h (m68hc11_legitimize_address): Remove.
* config/m68hc11/m68hc11.c (m68hc11_legitimize_address): Remove.
* config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Remove.
* gcc/config/arm/arm.h (LEGITIMIZE_ADDRESS, ARM_LEGITIMIZE_ADDRESS,
THUMB_LEGITIMIZE_ADDRESS, THUMB2_LEGITIMIZE_ADDRESS): Delete.
* gcc/config/s390/s390.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/m32c/m32c.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/sparc/sparc.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/m32r/m32r.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/i386/i386.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/sh/sh.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/avr/avr.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/m68hc11/m68hc11.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/iq2000/iq2000.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/mn10300/mn10300.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/m68k/m68k.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/score/score.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/pa/pa.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/mips/mips.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/alpha/alpha.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/frv/frv.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/spu/spu.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/xtensa/xtensa.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/cris/cris.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/rs6000/rs6000.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/picochip/picochip.h (LEGITIMIZE_ADDRESS): Delete.
* gcc/config/s390/s390-protos.h (legitimize_address): Delete.
* gcc/config/m32c/m32c-protos.h (m32c_legitimize_address): Delete.
* gcc/config/sparc/sparc-protos.h (legitimize_address): Delete.
* gcc/config/i386/i386-protos.h (legitimize_address): Delete.
* gcc/config/avr/avr-protos.h (legitimize_address): Delete.
* gcc/config/mn10300/mn10300-protos.h (legitimize_address): Delete.
* gcc/config/score/score-protos.h (score_legitimize_address): Delete.
* gcc/config/arm/arm-protos.h (arm_legitimize_address,
(thumb_legitimize_address): Delete.
* gcc/config/pa/pa-protos.h (hppa_legitimize_address): Delete.
* gcc/config/mips/mips-protos.h (mips_legitimize_address): Delete.
* gcc/config/alpha/alpha-protos.h (alpha_legitimize_address): Delete.
* gcc/config/frv/frv-protos.h (frv_legitimize_address): Delete.
* gcc/config/spu/spu-protos.h (spu_legitimize_address): Delete.
* gcc/config/xtensa/xtensa-protos.h (xtensa_legitimize_address): Delete.
* gcc/config/rs6000/rs6000-protos.h (rs6000_legitimize_address): Delete.
* config/arm/arm.c (arm_legitimize_address): Maybe call Thumb version.
* config/m32c/m32c.c (m32c_legitimize_address): Standardize.
* config/m32r/m32r.c (m32r_legitimize_address): New.
* config/m68k/m68k.c (m68k_legitimize_address): New.
* config/score/score.c (score_legitimize_address): Standardize.
* config/score/score3.c (score3_legitimize_address): Standardize.
* config/score/score3.h (score3_legitimize_address): Adjust.
* config/score/score7.c (score7_legitimize_address): Standardize.
* config/score/score7.h (score7_legitimize_address): Adjust.
* config/sh/sh.c (sh_legitimize_address): New.
* config/iq2000/iq2000.c (iq2000_legitimize_address): New.
* gcc/config/s390/s390.c (legitimize_address): Rename to...
(s390_legitimize_address): ... this.
* gcc/config/sparc/sparc.c (legitimize_address): Rename to...
(sparc_legitimize_address): ... this.
* gcc/config/i386/i386.c (legitimize_address): Rename to...
(ix86_legitimize_address): ... this.
* gcc/config/avr/avr.c (legitimize_address): Rename to...
(avr_legitimize_address): ... this.
* gcc/config/mn10300/mn10300.c (legitimize_address): Rename to...
(mn10300_legitimize_address): ... this.
* config/alpha/alpha.c (alpha_legitimize_address): Wrap...
(alpha_legitimize_address_1): ... the old alpha_legitimize_address.
(alpha_expand_mov): Adjust call.
* config/frv/frv.c (frv_legitimize_address): Return x on failure.
* config/spu/spu.c (spu_legitimize_address): Likewise.
* config/xtensa/xtensa.c (xtensa_legitimize_address): Likewise.
* config/rs6000/rs6000.c (rs6000_legitimize_address): Likewise.
From-SVN: r147098
|
|
2009-03-28 Paolo Bonzini <bonzini@gnu.org>
* c-common.c (c_expand_expr, c_staticp): Remove.
* c-common.def (COMPOUND_LITERAL_EXPR): Delete.
* c-common.h (emit_local_var, c_staticp, COMPOUND_LITERAL_EXPR_DECL,
COMPOUND_LITERAL_EXPR_DECL_EXPR): Remove.
* c-gimplify.c (gimplify_compound_literal_expr,
optimize_compound_literals_in_ctor): Remove.
(c_gimplify_expr): Remove COMPOUND_LITERAL_EXPR handling.
* c-objc-common.h (LANG_HOOKS_STATICP): Remove.
* c-semantics.c (emit_local_var): Remove.
* langhooks-def.h (lhd_expand_expr): Remove.
* langhooks.c (lhd_expand_expr): Remove.
* langhooks.h (LANG_HOOKS_DEF): Remove LANG_HOOKS_EXPAND_EXPR.
* expr.c (expand_expr_real_1): Move COMPOUND_LITERAL_EXPR
handling from c-semantics.c; don't call into langhook.
(expand_expr_addr_expr_1): Check that we don't get non-GENERIC trees.
* gimplify.c (gimplify_compound_literal_expr,
optimize_compound_literals_in_ctor): Move from c-gimplify.c.
(gimplify_init_constructor): Call optimize_compound_literals_in_ctor.
(gimplify_modify_expr_rhs, gimplify_expr): Handle COMPOUND_LITERAL_EXPR
as was done in c-gimplify.c.
* tree.c (staticp): Move COMPOUND_LITERAL_EXPR handling from c_staticp.
* tree.h (COMPOUND_LITERAL_EXPR_DECL, COMPOUND_LITERAL_EXPR_DECL_EXPR):
Move from c-common.h.
* tree.def (COMPOUND_LITERAL_EXPR): Move from c-common.def.
* tree.c (staticp): Do not call langhook.
* langhooks.c (lhd_staticp): Delete.
* langhooks-def.h (lhd_staticp): Delete prototype.
(LANG_HOOKS_STATICP): Delete.
(LANG_HOOKS_INITIALIZER): Delete LANG_HOOKS_STATICP.
* doc/c-tree.texi (Expression nodes): Refer to DECL_EXPRs
instead of DECL_STMTs.
cp:
2009-03-28 Paolo Bonzini <bonzini@gnu.org>
* cp/cp-objcp-common.h (LANG_HOOKS_STATICP): Remove.
* cp/cp-objcp-common.c (cxx_staticp): Remove.
* cp/cp-tree.h (cxx_staticp): Remove.
From-SVN: r145256
|
|
From-SVN: r144324
|
|
passed to mark_reg_pointer.
* emit-rtl.c (set_reg_attrs_from_value): Fix invalid alignment
information passed to mark_reg_pointer.
* explow.c (force_reg): Likewise.
From-SVN: r140318
|
|
PR ada/20548
* common.opt (-fstack-check): Do not declare the variable here.
(-fstack-check=): New option variant.
* doc/invoke.texi (Code Gen Options): Document it.
* expr.h (STACK_OLD_CHECK_PROTECT): New macro.
(STACK_CHECK_PROTECT): Bump to 3 pages if DWARF-2 EH is used.
(STACK_CHECK_STATIC_BUILTIN): New macro.
* doc/tm.texi (Stack Checking): Document STACK_CHECK_STATIC_BUILTIN.
* opts.c: Include expr.h.
(common_handle_option) <OPT_fold_stack_check_>: New case.
<OPT_fstack_check>: Likewise.
* calls.c (initialize_argument_information): Use TYPE_SIZE_UNIT
consistently in the test for variable-sized types. Adjust for
new behaviour of flag_stack_check.
* explow.c: Include except.h.
(allocate_dynamic_stack_space): Do not take into account
STACK_CHECK_MAX_FRAME_SIZE for static builtin stack checking.
* function.c (gimplify_parameters): Use DECL_SIZE_UNIT in the test
for variable-sized parameters. Treat all parameters whose size is
greater than STACK_CHECK_MAX_VAR_SIZE as variable-sized if generic
stack checking is enabled.
* gimplify.c (gimplify_decl_expr): Treat non-static objects whose
size is greater than STACK_CHECK_MAX_VAR_SIZE as variable-sized
if generic stack checking is enabled.
(expand_function_end): Adjust for new behaviour of flag_stack_check.
* reload1.c (reload): Likewise.
* stmt.c (expand_decl): Assert that all automatic variables have
fixed size at this point and remove dead code.
* flags.h (stack_check_type): New enumeration type.
(flag_stack_check): Declare.
* toplev.c (flag_stack_check): New global variable.
* Makefile.in (opts.o): Add dependency on EXPR_H.
(explow.o): Add dependency on except.h.
ada/
* gcc-interface/decl.c (gnat_to_gnu_entity): Use DECL_SIZE_UNIT in the
setjmp test consistently. Adjust for new behaviour of flag_stack_check.
* gcc-interface/utils2.c (build_call_alloc_dealloc): Remove redundant
test of flag_stack_check. Adjust for new behaviour of flag_stack_check.
From-SVN: r139159
|
|
* df-problems.c (df_set_note): Avoid C++ keywords.
* df-scan.c (df_ref_change_reg_with_loc_1): Likewise.
* dse.c (record_store, remove_useless_values): Likewise.
* emit-rtl.c (gen_reg_rtx, update_reg_offset, gen_rtx_REG_offset,
gen_reg_rtx_offset, operand_subword, change_address_1,
change_address, adjust_address_1, offset_address,
widen_memory_access, emit_copy_of_insn_after): Likewise.
* explow.c (round_push, allocate_dynamic_stack_space): Likewise.
* fwprop.c (should_replace_address, propagate_rtx_1,
propagate_rtx, try_fwprop_subst, forward_propagate_and_simplify):
Likewise.
* gcse.c (cprop_jump, find_implicit_sets, bypass_block,
gcse_emit_move_after, update_ld_motion_stores): Likewise.
* lcm.c (compute_insert_delete, pre_edge_lcm,
compute_rev_insert_delete, pre_edge_rev_lcm): Likewise.
* lower-subreg.c (resolve_reg_notes): Likewise.
* mode-switching.c (optimize_mode_switching): Likewise.
From-SVN: r137848
|
|
gcc/
* rtl.h (emit_clobber, gen_clobber, emit_use, gen_use): Declare.
* emit-rtl.c (emit_clobber, gen_clobber, emit_use, gen_use): New
functions. Do not emit uses and clobbers of CONCATs; individually
use and clobber their operands.
* builtins.c (expand_builtin_setjmp_receiver): Use emit_clobber,
gen_clobber, emit_use and gen_use.
(expand_builtin_longjmp, expand_builtin_nonlocal_goto): Likewise.
(expand_builtin_return): Likewise.
* cfgbuild.c (count_basic_blocks): Likewise.
* cfgrtl.c (rtl_flow_call_edges_add): Likewise.
* explow.c (emit_stack_restore): Likewise.
* expmed.c (extract_bit_field_1): Likewise.
* expr.c (convert_move, emit_move_complex_parts): Likewise.
(emit_move_multi_word, store_constructor): Likewise.
* function.c (do_clobber_return_reg, do_use_return_reg): Likewise.
(thread_prologue_and_epilogue_insns): Likewise.
* lower-subreg.c (resolve_simple_move): Likewise.
* optabs.c (widen_operand, expand_binop): Likewise.
(expand_doubleword_bswap, emit_no_conflict_block): Likewise.
* reload.c (find_reloads): Likewise.
* reload1.c (eliminate_regs_in_insn): Likewise.
* stmt.c (expand_nl_goto_receiver): Likewise.
* config/alpha/alpha.md (builtin_longjmp): Likewise.
* config/arc/arc.md (*movdi_insn, *movdf_insn): Likewise.
* config/arm/arm.c (arm_load_pic_register): Likewise.
(thumb1_expand_epilogue, thumb_set_return_address): Likewise.
* config/arm/arm.md (untyped_return): Likewise.
* config/arm/linux-elf.h (PROFILE_HOOK): Likewise.
* config/avr/avr.c (expand_prologue): Likewise.
* config/bfin/bfin.c (do_unlink): Likewise.
* config/bfin/bfin.md (<optab>di3, adddi3, subdi3): Likewise.
* config/cris/cris.c (cris_expand_prologue): Likewise.
* config/darwin.c (machopic_indirect_data_reference): Likewise.
(machopic_legitimize_pic_address): Likewise.
* config/frv/frv.c (frv_frame_access, frv_expand_epilogue): Likewise.
(frv_ifcvt_modify_insn, frv_expand_mdpackh_builtin): Likewise.
* config/i386/i386.c (ix86_expand_vector_move_misalign): Likewise.
(ix86_expand_convert_uns_didf_sse): Likewise.
(ix86_expand_vector_init_general): Likewise.
* config/ia64/ia64.md (eh_epilogue): Likewise.
* config/iq2000/iq2000.c (iq2000_expand_epilogue): Likewise.
* config/m32c/m32c.c (m32c_emit_eh_epilogue): Likewise.
* config/m32r/m32r.c (m32r_reload_lr): Likewise.
(config/iq2000/iq2000.c): Likewise.
* config/mips/mips.md (fixuns_truncdfsi2): Likewise.
(fixuns_truncdfdi2, fixuns_truncsfsi2, fixuns_truncsfdi2): Likewise.
(builtin_longjmp): Likewise.
* config/mn10300/mn10300.md (call, call_value): Likewise.
* config/pa/pa.md (nonlocal_goto, nonlocal_longjmp): Likewise.
* config/pdp11/pdp11.md (abshi2): Likewise.
* config/rs6000/rs6000.c (rs6000_emit_move): Likewise.
* config/s390/s390.c (s390_emit_prologue): Likewise.
* config/s390/s390.md (movmem_long, setmem_long): Likewise.
(cmpmem_long, extendsidi2, zero_extendsidi2, udivmoddi4): Likewise.
(builtin_setjmp_receiver, restore_stack_nonlocal): Likewise.
* config/sh/sh.c (prepare_move_operands): Likewise.
(output_stack_adjust, sh_expand_epilogue): Likewise.
(sh_set_return_address, sh_expand_t_scc): Likewise.
* config/sparc/sparc.c (load_pic_register): Likewise.
* config/sparc/sparc.md (untyped_return, nonlocal_goto): Likewise.
* config/spu/spu.c (spu_expand_epilogue): Likewise.
* config/v850/v850.c (expand_epilogue): Likewise.
From-SVN: r136251
|
|
PR testsuite/35843
* cfgexpand.c (pass_expand): Turn into RTL pass.
* passes.c (execute_one_pass): Do pass typechecking after execution.
* tree-pass.h (pass_expand): Turn into RTL pass.
* function.h (struct rtl_data): Move here fields
accesses_prior_frames, calls_eh_return, saves_all_registers,
has_nonlocal_goto, has_asm_statement, is_thunk,
all_throwers_are_sibcalls, limit_stack, profile, uses_const_pool,
uses_pic_offset_table, uses_eh_lsda, tail_call_emit,
arg_pointer_save_area_init from struct function; turn into bool.
(struct function): Move
calls_eh_return, saves_all_registers, has_nonlocal_goto,
has_asm_statement, is_thunk, all_throwers_are_sibcalls, limit_stack,
profile, uses_const_pool, uses_pic_offset_table, uses_eh_lsda,
tail_call_emit, arg_pointer_save_area_init
into struct rtl_data. Remove recursive_call_emit and gimplified flags.
(current_function_returns_struct, current_function_returns_pcc_struct,
current_function_calls_setjmp, current_function_calls_alloca,
current_function_accesses_prior_frames,
current_function_calls_eh_return, current_function_is_thunk,
current_function_stdarg, current_function_profile,
current_function_limit_stack, current_function_uses_pic_offset_table,
current_function_uses_const_pool, current_function_has_nonlocal_label,
current_function_saves_all_registers,
current_function_has_nonlocal_goto,
current_function_has_asm_statement): Remove accesor macros.
* ra-conflict.c (global_conflicts): Update.
* tree-tailcall.c (suitable_for_tail_opt_p): Update.
(suitable_for_tail_call_opt_p): Update.
* builtins.c (expand_builtin_return_addr): Update.
(expand_builtin_setjmp_setup): Update.
(expand_builtin_nonlocal_goto): Update.
* final.c (final_start_function): Update.
(profile_function): Update.
(leaf_function_p): Update.
(only_leaf_regs_used): Update.
* df-scan.c (df_get_exit_block_use_set): Update.
* dojump.c (clear_pending_stack_adjust): Update.
* tree-stdarg.c (gate_optimize_stdarg): Update.
* gimple-low.c (lower_function_body): Update.
* global.c (compute_regsets): Update.
(global_alloc): Update.
* dwarf2out.c (dwarf2out_begin_prologue): Update.
* expr.c (expand_assignment): Update.
* dse.c (dse_step0): Update.
(dse_step1): Update.
* c-decl.c (store_parm_decls): Update.
* local-alloc.c (combine_regs): Update.
(find_free_reg): Update.
* function.c (assign_parms_augmented_arg_list): Update.
(assign_parm_find_data_types): Update.
(assign_parms): Update.
(allocate_struct_function): Update.
(expand_function_start): Update.
(expand_function_end): Update.
(get_arg_pointer_save_area): Update.
(thread_prologue_and_epilogue_insns): Update.
(rest_of_match_asm_constraints): Update.
* stor-layout.c (variable_size): Update.
* gcse.c (gcse_main): Update.
(bypass_jumps): Update.
* gimplify.c (gimplify_function_tree): Update.
* calls.c (emit_call_1): Update.
(expand_call): Update.
* bt-load.c (compute_defs_uses_and_gen): Update.
* except.c (sjlj_assign_call_site_values): Update.
(sjlj_emit_function_enter): Update.
(can_throw_external): Update.
(set_nothrow_function_flags): Update.
(expand_builtin_unwind_init): Update.
(expand_eh_return): Update.
(convert_to_eh_region_ranges): Update.
(output_function_exception_table): Update.
* emit-rtl.c (gen_tmp_stack_mem): Update.
* cfgexpand.c (expand_used_vars): Update.
(tree_expand_cfg): Update.
* cfgcleanup.c (rest_of_handle_jump): Update.
* explow.c (allocate_dynamic_stack_space): Update.
* varasm.c (assemble_start_function): Update.
(force_const_mem): Update.
(mark_constant_pool): Update.
* tree-optimize.c (tree_rest_of_compilation): Update.
* stack-ptr-mod.c (notice_stack_pointer_modification): Update.
* tree-cfg.c (notice_special_calls): Update.
(is_ctrl_altering_stmt): Update.
(tree_can_make_abnormal_goto): Update.
(tree_purge_dead_abnormal_call_edges): Update.
* config/alpha/predicates.md: Update.
* config/alpha/alpha.c (alpha_sa_mask): Update.
(alpha_sa_size): Update.
(alpha_does_function_need_gp): Update.
(alpha_expand_prologue): Update.
(alpha_start_function): Update.
(alpha_output_function_end_prologue): Update.
(alpha_expand_epilogue): Update.
* config/frv/frv.c (frv_stack_info): Update.
(frv_expand_epilogue): Update.
* config/s390/s390.c (s390_regs_ever_clobbered): Update.
(s390_register_info): Update.
(s390_frame_info): Update.
(s390_init_frame_layout): Update.
(s390_can_eliminate): Update.
(save_gprs): Update.
* config/spu/spu.c (spu_split_immediate): Update.
(need_to_save_reg): Update.
(spu_expand_prologue): Update.
(spu_expand_epilogue): Update.
* config/sparc/sparc.md: Update.
* config/sparc/sparc.c (eligible_for_return_delay): Update.
(sparc_tls_got): Update.
(legitimize_pic_address): Update.
(sparc_emit_call_insn): Update.
(sparc_expand_prologue): Update.
(output_return): Update.
(print_operand): Update.
(sparc_function_ok_for_sibcall): Update.
* config/sparc/sparc.h (EXIT_IGNORE_STACK): Update.
* config/m32r/m32r.md: Update.
* config/m32r/m32r.c (MUST_SAVE_RETURN_ADDR): Update.
(m32r_compute_frame_size): Update.
(m32r_expand_prologue): Update.
(m32r_expand_epilogue): Update.
(m32r_legitimize_pic_address): Update.
* config/m32r/m32r.h (FRAME_POINTER_REQUIRED): Update.
* config/i386/linux.h (SUBTARGET_FRAME_POINTER_REQUIRED): Update.
* config/i386/i386.c (ix86_frame_pointer_required): Update.
(gen_push): Update.
(ix86_save_reg): Update.
(ix86_compute_frame_layout): Update.
(ix86_expand_prologue): Update.
(ix86_expand_epilogue): Update.
* config/sh/sh.c (output_stack_adjust): Update.
(calc_live_regs): Update.
(sh5_schedule_saves): Update.
(sh_expand_prologue): Update.
(sh_expand_epilogue): Update.
(sh_setup_incoming_varargs): Update.
(sh_allocate_initial_value): Update.
(sh_get_pr_initial_val): Update.
* config/sh/sh.h (SHMEDIA_REGS_STACK_ADJUST): Update.
* config/sh/sh.md (label:): Update.
* config/avr/avr.c (out_movhi_mr_r): Update.
* config/crx/crx.h (enum): Update.
* config/xtensa/xtensa.h (along): Update.
* config/stormy16/stormy16.c Update.
(xstormy16_compute_stack_layout): Update.
* config/fr30/fr30.c (MUST_SAVE_RETURN_POINTER): Update.
(fr30_expand_prologue): Update.
* config/cris/cris.c (cris_conditional_register_usage): Update.
(cris_reg_saved_in_regsave_area): Update.
(cris_initial_frame_pointer_offset): Update.
(cris_simple_epilogue): Update.
(cris_expand_prologue): Update.
(cris_expand_epilogue): Update.
(cris_expand_pic_call_address): Update.
(cris_asm_output_symbol_ref): Update.
(cris_asm_output_label_ref): Update.
* config/cris/cris.md Update.
* config/iq2000/iq2000.c (compute_frame_size): Update.
(iq2000_expand_epilogue): Update.
* config/mt/mt.h (save_direction): Update.
* config/mn10300/mn10300.c (mn10300_function_value): Update.
* config/ia64/ia64.c (ia64_compute_frame_size): Update.
(ia64_secondary_reload_class): Update.
* config/m68k/m68k.c (m68k_save_reg): Update.
(m68k_expand_prologue): Update.
(m68k_expand_epilogue): Update.
(legitimize_pic_address): Update.
* config/rs6000/rs6000.c (rs6000_got_register): Update.
(first_reg_to_save): Update.
(first_altivec_reg_to_save): Update.
(compute_vrsave_mask): Update.
(compute_save_world_info): Update.
(rs6000_stack_info): Update.
(spe_func_has_64bit_regs_p): Update.
(rs6000_ra_ever_killed): Update.
(rs6000_emit_eh_reg_restore): Update.
(rs6000_emit_allocate_stack): Update.
(rs6000_emit_prologue): Update.
(rs6000_emit_epilogue): Update.
(rs6000_output_function_epilogue): Update.
(output_profile_hook): Update.
(rs6000_elf_declare_function_name): Update.
* config/rs6000/rs6000.h (rs6000_args): Update.
* config/rs6000/rs6000.md: Update.
* config/mcore/mcore.c (mcore_expand_prolog): Update.
* config/arc/arc.c (arc_output_function_epilogue): Update.
* config/arc/arc.h (FRAME_POINTER_REQUIRED): Update.
* config/darwin.c (machopic_function_base_name): Update.
* config/score/score3.c (score3_compute_frame_size): Update.
(rpush): Update.
(rpop): Update.
(score3_epilogue): Update.
* config/score/score7.c (score7_compute_frame_size): Update.
(score7_prologue): Update.
(score7_epilogue): Update.
* config/score/score.h (FRAME_POINTER_REQUIRED): Update.
* config/arm/linux-elf.h (SUBTARGET_FRAME_POINTER_REQUIRED): Update.
* config/arm/arm.c (use_return_insn): Update.
(require_pic_register): Update.
(arm_load_pic_register): Update.
(arm_compute_save_reg0_reg12_mask): Update.
(arm_compute_save_reg_mask): Update.
(thumb1_compute_save_reg_mask): Update.
(output_return_instruction): Update.
(arm_output_function_prologue): Update.
(arm_output_epilogue): Update.
(arm_get_frame_offsets): Update.
(arm_expand_prologue): Update.
(thumb_pushpop): Update.
(thumb_exit): Update.
(thumb1_expand_prologue): Update.
(thumb1_expand_epilogue): Update.
(arm_unwind_emit): Update.
(arm_output_fn_unwind): Update.
* config/arm/arm.h (FRAME_POINTER_REQUIRED): Update.
* config/arm/arm.md: Update.
* config/pa/pa.md: Update.
* config/pa/pa.c (legitimize_pic_address): Update.
(compute_frame_size): Update.
(hppa_expand_prologue): Update.
(hppa_expand_epilogue): Update.
(borx_reg_operand): Update.
* config/pa/pa.h (FRAME_POINTER_REQUIRED): Update.
(HARD_REGNO_RENAME_OK): Update.
* config/mips/mips.c (mips_global_pointer): Update.
(mips_save_reg_p): Update.
(mips_compute_frame_info): Update.
(mips_frame_pointer_required): Update.
(mips_expand_prologue): Update.
(mips_expand_epilogue): Update.
(mips_can_use_return_insn): Update.
(mips_reorg_process_insns): Update.
* config/v850/v850.c (compute_register_save_size): Update.
* config/mmix/mmix.h (FRAME_POINTER_REQUIRED): Update.
* config/mmix/mmix.c (along): Update.
(mmix_expand_epilogue): Update.
* config/bfin/bfin.c (legitimize_pic_address): Update.
(must_save_p): Update.
(stack_frame_needed_p): Update.
(add_to_reg): Update.
(bfin_expand_prologue): Update.
* stmt.c (expand_asm_operands): Update.
* reload1.c (reload): Update.
(init_elim_table): Update.
From-SVN: r134682
|
|
call_site_record.
* except.c (dw2_size_of_call_site_table,
sjlj_size_of_call_site_table): Use vector API for call_site_record.
* cgraphbuild.c (build_cgraph_edges): Update.
* tree-pass.h: Update comment.
* final.c (leaf_function_p): Update.
(leaf_renumber_regs): Update.
(rest_of_clean_state): Update.
* omp-low.c (expand_omp_parallel): Update.
* ipa-reference.c (analyze_function): Update.
* reorg.c (find_end_label): Update.
(optimize_skip): Update.
(fill_simple_delay_slots): Update.
(fill_simple_delay_slots): Update.
(make_return_insns): Update.
(dbr_schedule): Update.
* gimple-low.c (record_vars_into): Update.
* cfgbuild.c (make_edges): Update.
* function.c (assign_stack_local): Update.
(assign_parm_adjust_stack_rtl): Update.
(locate_and_pad_parm): Update.
(allocate_struct_function): Do not initialize stack_alignment_needed
and preferred_stack_boundary here.
(stack_protect_prologue): Update.
(stack_protect_epilogue): Update.
(expand_function_start): Initialize stack_alignment_needed,
preferred_stack_boundary and max_jumptable_ents.
(expand_function_end): Update.
(free_after_compilation): Do not NULLify epilogue_delay_list.
* function.h (struct rtl_data): Add stack_protect_guard,
stack_alignment_needed,
preferred_stack_boundary, epilogue_delay_list.
(struct function): Remove value_histograms, stack_alignment_needed,
preferred_stack_boundary, epilogue_delay_list, max_jumptable_ents,
last_label_uid,
unexpanded_var_list, stack_protect_guard.
(current_function_epilogue_delay_list): Remove.
* ipa-type-escape.c (analyze_function): Update.
* gimplify.c (pop_gimplify_context): Update comment.
* calls.c (expand_call): Update.
(emit_library_call_value_1): Update.
* except.c (set_nothrow_function_flags): Update.
* cfgexpand.c (get_decl_align_unit): Update.
(create_stack_guard): Update.
(estimated_stack_frame_size): Update.
(expand_used_vars): Update.
(tree_expand_cfg): Free histogram earliers, init expansion variables.
* explow.c (allocate_dynamic_stack_space): Update.
* tree-ssa-live.c (remove_unused_locals): Update.
* varasm.c (mark_constant_pool): Update.
* tree-inline.c (remap_decls): Update.
(initialize_cfun): Update.
(declare_return_variable): Update.
(inline_forbidden_p): Update.
(expand_call_inline): Update.
(declare_inline_vars): Update.
(tree_function_versioning): Update.
* tree-flow.h (value_histograms): New.
(VALUE_HISTOGRAMS): New macro.
* basic-block.h (control_flow_graph): Add max_jumptable_ents,
last_label_uid.
* tree-cfg.c (set_bb_for_stmt): Update.
(replace_by_duplicate_decl): Update.
(move_block_to_fn): Update.
(new_label_mapper): Update.
(dump_function_to_file): Update.
* ipa-struct-reorg.c (build_data_structure): Update.
* cfgrtl.c (print_rtl_with_bb): Update.
* reload1.c (reload): Update.
(reload): Update.
* config/i386/i386.c (setup_incoming_varargs_64,
ix86_compute_frame_layout): Update.
* config/arc/arc.c (arc_output_function_epilogue): Update.
From-SVN: r134425
|
|
PR middle-end/PR28690
* explow.c (break_out_memory_refs): Use simplify_gen_binary rather
than gen_rtx_fmt_ee to perform more canonicalizations.
From-SVN: r134139
|
|
* explow.c (memory_address): Assert that the generated address is
valid.
From-SVN: r132578
|
|
reloading 'asm')
PR33713
* doc/invoke.texi: Remove -fforce-addr documentation.
* expr.c (emit_move_insn): Remove use of flag_force_addr.
(expand_expr_real_1): Same.
(do_tablejump): Same.
Call memory_address instead of memory_address_noforce.
* expr.h (memory_address_noforce): Remove prototype.
* explow.c (memory_address): Remove support for flag_force_addr.
(validize_mem): Same.
(memory_address_noforce): Remove.
* common.opt: Add dummy documentation for -fforce-addr.
* combine.c (can_combine_p): Remove -fforce-addr comment.
* config/cris/cris.h (OPTIMIZATION_OPTIONS): Remove set of
flag_force_addr.
* config/m68k/m68k.h (PIC_CASE_VECTOR_ADDRESS): Remove comment
relating to memory_address_noforce.
* testsuite/gcc.c-torture/compile/20050802-1.c: Remove.
* testsuite/gcc.c-torture/compile/20011113-1.c: Remove.
From-SVN: r130591
|
|
guard.
* config/arc/arc-protos.h arc_select_cc_mode, gen_compare_reg):
Wrap in RTX_CODE macro guard.
* config/arm/pe.c (arm_dllexport_p, arm_dllimport_p,
arm_dllexport_name_p, arm_dllimport_name_p, arm_mark_dllexport,
arm_mark_dllimport, arm_pe_encode_section_info,
arm_pe_unique_section): Use ISO-C function declarations.
* config/c4x/c4x-c.c (c4x_parse_pragma, c4x_pr_CODE_SECTION,
c4x_pr_DATA_SECTION, c4x_pr_FUNC_IS_PURE,
c4x_pr_FUNC_NEVER_RETURNS, c4x_pr_INTERRUPT, c4x_pr_ignored):
Likewise.
* config/iq2000/iq2000.h (ASM_OUTPUT_SKIP): Fix format warning.
* config/m68hc11/m68hc11.h (ASM_OUTPUT_EXTERNAL): Undef before
defining.
* config/mips/mips.h (ASM_DECLARE_OBJECT_NAME): Fix format
warnings.
* config/mn10300/mn10300.h (OUTPUT_ADDR_CONST_EXTRA): Likewise.
* config/pdp11/pdp11.c (pdp11_output_function_epilogue): Likewise.
(register_move_cost): Use ISO-C function declarations.
* config/pdp11/pdp11.h (PRINT_OPERAND): Fix format warnings.
* config/score/score-protos.h (score_declare_object): Add
ATTRIBUTE_PRINTF_4.
* config/score/score.h (ASM_DECLARE_OBJECT_NAME): Fix format
warnings.
* final.c (profile_function): Avoid empty if-bodies.
* calls.c (must_pass_in_stack_var_size,
must_pass_in_stack_var_size_or_pad): Constify.
* config/alpha/alpha-protos.h (function_value): Likewise.
* config/alpha/alpha.c (alpha_return_in_memory,
alpha_pass_by_reference, function_value,
unicosmk_must_pass_in_stack, TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN, TARGET_PROMOTE_PROTOTYPES):
Likewise.
* config/arc/arc.c (arc_return_in_memory, arc_pass_by_reference,
TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN,
TARGET_PROMOTE_PROTOTYPES): Likewise.
* config/arm/arm-protos.h (arm_return_in_memory,
arm_pad_arg_upward, arm_function_value): Likewise.
* config/arm/arm.c (arm_pass_by_reference,
arm_promote_prototypes, arm_return_in_msb, arm_must_pass_in_stack,
TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN,
arm_function_value, arm_return_in_memory, arm_pad_arg_upward):
Likewise.
* config/arm/arm.h (ARM_DECLARE_FUNCTION_NAME): Likewise.
* config/avr/avr-protos.h (avr_function_value): Likewise.
* config/avr/avr.c (avr_return_in_memory,
gas_output_limited_string, gas_output_ascii, avr_function_value,
avr_return_in_memory): Likewise.
* config/bfin/bfin-protos.h (bfin_return_in_memory): Likewise.
* config/bfin/bfin.c (bfin_pass_by_reference,
bfin_return_in_memory, TARGET_PROMOTE_PROTOTYPES,
TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN):
Likewise.
* config/cris/cris.c (cris_pass_by_reference,
TARGET_PROMOTE_FUNCTION_ARGS): Likewise.
* config/crx/crx.c (crx_return_in_memory): Likewise.
* config/darwin.c (function_base, machopic_function_base_name):
Likewise.
* config/fr30/fr30.c (fr30_must_pass_in_stack,
TARGET_PROMOTE_PROTOTYPES): Likewise.
* config/frv/frv.c (frv_must_pass_in_stack): Likewise.
* config/h8300/h8300.c (h8300_return_in_memory): Likewise.
* config/i386/i386-protos.h (ix86_return_in_memory,
ix86_sol10_return_in_memory): Likewise.
* config/i386/i386.c (ix86_function_value,
ix86_function_sseregparm, ix86_must_pass_in_stack,
type_natural_mode, classify_argument, examine_argument,
construct_container, ix86_pass_by_reference, function_value_32,
function_value_64, ix86_function_value_1, return_in_memory_32,
return_in_memory_64, return_in_memory_ms_64,
ix86_return_in_memory, ix86_sol10_return_in_memory,
TARGET_PROMOTE_PROTOTYPES): Likewise.
* config/ia64/ia64-protos.h (ia64_function_value,
ia64_hpux_function_arg_padding): Likewise.
* config/ia64/ia64.c (hfa_element_mode, ia64_return_in_memory,
ia64_function_value, bundle_state_hash, bundle_state_eq_p,
ia64_hpux_function_arg_padding): Likewise.
* config/iq2000/iq2000-protos.h (function_arg,
iq2000_function_value): Likewise.
* config/iq2000/iq2000.c (iq2000_return_in_memory,
iq2000_pass_by_reference, TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN, TARGET_PROMOTE_PROTOTYPES,
function_arg, iq2000_function_value): Likewise.
* config/m32c/m32c-protos.h (m32c_function_value,
m32c_promote_function_return): Likewise.
* config/m32c/m32c.c (m32c_pass_by_reference,
m32c_promote_prototypes, m32c_promote_function_return,
m32c_function_value): Likewise.
* config/m32r/m32r.c (m32r_return_in_memory,
m32r_pass_by_reference, TARGET_PROMOTE_PROTOTYPES,
m32r_in_small_data_p): Likewise.
* config/m68hc11/m68hc11-protos.h (m68hc11_function_arg_padding):
Likewise.
* config/m68hc11/m68hc11.c (m68hc11_return_in_memory,
m68hc11_function_arg_padding): Likewise.
* config/m68k/m68k-protos.h (m68k_function_value): Likewise.
* config/m68k/m68k.c (TARGET_PROMOTE_PROTOTYPES,
m68k_function_value): Likewise.
* config/mcore/mcore-protos.h (mcore_num_arg_regs,
mcore_function_value): Likewise.
* config/mcore/mcore.c (handle_structs_in_regs,
mcore_return_in_memory, TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN, TARGET_PROMOTE_PROTOTYPES,
mcore_num_arg_regs, mcore_function_value): Likewise.
* config/mips/mips-protos.h (mips_pad_arg_upward,
mips_function_value): Likewise.
* config/mips/mips.c (mips_fpr_return_fields, mips_return_in_msb,
mips_return_in_memory, mips_pass_by_reference, mips_callee_copies,
TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN,
TARGET_PROMOTE_PROTOTYPES, mips_pad_arg_upward,
mips_function_value): Likewise.
* config/mmix/mmix-protos.h (mmix_function_outgoing_value):
Likewise.
* config/mmix/mmix.c (mmix_pass_by_reference,
TARGET_PROMOTE_FUNCTION_ARGS, mmix_function_outgoing_value,
mmix_encode_section_info): Likewise.
* config/mn10300/mn10300-protos.h (mn10300_function_value):
Likewise.
* config/mn10300/mn10300.c (mn10300_return_in_memory,
mn10300_pass_by_reference, TARGET_PROMOTE_PROTOTYPES,
mn10300_function_value): Likewise.
* config/mt/mt-protos.h (mt_function_value): Likewise.
* config/mt/mt.c (mt_pass_by_reference, mt_function_value,
mt_pass_in_stack, TARGET_PROMOTE_PROTOTYPES): Likewise.
* config/pa/pa-protos.h (function_arg_padding, function_value,
pa_return_in_memory): Likewise.
* config/pa/pa.c (pa_pass_by_reference,
TARGET_PROMOTE_FUNCTION_RETURN, TARGET_PROMOTE_PROTOTYPES,
function_arg_padding, function_value, pa_return_in_memory):
Likewise.
* config/pdp11/pdp11.c (pdp11_return_in_memory): Likewise.
* config/rs6000/rs6000-protos.h (rs6000_function_value,
function_arg_padding): Likewise.
* config/rs6000/rs6000.c (rs6000_return_in_memory,
rs6000_darwin64_record_arg_recurse, rs6000_darwin64_record_arg,
rs6000_pass_by_reference, rs6000_must_pass_in_stack,
TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN,
function_arg_padding, altivec_expand_dst_builtin,
altivec_expand_builtin, rs6000_expand_builtin, spe_init_builtins,
altivec_init_builtins, rs6000_common_init_builtins,
rs6000_function_value): Likewise.
* s390/s390-protos.h (s390_function_value): Likewise.
* config/s390/s390.c (s390_function_arg_size,
s390_pass_by_reference, s390_return_in_memory,
s390_function_value, TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN): Likewise.
* config/score/score-protos.h (score_function_value): Likewise.
* config/score/score.c (score_arg_partial_bytes,
TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN,
TARGET_PROMOTE_PROTOTYPES, score_return_in_memory,
score_pass_by_reference, score_add_offset, score_function_value):
Likewise.
* config/sh/sh-protos.h (sh_attr_renesas_p,
sh_promote_prototypes): Likewise.
* config/sh/sh.c (sh_return_in_memory, sh_pass_by_reference,
sh_callee_copies, sh_promote_prototypes, shcompact_byref,
sh_attr_renesas_p): Likewise.
* config/sparc/sparc-protos.h (function_value,
function_arg_padding): Likewise.
* config/sparc/sparc.c (sparc_promote_prototypes,
sparc_return_in_memory, sparc_pass_by_reference,
TARGET_PROMOTE_FUNCTION_ARGS, TARGET_PROMOTE_FUNCTION_RETURN,
function_arg_record_value_2, function_arg_record_value_1,
function_arg_record_value, function_arg_record_value,
function_arg_padding, function_value): Likewise.
* config/spu/spu-protos.h (spu_function_value): Likewise.
* config/spu/spu.c (spu_pass_by_reference, spu_return_in_memory,
spu_function_value): Likewise.
* config/stormy16/stormy16-protos.h (xstormy16_function_value):
Likewise.
* config/stormy16/stormy16.c (xstormy16_return_in_memory,
xstormy16_function_value, TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN, TARGET_PROMOTE_PROTOTYPES):
Likewise.
* config/v850/v850.c (v850_return_in_memory,
v850_pass_by_reference, TARGET_PROMOTE_PROTOTYPES): Likewise.
* config/vax/vax.c (TARGET_PROMOTE_PROTOTYPES): Likewise.
* config/xtensa/xtensa.c (xtensa_return_in_msb,
xtensa_return_in_memory, TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN, TARGET_PROMOTE_PROTOTYPES):
Likewise.
* explow.c (promote_mode, hard_function_value): Likewise.
* expr.h (hard_function_value, promote_mode): Likewise.
* function.c (aggregate_value_p): Likewise.
* hooks.c (hook_bool_const_tree_true): New.
* hooks.h (hook_bool_const_tree_true): New.
* sdbout.c (SET_KNOWN_TYPE_TAG, plain_type_1): Constify.
* target-def.h (TARGET_PROMOTE_FUNCTION_ARGS,
TARGET_PROMOTE_FUNCTION_RETURN, TARGET_PROMOTE_PROTOTYPES,
TARGET_RETURN_IN_MSB): Likewise.
* target.h (promote_function_args, promote_function_return,
promote_prototypes, return_in_memory, return_in_msb,
pass_by_reference, must_pass_in_stack, callee_copies,
function_value): Likewise.
* targhooks.c (default_return_in_memory,
hook_pass_by_reference_must_pass_in_stack,
hook_callee_copies_named,
hook_bool_CUMULATIVE_ARGS_mode_tree_bool_false,
hook_bool_CUMULATIVE_ARGS_mode_tree_bool_true,
default_function_value): Likewise.
* targhooks.h (default_return_in_memory,
hook_pass_by_reference_must_pass_in_stack,
hook_callee_copies_named,
hook_bool_CUMULATIVE_ARGS_mode_tree_bool_false,
hook_bool_CUMULATIVE_ARGS_mode_tree_bool_true,
default_function_value): Likewise.
* tree-ssa-structalias.c (const_equiv_class_label_t): New.
(equiv_class_label_hash, equiv_class_label_eq): Constify.
* tree-vectorizer.c (bb_in_loop_p): Likewise.
* tree.c (needs_to_live_in_memory): Likewise.
* tree.h (struct tree_type, needs_to_live_in_memory,
aggregate_value_p, must_pass_in_stack_var_size,
must_pass_in_stack_var_size_or_pad): Likewise.
* vmsdbgout.c (write_debug_addr, write_debug_delta4,
write_debug_string, ASM_OUTPUT_DEBUG_STRING, write_rtnbeg,
lookup_filename): Likewise.
From-SVN: r127743
|
|
* tree.def (FIXED_POINT_TYPE): New type.
(FIXED_CST): New constant.
(FIXED_CONVERT_EXPR): New expr.
* doc/c-tree.texi (Types): Document FIXED_POINT_TYPE.
(Expressions): Document FIXED_CST and FIXED_CONVERT_EXPR.
* tree.h (struct tree_base): Add saturating_flag.
Remove one bit of spare for saturating_flag.
(NUMERICAL_TYPE_CHECK): Support FIXED_POINT_TYPE.
(NON_SAT_FIXED_POINT_TYPE_P, SAT_FIXED_POINT_TYPE_P,
FIXED_POINT_TYPE_P): Define.
(TYPE_SATURATING): Define.
(TREE_FIXED_CST_PTR, TREE_FIXED_CST): Define.
(struct tree_fixed_cst): New.
(TYPE_IBIT, TYPE_FBIT): Define.
(tree_node): Add fixed_cst.
(enum tree_index): Add new enumeration values of
TI_SAT_SFRACT_TYPE, TI_SAT_FRACT_TYPE, TI_SAT_LFRACT_TYPE,
TI_SAT_LLFRACT_TYPE, TI_SAT_USFRACT_TYPE, TI_SAT_UFRACT_TYPE,
TI_SAT_ULFRACT_TYPE, TI_SAT_ULLFRACT_TYPE, TI_SFRACT_TYPE,
TI_FRACT_TYPE, TI_LFRACT_TYPE, TI_LLFRACT_TYPE, TI_USFRACT_TYPE,
TI_UFRACT_TYPE, TI_ULFRACT_TYPE, TI_ULLFRACT_TYPE,
TI_SAT_SACCUM_TYPE, TI_SAT_ACCUM_TYPE, TI_SAT_LACCUM_TYPE,
TI_SAT_LLACCUM_TYPE, TI_SAT_USACCUM_TYPE, TI_SAT_UACCUM_TYPE,
TI_SAT_ULACCUM_TYPE, TI_SAT_ULLACCUM_TYPE, TI_SACCUM_TYPE,
TI_ACCUM_TYPE, TI_LACCUM_TYPE, TI_LLACCUM_TYPE, TI_USACCUM_TYPE,
TI_UACCUM_TYPE, TI_ULACCUM_TYPE, TI_ULLACCUM_TYPE,
TI_QQ_TYPE, TI_HQ_TYPE,_TYPE, TI_SQ_TYPE, TI_DQ_TYPE, TI_TQ_TYPE,
TI_UQQ_TYPE, TI_UHQ_TYPE, TI_USQ_TYPE, TI_UDQ_TYPE, TI_UTQ_TYPE,
TI_SAT_QQ_TYPE, TI_SAT_HQ_TYPE, TI_SAT_SQ_TYPE, TI_SAT_DQ_TYPE,
TI_SAT_TQ_TYPE, TI_SAT_UQQ_TYPE, TI_SAT_UHQ_TYPE, TI_SAT_USQ_TYPE,
TI_SAT_UDQ_TYPE, TI_SAT_UTQ_TYPE, TI_HA_TYPE, TI_SA_TYPE, TI_DA_TYPE,
TI_TA_TYPE, TI_UHA_TYPE, TI_USA_TYPE, TI_UDA_TYPE, TI_UTA_TYPE,
TI_SAT_HA_TYPE, TI_SAT_SA_TYPE, TI_SAT_DA_TYPE, TI_SAT_TA_TYPE,
TI_SAT_UHA_TYPE, TI_SAT_USA_TYPE, TI_SAT_UDA_TYPE, TI_SAT_UTA_TYPE.
(sat_short_fract_type_node, sat_fract_type_node,
sat_long_fract_type_node, sat_long_long_fract_type_node,
sat_unsigned_short_fract_type_node, sat_unsigned_fract_type_node,
sat_unsigned_long_fract_type_node,
sat_unsigned_long_long_fract_type_node, short_fract_type_node,
fract_type_node, long_fract_type_node, long_long_fract_type_node,
unsigned_short_fract_type_node, unsigned_fract_type_node,
unsigned_long_fract_type_node, unsigned_long_long_fract_type_node,
sat_short_accum_type_node, sat_accum_type_node,
sat_long_accum_type_node, sat_long_long_accum_type_node,
sat_unsigned_short_accum_type_node, sat_unsigned_accum_type_node,
sat_unsigned_long_accum_type_node,
sat_unsigned_long_long_accum_type_node, short_accum_type_node,
accum_type_node, long_accum_type_node, long_long_accum_type_node,
unsigned_short_accum_type_node, unsigned_accum_type_node,
unsigned_long_accum_type_node, unsigned_long_long_accum_type_node,
qq_type_node, hq_type_node, sq_type_node, dq_type_node, tq_type_node,
uqq_type_node, uhq_type_node, usq_type_node, udq_type_node,
utq_type_node, sat_qq_type_node, sat_hq_type_node, sat_sq_type_node,
sat_dq_type_node, sat_tq_type_node, sat_uqq_type_node,
sat_uhq_type_node, sat_usq_type_node, sat_udq_type_node,
sat_utq_type_node, ha_type_node, sa_type_node, da_type_node,
ta_type_node, uha_type_node, usa_type_node, uda_type_node,
uta_type_node, sat_ha_type_node, sat_sa_type_node, sat_da_type_node,
sat_ta_type_node, sat_uha_type_node, sat_usa_type_node,
sat_uda_type_node, sat_uta_type_node): New macro.
(make_fract_type, make_accum_type): Declare.
(make_signed_fract_type, make_unsigned_fract_type,
make_sat_signed_fract_type, make_sat_unsigned_fract_type,
make_signed_accum_type, make_unsigned_accum_type,
make_sat_signed_accum_type, make_sat_unsigned_accum_type,
make_or_reuse_signed_fract_type, make_or_reuse_unsigned_fract_type,
make_or_reuse_sat_signed_fract_type,
make_or_reuse_sat_unsigned_fract_type, make_or_reuse_signed_accum_type,
make_or_reuse_unsigned_accum_type, make_or_reuse_sat_signed_accum_type,
make_or_reuse_sat_unsigned_accum_type): New macro.
(fixed_zerop): Declare.
* defaults.h (SHORT_FRACT_TYPE_SIZE, FRACT_TYPE_SIZE,
LONG_FRACT_TYPE_SIZE, LONG_LONG_FRACT_TYPE_SIZE,
SHORT_ACCUM_TYPE_SIZE, ACCUM_TYPE_SIZE, LONG_ACCUM_TYPE_SIZE,
LONG_LONG_ACCUM_TYPE_SIZE): Define.
* treestruct.def: Add TS_FIXED_CST.
* Makefile.in (c-pretty-print.o): Add dependence on fixed-value.h.
(tree.o): Likewise.
(tree-dump.o): Likewise.
(print-tree.o): Likewise.
(tree-pretty-print.o): Likewise.
(fold-const.o): Likewise.
* tree-complex.c (some_nonzerop): Handle FIXED_CST.
* tree-gimple.c (is_gimple_formal_tmp_rhs): Handle FIXED_CST.
(is_gimple_min_invariant): Handle FIXED_CST.
* stor-layout.c (int_mode_for_mode): Handle MODE_FRACT, MODE_UFRACT,
MODE_ACCUM, MODE_UACCUM, MODE_VECTOR_FRACT, MODE_VECTOR_UFRACT,
MODE_VECTOR_ACCUM, MODE_VECTOR_UACCUM.
(layout_type): Handle FIXED_POINT_TYPE.
(make_fract_type, make_accum_type): New functions.
* tree-browser.c (browse_tree): Handle FIXED_POINT_TYPE.
* tree-dump.c (fixed-value.h): New include.
(dump_fixed): New function.
(dequeue_and_dump): Handle FIXED_POINT_TYPE and FIXED_CST.
* tree-inline.c (remap_type_1): Handle FIXED_POINT_TYPE.
(estimate_num_insns_1): Handle FIXED_CST and FIXED_CONVERT_EXPR.
* tree-pretty-print.c (fixed-value.h): New include.
(dump_generic_node): Handle FIXED_POINT_TYPE, FIXED_CST, and
FIXED_CONVERT_EXPR.
* tree-scalar-evolution.c (get_scalar_evolution): Handle FIXED_CST.
* tree-ssa-loop-im.c (for_each_index): Handle FIXED_CST.
* tree-ssa-pre.c (poolify_tree): Handle FIXED_CST.
* tree-ssa-reassoc.c (break_up_subtract_bb): We can do reassociation
for non-saturating fixed-point types.
(reassociate_bb): Likewise.
* emit-rtl.c (fixed-value.h): New include.
(fconst0, fconst1): New array.
(init_emit_once): Initialize fconst0 and fconst1 for fixed-point modes.
* tree-vect-generic.c expand_vector_operation): Support
MODE_VECTOR_FRACT, MODE_VECTOR_UFRACT, MODE_VECTOR_ACCUM, and
MODE_VECTOR_UACCUM.
(type_for_widest_vector_mode): Add one parameter for the
saturating flag.
Check scalar FRACT, UFRACT, ACCUM, and UACCUM mode to select their
vector mode.
Pass the satp parameter to type_for_mode for fixed-point types.
(expand_vector_operations_1): Pass the saturating flag to
type_for_widest_vector_mode.
Support MODE_VECTOR_FRACT, MODE_VECTOR_UFRACT, MODE_VECTOR_ACCUM,
and MODE_VECTOR_UACCUM.
* tree-vect-transform.c (vect_is_simple_cond): Support FIXED_CST.
(vectorizable_condition): Likewise.
* tree.c (fixed-value.h): New include.
(tree_code_size): Support FIXED_CST.
(build_fixed): New function.
(build_one_cst): Support FIXED_POINT_TYPE for accum types.
(fixed_zerop): New function.
(tree_node_structure): Support FIXED_CST.
(type_contains_placeholder_1): Support FIXED_POINT_TYPE.
(build_type_attribute_qual_variant): Handle FIXED_POINT_TYPE.
(type_hash_eq): Handle FIXED_POINT_TYPE.
(simple_cst_equal): Support FIXED_CST.
(iterative_hash_expr): Handle FIXED_CST.
(get_unwidened): Make sure type is not FIXED_POINT_TYPE.
(get_narrower): Likewise.
(variably_modified_type_p): Handle FIXED_POINT_TYPE.
(make_or_reuse_fract_type, make_or_reuse_accum_type): New functions.
(build_common_tree_nodes_2): Use MAKE_FIXED_TYPE_NODE_FAMILY and
MAKE_FIXED_MODE_NODE macros to initialize fixed-point type
nodes.
(build_vector_type_for_mode): Handle MODE_VECTOR_FRACT,
MODE_VECTOR_UFRACT, MODE_VECTOR_ACCUM, MODE_VECTOR_UACCUM.
(initializer_zerop): Support FIXED_CST.
(walk_tree): Handle FIXED_CST and FIXED_POINT_TYPE.
* dwarf2out.c (base_type_die): Use DW_ATE_signed_fixed or
DW_ATE_unsigned_fixed to describe FIXED_POINT_TYPE.
(is_base_type): Handle FIXED_POINT_TYPE.
(add_type_attribute): Handle FIXED_POINT_TYPE.
(gen_type_die_with_usage): Handle FIXED_POINT_TYPE.
* print-tree.c (fixed-value.h): New include.
(print_node_brief): Support FIXED_CST.
(print_node): Support FIXED_POINT_TYPE and FIXED_CST.
* c-pretty-print.c (fixed-value.h): New include.
(pp_c_type_specifier): Handle FIXED_POINT_TYPE. Need to pass
TYPE_SATURATING to c_common_type_for_mode for fixed-point modes.
(pp_c_direct_abstract_declarator): Handle FIXED_POINT_TYPE.
Support fixed-point types for inner items in VECTOR_TYPE.
(pp_c_direct_declarator): Likewise.
(pp_c_declarator): Likewise.
(pp_c_fixed_constant): New function.
(pp_c_constant): Handle FIXED_CST.
(pp_c_primary_expression): Likewise.
(pp_c_expression): Likewise.
* fold-const.c (fixed-value.h): New include.
(negate_expr_p): Return true for FIXED_CST.
(fold_negate_expr): Support FIXED_CST.
(split_tree): Support FIXED_CST.
(const_binop): Support FIXED_CST.
(fold_convert_const_int_from_fixed): New function to convert from
fixed to int.
(fold_convert_const_real_from_fixed): New function to convert from
fixed to real.
(fold_convert_const_fixed_from_fixed): New function to convert from
fixed to another fixed.
(fold_convert_const_fixed_from_int): New function to convert from
int to fixed.
(fold_convert_const_fixed_from_real): New function to convert from
real to fixed.
(fold_convert_const): Support conversions from fixed to int, from
fixed to real, from fixed to fixed, from int to fixed, and from real
to fixed.
(fold_convert): Support FIXED_CST and FIXED_POINT_TYPE.
(operand_equal_p): Support FIXED_CST.
(make_range): For fixed-point modes, we need to pass the
saturating flag as the 2nd parameter.
(tree_swap_operands_p): Handle FIXED_CST.
(fold_plusminus_mult_expr): For fract modes, we cannot generate
constant 1.
(fold_unary): Support FIXED_CONVERT_EXPR.
(fold_binary): Handle FIXED_CST.
Make sure the type is not saturating, before associating operations.
Ex: A + B + C, A * B * C, (A1 * C1) +/- (A2 * C2).
(tree_expr_nonnegative_warnv_p): Handle FIXED_CST.
(fold_negate_const): Support FIXED_CST.
(fold_relational_const): Support FIXED_CST.
* gimplify.c (omp_firstprivatize_type_sizes): Handle FIXED_POINT_TYPE.
(gimplify_expr): Handle FIXED_CST.
(gimplify_type_sizes): Handle FIXED_POINT_TYPE.
* ipa-prop.c (ipa_callsite_compute_param): Support FIXED_CST.
* ipa-type-escape.c (type_to_consider): Handle FIXED_POINT_TYPE.
* doc/tm.texi (Type Layout): Document SHORT_FRACT_TYPE_SIZE,
FRACT_TYPE_SIZE, LONG_FRACT_TYPE_SIZE, LONG_LONG_FRACT_TYPE_SIZE,
SHORT_ACCUM_TYPE_SIZE, ACCUM_TYPE_SIZE, LONG_ACCUM_TYPE_SIZE,
LONG_LONG_ACCUM_TYPE_SIZE.
* dbxout.c (dbxout_type): Handle FIXED_POINT_TYPE.
* c-aux-info.c (gen_type): Handle FIXED_POINT_TYPE.
* tree-sra.c (is_sra_scalar_type): Support FIXED_POINT_TYPE.
* expmed.c (extract_bit_field): Support MODE_FRACT, MODE_UFRACT,
MODE_ACCUM, and MODE_UACCUM.
* tree-vectorizer.c (vect_is_simple_reduction): Check for saturating
fixed-point types to disable reduction.
* explow.c (promote_mode): Support FIXED_POINT_TYPE.
From-SVN: r127306
|
|
License and to point readers at the COPYING3 file and the FSF's license web page.
From-SVN: r126948
|
|
call to expand_expr().
* builtins.c (expand_builtin_mathfn): Use EXPAND_NORMAL instead
of 0 in the call to expand_expr().
(expand_builtin_mathfn_3): Ditto.
(expand_builtin_interclass_mathfn): Ditto.
(expand_builtin_cexpi): Ditto.
(expand_builtin_int_roundingfn): Ditto.
(expand_builtin_int_roundingfn_2): Ditto.
(expand_builtin_pow): Ditto.
(expand_builtin_powi): Ditto.
(expand_builtin_bswap): Ditto.
(expand_builtin_unop): Ditto.
(expand_builtin_fabs): Ditto.
(get_builtin_sync_mem): Use NULL_RTX instead of NULL in
the call to expand_expr().
(expand_builtin_sync_operation): Ditto.
(expand_builtin_compare_and_swap): Ditto.
(expand_builtin_lock_test_and_set): Ditto.
* except.c (expand_builtin_eh_return_data_regno): Use EXPAND_NORMAL
instead of 0 in the call to expand_expr().
(expand_builtin_extract_return_addr): Ditto.
(expand_builtin_eh_return): Ditto.
(expand_eh_return): Ditto.
* explow.c (expr_size): Ditto.
* expr.c (optimize_bitfield_assignment_op): Ditto.
(expand_assignement): Ditto.
(store_expr): Ditto.
(store_field): Ditto.
(expand_expr_addr_expr_1): Use NULL_RTX instead of NULL in
the call to expand_expr().
(expand_expr_real_1) [COMPLEX_CST]: Use EXPAND_NORMAL instead of 0
in the call to expand_expr().
[CONSTRUCTOR, PLUS_EXPR, MINUS_EXPR, NEGATE_EXPR, ABS_EXPR,
BIT_NOT_EXPR, LSHIFT_EXPR, LT_EXPR, TRUTH_NOT_EXPR]: Ditto.
[VEC_UNPACK_HI_EXPR, VEC_UNPACK_LO]: Use expand_normal() instead
of expand_expr().
* optabs.c (expand_vec_shift_expr): Ditto.
(expand_vec_cond_expr): Ditto.
(vector_compare_rtx): Use EXPAND_STACK_PARM instead of 1 in the
call to expand_expr().
* stmt.c (expand_return): Use EXPAND_NORMAL instead of 0
in the call to expand_expr().
From-SVN: r124722
|
|
POINTERS_EXTEND_UNSIGNED < 0
* explow.c (convert_memory_address): Fold memory reference when
POINTERS_EXTEND_UNSIGNED < 0
From-SVN: r123113
|
|
* cp-objcp-common.c (cp_expr_size): Return NULL in the case
size is undefined.
* builtins.c (fold_builtin_memory_op): Check that expr_size match.
* explow.c (expr_size, int_expr_size): Assert that size is non_NULL.
From-SVN: r119515
|
|
From-SVN: r117143
|
|
* doc/tm.texi: Refer to SYMBOL_REF_HAS_BLOCK_INFO_P instead of
SYMBOL_REF_IN_BLOCK_P.
* doc/rtl.texi: Likewise. Refer to SYMBOL_FLAG_HAS_BLOCK_INFO instead
of SYMBOL_FLAG_IN_BLOCK.
* gengtype.c (adjust_field_rtx_def): Use SYMBOL_REF_HAS_BLOCK_INFO_P
instead of SYMBOL_REF_IN_BLOCK_P.
* explow.c (use_anchored_address): Likewise.
* rtl.c (rtx_size): Likewise.
* varasm.c (create_block_symbol): Set SYMBOL_FLAG_HAS_BLOCK_INFO
instead of SYMBOL_FLAG_IN_BLOCK.
(make_decl_rtl): Use SYMBOL_REF_HAS_BLOCK_INFO_P instead of
SYMBOL_REF_IN_BLOCK_P.
(assemble_variable): Likewise.
(output_constant_def_contents): Likewise.
(output_constant_pool): Likewise.
(default_encode_section_info): Preserve SYMBOL_FLAG_HAS_BLOCK_INFO
instead of SYMBOL_FLAG_IN_BLOCK.
* rtl.h (block_symbol): Refer to SYMBOL_REF_HAS_BLOCK_INFO_P instead of
SYMBOL_REF_IN_BLOCK_P.
(SYMBOL_REF_BLOCK): Likewise.
(SYMBOL_REF_OFFSET): Likewise.
(BLOCK_SYMBOL_CHECK): Use SYMBOL_REF_HAS_BLOCK_INFO_P instead of
SYMBOL_REF_IN_BLOCK_P.
(SYMBOL_FLAG_IN_BLOCK): Replace with...
(SYMBOL_FLAG_HAS_BLOCK_INFO): ...this.
(SYMBOL_REF_IN_BLOCK_P): Replace with...
(SYMBOL_REF_HAS_BLOCK_INFO_P): ...this.
From-SVN: r111675
|
|
* doc/tm.texi (TARGET_HAVE_SWITCHABLE_BSS_SECTIONS): Document.
(ASM_OUTPUT_BSS): Describe the two ways of handling global BSS,
and say that only one is needed.
* doc/rtl.texi (SYMBOL_REF_BLOCK): Say that the block can be null.
* target.h (have_switchable_bss_sections): New hook.
* explow.c (use_anchored_address): Check that the symbol is in a block.
* varasm.c (tls_comm_section, comm_section, lcomm_section)
(bss_noswitch_section): New variables.
(get_unnamed_section): Add SECTION_UNNAMED to the flags.
(get_noswitch_section): New function.
(get_block_for_section): Allow SECT to be null.
(unlikely_text_section_p): Use SECTION_STYLE.
(bss_initializer_p): New function.
(get_variable_section): Move earlier in file. Take a new argument,
prefer_noswitch_p. Move bss checks from assemble_variable to here.
Return one of the new *_sections in such cases.
(get_block_for_decl): New function, extracting some logic from
use_blocks_for_decl_p.
(change_symbol_section): Remove in favor of...
(change_symbol_block): ...this new function.
(use_blocks_for_decl_p): Remove checks now performed by
get_block_for_decl.
(make_decl_rtl): Use change_symbol_block and get_block_for_decl.
(ASM_EMIT_LOCAL, ASM_EMIT_BSS, ASM_EMIT_COMMON): Delete in favor of...
(emit_local, emit_bss, emit_common): ...these new functions.
Return true if the alignment was honored.
(emit_tls_common): New function.
(asm_emit_uninitialised): Delete.
(assemble_variable_noswitch): New function, split out from...
(assemble_variable): ...here. Don't make decisions about common
variables here. Globalize all public decls that go into non-common
sections. Check whether SYMBOL_REF_BLOCK is null.
(output_constant_def_contents): Check whether SYMBOL_REF_BLOCK is null.
(output_constant_pool): Likewise.
(init_varasm_once): Initialize the new section variables.
(have_global_bss_p): New function.
(categorize_decl_for_section): Use bss_initializer_p.
(switch_to_section): Use SECTION_STYLE. Abort for SECTION_NOSWITCH.
(place_block_symbol): Assert that the symbol must be in a block.
* target-def.h (TARGET_HAVE_SWITCHABLE_BSS_SECTIONS): New macro.
(TARGET_INITIALIZER): Include it.
* rtl.h (SYMBOL_REF_BLOCK): Document the null alternative.
* output.h (SECTION_STYLE_MASK, SECTION_COMMON): New macros.
(SECTION_MACH_DEP): Bump by two.
(SECTION_UNNAMED, SECTION_NOSWITCH): New macros.
(unnamed_section): Mention SECTION_UNNAMED in comment.
(named_section): Likewise SECTION_NAMED.
(noswitch_section_callback): New type.
(noswitch_section): New structure.
(section): Add a noswitch_section alternative.
(SECTION_STYLE): New macro.
(tls_comm_section, comm_section, lcomm_section): Declare.
(bss_noswitch_section, have_global_bss_p): Declare.
* config/elfos.h (TARGET_HAVE_SWITCHABLE_BSS_SECTIONS): Override.
* config/iq2000/iq2000.c (TARGET_HAVE_SWITCHABLE_BSS_SECTIONS):
Override.
* config/v850/v850.c (TARGET_HAVE_SWITCHABLE_BSS_SECTIONS): Override.
* config/stormy16/stormy16.c (TARGET_HAVE_SWITCHABLE_BSS_SECTIONS):
Override.
cp/
* decl.c (start_decl): Use have_global_bss_p when deciding
whether to make the decl common.
ada/
* utils.c (create_var_decl): Use have_global_bss_p when deciding
whether to make the decl common.
From-SVN: r111644
|
|
could be solved in less instructions)
* cselib.c (cselib_init): Change RTX_SIZE to RTX_CODE_SIZE.
* emit-rtl.c (copy_rtx_if_shared_1): Use shallow_copy_rtx.
(copy_insn_1): Likewise. Don't copy each field individually.
Reindent.
* read-rtl.c (apply_macro_to_rtx): Use RTX_CODE_SIZE instead
of RTX_SIZE.
* reload1.c (eliminate_regs): Use shallow_copy_rtx.
* rtl.c (rtx_size): Rename variable to...
(rtx_code_size): ...this.
(rtx_size): New function.
(rtx_alloc_stat): Use RTX_CODE_SIZE instead of RTX_SIZE.
(copy_rtx): Use shallow_copy_rtx. Don't copy each field individually.
Reindent.
(shallow_copy_rtx_stat): Use rtx_size instead of RTX_SIZE.
* rtl.h (rtx_code_size): New variable.
(rtx_size): Change from a variable to a function.
(RTX_SIZE): Rename to...
(RTX_CODE_SIZE): ...this.
PR target/9703
PR tree-optimization/17106
* doc/tm.texi (TARGET_USE_BLOCKS_FOR_CONSTANT_P): Document.
(Anchored Addresses): New section.
* doc/invoke.texi (-fsection-anchors): Document.
* doc/rtl.texi (SYMBOL_REF_IN_BLOCK_P, SYMBOL_FLAG_IN_BLOCK): Likewise.
(SYMBOL_REF_ANCHOR_P, SYMBOL_FLAG_ANCHOR): Likewise.
(SYMBOL_REF_BLOCK, SYMBOL_REF_BLOCK_OFFSET): Likewise.
* hooks.c (hook_bool_mode_rtx_false): New function.
* hooks.h (hook_bool_mode_rtx_false): Declare.
* gengtype.c (create_optional_field): New function.
(adjust_field_rtx_def): Add the "block_sym" field for SYMBOL_REFs when
SYMBOL_REF_IN_BLOCK_P is true.
* target.h (output_anchor, use_blocks_for_constant_p): New hooks.
(min_anchor_offset, max_anchor_offset): Likewise.
(use_anchors_for_symbol_p): New hook.
* toplev.c (compile_file): Call output_object_blocks.
(target_supports_section_anchors_p): New function.
(process_options): Check that -fsection-anchors is only used on
targets that support it and when -funit-at-a-time is in effect.
* tree-ssa-loop-ivopts.c (prepare_decl_rtl): Only create DECL_RTL
if the decl doesn't have one.
* dwarf2out.c: Remove instantiations of VEC(rtx,gc).
* expr.c (emit_move_multi_word, emit_move_insn): Pass the result
of force_const_mem through use_anchored_address.
(expand_expr_constant): New function.
(expand_expr_addr_expr_1): Call it. Use the same modifier when
calling expand_expr for INDIRECT_REF.
(expand_expr_real_1): Pass DECL_RTL through use_anchored_address
for all modifiers except EXPAND_INITIALIZER. Use expand_expr_constant.
* expr.h (use_anchored_address): Declare.
* loop-unroll.c: Don't declare rtx vectors here.
* explow.c: Include output.h.
(validize_mem): Call use_anchored_address.
(use_anchored_address): New function.
* common.opt (-fsection-anchors): New switch.
* varasm.c (object_block_htab, anchor_labelno): New variables.
(hash_section, object_block_entry_eq, object_block_entry_hash)
(use_object_blocks_p, get_block_for_section, create_block_symbol)
(use_blocks_for_decl_p, change_symbol_section): New functions.
(get_variable_section): New function, split out from assemble_variable.
(make_decl_rtl): Create a block symbol if use_object_blocks_p and
use_blocks_for_decl_p say so. Use change_symbol_section if the
symbol has already been created.
(assemble_variable_contents): New function, split out from...
(assemble_variable): ...here. Don't output any code for
block symbols; just pass them to place_block_symbol.
Use get_variable_section and assemble_variable_contents.
(get_constant_alignment, get_constant_section, get_constant_size): New
functions, split from output_constant_def_contents.
(build_constant_desc): Create a block symbol if use_object_blocks_p
says so. Or into SYMBOL_REF_FLAGS.
(assemble_constant_contents): New function, split from...
(output_constant_def_contents): ...here. Don't output any code
for block symbols; just pass them to place_section_symbol.
Use get_constant_section and get_constant_alignment.
(force_const_mem): Create a block symbol if use_object_blocks_p and
use_blocks_for_constant_p say so. Or into SYMBOL_REF_FLAGS.
(output_constant_pool_1): Add an explicit alignment argument.
Don't switch sections here.
(output_constant_pool): Adjust call to output_constant_pool_1.
Switch sections here instead. Don't output anything for block symbols;
just pass them to place_block_symbol.
(init_varasm_once): Initialize object_block_htab.
(default_encode_section_info): Keep the old SYMBOL_FLAG_IN_BLOCK.
(default_asm_output_anchor, default_use_aenchors_for_symbol_p)
(place_block_symbol, get_section_anchor, output_object_block)
(output_object_block_htab, output_object_blocks): New functions.
* target-def.h (TARGET_ASM_OUTPUT_ANCHOR): New macro.
(TARGET_ASM_OUT): Include it.
(TARGET_USE_BLOCKS_FOR_CONSTANT_P): New macro.
(TARGET_MIN_ANCHOR_OFFSET, TARGET_MAX_ANCHOR_OFFSET): New macros.
(TARGET_USE_ANCHORS_FOR_SYMBOL_P): New macro.
(TARGET_INITIALIZER): Include them.
* rtl.c (rtl_check_failed_block_symbol): New function.
* rtl.h: Include vec.h. Declare heap and gc rtx vectors.
(block_symbol, object_block): New structures.
(rtx_def): Add a block_symbol field to the union.
(BLOCK_SYMBOL_CHECK): New macro.
(rtl_check_failed_block_symbol): Declare.
(SYMBOL_FLAG_IN_BLOCK, SYMBOL_FLAG_ANCHOR): New SYMBOL_REF flags.
(SYMBOL_REF_IN_BLOCK_P, SYMBOL_REF_ANCHOR_P): New predicates.
(SYMBOL_FLAG_MACH_DEP_SHIFT): Bump by 2.
(SYMBOL_REF_BLOCK, SYMBOL_REF_BLOCK_OFFSET): New accessors.
* output.h (output_section_symbols): Declare.
(object_block): Name structure.
(place_section_symbol, get_section_anchor, default_asm_output_anchor)
(default_use_anchors_for_symbol_p): Declare.
* Makefile.in (RTL_BASE_H): Add vec.h.
(explow.o): Depend on output.h.
* config/rs6000/rs6000.c (TARGET_MIN_ANCHOR_OFFSET): Override default.
(TARGET_MAX_ANCHOR_OFFSET): Likewise.
(TARGET_USE_BLOCKS_FOR_CONSTANT_P): Likewise.
(rs6000_use_blocks_for_constant_p): New function.
From-SVN: r111254
|
|
* tree.def (CHAR_TYPE): Remove.
* dbxout.c (dbxout_type): Delete dead handling of CHAR_TYPE.
* dwarf2out.c (base_type_die, is_base_type): Likewise.
(gen_type_die) <ARRAY_TYPE>: Remove handling of CHAR_TYPE arrays.
(gen_string_type_die): Delete unreachable function.
* tree-pretty-print.c (dump_generic_node): Don't handle CHAR_TYPE.
* tree.c (build_int_cst_wide, type_contains_placeholder_1,
type_hash_eq, variably_modified_type_p, walk_type_fields): Likewise.
* tree.h (NUMERICAL_TYPE_CHECK, INTEGRAL_TYPE_P): Likewise.
* builtins.c (type_to_class): Likewise.
* fold-const.c (fold_convert, build_range_check,
merge_ranges): Likewise.
* expr.c (count_type_elements): Likewise.
* c-pretty-print.c (pp_c_type_specifier): Likewise.
* stor-layout.c (layout_type): Likewise.
* ipa-type-escape.c (type_to_consider): Likewise.
* gimplify.c (omp_firstprivatize_type_sizes,
gimplify_type_sizes): Likewise.
* explow.c (promote_mode): Likewise.
* tree-sra.c (is_sra_scalar_type): Likewise.
* varasm.c (output_constant): Likewise.
* tree-inline.c (remap_type_1): Likewise.
* convert.c (convert_to_pointer, convert_to_real,
convert_to_integer, convert_to_complex): Likewise.
From-SVN: r110775
|
|
PR 23196
* explow.c (memory_address): Remove special-case for
virtual_stack_vars_rtx and virtual_incoming_args_rtx.
From-SVN: r102668
|
|
2005-07-14 Richard Guenther <rguenther@suse.de>
* Makefile.in (explow.o, reg-stack.o): Depend on target.h.
* calls.c (expand_call): Pass fntype to hard_function_value.
(emit_library_call_value_1): Likewise.
* explow.c: Include target.h.
(hard_function_value): Take extra argument, the fntype.
Use new target hook for function_value.
* expr.h (hard_function_value): Change prototype.
* function.c (aggregate_value_p): Pass 0 as fntype to
hard_function_value.
(assign_parms): Use new target hook for function_value.
Pass 0 as fntype to hard_function_value.
(expand_function_end): Likewise.
* reg-stack.c: Include target.h.
(stack_result): Use new target hook for function_value.
* target-def.h: New target hook function_value.
* target.h: Likewise.
* targhooks.c (default_function_value): New function.
* targhooks.h (default_function_value): Declare.
From-SVN: r102013
|
|
From-SVN: r101317
|
|
From-SVN: r98881
|