GCC Middle and Back End API Reference
|
#include "config.h"
#include "system.h"
#include "coretypes.h"
#include "memmodel.h"
#include "backend.h"
#include "target.h"
#include "rtl.h"
#include "tree.h"
#include "df.h"
#include "tm_p.h"
#include "stringpool.h"
#include "insn-config.h"
#include "regs.h"
#include "emit-rtl.h"
#include "recog.h"
#include "diagnostic-core.h"
#include "alias.h"
#include "fold-const.h"
#include "varasm.h"
#include "cfgrtl.h"
#include "tree-eh.h"
#include "explow.h"
#include "expr.h"
#include "builtins.h"
#include "rtl-iter.h"
#include "stor-layout.h"
#include "opts.h"
#include "optabs.h"
#include "predict.h"
#include "rtx-vector-builder.h"
#include "gimple.h"
#include "gimple-ssa.h"
#include "gimplify.h"
#include "gt-emit-rtl.h"
Data Structures | |
struct | const_int_hasher |
struct | const_wide_int_hasher |
struct | const_poly_int_hasher |
struct | reg_attr_hasher |
struct | const_double_hasher |
struct | const_fixed_hasher |
Macros | |
#define | initial_regno_reg_rtx (this_target_rtl->x_initial_regno_reg_rtx) |
#define | cur_insn_uid (crtl->emit.x_cur_insn_uid) |
#define | cur_debug_insn_uid (crtl->emit.x_cur_debug_insn_uid) |
#define | first_label_num (crtl->emit.x_first_label_num) |
#define cur_debug_insn_uid (crtl->emit.x_cur_debug_insn_uid) |
Referenced by get_max_insn_count(), init_emit(), make_debug_insn_raw(), and set_new_first_and_last_insn().
#define cur_insn_uid (crtl->emit.x_cur_insn_uid) |
Referenced by copy_delay_slot_insn(), emit_barrier(), emit_barrier_after(), emit_barrier_before(), emit_jump_table_data(), emit_label(), emit_label_after(), emit_label_before(), get_max_insn_count(), init_emit(), make_call_insn_raw(), make_debug_insn_raw(), make_insn_raw(), make_jump_insn_raw(), make_note_raw(), and set_new_first_and_last_insn().
#define first_label_num (crtl->emit.x_first_label_num) |
Referenced by get_first_label_num(), init_emit(), and maybe_set_first_label_num().
#define initial_regno_reg_rtx (this_target_rtl->x_initial_regno_reg_rtx) |
Referenced by init_emit(), and init_emit_regs().
References CALL_P, GET_CODE, JUMP_P, JUMP_TABLE_DATA_P, NONJUMP_INSN_P, PATTERN(), and reload_completed.
Referenced by add_cfis_to_fde(), bb_ok_for_noce_convert_multiple_sets(), bb_valid_for_noce_process_p(), bbs_ok_for_cmove_arith(), can_fallthru(), count_bb_insns(), emit_pattern_after_setloc(), emit_pattern_before_setloc(), expensive_function_p(), flow_active_insn_p(), flow_find_cross_jump(), flow_find_head_matching_sequence(), init_noce_multiple_sets_info(), loop_exit_at_end_p(), maybe_add_nop_after_section_switch(), next_active_insn(), next_active_insn_bb(), noce_convert_multiple_sets_1(), noce_emit_all_but_last(), peep2_attempt(), prev_active_insn(), prev_active_insn_bb(), and reemit_insn_block_notes().
Append CALL_FUSAGE to the CALL_INSN_FUNCTION_USAGE for CALL_INSN.
References CALL_INSN_FUNCTION_USAGE, CALL_P, gcc_assert, and XEXP.
Referenced by emit_call_1(), and expand_builtin_apply().
void add_insn | ( | rtx_insn * | insn | ) |
Add INSN to the end of the doubly-linked list. INSN may be an INSN, JUMP_INSN, CALL_INSN, CODE_LABEL, BARRIER or NOTE.
References get_insns(), get_last_insn(), link_insn_into_chain(), NULL, set_first_insn(), and set_last_insn().
Referenced by address_reload_context::emit_autoinc(), emit_barrier(), emit_call_insn(), emit_debug_insn(), emit_insn(), emit_jump_insn(), emit_jump_table_data(), emit_label(), emit_libcall_block_1(), emit_note(), emit_note_copy(), inc_for_reload(), and noce_emit_czero().
void add_insn_after | ( | rtx_insn * | insn, |
rtx_insn * | after, | ||
basic_block | bb ) |
Like add_insn_after_nobb, but try to set BLOCK_FOR_INSN. If BB is NULL, an attempt is made to infer the bb from before. This and the next function should be the only functions called to insert an insn once delay slots have been filled since only they know how to update a SEQUENCE.
References add_insn_after_nobb(), BARRIER_P, BB_END, BLOCK_FOR_INSN(), df_insn_rescan(), INSN_P, NOTE_INSN_BASIC_BLOCK_P, and set_block_for_insn().
Referenced by delete_from_delay_slot(), emit_barrier_after(), emit_delay_sequence(), emit_label_after(), emit_note_after(), emit_pattern_after_noloc(), make_return_insns(), and relax_delay_slots().
Add INSN into the doubly-linked list after insn AFTER.
References rtx_insn::deleted(), gcc_assert, get_current_sequence(), sequence_stack::last, link_insn_into_chain(), sequence_stack::next, NEXT_INSN(), and NULL.
Referenced by add_insn_after(), and emit_note_after().
void add_insn_before | ( | rtx_insn * | insn, |
rtx_insn * | before, | ||
basic_block | bb ) |
Like add_insn_before_nobb, but try to set BLOCK_FOR_INSN. If BB is NULL, an attempt is made to infer the bb from before. This and the previous function should be the only functions called to insert an insn once delay slots have been filled since only they know how to update a SEQUENCE.
References add_insn_before_nobb(), BARRIER_P, BB_HEAD, BLOCK_FOR_INSN(), df_insn_rescan(), gcc_assert, INSN_P, NOTE_INSN_BASIC_BLOCK_P, and set_block_for_insn().
Referenced by emit_barrier_before(), emit_label_before(), emit_note_before(), and emit_pattern_before_noloc().
Add INSN into the doubly-linked list before insn BEFORE.
References rtx_insn::deleted(), sequence_stack::first, gcc_assert, get_current_sequence(), link_insn_into_chain(), sequence_stack::next, NULL, and PREV_INSN().
Referenced by add_insn_before(), and emit_note_before().
rtx adjust_address_1 | ( | rtx | memref, |
machine_mode | mode, | ||
poly_int64 | offset, | ||
int | validate, | ||
int | adjust_address, | ||
int | adjust_object, | ||
poly_int64 | size ) |
Return a memory reference like MEMREF, but with its mode changed to MODE and its address offset by OFFSET bytes. If VALIDATE is nonzero, the memory address is forced to be valid. If ADJUST_ADDRESS is zero, OFFSET is only used to update MEM_ATTRS and the caller is responsible for adjusting MEMREF base register. If ADJUST_OBJECT is zero, the underlying object associated with the memory reference is left unchanged and the caller is responsible for dealing with it. Otherwise, if the new memory reference is outside the underlying object, even partially, then the object is dropped. SIZE, if nonzero, is the size of an access in cases where MODE has no inherent size.
References adjust_address, change_address_1(), copy_rtx(), gcc_assert, get_address_mode(), GET_CODE, get_mem_attrs(), GET_MODE, GET_MODE_ALIGNMENT, known_eq, maybe_gt, memory_address_addr_space_p(), MIN, mode_mem_attrs, NULL_TREE, attrs::offset, offset, plus_constant(), set_mem_attrs(), mem_attrs::size, targetm, trunc_int_for_mode(), and XEXP.
Referenced by adjust_automodify_address_1(), store_expr(), and widen_memory_access().
rtx adjust_automodify_address_1 | ( | rtx | memref, |
machine_mode | mode, | ||
rtx | addr, | ||
poly_int64 | offset, | ||
int | validate ) |
Return a memory reference like MEMREF, but with its mode changed to MODE and its address changed to ADDR, which is assumed to be MEMREF offset by OFFSET bytes. If VALIDATE is nonzero, the memory address is forced to be valid.
References adjust_address_1(), change_address_1(), and offset.
void adjust_reg_mode | ( | rtx | reg, |
machine_mode | mode ) |
Adjust REG in-place so that it has mode MODE. It is assumed that the new register is a (possibly paradoxical) lowpart of the old one.
References byte_lowpart_offset(), GET_MODE, PUT_MODE(), and update_reg_offset().
Referenced by subst_mode(), try_combine(), and undo_to_marker().
poly_int64 byte_lowpart_offset | ( | machine_mode | outer_mode, |
machine_mode | inner_mode ) |
Return the number of bytes between the start of an OUTER_MODE in-memory value and the start of an INNER_MODE in-memory value, given that the former is a lowpart of the latter. It may be a paradoxical lowpart, in which case the offset will be negative on big-endian targets.
References paradoxical_subreg_p(), and subreg_lowpart_offset().
Referenced by adjust_reg_mode(), alter_subreg(), gen_lowpart_for_combine(), gen_lowpart_general(), gen_lowpart_if_possible(), replace_reg_with_saved_mem(), rtl_for_decl_location(), rtx_equal_for_field_assignment_p(), set_reg_attrs_for_decl_rtl(), set_reg_attrs_from_value(), simplify_immed_subreg(), track_loc_p(), var_lowpart(), and vt_add_function_parameter().
Like change_address_1 with VALIDATE nonzero, but we are not saying in what way we are changing MEMREF, so we only preserve the alias set.
References mem_attrs::align, attrs, change_address_1(), gen_rtx_MEM(), get_mem_attrs(), GET_MODE, mem_attrs_eq_p(), MEM_COPY_ATTRIBUTES, mode_mem_attrs, NULL_TREE, set_mem_attrs(), mem_attrs::size, mem_attrs::size_known_p, and XEXP.
Referenced by assign_parm_setup_block(), drop_writeback(), emit_block_cmp_via_loop(), emit_block_move_via_loop(), expand_assignment(), expand_builtin_init_trampoline(), expand_expr_real_1(), extract_writebacks(), store_expr(), and try_store_by_multiple_pieces().
|
static |
Return a memory reference like MEMREF, but with its mode changed to MODE and its address changed to ADDR. (VOIDmode means don't change the mode. NULL for ADDR means don't change the address.) VALIDATE is nonzero if the returned memory location is required to be valid. INPLACE is true if any changes can be made directly to MEMREF or false if MEMREF must be treated as immutable. The memory attributes are not changed.
References gcc_assert, gen_rtx_MEM(), GET_MODE, lra_in_progress, MEM_ADDR_SPACE, MEM_COPY_ATTRIBUTES, MEM_P, memory_address_addr_space(), memory_address_addr_space_p(), reload_completed, reload_in_progress, rtx_equal_p(), and XEXP.
Referenced by adjust_address_1(), adjust_automodify_address_1(), change_address(), offset_address(), replace_equiv_address(), and replace_equiv_address_nv().
void clear_mem_offset | ( | rtx | mem | ) |
Clear the offset of MEM.
References attrs, get_mem_attrs(), and set_mem_attrs().
Referenced by expand_partial_load_optab_fn(), expand_partial_store_optab_fn(), get_memory_rtx(), merge_memattrs(), and try_store_by_multiple_pieces().
void clear_mem_size | ( | rtx | mem | ) |
Clear the size of MEM.
References attrs, get_mem_attrs(), and set_mem_attrs().
Referenced by merge_memattrs().
rtx const_double_from_real_value | ( | REAL_VALUE_TYPE | value, |
machine_mode | mode ) |
Return a CONST_DOUBLE rtx for a floating-point value specified by VALUE in mode MODE.
References lookup_const_double(), PUT_MODE(), rtx_alloc(), rtx_def::u::rv, and rtx_def::u.
Referenced by avoid_constant_pool_reference(), compress_float_constant(), const_vector_from_tree(), expand_expr_real_1(), expand_fix(), expand_float(), fold_rtx(), init_emit_once(), native_decode_rtx(), relational_result(), simplify_context::simplify_binary_operation_1(), simplify_const_binary_operation(), and simplify_const_unary_operation().
rtx const_fixed_from_fixed_value | ( | FIXED_VALUE_TYPE | value, |
machine_mode | mode ) |
Return a CONST_FIXED rtx for a fixed-point value specified by VALUE in mode MODE.
References rtx_def::u::fv, lookup_const_fixed(), PUT_MODE(), rtx_alloc(), and rtx_def::u.
A subroutine of const_vec_series_p that handles the case in which: (GET_CODE (X) == CONST_VECTOR && CONST_VECTOR_NPATTERNS (X) == 1 && !CONST_VECTOR_DUPLICATE_P (X)) is known to hold.
References CONST0_RTX, CONST_VECTOR_ELT, CONST_VECTOR_ENCODED_ELT, CONST_VECTOR_NUNITS, CONST_VECTOR_STEPPED_P, GET_MODE, GET_MODE_CLASS, GET_MODE_INNER, rtx_equal_p(), and simplify_binary_operation().
Referenced by const_vec_series_p().
Return the value of element I of CONST_VECTOR X.
References CONST_VECTOR_ENCODED_ELT, const_vector_encoded_nelts(), const_vector_int_elt(), CONST_VECTOR_NPATTERNS, CONST_VECTOR_STEPPED_P, GET_MODE, GET_MODE_INNER, i, immed_wide_int_const(), and XVECLEN.
Return the value of element I of CONST_VECTOR X as a wide_int.
References wi::add(), CONST_VECTOR_ENCODED_ELT, const_vector_encoded_nelts(), CONST_VECTOR_NPATTERNS, CONST_VECTOR_STEPPED_P, count, GET_MODE, GET_MODE_INNER, i, wi::sub(), and XVECLEN.
Referenced by const_vector_elt().
Return a copy of INSN that can be used in a SEQUENCE delay slot, on that assumption that INSN itself remains in its original place.
References as_a(), copy_rtx(), cur_insn_uid, and INSN_UID().
Referenced by fill_simple_delay_slots(), fill_slots_from_thread(), and steal_delay_list_from_target().
Create a new copy of an rtx. This function differs from copy_rtx in that it handles SCRATCHes and ASM_OPERANDs properly. INSN doesn't really have to be a full INSN; it could be just the pattern.
References copy_asm_constraints_vector, copy_asm_operands_vector, copy_insn_1(), copy_insn_n_scratches, orig_asm_constraints_vector, and orig_asm_operands_vector.
Referenced by bypass_block(), compare_and_jump_seq(), do_remat(), eliminate_partially_redundant_load(), eliminate_regs_in_insn(), emit_copy_of_insn_after(), lra_process_new_insns(), and try_optimize_cfg().
Recursively create a new copy of an rtx for copy_insn. This function differs from copy_rtx in that it handles SCRATCHes and ASM_OPERANDs properly. Normally, this function is not used directly; use copy_insn as front end. However, you could first copy an insn pattern with copy_insn and then use this function afterwards to properly copy any REG_NOTEs containing SCRATCHes.
References ASM_OPERANDS_INPUT_CONSTRAINT_VEC, ASM_OPERANDS_INPUT_VEC, CASE_CONST_ANY, copy_asm_constraints_vector, copy_asm_operands_vector, copy_insn_1(), copy_insn_n_scratches, copy_insn_scratch_in, copy_insn_scratch_out, gcc_assert, gcc_unreachable, GET_CODE, GET_RTX_FORMAT, GET_RTX_LENGTH, HARD_REGISTER_NUM_P, i, INSN_P, NULL, orig_asm_constraints_vector, orig_asm_operands_vector, ORIGINAL_REGNO, REG_P, REGNO, rtvec_alloc(), RTX_CODE, RTX_FLAG, shallow_copy_rtx(), shared_const_p(), XEXP, XVEC, XVECEXP, and XVECLEN.
Referenced by copy_insn(), copy_insn_1(), duplicate_reg_note(), eliminate_regs_in_insn(), and gcse_emit_move_after().
Mark ORIG as in use, and return a copy of it if it was already in use. Recursively does the same for subexpressions. Uses copy_rtx_if_shared_1 to reduce stack space.
References copy_rtx_if_shared_1().
Referenced by emit_notes_in_bb(), try_combine(), unshare_all_rtl(), unshare_all_rtl_1(), and unshare_all_rtl_in_chain().
|
static |
Mark *ORIG1 as in use, and set it to a copy of it if it was already in use. Recursively does the same for subexpressions.
References CASE_CONST_ANY, copy_rtx_if_shared_1(), gen_rtvec_v(), GET_CODE, GET_RTX_FORMAT, GET_RTX_LENGTH, HARD_REGISTER_NUM_P, i, NULL, ORIGINAL_REGNO, REG_P, REGNO, RTX_FLAG, shallow_copy_rtx(), shared_const_p(), XEXP, XVEC, XVECEXP, and XVECLEN.
Referenced by copy_rtx_if_shared(), and copy_rtx_if_shared_1().
location_t curr_insn_location | ( | void | ) |
Get current location.
References curr_location.
Referenced by expand_expr_real_1(), expand_expr_real_gassign(), expand_gimple_basic_block(), expand_gimple_cond(), expand_thunk(), make_call_insn_raw(), make_debug_insn_raw(), make_insn_raw(), make_jump_insn_raw(), and store_expr().
void delete_insns_since | ( | rtx_insn * | from | ) |
Delete all insns made since FROM. FROM becomes the new last instruction.
References set_first_insn(), set_last_insn(), and SET_NEXT_INSN().
Referenced by base_to_reg(), can_widen_mult_without_libcall(), default_zero_call_used_regs(), emit_add3_insn(), address_reload_context::emit_autoinc(), emit_conditional_add(), emit_conditional_move(), emit_conditional_neg_or_complement(), emit_cstore(), emit_insn_if_valid_for_reload_1(), emit_store_flag(), emit_store_flag_int(), expand_abs_nojump(), expand_addsub_overflow(), expand_atomic_load(), expand_atomic_store(), expand_binop(), expand_binop_directly(), expand_builtin_interclass_mathfn(), expand_builtin_issignaling(), expand_builtin_signbit(), expand_ccmp_expr(), expand_DIVMOD(), expand_divmod(), expand_doubleword_shift(), expand_fix(), expand_mul_overflow(), expand_neg_overflow(), expand_one_cmpl_abs_nojump(), expand_parity(), expand_sfix_optab(), expand_twoval_binop(), expand_twoval_unop(), expand_unop(), expand_unop_direct(), expand_vec_perm_const(), extract_integral_bit_field(), force_subreg(), gen_reload_chain_without_interm_reg_p(), inc_for_reload(), lra_emit_add(), maybe_emit_sync_lock_test_and_set(), maybe_legitimize_operand_same_code(), maybe_legitimize_operands(), move_block_from_reg(), move_block_to_reg(), prepare_cmp_insn(), process_address_1(), store_bit_field_using_insv(), store_integral_bit_field(), widen_bswap(), and widen_leading().
Emit the rtl pattern X as an appropriate kind of insn. Also emit a following barrier if the instruction needs one and if ALLOW_BARRIER_P is true. If X is a label, it is simply added into the insn chain.
References any_uncondjump_p(), classify_insn(), emit_barrier(), emit_call_insn(), emit_debug_insn(), emit_insn(), emit_jump_insn(), emit_label(), gcc_unreachable, and GET_CODE.
Referenced by ensure_regno(), and gen_reg_rtx().
rtx_barrier * emit_barrier | ( | void | ) |
Make an insn of code BARRIER and add it to the end of the doubly-linked list.
References add_insn(), as_a(), cur_insn_uid, INSN_UID(), and rtx_alloc().
Referenced by allocate_dynamic_stack_space(), compare_by_pieces(), do_tablejump(), duplicate_insn_chain(), emit(), emit_case_dispatch_table(), emit_indirect_jump(), emit_jump(), expand_builtin_return(), expand_builtin_trap(), expand_builtin_unreachable(), expand_divmod(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_shift(), expand_expr_real_2(), expand_fix(), expand_float(), find_end_label(), and store_expr().
rtx_barrier * emit_barrier_after | ( | rtx_insn * | after | ) |
Make an insn of code BARRIER and output it after the insn AFTER.
References add_insn_after(), as_a(), cur_insn_uid, INSN_UID(), NULL, and rtx_alloc().
Referenced by commit_one_edge_insertion(), delete_from_delay_slot(), emit_barrier_after_bb(), emit_library_call_value_1(), expand_call(), find_cond_trap(), fixup_reorder_chain(), make_return_insns(), try_optimize_cfg(), try_redirect_by_replacing_jump(), and update_cfg_for_uncondjump().
rtx_barrier * emit_barrier_before | ( | rtx_insn * | before | ) |
Make an insn of code BARRIER and output it before the insn BEFORE.
References add_insn_before(), as_a(), cur_insn_uid, INSN_UID(), NULL, and rtx_alloc().
Make an insn of code CALL_INSN with pattern X and add it to the end of the doubly-linked list.
References add_insn(), emit_insn(), gcc_unreachable, GET_CODE, and make_call_insn_raw().
Referenced by emit().
Like emit_call_insn_after_noloc, but set INSN_LOCATION according to AFTER.
References emit_pattern_after(), and make_call_insn_raw().
Referenced by emit_copy_of_insn_after().
Make an instruction with body X and code CALL_INSN and output it after the instruction AFTER.
References emit_pattern_after_noloc(), make_call_insn_raw(), and NULL.
Like emit_call_insn_after_noloc, but set INSN_LOCATION according to LOC.
References emit_pattern_after_setloc(), and make_call_insn_raw().
Like emit_call_insn_before_noloc, but set insn_location according to BEFORE.
References emit_pattern_before(), and make_call_insn_raw().
Make an instruction with body X and code CALL_INSN and output it before the instruction BEFORE.
References emit_pattern_before_noloc(), make_call_insn_raw(), and NULL.
Like emit_insn_before_noloc, but set INSN_LOCATION according to LOC.
References emit_pattern_before_setloc(), and make_call_insn_raw().
Emit a clobber of lvalue X.
References emit_clobber(), emit_insn(), GET_CODE, and XEXP.
Referenced by convert_mode_scalar(), do_clobber_return_reg(), emit_clobber(), emit_move_complex_parts(), emit_move_multi_word(), emit_stack_restore(), expand_binop(), expand_builtin_longjmp(), expand_builtin_nonlocal_goto(), expand_builtin_setjmp_receiver(), expand_clobber(), expand_doubleword_bswap(), expand_eh_return(), extract_integral_bit_field(), gen_clobber(), initialize_uninitialized_regs(), match_reload(), resolve_simple_move(), store_constructor(), and widen_operand().
Produce exact duplicate of insn INSN after AFTER. Care updating of libcall regions if present.
References CALL_INSN_FUNCTION_USAGE, copy_insn(), CROSSING_JUMP_P, duplicate_reg_note(), emit_call_insn_after(), emit_debug_insn_after(), emit_insn_after(), emit_jump_insn_after(), gcc_unreachable, GET_CODE, INSN_CODE, INSN_LOCATION(), mark_jump_label(), NONDEBUG_INSN_P, NULL_RTX, PATTERN(), REG_NOTE_KIND, REG_NOTES, RTL_CONST_CALL_P, RTL_LOOPING_CONST_OR_PURE_CALL_P, RTL_PURE_CALL_P, RTX_FRAME_RELATED_P, SIBLING_CALL_P, and XEXP.
Referenced by duplicate_insn_chain(), make_return_insns(), and relax_delay_slots().
Make an insn of code DEBUG_INSN with pattern X and add it to the end of the doubly-linked list.
References add_insn(), as_a(), gcc_unreachable, GET_CODE, get_last_insn(), last, make_debug_insn_raw(), sequence_stack::next, NEXT_INSN(), and NULL_RTX.
Referenced by emit(), and expand_gimple_basic_block().
Like emit_debug_insn_after_noloc, but set INSN_LOCATION according to AFTER.
References emit_pattern_after(), and make_debug_insn_raw().
Referenced by dead_debug_insert_temp(), and emit_copy_of_insn_after().
Make an instruction with body X and code CALL_INSN and output it after the instruction AFTER.
References emit_pattern_after_noloc(), make_debug_insn_raw(), and NULL.
Like emit_debug_insn_after_noloc, but set INSN_LOCATION according to LOC.
References emit_pattern_after_setloc(), and make_debug_insn_raw().
Like emit_debug_insn_before_noloc, but set insn_location according to BEFORE.
References emit_pattern_before(), and make_debug_insn_raw().
Referenced by avoid_complex_debug_insns(), dead_debug_insert_temp(), dead_debug_promote_uses(), delete_trivially_dead_insns(), and propagate_for_debug_subst().
Make an instruction with body X and code DEBUG_INSN and output it before the instruction BEFORE.
References emit_pattern_before_noloc(), make_debug_insn_raw(), and NULL.
Like emit_insn_before_noloc, but set INSN_LOCATION according to LOC.
References emit_pattern_before_setloc(), and make_debug_insn_raw().
Take X and emit it at the end of the doubly-linked INSN list. Returns the last insn emitted.
References add_insn(), as_a(), gcc_unreachable, GET_CODE, get_last_insn(), last, make_insn_raw(), sequence_stack::next, NEXT_INSN(), and NULL_RTX.
Referenced by allocate_dynamic_stack_space(), anti_adjust_stack_and_probe_stack_clash(), asan_clear_shadow(), assign_parm_setup_reg(), assign_parms(), base_to_reg(), check_and_process_move(), compute_can_copy(), convert_mode_scalar(), curr_insn_transform(), default_speculation_safe_value(), do_compare_and_jump(), do_remat(), emit(), emit_add2_insn(), emit_add3_insn(), address_reload_context::emit_autoinc(), emit_call_1(), emit_call_insn(), emit_clobber(), emit_delay_sequence(), emit_inc_dec_insn_before(), emit_input_reload_insns(), emit_insn_if_valid_for_reload_1(), emit_move_ccmode(), emit_move_insn_1(), emit_move_list(), emit_move_multi_word(), emit_move_via_integer(), emit_output_reload_insns(), emit_stack_probe(), emit_stack_restore(), emit_stack_save(), emit_use(), expand_absneg_bit(), expand_asm_loc(), expand_asm_memory_blockage(), expand_asm_reg_clobber_mem_blockage(), expand_asm_stmt(), expand_atomic_fetch_op(), expand_binop(), expand_binop_directly(), expand_builtin_apply(), expand_builtin_feclear_feraise_except(), expand_builtin_fegetround(), expand_builtin_goacc_parlevel_id_size(), expand_builtin_int_roundingfn(), expand_builtin_int_roundingfn_2(), expand_builtin_longjmp(), expand_builtin_mathfn_3(), expand_builtin_mathfn_ternary(), expand_builtin_nonlocal_goto(), expand_builtin_prefetch(), expand_builtin_return(), expand_builtin_setjmp_receiver(), expand_builtin_setjmp_setup(), expand_builtin_trap(), expand_call(), expand_ccmp_expr(), expand_clrsb_using_clz(), expand_compare_and_swap_loop(), expand_cond_expr_using_cmove(), expand_copysign_bit(), expand_ctz(), expand_DIVMOD(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_popcount(), expand_dw2_landing_pad_for_region(), expand_eh_return(), expand_expr_divmod(), expand_expr_real_1(), expand_expr_real_2(), expand_ffs(), expand_function_end(), expand_GOACC_DIM_POS(), expand_GOACC_DIM_SIZE(), expand_GOMP_SIMT_LANE(), expand_mem_thread_fence(), expand_memory_blockage(), expand_POPCOUNT(), expand_sdiv_pow2(), expand_UNIQUE(), expand_unop(), expand_unop_direct(), expand_vector_broadcast(), expmed_mult_highpart_optab(), find_shift_sequence(), gen_cond_trap(), gen_reload(), gen_reload_chain_without_interm_reg_p(), move_by_pieces_d::generate(), store_by_pieces_d::generate(), inc_for_reload(), pieces_addr::increment_address(), inline_string_cmp(), insert_insn_on_edge(), insert_move_for_subreg(), ira(), lra_emit_move(), lra_process_new_insns(), make_prologue_seq(), make_split_prologue_seq(), match_reload(), maybe_emit_unop_insn(), maybe_expand_insn(), maybe_optimize_mod_cmp(), maybe_optimize_pow2p_mod_cmp(), move_block_from_reg(), move_block_to_reg(), noce_convert_multiple_sets_1(), noce_emit_all_but_last(), noce_emit_cmove(), noce_emit_insn(), noce_emit_move_insn(), noce_emit_store_flag(), prepare_call_address(), prepare_cmp_insn(), prepare_copy_insn(), prepend_insn_to_edge(), probe_stack_range(), process_addr_reg(), process_address_1(), remove_inheritance_pseudos(), stack_protect_epilogue(), stack_protect_prologue(), store_constructor(), and thread_prologue_and_epilogue_insns().
Like emit_insn_after_noloc, but set INSN_LOCATION according to AFTER.
References emit_pattern_after(), and make_insn_raw().
Referenced by combine_var_copies_in_loop_exit(), doloop_modify(), eliminate_regs_in_insn(), emit_common_heads_for_components(), emit_common_tails_for_components(), emit_copy_of_insn_after(), emit_moves(), emit_reload_insns(), expand_builtin_saveregs(), expand_builtin_strlen(), expand_function_end(), fill_slots_from_thread(), find_and_remove_re(), find_moveable_pseudos(), find_reloads(), gcse_emit_move_after(), get_arg_pointer_save_area(), insert_one_insn(), insert_prologue_epilogue_for_components(), insert_var_expansion_initialization(), lra_process_new_insns(), maybe_add_nop_after_section_switch(), move_insn_for_shrink_wrap(), move_invariant_reg(), move_unallocated_pseudos(), pre_insert_copy_insn(), replace_store_insn(), resolve_clobber(), rtl_lv_add_condition_to_bb(), sjlj_emit_function_enter(), sjlj_emit_function_exit(), split_edge_and_insert(), split_live_ranges_for_shrink_wrap(), and try_merge_compare().
|
static |
Helper for emit_insn_after, handles lists of instructions efficiently.
References BARRIER_P, BB_END, BLOCK_FOR_INSN(), df_insn_rescan(), df_set_bb_dirty(), sequence_stack::first, get_last_insn(), last, NEXT_INSN(), set_block_for_insn(), set_last_insn(), SET_NEXT_INSN(), and SET_PREV_INSN().
Referenced by emit_pattern_after_noloc().
rtx_insn * emit_insn_after_noloc | ( | rtx | x, |
rtx_insn * | after, | ||
basic_block | bb ) |
Make X be output after the insn AFTER and set the BB of insn. If BB is NULL, an attempt is made to infer the BB from AFTER.
References emit_pattern_after_noloc(), and make_insn_raw().
Referenced by cfg_layout_merge_blocks(), commit_one_edge_insertion(), emit_nop_for_unique_locus_between(), expand_gimple_basic_block(), fixup_reorder_chain(), insert_insn_end_basic_block(), insert_insn_start_basic_block(), and lra_process_new_insns().
Like emit_insn_after_noloc, but set INSN_LOCATION according to LOC.
References emit_pattern_after_setloc(), and make_insn_raw().
Referenced by peep2_attempt(), and try_split().
Like emit_insn_before_noloc, but set INSN_LOCATION according to BEFORE.
References emit_pattern_before(), and make_insn_raw().
Referenced by attempt_change(), combine_and_move_insns(), emit_common_tails_for_components(), emit_inc_dec_insn_before(), emit_moves(), emit_reload_insns(), emit_to_new_bb_before(), expand_builtin_apply_args(), expand_builtin_strlen(), expand_function_end(), find_moveable_pseudos(), find_reloads(), find_reloads_address(), find_reloads_subreg_address(), find_reloads_toplev(), fix_crossing_unconditional_branches(), force_move_args_size_note(), gen_call_used_regs_seq(), hwasan_maybe_emit_frame_base_init(), initialize_uninitialized_regs(), insert_base_initialization(), insert_one_insn(), insert_prologue_epilogue_for_components(), instantiate_virtual_regs_in_insn(), lra_process_new_insns(), make_more_copies(), match_asm_constraints_1(), pre_insert_copy_insn(), replace_read(), resolve_shift_zext(), resolve_simple_move(), sjlj_emit_function_enter(), sjlj_mark_call_sites(), split_iv(), subst_reg_equivs(), thread_prologue_and_epilogue_insns(), try_optimize_cfg(), update_block(), and update_ld_motion_stores().
rtx_insn * emit_insn_before_noloc | ( | rtx | x, |
rtx_insn * | before, | ||
basic_block | bb ) |
Make X be output before the instruction BEFORE.
References emit_pattern_before_noloc(), and make_insn_raw().
Referenced by commit_one_edge_insertion(), insert_insn_end_basic_block(), and lra_process_new_insns().
Like emit_insn_before_noloc, but set INSN_LOCATION according to LOC.
References emit_pattern_before_setloc(), and make_insn_raw().
Referenced by cond_move_process_if_block(), emit_to_new_bb_before(), find_cond_trap(), noce_convert_multiple_sets(), noce_process_if_block(), noce_try_abs(), noce_try_addcc(), noce_try_bitop(), noce_try_cmove(), noce_try_cmove_arith(), noce_try_cond_zero_arith(), noce_try_ifelse_collapse(), noce_try_inverse_constants(), noce_try_minmax(), noce_try_move(), noce_try_sign_mask(), noce_try_store_flag(), noce_try_store_flag_constants(), and noce_try_store_flag_mask().
Make an insn of code JUMP_INSN with pattern X and add it to the end of the doubly-linked list.
References add_insn(), as_a(), gcc_unreachable, GET_CODE, last, make_jump_insn_raw(), sequence_stack::next, NEXT_INSN(), and NULL.
Referenced by compare_and_jump_seq(), create_eh_forwarder_block(), do_tablejump(), emit(), emit_cmp_and_jump_insn_1(), emit_jump(), emit_likely_jump_insn(), emit_unlikely_jump_insn(), expand_asm_stmt(), expand_builtin_return(), expand_divmod(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_shift(), expand_expr_real_2(), expand_fix(), expand_float(), find_end_label(), fix_crossing_conditional_branches(), get_uncond_jump_length(), make_epilogue_seq(), maybe_expand_jump_insn(), and store_expr().
rtx_jump_insn * emit_jump_insn_after | ( | rtx | pattern, |
rtx_insn * | after ) |
Like emit_jump_insn_after_noloc, but set INSN_LOCATION according to AFTER.
References as_a(), emit_pattern_after(), and make_jump_insn_raw().
Referenced by add_labels_and_missing_jumps(), doloop_modify(), emit_copy_of_insn_after(), find_cond_trap(), and handle_simple_exit().
rtx_jump_insn * emit_jump_insn_after_noloc | ( | rtx | x, |
rtx_insn * | after ) |
Make an insn of code JUMP_INSN with body X and output it after the insn AFTER.
References as_a(), emit_pattern_after_noloc(), make_jump_insn_raw(), and NULL.
Referenced by try_redirect_by_replacing_jump().
rtx_jump_insn * emit_jump_insn_after_setloc | ( | rtx | pattern, |
rtx_insn * | after, | ||
location_t | loc ) |
Like emit_jump_insn_after_noloc, but set INSN_LOCATION according to LOC.
References as_a(), emit_pattern_after_setloc(), and make_jump_insn_raw().
Referenced by force_nonfallthru_and_redirect().
rtx_jump_insn * emit_jump_insn_before | ( | rtx | pattern, |
rtx_insn * | before ) |
Like emit_jump_insn_before_noloc, but set INSN_LOCATION according to BEFORE.
References as_a(), emit_pattern_before(), and make_jump_insn_raw().
Referenced by cse_insn().
rtx_jump_insn * emit_jump_insn_before_noloc | ( | rtx | x, |
rtx_insn * | before ) |
Make an instruction with body X and code JUMP_INSN and output it before the instruction BEFORE.
References as_a(), emit_pattern_before_noloc(), make_jump_insn_raw(), and NULL.
rtx_jump_insn * emit_jump_insn_before_setloc | ( | rtx | pattern, |
rtx_insn * | before, | ||
location_t | loc ) |
like emit_insn_before_noloc, but set INSN_LOCATION according to LOC.
References as_a(), emit_pattern_before_setloc(), and make_jump_insn_raw().
rtx_jump_table_data * emit_jump_table_data | ( | rtx | table | ) |
Make an insn of code JUMP_TABLE_DATA and add it to the end of the doubly-linked list.
References add_insn(), as_a(), BLOCK_FOR_INSN(), cur_insn_uid, INSN_UID(), NULL, PATTERN(), rtx_alloc(), and table.
Referenced by emit_case_dispatch_table().
rtx_code_label * emit_label | ( | rtx | uncast_label | ) |
Add the label LABEL to the end of the doubly-linked list.
References add_insn(), as_a(), cur_insn_uid, gcc_checking_assert, and INSN_UID().
Referenced by allocate_dynamic_stack_space(), anti_adjust_stack_and_probe(), anti_adjust_stack_and_probe_stack_clash(), asan_clear_shadow(), asan_emit_stack_protection(), compare_by_pieces(), create_eh_forwarder_block(), do_compare_rtx_and_jump(), do_jump(), do_jump_1(), do_jump_by_parts_equality_rtx(), do_jump_by_parts_greater_rtx(), do_jump_by_parts_zero_rtx(), dw2_build_landing_pads(), emit(), emit_block_cmp_via_loop(), emit_block_move_via_loop(), emit_block_move_via_oriented_loop(), emit_case_dispatch_table(), emit_stack_clash_protection_probe_loop_end(), emit_stack_clash_protection_probe_loop_start(), emit_store_flag_force(), expand_abs(), expand_addsub_overflow(), expand_arith_overflow_result_store(), expand_asm_stmt(), expand_builtin_atomic_compare_exchange(), expand_builtin_strub_leave(), expand_builtin_strub_update(), expand_compare_and_swap_loop(), expand_copysign_absneg(), expand_divmod(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_shift(), expand_eh_return(), expand_expr_real_1(), expand_expr_real_2(), expand_ffs(), expand_fix(), expand_float(), expand_function_end(), expand_gimple_basic_block(), expand_label(), expand_mul_overflow(), expand_neg_overflow(), expand_sdiv_pow2(), expand_sjlj_dispatch_table(), expand_smod_pow2(), expand_vector_ubsan_overflow(), find_end_label(), fix_crossing_conditional_branches(), get_uncond_jump_length(), inline_string_cmp(), prepare_call_address(), probe_stack_range(), sjlj_emit_dispatch_table(), stack_protect_epilogue(), store_constructor(), store_expr(), and try_store_by_multiple_pieces().
Emit the label LABEL after the insn AFTER.
References add_insn_after(), cur_insn_uid, gcc_checking_assert, INSN_UID(), and NULL.
Referenced by find_end_label(), and get_label_before().
rtx_code_label * emit_label_before | ( | rtx_code_label * | label, |
rtx_insn * | before ) |
Emit the label LABEL before the insn BEFORE.
References add_insn_before(), cur_insn_uid, gcc_checking_assert, INSN_UID(), and NULL.
Referenced by block_label().
Make an insn of code JUMP_INSN with pattern X, add a REG_BR_PROB note that indicates very likely probability, and add it to the end of the doubly-linked list.
References add_reg_br_prob_note(), emit_jump_insn(), and profile_probability::very_likely().
Make an insn of code NOTE or type NOTE_NO and add it to the end of the doubly-linked list.
References add_insn(), and make_note_raw().
Referenced by duplicate_insn_chain(), expand_function_start(), expand_gimple_basic_block(), lra(), make_epilogue_seq(), make_prologue_seq(), reemit_insn_block_notes(), reload(), reload_as_needed(), thread_prologue_and_epilogue_insns(), and update_sjlj_context().
Emit a note of subtype SUBTYPE after the insn AFTER.
References add_insn_after(), add_insn_after_nobb(), BARRIER_P, BB_END, BLOCK_FOR_INSN(), make_note_raw(), note_outside_basic_block_p(), and NULL.
Referenced by add_cfi(), create_basic_block_structure(), emit_note_eh_region_end(), emit_note_insn_var_location(), expand_gimple_basic_block(), handle_simple_exit(), reemit_insn_block_notes(), rtl_split_block(), and thread_prologue_and_epilogue_insns().
Emit a note of subtype SUBTYPE before the insn BEFORE.
References add_insn_before(), add_insn_before_nobb(), BARRIER_P, BB_HEAD, BLOCK_FOR_INSN(), make_note_raw(), note_outside_basic_block_p(), and NULL.
Referenced by add_cfis_to_fde(), change_scope(), convert_to_eh_region_ranges(), create_basic_block_structure(), emit_note_insn_var_location(), insert_section_boundary_note(), reemit_insn_block_notes(), and reemit_marker_as_note().
Emit a copy of note ORIG.
References add_insn(), make_note_raw(), NOTE_DATA, and NOTE_KIND.
Referenced by duplicate_insn_chain().
|
static |
Insert PATTERN after AFTER. MAKE_RAW indicates how to turn PATTERN into a real insn. SKIP_DEBUG_INSNS indicates whether to insert after any DEBUG_INSNs.
References DEBUG_INSN_P, emit_pattern_after_noloc(), emit_pattern_after_setloc(), INSN_LOCATION(), INSN_P, NULL, and PREV_INSN().
Referenced by emit_call_insn_after(), emit_debug_insn_after(), emit_insn_after(), and emit_jump_insn_after().
|
static |
References add_insn_after(), as_a(), emit_insn_after_1(), gcc_assert, gcc_unreachable, GET_CODE, last, and NULL_RTX.
Referenced by emit_call_insn_after_noloc(), emit_debug_insn_after_noloc(), emit_insn_after_noloc(), emit_jump_insn_after_noloc(), emit_pattern_after(), and emit_pattern_after_setloc().
|
static |
Insert PATTERN after AFTER, setting its INSN_LOCATION to LOC. MAKE_RAW indicates how to turn PATTERN into a real insn.
References active_insn_p(), emit_pattern_after_noloc(), INSN_LOCATION(), JUMP_TABLE_DATA_P, last, NEXT_INSN(), NULL, and NULL_RTX.
Referenced by emit_call_insn_after_setloc(), emit_debug_insn_after_setloc(), emit_insn_after_setloc(), emit_jump_insn_after_setloc(), and emit_pattern_after().
|
static |
Insert PATTERN before BEFORE. MAKE_RAW indicates how to turn PATTERN into a real insn. SKIP_DEBUG_INSNS indicates whether to insert before any DEBUG_INSNs. INSNP indicates if PATTERN is meant for an INSN as opposed to a JUMP_INSN, CALL_INSN, etc.
References DEBUG_INSN_P, emit_pattern_before_noloc(), emit_pattern_before_setloc(), INSN_LOCATION(), INSN_P, sequence_stack::next, NULL, and PREV_INSN().
Referenced by emit_call_insn_before(), emit_debug_insn_before(), emit_insn_before(), and emit_jump_insn_before().
|
static |
Emit insn(s) of given code and pattern at a specified place within the doubly-linked list. All of the emit_foo global entry points accept an object X which is either an insn list or a PATTERN of a single instruction. There are thus a few canonical ways to generate code and emit it at a specific place in the instruction stream. For example, consider the instruction named SPOT and the fact that we would like to emit some instructions before SPOT. We might do it like this: start_sequence (); ... emit the new instructions ... insns_head = get_insns (); end_sequence (); emit_insn_before (insns_head, SPOT); It used to be common to generate SEQUENCE rtl instead, but that is a relic of the past which no longer occurs. The reason is that SEQUENCE rtl results in much fragmented RTL memory since the SEQUENCE generated would almost certainly die right after it was created.
References add_insn_before(), as_a(), gcc_assert, gcc_unreachable, GET_CODE, last, sequence_stack::next, NEXT_INSN(), and NULL_RTX.
Referenced by emit_call_insn_before_noloc(), emit_debug_insn_before_noloc(), emit_insn_before_noloc(), emit_jump_insn_before_noloc(), emit_pattern_before(), and emit_pattern_before_setloc().
|
static |
Insert PATTERN before BEFORE, setting its INSN_LOCATION to LOC. MAKE_RAW indicates how to turn PATTERN into a real insn. INSNP indicates if PATTERN is meant for an INSN as opposed to a JUMP_INSN, CALL_INSN, etc.
References active_insn_p(), emit_pattern_before_noloc(), sequence_stack::first, get_insns(), INSN_LOCATION(), JUMP_TABLE_DATA_P, last, NEXT_INSN(), NULL, NULL_RTX, and PREV_INSN().
Referenced by emit_call_insn_before_setloc(), emit_debug_insn_before_setloc(), emit_insn_before_setloc(), emit_jump_insn_before_setloc(), and emit_pattern_before().
Make an insn of code JUMP_INSN with pattern X, add a REG_BR_PROB note that indicates very unlikely probability, and add it to the end of the doubly-linked list.
References add_reg_br_prob_note(), emit_jump_insn(), and profile_probability::very_unlikely().
Emit a use of rvalue X.
References emit_insn(), emit_use(), GET_CODE, and XEXP.
Referenced by do_use_return_reg(), emit_use(), expand_builtin_longjmp(), expand_builtin_nonlocal_goto(), expand_builtin_return(), expand_builtin_setjmp_receiver(), gen_use(), and make_prologue_seq().
void end_sequence | ( | void | ) |
After emitting to a sequence, restore previous saved state. To get the contents of the sequence just made, you must call `get_insns' *before* calling here. If the compiler might have deferred popping arguments while generating this sequence, and this sequence will not be immediately inserted into the instruction stream, use do_pending_stack_adjust before calling get_insns. That will ensure that the deferred pops are inserted into this sequence, and not into some random location in the instruction stream. See INHIBIT_DEFER_POP for more information about deferred popping of arguments.
References sequence_stack::first, free_sequence_stack, get_current_sequence(), sequence_stack::last, sequence_stack::next, set_first_insn(), and set_last_insn().
Referenced by add_test(), asan_clear_shadow(), asan_emit_allocas_unpoison(), asan_emit_stack_protection(), assign_parm_setup_block(), assign_parm_setup_reg(), assign_parm_setup_stack(), assign_parms_unsplit_complex(), attempt_change(), check_and_process_move(), combine_reaching_defs(), combine_var_copies_in_loop_exit(), compare_and_jump_seq(), computation_cost(), compute_can_copy(), cond_move_process_if_block(), convert_mode_scalar(), curr_insn_transform(), do_remat(), doloop_modify(), dw2_build_landing_pads(), emit_common_heads_for_components(), emit_common_tails_for_components(), emit_delay_sequence(), emit_inc_dec_insn_before(), emit_initial_value_sets(), emit_input_reload_insns(), emit_move_list(), emit_move_multi_word(), emit_output_reload_insns(), emit_partition_copy(), end_ifcvt_sequence(), expand_absneg_bit(), expand_asm_stmt(), expand_atomic_fetch_op(), expand_binop(), expand_builtin_apply_args(), expand_builtin_int_roundingfn(), expand_builtin_int_roundingfn_2(), expand_builtin_mathfn_3(), expand_builtin_mathfn_ternary(), expand_builtin_return(), expand_builtin_saveregs(), expand_builtin_strlen(), expand_call(), expand_clrsb_using_clz(), expand_cond_expr_using_cmove(), expand_copysign_bit(), expand_ctz(), expand_DIVMOD(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_popcount(), expand_dummy_function_end(), expand_expr_divmod(), expand_expr_real_2(), expand_ffs(), expand_fix(), expand_fixed_convert(), expand_float(), expand_function_end(), expand_POPCOUNT(), expand_sdiv_pow2(), expand_twoval_binop_libfunc(), expand_unop(), expmed_mult_highpart_optab(), find_shift_sequence(), fix_crossing_unconditional_branches(), gen_call_used_regs_seq(), gen_clobber(), gen_cond_trap(), gen_move_insn(), gen_use(), get_arg_pointer_save_area(), get_uncond_jump_length(), hwasan_emit_untag_frame(), hwasan_frame_base(), inherit_in_ebb(), inherit_reload_reg(), init_set_costs(), initialize_uninitialized_regs(), inline_string_cmp(), insert_base_initialization(), insert_insn_on_edge(), insert_move_for_subreg(), insert_prologue_epilogue_for_components(), insert_value_copy_on_edge(), insert_var_expansion_initialization(), instantiate_virtual_regs_in_insn(), ira(), lra_process_new_insns(), make_epilogue_seq(), make_prologue_seq(), make_split_prologue_seq(), match_asm_constraints_1(), match_reload(), maybe_optimize_mod_cmp(), maybe_optimize_pow2p_mod_cmp(), noce_convert_multiple_sets(), noce_convert_multiple_sets_1(), noce_emit_cmove(), noce_emit_move_insn(), noce_emit_store_flag(), noce_process_if_block(), noce_try_abs(), noce_try_addcc(), noce_try_cmove(), noce_try_cmove_arith(), noce_try_cond_zero_arith(), noce_try_inverse_constants(), noce_try_minmax(), noce_try_sign_mask(), noce_try_store_flag(), noce_try_store_flag_constants(), noce_try_store_flag_mask(), pop_topmost_sequence(), prepare_copy_insn(), prepare_float_lib_cmp(), prepend_insn_to_edge(), process_addr_reg(), process_address_1(), process_invariant_for_inheritance(), record_store(), remove_inheritance_pseudos(), replace_read(), resolve_shift_zext(), resolve_simple_move(), rtl_lv_add_condition_to_bb(), sjlj_emit_dispatch_table(), sjlj_emit_function_enter(), sjlj_emit_function_exit(), sjlj_mark_call_sites(), split_iv(), thread_prologue_and_epilogue_insns(), try_emit_cmove_seq(), and unroll_loop_runtime_iterations().
Find a RTX_AUTOINC class rtx which matches DATA.
References FOR_EACH_SUBRTX, GET_CODE, GET_RTX_CLASS, RTX_AUTOINC, rtx_equal_p(), and XEXP.
Referenced by try_split().
Return a memory reference like MEM, but with the address reloaded into a pseudo register.
References address_reload_context::emit_autoinc(), force_reg(), GET_CODE, GET_MODE, GET_MODE_SIZE(), GET_RTX_CLASS, replace_equiv_address(), RTX_AUTOINC, mem_attrs::size, and XEXP.
rtx gen_blockage | ( | void | ) |
Generate an empty ASM_INPUT, which is used to block attempts to schedule, and to block register equivalences to be seen across this insn.
References gen_rtx_ASM_INPUT, and MEM_VOLATILE_P.
Referenced by anti_adjust_stack_and_probe_stack_clash(), expand_builtin_longjmp(), expand_builtin_nonlocal_goto(), expand_builtin_setjmp_receiver(), expand_function_end(), make_prologue_seq(), and probe_stack_range().
Return a sequence of insns to clobber lvalue X.
References emit_clobber(), end_sequence(), get_insns(), and start_sequence().
Referenced by eliminate_regs_in_insn(), and find_reloads().
Generate a memory referring to non-trapping constant memory.
References gen_rtx_MEM(), MEM_NOTRAP_P, and MEM_READONLY_P.
Referenced by assemble_trampoline_template(), build_constant_desc(), do_tablejump(), and force_const_mem().
Generate a vector constant of mode MODE in which every element has value ELT.
References rtx_vector_builder::build().
Referenced by builtin_memset_read_str(), expand_absneg_bit(), expand_vector_broadcast(), gen_const_vector(), gen_rtx_CONST_VECTOR(), gen_vec_duplicate(), relational_result(), and simplify_const_unary_operation().
Generate a vector constant of mode MODE in which element I has the value BASE + I * STEP.
References rtx_vector_builder::build(), gcc_assert, GET_MODE_INNER, i, simplify_gen_binary(), and valid_for_const_vector_p().
Referenced by gen_vec_series(), and simplify_context::simplify_binary_operation_1().
|
static |
Generate a new vector constant for mode MODE and constant value CONSTANT.
References const_tiny_rtx, DECIMAL_FLOAT_MODE_P, gcc_assert, gen_const_vec_duplicate(), and GET_MODE_INNER.
Referenced by init_emit_once().
Generate a MEM referring to fixed portions of the frame, e.g., register save areas.
References gen_rtx_MEM(), get_frame_alias_set(), MEM_NOTRAP_P, and set_mem_alias_set().
Referenced by expand_builtin_return_addr().
rtx gen_hard_reg_clobber | ( | machine_mode | mode, |
unsigned int | regno ) |
References gen_rtx_REG(), and hard_reg_clobbers.
Referenced by emit_insn_if_valid_for_reload().
In emit-rtl.cc
References adjust_address, gcc_assert, GET_MODE, GET_MODE_SIZE(), GET_MODE_UNIT_SIZE, known_eq, known_le, MEM_P, offset, simplify_gen_subreg(), and subreg_highpart_offset().
Referenced by expand_doubleword_clz_ctz_ffs(), expand_expr_real_2(), extract_high_half(), and gen_highpart_mode().
Like gen_highpart, but accept mode of EXP operand in case EXP can be VOIDmode constant.
References exp(), gcc_assert, gen_highpart(), GET_MODE, simplify_gen_subreg(), and subreg_highpart_offset().
rtx gen_int_mode | ( | poly_int64 | c, |
machine_mode | mode ) |
References as_a(), poly_int< N, C >::coeffs, poly_int< N, C >::from(), GEN_INT, GET_MODE_PRECISION(), immed_wide_int_const(), poly_int< N, C >::is_constant(), SIGNED, and trunc_int_for_mode().
Referenced by add_args_size_note(), addr_offset_valid_p(), align_dynamic_address(), allocate_dynamic_stack_space(), anti_adjust_stack_and_probe(), asan_clear_shadow(), asan_emit_stack_protection(), assemble_real(), assign_parm_setup_block(), assign_parms(), autoinc_split(), builtin_memset_read_str(), calculate_table_based_CRC(), canonicalize_address_mult(), canonicalize_condition(), cleanup_auto_inc_dec(), combine_set_extension(), combine_simplify_rtx(), convert_mode_scalar(), create_integer_operand(), cselib_hash_rtx(), default_memtag_untagged_pointer(), do_pending_stack_adjust(), do_tablejump(), dw2_asm_output_offset(), address_reload_context::emit_autoinc(), emit_call_1(), emit_library_call_value_1(), emit_move_complex(), emit_move_resolve_push(), emit_push_insn(), emit_store_flag(), emit_store_flag_int(), expand_atomic_test_and_set(), expand_binop(), expand_builtin_crc_table_based(), expand_builtin_memset_args(), expand_call(), expand_ctz(), expand_debug_expr(), expand_divmod(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_mod(), expand_expr_real_1(), expand_expr_real_2(), expand_ffs(), expand_field_assignment(), expand_fix(), expand_HWASAN_CHOOSE_TAG(), expand_sdiv_pow2(), expand_SET_EDOM(), expand_shift_1(), expand_smod_pow2(), expand_stack_vars(), expand_unop(), expand_vector_ubsan_overflow(), expmed_mult_highpart(), extract_left_shift(), find_split_point(), asan_redzone_buffer::flush_redzone_payload(), for_each_inc_dec_find_inc_dec(), force_int_to_mode(), force_to_mode(), gen_common_operation_to_reflect(), gen_int_shift_amount(), get_call_args(), get_dynamic_stack_base(), get_mode_bounds(), get_stored_val(), hwasan_emit_prologue(), hwasan_truncate_to_tag_size(), if_then_else_cond(), immed_double_const(), immed_wide_int_const_1(), inc_for_reload(), pieces_addr::increment_address(), init_caller_save(), init_one_dwarf_reg_size(), init_reload(), init_return_column_size(), insert_const_anchor(), instantiate_virtual_regs_in_insn(), iv_number_of_iterations(), make_compound_operation_int(), make_extraction(), make_field_assignment(), maybe_legitimize_operand(), mem_loc_descriptor(), move2add_use_add2_insn(), move2add_use_add3_insn(), multiplier_allowed_in_address_p(), native_decode_vector_rtx(), noce_try_bitop(), noce_try_cmove(), noce_try_store_flag_constants(), optimize_bitfield_assignment_op(), output_constant_pool_2(), plus_constant(), probe_stack_range(), push_block(), reload_cse_move2add(), round_trampoline_addr(), simplify_and_const_int(), simplify_and_const_int_1(), simplify_context::simplify_binary_operation_1(), simplify_compare_const(), simplify_comparison(), simplify_if_then_else(), simplify_set(), simplify_shift_const_1(), simplify_context::simplify_ternary_operation(), sjlj_mark_call_sites(), split_iv(), store_bit_field_using_insv(), store_constructor(), store_field(), store_one_arg(), try_store_by_multiple_pieces(), unroll_loop_constant_iterations(), unroll_loop_runtime_iterations(), update_reg_equal_equiv_notes(), validate_test_and_branch(), vec_perm_indices_to_rtx(), and widen_leading().
rtx gen_int_shift_amount | ( | machine_mode | , |
poly_int64 | value ) |
Return a constant shift amount for shifting a value of mode MODE by VALUE bits.
References gen_int_mode(), int_mode_for_size(), and opt_mode< T >::require().
Referenced by asan_emit_stack_protection(), change_zero_ext(), expand_binop(), expand_doubleword_mult(), expand_shift(), expand_shift_1(), expand_smod_pow2(), expand_superword_shift(), expand_unop(), expand_vec_perm_var(), find_shift_sequence(), find_split_point(), fold_rtx(), force_int_to_mode(), init_expmed_one_mode(), shift_amt_for_vec_perm_mask(), shift_cost(), shift_return_value(), simplify_context::simplify_binary_operation_1(), simplify_shift_const(), simplify_shift_const_1(), simplify_context::simplify_unary_operation_1(), and try_combine().
rtx_code_label * gen_label_rtx | ( | void | ) |
Return a newly created CODE_LABEL rtx with a unique label number.
References as_a(), label_num, NULL, and NULL_RTX.
Referenced by allocate_dynamic_stack_space(), anti_adjust_stack_and_probe(), anti_adjust_stack_and_probe_stack_clash(), asan_clear_shadow(), asan_emit_stack_protection(), block_label(), compare_by_pieces(), do_compare_rtx_and_jump(), do_jump(), do_jump_1(), do_jump_by_parts_equality_rtx(), do_jump_by_parts_greater_rtx(), do_jump_by_parts_zero_rtx(), dw2_build_landing_pads(), dw2_fix_up_crossing_landing_pad(), emit_block_cmp_via_loop(), emit_block_move_via_loop(), emit_block_move_via_oriented_loop(), emit_case_dispatch_table(), emit_stack_clash_protection_probe_loop_start(), emit_store_flag_force(), expand_abs(), expand_addsub_overflow(), expand_arith_overflow_result_store(), expand_asm_stmt(), expand_builtin_atomic_compare_exchange(), expand_builtin_eh_return(), expand_builtin_strub_leave(), expand_builtin_strub_update(), expand_compare_and_swap_loop(), expand_copysign_absneg(), expand_divmod(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_shift(), expand_eh_return(), expand_expr_real_1(), expand_expr_real_2(), expand_ffs(), expand_fix(), expand_float(), expand_function_start(), expand_mul_overflow(), expand_naked_return(), expand_neg_overflow(), expand_sdiv_pow2(), expand_sjlj_dispatch_table(), expand_smod_pow2(), expand_vector_ubsan_overflow(), find_end_label(), fix_crossing_conditional_branches(), get_label_before(), get_uncond_jump_length(), inline_string_cmp(), label_rtx(), label_rtx_for_bb(), prepare_call_address(), probe_stack_range(), sjlj_build_landing_pads(), sjlj_emit_dispatch_table(), sjlj_fix_up_crossing_landing_pad(), stack_protect_epilogue(), store_constructor(), store_expr(), and try_store_by_multiple_pieces().
Return a value representing some low-order bits of X, where the number of low-order bits is given by MODE. Note that no conversion is done between floating-point and fixed-point values, rather, the bit representation is returned. This function handles the cases in common between gen_lowpart, below, and two variants in cse.cc and combine.cc. These are the cases that can be safely handled at all points in the compilation. If this is not a case we can handle, return 0.
References CONST_DOUBLE_AS_FLOAT_P, CONST_INT_P, CONST_POLY_INT_P, CONST_SCALAR_INT_P, gcc_assert, gen_lowpart_common(), GET_CODE, GET_MODE, GET_MODE_SIZE(), HOST_BITS_PER_DOUBLE_INT, HOST_BITS_PER_WIDE_INT, int_mode_for_size(), is_a(), known_le, lowpart_subreg(), maybe_gt, REG_P, REGMODE_NATURAL_SIZE, opt_mode< T >::require(), SCALAR_FLOAT_MODE_P, and XEXP.
Referenced by combine_simplify_rtx(), do_output_reload(), expand_expr_real_1(), extract_low_bits(), force_to_mode(), gen_lowpart_common(), gen_lowpart_for_combine(), gen_lowpart_general(), gen_lowpart_if_possible(), move2add_use_add2_insn(), store_split_bit_field(), and strip_paradoxical_subreg().
Generate a SUBREG representing the least-significant part of REG if MODE is smaller than mode of REG, otherwise paradoxical SUBREG.
References gen_rtx_SUBREG(), GET_MODE, and subreg_lowpart_offset().
Referenced by assign_parm_setup_block(), assign_parms_unsplit_complex(), change_zero_ext(), convert_wider_int_to_float(), emit_input_reload_insns(), emit_spill_move(), expand_call(), expand_expr_real_1(), extract_bit_field_using_extv(), gen_lowpart_if_possible(), match_reload(), precompute_arguments(), reverse_op(), simplify_operand_subreg(), and store_bit_field_using_insv().
rtx gen_raw_REG | ( | machine_mode | mode, |
unsigned int | regno ) |
Generate a new REG rtx. Make sure ORIGINAL_REGNO is set properly, and don't attempt to share with the various global pieces of rtl (such as frame_pointer_rtx).
References init_raw_REG(), MEM_STAT_INFO, and rtx_alloc().
Referenced by addr_for_mem_ref(), addr_offset_valid_p(), adjust_insn(), assign_spill_hard_regs(), can_widen_mult_without_libcall(), tree_switch_conversion::bit_test_cluster::emit(), expand_debug_parm_decl(), expand_expr_real_1(), expand_mult(), gen_reg_rtx(), gen_rtx_REG(), gen_rtx_REG_offset(), get_address_cost_ainc(), init_emit_regs(), init_expmed(), init_expr_target(), init_set_costs(), lshift_cheap_p(), make_decl_rtl(), maybe_mode_change(), mult_by_coeff_cost(), multiplier_allowed_in_address_p(), optimize_range_tests_to_bit_test(), prepare_decl_rtl(), produce_memory_decl_rtl(), regrename_do_replace(), try_combine(), and vt_add_function_parameter().
rtx gen_reg_rtx | ( | machine_mode | mode | ) |
Generate a REG rtx for a new pseudo register of mode MODE. This pseudo is assigned the next sequential register number.
References can_create_pseudo_p, crtl, emit(), gcc_assert, gen_raw_REG(), gen_reg_rtx(), generating_concat_p, GET_MODE_ALIGNMENT, GET_MODE_CLASS, GET_MODE_INNER, min_align(), MINIMUM_ALIGNMENT, NULL, reg_rtx_no, regno_reg_rtx, and SUPPORTS_STACK_ALIGNMENT.
Referenced by allocate_basic_variable(), allocate_dynamic_stack_space(), asan_emit_stack_protection(), assign_parm_remove_parallels(), assign_parm_setup_block(), assign_parm_setup_reg(), assign_parm_setup_stack(), assign_temp(), avoid_likely_spilled_reg(), builtin_memset_gen_str(), builtin_memset_read_str(), calculate_table_based_CRC(), compare_by_pieces(), compress_float_constant(), convert_mode_scalar(), convert_modes(), copy_blkmode_to_reg(), copy_to_mode_reg(), copy_to_reg(), copy_to_suggested_reg(), do_compare_and_jump(), do_jump_by_parts_zero_rtx(), do_store_flag(), do_tablejump(), doloop_optimize(), emit_block_cmp_via_loop(), emit_block_move_via_loop(), emit_conditional_add(), emit_conditional_move(), emit_conditional_move_1(), emit_conditional_neg_or_complement(), emit_cstore(), emit_group_load_1(), emit_group_store(), emit_libcall_block_1(), emit_library_call_value_1(), emit_push_insn(), emit_stack_save(), emit_store_flag_1(), emit_store_flag_force(), entry_register(), expand_abs(), expand_absneg_bit(), expand_addsub_overflow(), expand_asm_stmt(), expand_atomic_compare_and_swap(), expand_atomic_fetch_op(), expand_atomic_load(), expand_atomic_test_and_set(), expand_binop(), expand_builtin(), expand_builtin_apply(), expand_builtin_cexpi(), expand_builtin_crc_table_based(), expand_builtin_eh_copy_values(), expand_builtin_eh_filter(), expand_builtin_eh_pointer(), expand_builtin_feclear_feraise_except(), expand_builtin_fegetround(), expand_builtin_goacc_parlevel_id_size(), expand_builtin_int_roundingfn(), expand_builtin_int_roundingfn_2(), expand_builtin_issignaling(), expand_builtin_mathfn_3(), expand_builtin_mathfn_ternary(), expand_builtin_powi(), expand_builtin_signbit(), expand_builtin_sincos(), expand_builtin_stpcpy_1(), expand_builtin_strlen(), expand_builtin_thread_pointer(), expand_call(), expand_ccmp_expr(), expand_compare_and_swap_loop(), expand_copysign_absneg(), expand_copysign_bit(), expand_crc_optab_fn(), expand_crc_table_based(), expand_DIVMOD(), expand_divmod(), expand_doubleword_bswap(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_mod(), expand_doubleword_popcount(), expand_doubleword_shift_condmove(), expand_expr_real_1(), expand_expr_real_2(), expand_fix(), expand_float(), expand_function_end(), expand_function_start(), expand_gimple_basic_block(), expand_GOMP_SIMT_ENTER_ALLOC(), expand_ifn_atomic_bit_test_and(), expand_ifn_atomic_op_fetch_cmp_0(), expand_mul_overflow(), expand_mult_highpart(), expand_neg_overflow(), expand_one_error_var(), expand_one_register_var(), expand_one_ssa_partition(), expand_parity(), expand_reversed_crc_table_based(), expand_sdiv_pow2(), expand_sfix_optab(), expand_single_bit_test(), expand_smod_pow2(), expand_speculation_safe_value(), expand_stack_vars(), expand_twoval_binop(), expand_twoval_unop(), expand_UADDC(), expand_ubsan_result_store(), expand_unop(), expand_used_vars(), expand_var_during_unrolling(), expand_vec_perm_const(), expand_vec_perm_var(), expand_vec_set_optab_fn(), expand_vector_broadcast(), expand_vector_ubsan_overflow(), extract_bit_field_1(), extract_bit_field_using_extv(), extract_integral_bit_field(), find_shift_sequence(), fix_crossing_unconditional_branches(), force_not_mem(), force_operand(), force_reg(), gen_group_rtx(), gen_reg_rtx(), gen_reg_rtx_and_attrs(), gen_reg_rtx_offset(), get_dynamic_stack_base(), get_hard_reg_initial_val(), address_reload_context::get_reload_reg(), get_scratch_reg(), get_temp_reg(), inline_string_cmp(), ira_create_new_reg(), load_register_parameters(), lra(), lra_create_new_reg_with_unique_value(), make_more_copies(), make_safe_from(), maybe_emit_compare_and_swap_exchange_loop(), maybe_emit_group_store(), maybe_legitimize_operand(), maybe_optimize_fetch_op(), noce_convert_multiple_sets_1(), noce_emit_cmove(), noce_process_if_block(), noce_try_addcc(), noce_try_cmove_arith(), noce_try_cond_zero_arith(), noce_try_inverse_constants(), noce_try_sign_mask(), noce_try_store_flag_constants(), noce_try_store_flag_mask(), prepare_cmp_insn(), prepare_float_lib_cmp(), resolve_simple_move(), round_trampoline_addr(), split_iv(), store_bit_field_using_insv(), store_constructor(), store_field(), store_integral_bit_field(), store_one_arg(), store_unaligned_arguments_into_pseudos(), unroll_loop_runtime_iterations(), widen_bswap(), widen_leading(), and widen_operand().
Generate a REG rtx for a new pseudo register, copying the mode and attributes from X.
References gen_reg_rtx(), GET_MODE, and set_reg_attrs_from_value().
Referenced by build_store_vectors(), delete_store(), hoist_code(), move_invariant_reg(), and pre_delete().
Generate a new pseudo-register with the same attributes as REG, but with OFFSET added to the REG_OFFSET.
References gen_reg_rtx(), offset, and update_reg_offset().
Referenced by decompose_register().
rtvec gen_rtvec | ( | int | n, |
... ) |
Create an rtvec and stores within it the RTXen passed in the arguments.
References rtvec_def::elem, i, NULL_RTVEC, and rtvec_alloc().
Referenced by combine_reg_notes(), convert_memory_address_addr_space_1(), emit_insn_if_valid_for_reload(), expand_asm_memory_blockage(), simplify_context::simplify_gen_vec_select(), try_combine(), and try_validate_parallel().
In emit-rtl.cc
References rtvec_def::elem, i, NULL_RTVEC, and rtvec_alloc().
Referenced by copy_rtx_if_shared_1(), eliminate_regs_1(), emit_case_dispatch_table(), emit_note_insn_var_location(), gen_group_rtx(), lra_eliminate_regs_1(), and result_vector().
References rtvec_def::elem, i, NULL_RTVEC, and rtvec_alloc().
rtx gen_rtx_CONST_INT | ( | machine_mode | mode, |
HOST_WIDE_INT | arg ) |
References const_int_htab, const_int_rtx, const_true_rtx, MAX_SAVED_CONST_INT, and STORE_FLAG_VALUE.
Referenced by anti_adjust_stack_and_probe_stack_clash(), function_reader::consolidate_singletons(), expand_crc_optab_fn(), and init_emit_once().
Generate a vector like gen_rtx_raw_CONST_VEC, but use the zero vector when all elements are zero, and the one vector when all elements are one.
References rtx_vector_builder::build(), gcc_assert, gen_const_vec_duplicate(), GET_MODE_NUNITS(), GET_NUM_ELEM, i, known_eq, rtvec_all_equal_p(), and RTVEC_ELT.
Referenced by function_reader::consolidate_singletons(), simplify_context::simplify_binary_operation_1(), simplify_const_binary_operation(), and simplify_context::simplify_ternary_operation().
rtx_expr_list * gen_rtx_EXPR_LIST | ( | machine_mode | mode, |
rtx | expr, | ||
rtx | expr_list ) |
There are some RTL codes that require special attention; the generation functions do the raw handling. If you add to this list, modify special_rtx in gengenrtl.cc as well.
References as_a().
Referenced by alloc_EXPR_LIST(), assemble_external_libcall(), clobber_reg_mode(), emit_call_1(), emit_library_call_value_1(), emit_note_insn_var_location(), expand_call(), gen_group_rtx(), prepare_call_arguments(), use_reg_mode(), and vt_add_function_parameter().
rtx_insn * gen_rtx_INSN | ( | machine_mode | mode, |
rtx_insn * | prev_insn, | ||
rtx_insn * | next_insn, | ||
basic_block | bb, | ||
rtx | pattern, | ||
int | location, | ||
int | code, | ||
rtx | reg_notes ) |
References as_a(), and next_insn().
Referenced by init_caller_save(), init_emit_once(), setup_prohibited_mode_move_regs(), and try_combine().
rtx_insn_list * gen_rtx_INSN_LIST | ( | machine_mode | mode, |
rtx | insn, | ||
rtx | insn_list ) |
References as_a().
Referenced by add_next_usage_insn(), add_store_equivs(), alloc_INSN_LIST(), combine_and_move_insns(), emit_move_list(), expand_builtin(), expand_label(), ira_update_equiv_info_by_shuffle_insn(), no_equiv(), and update_equiv_regs().
References MEM_ATTRS.
Referenced by asan_emit_stack_protection(), assign_parm_find_stack_rtl(), assign_parm_setup_block(), assign_parm_setup_reg(), assign_parms(), assign_stack_local_1(), assign_stack_temp_for_type(), calculate_table_based_CRC(), change_address(), change_address_1(), compute_argument_addresses(), cselib_init(), decode_addr_const(), default_static_chain(), emit_call_1(), emit_library_call_value_1(), emit_move_change_mode(), emit_move_complex_push(), emit_push_insn(), emit_stack_probe(), emit_stack_restore(), expand_asm_loc(), expand_asm_memory_blockage(), expand_asm_reg_clobber_mem_blockage(), expand_asm_stmt(), expand_assignment(), expand_builtin_apply(), expand_builtin_atomic_compare_exchange(), expand_builtin_init_descriptor(), expand_builtin_init_dwarf_reg_sizes(), expand_builtin_init_trampoline(), expand_builtin_longjmp(), expand_builtin_nonlocal_goto(), expand_builtin_return(), expand_builtin_setjmp_setup(), expand_builtin_strlen(), expand_builtin_strub_leave(), expand_builtin_update_setjmp_buf(), expand_builtin_va_copy(), expand_call(), expand_debug_expr(), expand_expr_real_1(), expand_function_start(), expand_one_error_var(), expand_one_stack_var_at(), expand_SET_EDOM(), gen_const_mem(), gen_frame_mem(), gen_tmp_stack_mem(), gen_tombstone(), get_builtin_sync_mem(), get_group_info(), get_memory_rtx(), get_spill_slot_decl(), init_caller_save(), init_expr_target(), init_fake_stack_mems(), init_reload(), init_set_costs(), initialize_argument_information(), make_decl_rtl(), noce_try_cmove_arith(), prepare_call_address(), prepare_call_arguments(), produce_memory_decl_rtl(), replace_pseudos_in(), rtl_for_decl_init(), rtl_for_decl_location(), scan_insn(), store_one_arg(), and vt_add_function_parameter().
rtx gen_rtx_REG | ( | machine_mode | mode, |
unsigned int | regno ) |
References arg_pointer_rtx, cfun, fixed_regs, frame_pointer_needed, frame_pointer_rtx, gen_raw_REG(), HARD_FRAME_POINTER_IS_FRAME_POINTER, HARD_FRAME_POINTER_REGNUM, hard_frame_pointer_rtx, INVALID_REGNUM, lra_in_progress, PIC_OFFSET_TABLE_REGNUM, pic_offset_table_rtx, reg_raw_mode, regno_reg_rtx, reload_completed, reload_in_progress, return_address_pointer_rtx, and stack_pointer_rtx.
Referenced by assign_parm_setup_block(), can_assign_to_reg_without_clobbers_p(), can_eliminate_compare(), can_reload_into(), canon_reg(), canonicalize_comparison(), change_zero_ext(), choose_reload_regs(), combine_reaching_defs(), combine_reloads(), combine_set_extension(), compute_can_copy(), cse_cc_succs(), cse_condition_code_reg(), cse_insn(), default_static_chain(), default_zero_call_used_regs(), do_output_reload(), do_reload(), emit_library_call_value_1(), emit_push_insn(), expand_asm_stmt(), expand_builtin_apply(), expand_builtin_apply_args_1(), expand_builtin_init_dwarf_reg_sizes(), expand_builtin_return(), expand_call(), expand_dw2_landing_pad_for_region(), expand_function_end(), find_and_remove_re(), find_dummy_reload(), find_reloads_address_1(), gen_hard_reg_clobber(), gen_reload(), gen_reload_chain_without_interm_reg_p(), get_hard_reg_initial_val(), init_caller_save(), init_elim_table(), init_elim_table(), init_emit_regs(), init_expr_target(), init_lower_subreg(), init_reload(), insert_restore(), insert_save(), load_register_parameters(), maybe_memory_address_addr_space_p(), maybe_select_cc_mode(), move2add_use_add3_insn(), move_block_from_reg(), move_block_to_reg(), peep2_find_free_register(), prefer_and_bit_test(), push_reload(), reload_adjust_reg_for_mode(), reload_combine_recognize_pattern(), reload_cse_regs_1(), reload_cse_simplify_operands(), reload_cse_simplify_set(), replace_reg_with_saved_mem(), result_vector(), set_reload_reg(), setup_prohibited_mode_move_regs(), simplify_set(), split_reg(), transform_ifelse(), try_combine(), try_eliminate_compare(), vt_add_function_parameter(), and zcur_select_mode_rtx().
rtx gen_rtx_REG_offset | ( | rtx | reg, |
machine_mode | mode, | ||
unsigned int | regno, | ||
poly_int64 | offset ) |
Generate a register with same attributes as REG, but with OFFSET added to the REG_OFFSET.
References gen_raw_REG(), offset, and update_reg_offset().
Referenced by alter_subreg(), expand_debug_parm_decl(), simplify_context::simplify_subreg(), var_lowpart(), and vt_add_function_parameter().
rtx gen_rtx_SUBREG | ( | machine_mode | mode, |
rtx | reg, | ||
poly_uint64 | offset ) |
References gcc_assert, GET_MODE, offset, and validate_subreg().
Referenced by curr_insn_transform(), eliminate_regs_1(), equiv_constant(), expand_debug_expr(), extract_low_bits(), find_reloads(), gen_lowpart_for_combine(), gen_lowpart_SUBREG(), lra_substitute_pseudo(), make_extraction(), noce_emit_cmove(), simplify_context::simplify_gen_subreg(), simplify_context::simplify_subreg(), store_bit_field_using_insv(), and store_integral_bit_field().
rtx gen_rtx_VAR_LOCATION | ( | machine_mode | mode, |
tree | decl, | ||
rtx | loc, | ||
enum var_init_status | status ) |
Generate a MEM referring to a temporary use of the stack, not part of the fixed stack frame. For example, something which is pushed by a target splitter.
References cfun, gen_rtx_MEM(), get_frame_alias_set(), MEM_NOTRAP_P, and set_mem_alias_set().
Return a sequence of insns to use rvalue X.
References emit_use(), end_sequence(), get_insns(), and start_sequence().
Referenced by rtl_flow_call_edges_add().
Return a vector rtx of mode MODE in which every element has value X. The result will be a constant if X is constant.
References gen_const_vec_duplicate(), and valid_for_const_vector_p().
Referenced by gen_vec_series(), simplify_context::simplify_binary_operation_1(), simplify_context::simplify_subreg(), and simplify_context::simplify_unary_operation_1().
Generate a vector of mode MODE in which element I has the value BASE + I * STEP. The result will be a constant if BASE and STEP are both constants.
References const0_rtx, gen_const_vec_series(), gen_vec_duplicate(), and valid_for_const_vector_p().
Referenced by simplify_context::simplify_binary_operation_series(), and simplify_context::simplify_unary_operation_1().
int get_first_label_num | ( | void | ) |
Return first label number used in this function (if any were used).
References first_label_num.
Referenced by compute_alignments(), init_eliminable_invariants(), and reload_combine().
rtx_insn * get_first_nonnote_insn | ( | void | ) |
Return the first nonnote insn emitted in current sequence or current function. This routine looks inside SEQUENCEs.
References as_a(), GET_CODE, get_insns(), next_insn(), NONJUMP_INSN_P, NOTE_P, and PATTERN().
rtx_insn * get_last_insn_anywhere | ( | void | ) |
Emission of insns (adding them to the doubly-linked list).
Return the last insn emitted, even if it is in a sequence now pushed.
References get_current_sequence(), sequence_stack::last, and sequence_stack::next.
rtx_insn * get_last_nonnote_insn | ( | void | ) |
Return the last nonnote insn emitted in current sequence or current function. This routine looks inside SEQUENCEs.
References dyn_cast(), get_last_insn(), NONJUMP_INSN_P, NOTE_P, PATTERN(), and previous_insn().
int get_max_insn_count | ( | void | ) |
Return the number of actual (non-debug) insns emitted in this function.
References cur_debug_insn_uid, and cur_insn_uid.
Referenced by alloc_hash_table(), and alloc_hash_table().
int get_mem_align_offset | ( | rtx | mem, |
unsigned int | align ) |
Return OFFSET if XEXP (MEM, 0) - OFFSET is known to be ALIGN bits aligned for 0 <= OFFSET < ALIGN / BITS_PER_UNIT, or -1 if not known.
References component_ref_field_offset(), DECL_ALIGN, DECL_FIELD_BIT_OFFSET, DECL_FIELD_CONTEXT, DECL_P, expr, gcc_assert, INDIRECT_REF_P, MEM_EXPR, MEM_OFFSET, MEM_OFFSET_KNOWN_P, MEM_P, NULL_TREE, offset, poly_int_tree_p(), TREE_CODE, tree_fits_uhwi_p(), TREE_OPERAND, tree_to_uhwi(), TREE_TYPE, and TYPE_ALIGN.
|
static |
Allocate a new reg_attrs structure and insert it into the hash table if one identical to it is not already in the table. We are doing this for MEM of mode MODE.
References attrs, ggc_alloc(), known_eq, attrs::offset, offset, and reg_attrs_htab.
Referenced by set_reg_attrs_for_decl_rtl(), set_reg_attrs_for_parm(), set_reg_attrs_from_value(), and update_reg_offset().
References attrs, build_decl(), current_function_decl, DECL_ARTIFICIAL, DECL_IGNORED_P, DECL_SOURCE_LOCATION, frame_pointer_rtx, gen_rtx_MEM(), get_identifier(), MEM_NOTRAP_P, mode_mem_attrs, new_alias_set(), SET_DECL_RTL, set_mem_attrs(), spill_slot_decl, TREE_USED, and void_type_node.
Referenced by ao_ref_from_mem(), nonoverlapping_memrefs_p(), set_mem_attrs_for_spill(), and vt_add_function_parameter().
rtx immed_double_const | ( | HOST_WIDE_INT | i0, |
HOST_WIDE_INT | i1, | ||
machine_mode | mode ) |
Return a CONST_DOUBLE or CONST_INT for a value specified as a pair of ints: I0 is the low-order word and I1 is the high-order word. For values that are larger than HOST_BITS_PER_DOUBLE_INT, the implied upper bits are copies of the high bit of i1. The value itself is neither signed nor unsigned. Do not use this routine for non-integer modes; convert to REAL_VALUE_TYPE and use const_double_from_real_value.
References CONST_DOUBLE_FORMAT, CONST_DOUBLE_HIGH, CONST_DOUBLE_LOW, GEN_INT, gen_int_mode(), GET_MODE_BITSIZE(), HOST_BITS_PER_WIDE_INT, i, i1, is_a(), lookup_const_double(), PUT_MODE(), rtx_alloc(), and XWINT.
Referenced by immed_wide_int_const_1().
rtx immed_wide_int_const | ( | const poly_wide_int_ref & | c, |
machine_mode | mode ) |
Return an rtx representation of C in mode MODE.
References inchash::hash::add_int(), inchash::hash::add_wide_int(), as_a(), poly_int< N, C >::coeffs, CONST_POLY_INT_COEFFS, const_poly_int_htab, inchash::hash::end(), poly_int< N, C >::from(), gcc_assert, GET_MODE_PRECISION(), i, immed_wide_int_const_1(), poly_int< N, C >::is_constant(), NUM_POLY_INT_COEFFS, PUT_MODE(), rtx_alloc_v, and SIGNED.
Referenced by addr_for_mem_ref(), rtx_vector_builder::apply_step(), canon_condition(), canonicalize_comparison(), change_zero_ext(), clz_loc_descriptor(), const_vector_elt(), const_vector_from_tree(), convert_modes(), tree_switch_conversion::bit_test_cluster::emit(), expand_absneg_bit(), expand_addsub_overflow(), expand_arith_overflow_result_store(), expand_builtin_signbit(), expand_copysign_absneg(), expand_copysign_bit(), expand_debug_expr(), expand_doubleword_divmod(), expand_doubleword_mod(), expand_doubleword_shift(), expand_expr_real_1(), expand_expr_real_2(), expand_mul_overflow(), expand_mult_const(), expand_smod_pow2(), expand_subword_shift(), expand_ubsan_result_store(), gen_int_mode(), internal_check_ptrs_fn_supported_p(), lshift_value(), mask_rtx(), native_decode_rtx(), neg_poly_int_rtx(), optimize_range_tests_to_bit_test(), plus_constant(), prefer_and_bit_test(), reduce_to_bit_field_precision(), reload_cse_simplify_set(), simplify_context::simplify_binary_operation_1(), simplify_const_binary_operation(), simplify_const_unary_operation(), simplify_context::simplify_subreg(), and try_combine().
|
static |
Return an rtx constant for V, given that the constant has mode MODE. The returned rtx will be a CONST_INT if V fits, otherwise it will be a CONST_DOUBLE (if !TARGET_SUPPORTS_WIDE_INT) or a CONST_WIDE_INT (if TARGET_SUPPORTS_WIDE_INT).
References as_a(), const_wide_int_alloc, CONST_WIDE_INT_ELT, CWI_PUT_NUM_ELEM, generic_wide_int< storage >::elt(), gcc_assert, gen_int_mode(), GET_MODE_PRECISION(), HOST_BITS_PER_WIDE_INT, i, immed_double_const(), and PUT_MODE().
Referenced by immed_wide_int_const().
bool in_sequence_p | ( | void | ) |
Return true if currently emitting into a sequence.
References get_current_sequence(), and sequence_stack::next.
Referenced by expand_dummy_function_end(), expand_function_end(), leaf_function_p(), and resolve_simple_move().
void init_derived_machine_modes | ( | void | ) |
Initialize global machine_mode variables.
References as_a(), BITS_PER_WORD, byte_mode, opt_mode< T >::exists(), FOR_EACH_MODE_IN_CLASS, GET_MODE_BITSIZE(), GET_MODE_CLASS, mode_for_size(), POINTER_SIZE, ptr_mode, opt_mode< T >::require(), require(), and word_mode.
Referenced by do_compile().
void init_emit | ( | void | ) |
Initialize data structures and variables in this file before generating rtl for each function.
References arg_pointer_rtx, BITS_PER_WORD, crtl, cur_debug_insn_uid, cur_insn_uid, first_label_num, frame_pointer_rtx, get_current_sequence(), ggc_cleared_vec_alloc(), HARD_FRAME_POINTER_REGNUM, hard_frame_pointer_rtx, init_virtual_regs(), initial_regno_reg_rtx, label_num, LAST_VIRTUAL_REGISTER, sequence_stack::next, NULL, REG_POINTER, reg_rtx_no, REGNO_POINTER_ALIGN, regno_reg_rtx, set_first_insn(), set_last_insn(), stack_pointer_rtx, VIRTUAL_CFA_REGNUM, virtual_cfa_rtx, VIRTUAL_INCOMING_ARGS_REGNUM, virtual_incoming_args_rtx, VIRTUAL_OUTGOING_ARGS_REGNUM, virtual_outgoing_args_rtx, VIRTUAL_STACK_DYNAMIC_REGNUM, virtual_stack_dynamic_rtx, VIRTUAL_STACK_VARS_REGNUM, and virtual_stack_vars_rtx.
Referenced by prepare_function_start(), read_rtl_function_body(), and read_rtl_function_body_from_file_range().
void init_emit_once | ( | void | ) |
Create some permanent unique rtl objects shared between all functions.
References as_a(), const0_rtx, const1_rtx, const_double_from_real_value(), const_double_htab, CONST_FIXED_FROM_FIXED_VALUE, const_fixed_htab, const_int_htab, const_int_rtx, const_poly_int_htab, const_tiny_rtx, const_true_rtx, const_wide_int_htab, constm1_rtx, hash_table< Descriptor, Lazy, Allocator >::create_ggc(), dconst0, dconst1, dconst2, dconsthalf, dconstinf, dconstm0, dconstm1, dconstninf, double_int_one, FCONST0, FCONST1, FOR_EACH_MODE_IN_CLASS, gen_const_vector(), GEN_INT, gen_rtx_CONST_INT(), gen_rtx_INSN(), GET_MODE_CLASS, GET_MODE_FBIT, GET_MODE_INNER, HOST_BITS_PER_DOUBLE_INT, i, invalid_insn_rtx, MAX_SAVED_CONST_INT, NULL, NULL_RTX, NUM_POLY_INT_COEFFS, pc_rtx, r, REAL_EXP, real_from_integer(), real_inf(), REAL_VALUE_TYPE, reg_attrs_htab, opt_mode< T >::require(), ret_rtx, SET_REAL_EXP, SIGNED, SIGNED_FIXED_POINT_MODE_P, simple_return_rtx, STORE_FLAG_VALUE, targetm, and TI_DOUBLE_TYPE.
Referenced by backend_init().
void init_emit_regs | ( | void | ) |
Initialise global register information required by all functions.
References ADDR_SPACE_GENERIC, arg_pointer_rtx, attrs, frame_pointer_rtx, gen_raw_REG(), gen_rtx_REG(), GET_MODE_ALIGNMENT, GET_MODE_SIZE(), ggc_cleared_alloc(), ggc_strdup, HARD_FRAME_POINTER_REGNUM, hard_frame_pointer_rtx, i, init_reg_modes_target(), initial_regno_reg_rtx, INVALID_REGNUM, mode_mem_attrs, NULL, NULL_RTX, opt_fstack_limit_register_no, opt_fstack_limit_symbol_arg, PIC_OFFSET_TABLE_REGNUM, pic_offset_table_rtx, reg_attrs_htab, reg_raw_mode, return_address_pointer_rtx, split_branch_probability, stack_limit_rtx, stack_pointer_rtx, profile_probability::uninitialized(), VIRTUAL_CFA_REGNUM, virtual_cfa_rtx, VIRTUAL_INCOMING_ARGS_REGNUM, virtual_incoming_args_rtx, VIRTUAL_OUTGOING_ARGS_REGNUM, virtual_outgoing_args_rtx, VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM, virtual_preferred_stack_boundary_rtx, VIRTUAL_STACK_DYNAMIC_REGNUM, virtual_stack_dynamic_rtx, VIRTUAL_STACK_VARS_REGNUM, and virtual_stack_vars_rtx.
Referenced by backend_init(), and target_reinit().
Initialize a fresh REG rtx with mode MODE and register REGNO.
References NULL, ORIGINAL_REGNO, REG_ATTRS, and set_mode_and_regno().
Referenced by gen_raw_REG().
|
static |
Put the various virtual registers into REGNO_REG_RTX.
References regno_reg_rtx, VIRTUAL_CFA_REGNUM, virtual_cfa_rtx, VIRTUAL_INCOMING_ARGS_REGNUM, virtual_incoming_args_rtx, VIRTUAL_OUTGOING_ARGS_REGNUM, virtual_outgoing_args_rtx, VIRTUAL_PREFERRED_STACK_BOUNDARY_REGNUM, virtual_preferred_stack_boundary_rtx, VIRTUAL_STACK_DYNAMIC_REGNUM, virtual_stack_dynamic_rtx, VIRTUAL_STACK_VARS_REGNUM, and virtual_stack_vars_rtx.
Referenced by init_emit().
const char * insn_file | ( | const rtx_insn * | insn | ) |
Return source file of the statement that produced this insn.
References INSN_LOCATION(), and LOCATION_FILE.
int insn_line | ( | const rtx_insn * | insn | ) |
Return line number of the statement that produced this insn.
References INSN_LOCATION(), and LOCATION_LINE.
expanded_location insn_location | ( | const rtx_insn * | insn | ) |
Return expanded location of the statement that produced this insn.
References expand_location(), and INSN_LOCATION().
Referenced by notice_source_line(), and rtx_writer::print_rtx_operand_code_i().
void insn_locations_finalize | ( | void | ) |
At the end of emit stage, clear current location.
References curr_location, epilogue_location, and UNKNOWN_LOCATION.
Referenced by expand_thunk().
void insn_locations_init | ( | void | ) |
Allocate insn location datastructure.
References curr_location, epilogue_location, prologue_location, and UNKNOWN_LOCATION.
Referenced by compile_file(), and expand_thunk().
Return lexical scope block insn belongs to.
References INSN_LOCATION(), and LOCATION_BLOCK.
Referenced by reemit_insn_block_notes().
rtx_call_insn * last_call_insn | ( | void | ) |
Return the last CALL_INSN in the current list, or 0 if there is none. This routine does not look inside SEQUENCEs.
References CALL_P, get_last_insn(), PREV_INSN(), and safe_as_a().
Referenced by emit_call_1(), emit_library_call_value_1(), expand_builtin_apply(), and expand_call().
Add INSN to the end of the doubly-linked list, between PREV and NEXT. INSN may be any object that can appear in the chain: INSN_P and NOTE_P objects, but also BARRIERs and JUMP_TABLE_DATAs. PREV and NEXT may be NULL.
References as_a(), GET_CODE, rtx_sequence::insn(), rtx_sequence::len(), sequence_stack::next, NONJUMP_INSN_P, NULL, PATTERN(), SET_NEXT_INSN(), and SET_PREV_INSN().
Referenced by add_insn(), add_insn_after_nobb(), and add_insn_before_nobb().
CONST_DOUBLEs might be created from pairs of integers, or from REAL_VALUE_TYPEs. Also, their length is known only at run time, so we cannot use gen_rtx_raw_CONST_DOUBLE.
Determine whether REAL, a CONST_DOUBLE, already exists in the hash table. If so, return its counterpart; otherwise add it to the hash table and return it.
References const_double_htab.
Referenced by const_double_from_real_value(), and immed_double_const().
Determine whether FIXED, a CONST_FIXED, already exists in the hash table. If so, return its counterpart; otherwise add it to the hash table and return it.
References const_fixed_htab.
Referenced by const_fixed_from_fixed_value().
Like `make_insn_raw' but make a CALL_INSN instead of an insn.
References as_a(), BLOCK_FOR_INSN(), CALL_INSN_FUNCTION_USAGE, cur_insn_uid, curr_insn_location(), INSN_CODE, INSN_LOCATION(), INSN_UID(), NULL, PATTERN(), REG_NOTES, and rtx_alloc().
Referenced by emit_call_insn(), emit_call_insn_after(), emit_call_insn_after_noloc(), emit_call_insn_after_setloc(), emit_call_insn_before(), emit_call_insn_before_noloc(), and emit_call_insn_before_setloc().
Like `make_insn_raw' but make a DEBUG_INSN instead of an insn.
References as_a(), BLOCK_FOR_INSN(), cur_debug_insn_uid, cur_insn_uid, curr_insn_location(), INSN_CODE, INSN_LOCATION(), INSN_UID(), NULL, PATTERN(), REG_NOTES, and rtx_alloc().
Referenced by emit_debug_insn(), emit_debug_insn_after(), emit_debug_insn_after_noloc(), emit_debug_insn_after_setloc(), emit_debug_insn_before(), emit_debug_insn_before_noloc(), and emit_debug_insn_before_setloc().
Make and return an INSN rtx, initializing all its slots. Store PATTERN in the pattern slots.
References as_a(), BLOCK_FOR_INSN(), cur_insn_uid, curr_insn_location(), debug_rtx(), GET_CODE, INSN_CODE, INSN_LOCATION(), INSN_P, INSN_UID(), NULL, PATTERN(), pc_rtx, REG_NOTES, returnjump_p(), rtx_alloc(), SET, SET_DEST, and warning().
Referenced by can_assign_to_reg_without_clobbers_p(), can_reload_into(), check_asm_operands(), default_print_patchable_function_entry(), emit_delay_sequence(), emit_insn(), emit_insn_after(), emit_insn_after_noloc(), emit_insn_after_setloc(), emit_insn_before(), emit_insn_before_noloc(), emit_insn_before_setloc(), noce_emit_czero(), and try_validate_parallel().
Like `make_insn_raw' but make a JUMP_INSN instead of an insn.
References as_a(), BLOCK_FOR_INSN(), cur_insn_uid, curr_insn_location(), INSN_CODE, INSN_LOCATION(), INSN_UID(), JUMP_LABEL, NULL, PATTERN(), REG_NOTES, and rtx_alloc().
Referenced by emit_jump_insn(), emit_jump_insn_after(), emit_jump_insn_after_noloc(), emit_jump_insn_after_setloc(), emit_jump_insn_before(), emit_jump_insn_before_noloc(), and emit_jump_insn_before_setloc().
Like `make_insn_raw' but make a NOTE instead of an insn.
References as_a(), BLOCK_FOR_INSN(), cur_insn_uid, gcc_assert, INSN_UID(), NOTE_DATA, NOTE_KIND, NULL, and rtx_alloc().
Referenced by emit_note(), emit_note_after(), emit_note_before(), and emit_note_copy().
Copy X if necessary so that it won't be altered by changes in OTHER. Return X or the rtx for the pseudo reg the value of X was copied into. OTHER must be valid as a SET_DEST.
References CONSTANT_P, emit_move_insn(), gen_reg_rtx(), GET_CODE, GET_MODE, MEM_P, reg_mentioned_p(), REG_P, REGNO, SUBREG_REG, and XEXP.
|
static |
Increment the label uses for all labels present in rtx.
References GET_CODE, GET_RTX_FORMAT, GET_RTX_LENGTH, i, LABEL_NUSES, LABEL_P, label_ref_label(), mark_label_nuses(), XEXP, XVECEXP, and XVECLEN.
Referenced by mark_label_nuses(), and try_split().
void mark_reg_pointer | ( | rtx | reg, |
int | align ) |
Identify REG as a probable pointer register and show its alignment as ALIGN, if nonzero.
References REG_POINTER, REGNO, and REGNO_POINTER_ALIGN.
Referenced by adjust_one_expanded_partition_var(), allocate_dynamic_stack_space(), assign_parm_setup_block(), assign_parm_setup_reg(), expand_call(), expand_expr_real_1(), expand_function_start(), expand_one_register_var(), force_reg(), get_dynamic_stack_base(), get_temp_reg(), memory_address_addr_space(), and set_reg_attrs_from_value().
|
static |
Set the USED bit in X and its non-shareable subparts to FLAG.
References CASE_CONST_ANY, GET_CODE, GET_RTX_FORMAT, GET_RTX_LENGTH, i, mark_used_flags(), RTX_FLAG, XEXP, XVECEXP, and XVECLEN.
Referenced by mark_used_flags(), reset_used_flags(), and set_used_flags().
void mark_user_reg | ( | rtx | reg | ) |
Identify REG (which may be a CONCAT) as a user register.
References gcc_assert, GET_CODE, REG_P, REG_USERVAR_P, and XEXP.
Referenced by adjust_one_expanded_partition_var(), assign_parm_setup_reg(), and expand_one_register_var().
int max_label_num | ( | void | ) |
Return 1 + the largest label number used so far in the current function.
References label_num.
Referenced by compute_alignments(), grow_label_align(), init_eliminable_invariants(), reload_combine(), shorten_branches(), and update_alignments().
int max_reg_num | ( | void | ) |
Return 1 plus largest pseudo reg number used in the current function.
References reg_rtx_no.
Referenced by allocate_reg_info(), assign_by_spills(), build_conflicts(), build_store_vectors(), calculate_equiv_gains(), cleanup_cfg(), combine_and_move_insns(), combine_split_insns(), compute_hash_table_work(), compute_store_table(), create_cands(), create_live_range_start_chains(), create_log_links(), cse_main(), cselib_init(), curr_insn_transform(), dead_or_predicable(), decompose_multiword_subregs(), df_grow_reg_info(), df_print_word_regset(), dump_reg_info(), expand_reg_data(), expand_reg_info(), expand_reg_info(), find_costs_and_classes(), find_moveable_pseudos(), fix_reg_equiv_init(), fwprop_done(), gcse_or_cprop_is_too_expensive(), grow_reg_equivs(), if_convert(), init_alias_analysis(), init_costs(), init_live_reload_and_inheritance_pseudos(), init_lives(), init_loop_tree_node(), init_reg_info(), init_regno_assign_info(), init_subregs_of_mode(), initiate_allocnos(), initiate_regno_cost_classes(), ira(), ira_emit(), ira_expand_reg_equiv(), ira_flattening(), ira_print_disposition(), ira_set_pseudo_classes(), ira_sort_regnos_for_alter_reg(), lra(), lra_assign(), lra_clear_live_ranges(), lra_coalesce(), lra_constrain_insn(), lra_constraints(), lra_create_live_ranges_1(), lra_create_new_reg_with_unique_value(), lra_emit_add(), lra_emit_move(), lra_final_code_change(), lra_init_equiv(), lra_need_for_scratch_reg_p(), lra_need_for_spills_p(), lra_remat(), lra_spill(), lra_split_hard_reg_for(), lra_update_reg_val_offset(), maybe_memory_address_addr_space_p(), print_live_ranges(), print_pseudo_costs(), propagate_allocno_info(), rebuild_regno_allocno_maps(), regno_clobbered_at_setjmp(), regstat_compute_calls_crossed(), regstat_compute_ri(), regstat_init_n_sets_and_refs(), remove_some_program_points_and_update_live_ranges(), remove_unnecessary_allocnos(), resize_reg_info(), rest_of_handle_combine(), rest_of_handle_cse(), rest_of_handle_cse2(), rest_of_handle_cse_after_global_opts(), run_rtl_passes(), setup_live_pseudos_and_spill_after_risky_transforms(), setup_min_max_allocno_live_range_point(), setup_preferred_alternate_classes_for_new_pseudos(), setup_reg_classes(), setup_reg_equiv_init(), spill_pseudos(), and try_combine().
void maybe_set_first_label_num | ( | rtx_code_label * | x | ) |
If the rtx for label was created during the expansion of a nested function, then first_label_num won't include this label number. Fix this now so that array indices work later.
References CODE_LABEL_NUMBER, and first_label_num.
Referenced by expand_label().
void maybe_set_max_label_num | ( | rtx_code_label * | x | ) |
For use by the RTL function loader, when mingling with normal functions. Ensure that label_num is greater than the label num of X, to avoid duplicate labels in the generated assembler.
References CODE_LABEL_NUMBER, and label_num.
Referenced by function_reader::parse_insn().
Return true if the given memory attributes are equal.
References mem_attrs::addrspace, mem_attrs::alias, mem_attrs::align, mem_attrs::expr, known_eq, NULL_TREE, mem_attrs::offset, mem_attrs::offset_known_p, operand_equal_p(), mem_attrs::size, and mem_attrs::size_known_p.
Referenced by change_address(), exp_equiv_p(), merge_memattrs(), rtx_interchangeable_p(), and set_mem_attrs().
bool mem_expr_equal_p | ( | const_tree | expr1, |
const_tree | expr2 ) |
Returns true if both MEM_EXPR can be considered equal and false otherwise.
References operand_equal_p(), and TREE_CODE.
Referenced by merge_memattrs().
Return true if memory model MODEL requires a pre-operation (release-style) barrier or a post-operation (acquire-style) barrier. While not universal, this function matches behavior of several targets.
References gcc_unreachable, MEMMODEL_ACQ_REL, MEMMODEL_ACQUIRE, MEMMODEL_BASE_MASK, MEMMODEL_CONSUME, MEMMODEL_RELAXED, MEMMODEL_RELEASE, and MEMMODEL_SEQ_CST.
Find the next insn after INSN that really does something. This routine does not look inside SEQUENCEs. After reload this also skips over standalone USE and CLOBBER insn.
References active_insn_p(), and NEXT_INSN().
Referenced by can_combine_p(), can_fallthru(), clear_hashed_info_until_next_barrier(), dbr_schedule(), fill_eager_delay_slots(), fill_simple_delay_slots(), fill_slots_from_thread(), first_active_target_insn(), follow_jumps(), label_before_next_insn(), optimize_skip(), own_thread_p(), peep2_attempt(), relax_delay_slots(), thread_prologue_and_epilogue_insns(), try_combine(), and try_merge_delay_insns().
Return the next insn. If it is a SEQUENCE, return the first insn of the sequence.
References as_a(), GET_CODE, NEXT_INSN(), NONJUMP_INSN_P, and PATTERN().
Referenced by collect_fn_hard_reg_usage(), constprop_register(), emit_notes_in_bb(), find_reload_regno_insns(), gen_rtx_INSN(), get_first_nonnote_insn(), mark_target_live_regs(), peephole2_optimize(), process_insn_equiv_class(), record_effective_endpoints(), and tablejump_p().
Return the next insn after INSN that is not a DEBUG_INSN. This routine does not look inside SEQUENCEs.
References DEBUG_INSN_P, and NEXT_INSN().
Referenced by constprop_register().
Return the next insn after INSN that is not a NOTE. This routine does not look inside SEQUENCEs.
References NEXT_INSN(), and NOTE_P.
Referenced by clear_hashed_info_until_next_barrier(), fill_simple_delay_slots(), fill_slots_from_thread(), find_basic_block(), fix_reg_dead_note(), init_resource_info(), keep_with_call_p(), merge_blocks_move_predecessor_nojumps(), optimize_skip(), try_merge_delay_insns(), and update_reg_dead_notes().
Return the next insn after INSN that is not a NOTE nor DEBUG_INSN. This routine does not look inside SEQUENCEs.
References DEBUG_INSN_P, NEXT_INSN(), and NOTE_P.
Referenced by distribute_notes(), find_moveable_pseudos(), reload_cse_move2add(), rtl_verify_bb_layout(), rtx_renumbered_equal_p(), try_combine(), try_redirect_by_replacing_jump(), and update_cfg_for_uncondjump().
Return the next insn after INSN that is not a NOTE nor DEBUG_INSN, but stop the search before we enter another basic block. This routine does not look inside SEQUENCEs.
References DEBUG_INSN_P, NEXT_INSN(), NOTE_INSN_BASIC_BLOCK_P, NOTE_P, and NULL.
Referenced by get_last_bb_insn().
Return the next INSN, CALL_INSN, JUMP_INSN or DEBUG_INSN after INSN; or 0, if there is none. This routine does not look inside SEQUENCEs.
References INSN_P, and NEXT_INSN().
Referenced by decrease_live_ranges_number(), expand_gimple_stmt(), and mark_transaction_restart_calls().
Return the next INSN, CALL_INSN or JUMP_INSN after INSN; or 0, if there is none. This routine does not look inside SEQUENCEs.
References NEXT_INSN(), NONDEBUG_INSN_P, and safe_as_a().
Referenced by fill_simple_delay_slots(), and relax_delay_slots().
Notes require a bit of special handling: Some notes need to have their BLOCK_FOR_INSN set, others should never have it set, and some should have it set or clear depending on the context.
Return true iff a note of kind SUBTYPE should be emitted with routines that never set BLOCK_FOR_INSN on NOTE. BB_BOUNDARY is true if the caller is asked to emit a note before BB_HEAD, or after BB_END.
Referenced by emit_note_after(), and emit_note_before().
Return a memory reference like MEMREF, but whose address is changed by adding OFFSET, an RTX, to it. POW2 is the highest power of two factor known to be in OFFSET (possibly 1).
References attrs, change_address_1(), force_reg(), get_address_mode(), GET_CODE, get_mem_attrs(), GET_MODE, memory_address_addr_space_p(), MIN, mode_mem_attrs, offset, pic_offset_table_rtx, set_mem_attrs(), simplify_gen_binary(), mem_attrs::size, mem_attrs::size_known_p, update_temp_slot_address(), and XEXP.
Referenced by expand_assignment(), expand_expr_real_1(), store_constructor(), and store_expr().
rtx operand_subword | ( | rtx | op, |
poly_uint64 | offset, | ||
int | validate_address, | ||
machine_mode | mode ) |
Return subword OFFSET of operand OP. The word number, OFFSET, is interpreted as the word number starting at the low-order address. OFFSET 0 is the low-order word if not WORDS_BIG_ENDIAN, otherwise it is the high-order word. If we cannot extract the required word, we return zero. Otherwise, an rtx corresponding to the requested word will be returned. VALIDATE_ADDRESS is nonzero if the address should be validated. Before reload has completed, a valid address will always be returned. After reload, if a valid address cannot be returned, we return zero. If VALIDATE_ADDRESS is zero, we simply form the required address; validating it is the responsibility of the caller. MODE is the mode of OP in case it is a CONST_INT. ??? This is still rather broken for some cases. The problem for the moment is that all callers of this thing provide no 'goal mode' to tell us to work with. This exists because all callers were written in a word based SUBREG world. Now use of this function can be deprecated by simplify_subreg in most cases.
References adjust_address_nv, const0_rtx, gcc_assert, GET_MODE, GET_MODE_SIZE(), maybe_gt, MEM_ADDR_SPACE, MEM_P, offset, reload_completed, replace_equiv_address(), simplify_gen_subreg(), strict_memory_address_addr_space_p(), word_mode, and XEXP.
Referenced by convert_mode_scalar(), copy_blkmode_from_reg(), copy_blkmode_to_reg(), emit_move_multi_word(), expand_absneg_bit(), expand_binop(), expand_copysign_bit(), expand_doubleword_bswap(), expand_doubleword_mult(), expand_unop(), extract_integral_bit_field(), find_equiv_reg(), move_block_from_reg(), and operand_subword_force().
rtx operand_subword_force | ( | rtx | op, |
poly_uint64 | offset, | ||
machine_mode | mode ) |
Similar to `operand_subword', but never return 0. If we can't extract the required subword, put OP into a register and try again. The second attempt must succeed. We always validate the address in this case. MODE is the mode of OP, in case it is CONST_INT.
References copy_to_reg(), force_reg(), gcc_assert, offset, operand_subword(), and REG_P.
Referenced by copy_blkmode_from_reg(), copy_blkmode_to_reg(), do_jump_by_parts_equality_rtx(), do_jump_by_parts_greater_rtx(), do_jump_by_parts_zero_rtx(), emit_move_multi_word(), emit_push_insn(), expand_absneg_bit(), expand_binop(), expand_builtin_signbit(), expand_copysign_absneg(), expand_copysign_bit(), expand_doubleword_bswap(), expand_doubleword_mod(), expand_doubleword_mult(), expand_doubleword_parity(), expand_doubleword_popcount(), expand_unop(), extract_split_bit_field(), move_block_to_reg(), store_integral_bit_field(), store_split_bit_field(), and store_unaligned_arguments_into_pseudos().
void pop_topmost_sequence | ( | void | ) |
After emitting to the outer-level insn chain, update the outer-level insn chain, and restore the previous saved state.
References end_sequence(), sequence_stack::first, get_insns(), get_last_insn(), get_topmost_sequence(), and sequence_stack::last.
Referenced by expand_builtin_apply_args(), expand_builtin_saveregs(), and get_arg_pointer_save_area().
Find the last insn before INSN that really does something. This routine does not look inside SEQUENCEs. After reload this also skips over standalone USE and CLOBBER insn.
References active_insn_p(), and PREV_INSN().
Referenced by delete_dead_insn(), merge_blocks_move_successor_nojumps(), and relax_delay_slots().
Return the previous insn before INSN that is not a DEBUG_INSN. This routine does not look inside SEQUENCEs.
References DEBUG_INSN_P, and PREV_INSN().
Referenced by combine_and_move_insns(), doloop_condition_get(), expand_gimple_basic_block(), and try_forward_edges().
Return the previous insn before INSN that is not a NOTE. This routine does not look inside SEQUENCEs.
References NOTE_P, and PREV_INSN().
Referenced by assign_parm_setup_reg(), commit_one_edge_insertion(), delete_prior_computation(), fill_simple_delay_slots(), final_scan_insn_1(), find_basic_block(), get_label_before(), own_thread_p(), relax_delay_slots(), reversed_comparison_code_parts(), and set_label_offsets().
Return the previous insn before INSN that is not a NOTE nor DEBUG_INSN. This routine does not look inside SEQUENCEs.
References DEBUG_INSN_P, NOTE_P, and PREV_INSN().
Referenced by canonicalize_condition(), cleanup_barriers(), noce_get_alt_condition(), noce_process_if_block(), noce_try_abs(), and reload_combine_recognize_pattern().
Return the previous insn before INSN that is not a NOTE nor DEBUG_INSN, but stop the search before we enter another basic block. This routine does not look inside SEQUENCEs.
References DEBUG_INSN_P, NOTE_INSN_BASIC_BLOCK_P, NOTE_P, NULL, and PREV_INSN().
Referenced by find_bb_boundaries(), and setup_sp_offset().
Return the last INSN, CALL_INSN, JUMP_INSN or DEBUG_INSN before INSN; or 0, if there is none. This routine does not look inside SEQUENCEs.
References INSN_P, and PREV_INSN().
Referenced by add_var_loc_to_decl(), and lra_delete_dead_insn().
Return the last INSN, CALL_INSN or JUMP_INSN before INSN; or 0, if there is none. This routine does not look inside SEQUENCEs.
References NONDEBUG_INSN_P, and PREV_INSN().
Referenced by move_deaths(), and try_head_merge_bb().
Return the previous insn. If it is a SEQUENCE, return the last insn of the sequence.
References dyn_cast(), NONJUMP_INSN_P, PATTERN(), and PREV_INSN().
Referenced by get_last_nonnote_insn().
void push_to_sequence | ( | rtx_insn * | first | ) |
Set up the insn chain starting with FIRST as the current sequence, saving the previously current one. See the documentation for start_sequence for more information about how to use this function.
References sequence_stack::first, last, NEXT_INSN(), set_first_insn(), set_last_insn(), and start_sequence().
Referenced by asan_emit_allocas_unpoison(), curr_insn_transform(), emit_input_reload_insns(), emit_output_reload_insns(), expand_builtin_return(), insert_insn_on_edge(), insert_move_for_subreg(), match_reload(), process_addr_reg(), and process_address_1().
Like push_to_sequence, but take the last insn as an argument to avoid looping through the list.
References sequence_stack::first, last, set_first_insn(), set_last_insn(), and start_sequence().
Referenced by assign_parm_setup_block(), assign_parm_setup_reg(), assign_parm_setup_stack(), assign_parms_unsplit_complex(), and expand_asm_stmt().
void push_topmost_sequence | ( | void | ) |
Set up the outer-level insn chain as the current sequence, saving the previously current one.
References sequence_stack::first, get_topmost_sequence(), sequence_stack::last, set_first_insn(), set_last_insn(), and start_sequence().
Referenced by expand_builtin_apply_args(), expand_builtin_saveregs(), and get_arg_pointer_save_area().
Return TRUE if REG is a PARM_DECL, FALSE otherwise.
References gcc_assert, REG_EXPR, REG_P, and TREE_CODE.
Referenced by ira_build_conflicts().
void remove_insn | ( | rtx_insn * | insn | ) |
Unlink INSN from the insn chain. This function knows how to handle sequences. This function does not invalidate data flow information associated with INSN (i.e. does not call df_insn_delete). That makes this function usable for only disconnecting an insn from the chain, and re-emit it elsewhere later. To later insert INSN elsewhere in the insn chain via add_insn and similar functions, PREV_INSN and NEXT_INSN must be nullified by the caller. Nullifying them here breaks many insn chain walks. To really delete an insn and related DF information, use delete_insn.
References as_a(), BARRIER_P, BB_END, BB_HEAD, BLOCK_FOR_INSN(), sequence_stack::first, gcc_assert, GET_CODE, get_current_sequence(), rtx_sequence::insn(), sequence_stack::last, rtx_sequence::len(), sequence_stack::next, NEXT_INSN(), NONJUMP_INSN_P, NOTE_P, PATTERN(), PREV_INSN(), SET_NEXT_INSN(), and SET_PREV_INSN().
Referenced by delete_insn(), emit_delay_sequence(), and resolve_simple_move().
Same as function above, but take care to update BB boundaries.
References BARRIER_P, BB_END, BLOCK_FOR_INSN(), df_insn_change_bb(), df_set_bb_dirty(), NEXT_INSN(), PREV_INSN(), and reorder_insns_nobb().
Referenced by dead_or_predicable(), expand_case(), expand_sjlj_dispatch_table(), move_invariant_reg(), noce_process_if_block(), reload_combine_recognize_const_pattern(), reposition_prologue_and_epilogue_notes(), rtl_tidy_fallthru_edge(), skip_insns_after_block(), thread_prologue_and_epilogue_insns(), and try_head_merge_bb().
This function is deprecated, please use sequences instead. Move a consecutive bunch of insns to a different place in the chain. The insns to be moved are those between FROM and TO. They are moved to a new position after the insn AFTER. AFTER must not be FROM or TO or any insn in between. This function does not know about SEQUENCEs and hence should not be called after delay-slot filling has been done.
References gcc_assert, get_insns(), get_last_insn(), NEXT_INSN(), PREV_INSN(), set_first_insn(), set_last_insn(), SET_NEXT_INSN(), and SET_PREV_INSN().
Referenced by cleanup_barriers(), create_basic_block_structure(), delete_insn(), find_bb_boundaries(), maybe_duplicate_computed_goto(), merge_blocks_move_predecessor_nojumps(), merge_blocks_move_successor_nojumps(), reload_as_needed(), reorder_insns(), and rtl_merge_blocks().
Return a memory reference like MEMREF, but with its address changed to ADDR. The caller is asserting that the actual piece of memory pointed to is the same, just the form of the address is being changed, such as by putting something into a register. INPLACE is true if any changes can be made directly to MEMREF or false if MEMREF must be treated as immutable.
References change_address_1(), update_temp_slot_address(), and XEXP.
Referenced by emit_move_resolve_push(), expand_expr_real_1(), expand_movstr(), force_reload_address(), instantiate_virtual_regs_in_insn(), maybe_legitimize_operand_same_code(), operand_subword(), try_apply_stack_adjustment(), try_store_by_multiple_pieces(), use_anchored_address(), and validize_mem().
Likewise, but the reference is not required to be valid.
References change_address_1().
Referenced by add_mem_for_addr(), adjust_mems(), attempt_change(), canon_rtx(), eliminate_regs_1(), emit_move_multi_word(), expand_debug_parm_decl(), pair_fusion_bb_info::fuse_pair(), lra_eliminate_regs_1(), make_memloc(), push_reload(), replace_expr_with_values(), simplify_replace_fn_rtx(), try_apply_stack_adjustment(), and vt_add_function_parameter().
|
static |
Go through all the RTL insn bodies and clear all the USED bits.
References gcc_assert, GET_CODE, get_insns(), i, INSN_P, NEXT_INSN(), NULL, PATTERN(), REG_NOTES, reset_insn_used_flags(), XVECEXP, and XVECLEN.
Referenced by verify_rtl_sharing().
|
static |
Reset used-flags for INSN.
References CALL_INSN_FUNCTION_USAGE, CALL_P, gcc_assert, INSN_P, PATTERN(), REG_NOTES, and reset_used_flags().
Referenced by reset_all_used_flags().
void reset_used_flags | ( | rtx | x | ) |
Clear all the USED bits in X to allow copy_rtx_if_shared to be used to look for shared sub-parts.
References mark_used_flags().
Referenced by doloop_modify(), reset_insn_used_flags(), try_combine(), and unshare_all_rtl_again().
double_int rtx_to_double_int | ( | const_rtx | cst | ) |
Constructs double_int from rtx CST.
References CONST_DOUBLE_AS_INT_P, CONST_DOUBLE_HIGH, CONST_DOUBLE_LOW, CONST_INT_P, double_int::from_shwi(), gcc_unreachable, INTVAL, and r.
Referenced by loc_descriptor(), and mem_loc_descriptor().
void set_curr_insn_location | ( | location_t | location | ) |
Set current location.
References curr_location.
Referenced by expand_expr_real_gassign(), expand_function_end(), expand_gimple_basic_block(), expand_gimple_cond(), expand_gimple_stmt_1(), expand_thunk(), insert_part_to_rtx_on_edge(), insert_partition_copy_on_edge(), insert_rtx_to_part_on_edge(), insert_value_copy_on_edge(), and set_location_for_edge().
Assign the RTX X to parameter declaration T. BY_REFERENCE_P is true if the ABI requires the parameter to be passed by reference.
References DECL_INCOMING_RTL, and set_reg_attrs_for_decl_rtl().
Referenced by assign_parms(), assign_parms_unsplit_complex(), and expand_function_start().
Assign the RTX X to declaration T.
References DECL_WRTL_CHECK, and set_reg_attrs_for_decl_rtl().
Referenced by initialize_argument_information().
Like set_unique_reg_note, but don't do anything unless INSN sets DST.
References NULL_RTX, SET_DEST, set_for_reg_notes(), and set_unique_reg_note().
Referenced by assign_parm_setup_reg(), emit_libcall_block_1(), expand_absneg_bit(), expand_binop(), expand_DIVMOD(), expand_divmod(), expand_fix(), expand_function_start(), expand_mult_const(), gen_reload(), and reload_cse_simplify().
Notes like REG_EQUAL and REG_EQUIV refer to a set in an instruction. Return the set in INSN that such notes describe, or NULL if the notes have no meaning for INSN.
References GET_CODE, INSN_P, multiple_sets(), NULL_RTX, PATTERN(), REG_P, SET, SET_DEST, XEXP, and XVECEXP.
Referenced by add_equal_note(), forward_propagate_and_simplify(), reload_cse_simplify(), set_dst_reg_note(), set_unique_reg_note(), and try_fwprop_subst_pattern().
void set_insn_deleted | ( | rtx_insn * | insn | ) |
Replace insn with an deleted instruction note.
References df_insn_delete(), INSN_P, NOTE_KIND, and PUT_CODE.
Referenced by find_moveable_pseudos(), and one_cprop_pass().
void set_insn_locations | ( | rtx_insn * | insn, |
location_t | loc ) |
Set the location of the insn chain starting at INSN to LOC.
References INSN_LOCATION(), INSN_P, and NEXT_INSN().
Referenced by emit_moves(), expand_function_end(), make_epilogue_seq(), make_prologue_seq(), make_split_prologue_seq(), and thread_prologue_and_epilogue_insns().
void set_mem_addr_space | ( | rtx | mem, |
addr_space_t | addrspace ) |
Set the address space of MEM to ADDRSPACE (target-defined).
References mem_attrs::addrspace, attrs, get_mem_attrs(), and set_mem_attrs().
Referenced by expand_debug_expr(), expand_expr_real_1(), get_builtin_sync_mem(), function_reader::handle_any_trailing_information(), noce_try_cmove_arith(), and produce_memory_decl_rtl().
void set_mem_alias_set | ( | rtx | mem, |
alias_set_type | set ) |
Set the alias set of MEM to SET.
References alias_sets_conflict_p(), attrs, gcc_checking_assert, get_mem_attrs(), MEM_ALIAS_SET, and set_mem_attrs().
Referenced by asan_emit_stack_protection(), assign_stack_temp_for_type(), build_constant_desc(), compute_argument_addresses(), expand_builtin_longjmp(), expand_builtin_setjmp_setup(), expand_builtin_va_copy(), gen_frame_mem(), gen_tmp_stack_mem(), get_builtin_sync_mem(), get_memory_rtx(), function_reader::handle_any_trailing_information(), merge_memattrs(), noce_try_cmove_arith(), optimize_bitfield_assignment_op(), setup_save_areas(), store_constructor_field(), and store_field().
void set_mem_align | ( | rtx | mem, |
unsigned int | align ) |
Set the alignment of MEM to ALIGN bits.
References mem_attrs::align, attrs, get_mem_attrs(), and set_mem_attrs().
Referenced by asan_emit_stack_protection(), assemble_trampoline_template(), assemble_variable(), assign_parm_find_stack_rtl(), assign_parm_setup_stack(), assign_stack_local_1(), assign_stack_temp_for_type(), attempt_change(), build_constant_desc(), compute_argument_addresses(), emit_push_insn(), expand_builtin_apply(), expand_builtin_init_descriptor(), expand_builtin_init_trampoline(), expand_builtin_memory_copy_args(), expand_builtin_memset_args(), expand_builtin_va_copy(), expand_expr_real_1(), expand_one_stack_var_at(), force_const_mem(), get_builtin_sync_mem(), get_memory_rtx(), function_reader::handle_any_trailing_information(), merge_memattrs(), noce_try_cmove_arith(), and try_store_by_multiple_pieces().
Given REF, a MEM, and T, either the type of X or the expression corresponding to REF, set the memory attributes. OBJECTP is nonzero if we are making a new object of this type.
References set_mem_attributes_minus_bitpos().
Referenced by assign_parm_find_stack_rtl(), assign_parm_setup_block(), assign_parm_setup_reg(), assign_parm_setup_stack(), assign_parms(), assign_parms_unsplit_complex(), compute_argument_addresses(), expand_builtin_init_trampoline(), expand_call(), expand_debug_expr(), expand_expr_real_1(), expand_expr_real_2(), expand_function_start(), get_memory_rtx(), initialize_argument_information(), layout_decl(), make_decl_rtl(), and set_rtl().
void set_mem_attributes_minus_bitpos | ( | rtx | ref, |
tree | t, | ||
int | objectp, | ||
poly_int64 | bitpos ) |
Given REF (a MEM) and T, either the type of X or the expression corresponding to REF, set the memory attributes. OBJECTP is nonzero if we are making a new object of this type. BITPOS is nonzero if there is an offset outstanding on T that will be applied later.
References mem_attrs::align, bits_to_bytes_round_down, build2(), build_int_cst(), cfun, component_uses_parent_alias_set_from(), CONSTANT_CLASS_P, CONVERT_EXPR_P, DECL_BIT_FIELD, DECL_EXTERNAL, DECL_P, DECL_RTL_IF_SET, DECL_SIZE_UNIT, error_mark_node, mem_attrs::expr, gcc_assert, get_alias_set(), get_base_address(), GET_MODE, get_object_alignment_1(), handled_component_p(), is_global_var(), MAX, MEM_ATTRS, MEM_KEEP_ALIAS_SET_P, MEM_NOTRAP_P, MEM_POINTER, MEM_READONLY_P, MEM_VOLATILE_P, MIN, mode_mem_attrs, NULL, NULL_TREE, attrs::offset, mem_attrs::offset, mem_attrs::offset_known_p, POINTER_TYPE_P, poly_int_tree_p(), reference_alias_ptr_type(), set_mem_attrs(), mem_attrs::size, mem_attrs::size_known_p, TREE_CODE, tree_could_trap_p(), TREE_OPERAND, TREE_READONLY, TREE_STATIC, TREE_THIS_VOLATILE, TREE_TYPE, type(), TYPE_ADDR_SPACE, TYPE_ALIGN, TYPE_P, TYPE_SIZE_UNIT, TYPE_VOLATILE, unshare_expr(), and VAR_P.
Referenced by expand_assignment(), and set_mem_attributes().
Set MEM's memory attributes so that they are the same as ATTRS.
References GET_MODE, ggc_alloc(), MEM_ATTRS, mem_attrs_eq_p(), and mode_mem_attrs.
Referenced by adjust_address_1(), change_address(), clear_mem_offset(), clear_mem_size(), get_spill_slot_decl(), offset_address(), set_mem_addr_space(), set_mem_alias_set(), set_mem_align(), set_mem_attributes_minus_bitpos(), set_mem_attrs_for_spill(), set_mem_expr(), set_mem_offset(), set_mem_size(), and widen_memory_access().
void set_mem_attrs_for_spill | ( | rtx | mem | ) |
Given MEM, a result from assign_stack_local, fill in the memory attributes as appropriate for a register allocator spill slot. These slots are not aliasable by other memory. We arrange for them all to use a single MEM_EXPR, so that the aliasing code can work properly in the case of shared spill slots.
References ADDR_SPACE_GENERIC, attrs, DECL_RTL, get_mem_attrs(), get_spill_slot_decl(), MEM_ALIAS_SET, MEM_NOTRAP_P, attrs::offset, set_mem_attrs(), strip_offset(), and XEXP.
Referenced by alter_reg(), and assign_mem_slot().
Set the expr for MEM to EXPR.
References attrs, expr, get_mem_attrs(), and set_mem_attrs().
Referenced by fixup_expr::apply(), duplicate_insn_chain(), emit_call_1(), expand_debug_expr(), expand_expr_real_1(), expand_partial_load_optab_fn(), expand_partial_store_optab_fn(), merge_memattrs(), and optimize_bitfield_assignment_op().
void set_mem_offset | ( | rtx | mem, |
poly_int64 | offset ) |
Set the offset of MEM to OFFSET.
References attrs, get_mem_attrs(), attrs::offset, offset, and set_mem_attrs().
Referenced by assign_parm_find_stack_rtl(), assign_parm_setup_stack(), and function_reader::handle_any_trailing_information().
void set_mem_size | ( | rtx | mem, |
poly_int64 | size ) |
Set the size of MEM to SIZE.
References attrs, get_mem_attrs(), set_mem_attrs(), and mem_attrs::size.
Referenced by assemble_trampoline_template(), assign_parm_find_stack_rtl(), compute_argument_addresses(), emit_block_move_hints(), expand_builtin_init_trampoline(), expand_builtin_memcmp(), expand_expr_real_1(), function_reader::handle_any_trailing_information(), merge_memattrs(), and scan_insn().
void set_mode_and_regno | ( | rtx | x, |
machine_mode | mode, | ||
unsigned int | regno ) |
Set the mode and register number of X to MODE and REGNO.
References HARD_REGISTER_NUM_P, hard_regno_nregs(), PUT_MODE_RAW, and set_regno_raw().
Referenced by df_ref_change_reg_with_loc(), init_expr_target(), init_raw_REG(), PUT_MODE(), reg_save_code(), reload_cse_simplify_operands(), and setup_prohibited_mode_move_regs().
For procedure integration.
Install new pointers to the first and last insns in the chain. Also, set cur_insn_uid to one higher than the last in use. Used for an inline-procedure after copying the insn chain.
References cur_debug_insn_uid, cur_insn_uid, DEBUG_INSN_P, INSN_UID(), last, MAX, MAY_HAVE_DEBUG_INSNS, NEXT_INSN(), set_first_insn(), and set_last_insn().
Set the REG_ATTRS for registers in value X, given that X represents decl T.
References byte_lowpart_offset(), DECL_MODE, DECL_P, gcc_assert, GET_CODE, GET_MODE, GET_MODE_UNIT_SIZE, get_reg_attrs(), i, INTVAL, REG_ATTRS, REG_P, subreg_lowpart_p(), SUBREG_REG, TREE_TYPE, TYPE_MODE, XEXP, XVECEXP, XVECLEN, and y.
Referenced by fixup_expr::apply(), expand_asm_stmt(), expand_expr_real_gassign(), set_decl_incoming_rtl(), set_decl_rtl(), and set_rtl().
Set the register attributes for registers contained in PARM_RTX. Use needed values from memory attributes of MEM.
References GET_CODE, get_reg_attrs(), i, INTVAL, MEM_EXPR, REG_ATTRS, REG_P, set_reg_attrs_from_value(), XEXP, XVECEXP, and XVECLEN.
Referenced by assign_parm_find_stack_rtl().
Copy REG's attributes from X, if X has any attributes. If REG and X have different modes, REG is a (possibly paradoxical) lowpart of X.
References byte_lowpart_offset(), GET_CODE, GET_MODE, get_reg_attrs(), HARD_REGISTER_P, mark_reg_pointer(), MEM_EXPR, MEM_OFFSET, MEM_OFFSET_KNOWN_P, MEM_P, MEM_POINTER, offset, paradoxical_subreg_p(), REG_ATTRS, REG_P, REG_POINTER, REGNO, REGNO_POINTER_ALIGN, SUBREG_CHECK_PROMOTED_SIGN, subreg_lowpart_p(), SUBREG_PROMOTED_VAR_P, targetm, update_reg_offset(), and XEXP.
Referenced by gen_reg_rtx_and_attrs(), make_more_copies(), reg_scan_mark_refs(), and set_reg_attrs_for_parm().
Place a note of KIND on insn INSN with DATUM as the datum. If a note of this type already exists, remove it first.
References add_reg_note(), as_a(), df_notes_rescan(), find_reg_note(), GET_CODE, NULL_RTX, PATTERN(), REG_NOTES, set_for_reg_notes(), side_effects_p(), and XEXP.
Referenced by add_equal_note(), add_store_equivs(), assign_parm_setup_reg(), compress_float_constant(), cprop_jump(), cse_insn(), emit_move_insn(), find_reloads(), force_reg(), forward_propagate_and_simplify(), gcse_emit_move_after(), gen_reload(), ira_update_equiv_info_by_shuffle_insn(), set_dst_reg_note(), split_insn(), try_back_substitute_reg(), try_fwprop_subst_pattern(), try_replace_reg(), and update_equiv_regs().
|
static |
Go through all virtual stack slots of a function and mark them as shared. We never replace the DECL_RTLs themselves with a copy, but expressions mentioned into a DECL_RTL cannot be shared with expressions in the instruction stream. Note that reload may convert pseudo registers into memories in-place. Pseudo registers are always shared, but MEMs never are. Thus if we reset the used flags on MEMs in the instruction stream, we must set them again on MEMs that appear in DECL_RTLs.
References BLOCK_CHAIN, BLOCK_SUBBLOCKS, BLOCK_VARS, DECL_CHAIN, DECL_RTL, DECL_RTL_SET_P, set_used_decls(), and set_used_flags().
Referenced by set_used_decls(), and unshare_all_rtl_again().
void set_used_flags | ( | rtx | x | ) |
Set all the USED bits in X to allow copy_rtx_if_shared to be used to look for shared sub-parts.
References mark_used_flags().
Referenced by doloop_modify(), end_ifcvt_sequence(), noce_convert_multiple_sets(), noce_process_if_block(), set_used_decls(), and unshare_all_rtl_again().
void start_sequence | ( | void | ) |
Begin emitting insns to a sequence. If this sequence will contain something that might cause the compiler to pop arguments to function calls (because those pops have previously been deferred; see INHIBIT_DEFER_POP for more details), use do_pending_stack_adjust before calling this function. That will ensure that the deferred pops are not accidentally emitted in the middle of this sequence.
References sequence_stack::first, free_sequence_stack, get_current_sequence(), get_insns(), get_last_insn(), ggc_alloc(), sequence_stack::last, sequence_stack::next, NULL, set_first_insn(), and set_last_insn().
Referenced by add_test(), asan_clear_shadow(), asan_emit_allocas_unpoison(), asan_emit_stack_protection(), assign_parm_setup_reg(), attempt_change(), check_and_process_move(), combine_reaching_defs(), combine_var_copies_in_loop_exit(), compare_and_jump_seq(), computation_cost(), compute_can_copy(), cond_move_process_if_block(), convert_mode_scalar(), curr_insn_transform(), do_remat(), doloop_modify(), dw2_build_landing_pads(), emit_common_heads_for_components(), emit_common_tails_for_components(), emit_delay_sequence(), emit_inc_dec_insn_before(), emit_initial_value_sets(), emit_move_list(), emit_move_multi_word(), emit_output_reload_insns(), emit_partition_copy(), expand_absneg_bit(), expand_asm_stmt(), expand_atomic_fetch_op(), expand_binop(), expand_builtin_apply_args(), expand_builtin_int_roundingfn(), expand_builtin_int_roundingfn_2(), expand_builtin_mathfn_3(), expand_builtin_mathfn_ternary(), expand_builtin_saveregs(), expand_builtin_strlen(), expand_call(), expand_clrsb_using_clz(), expand_cond_expr_using_cmove(), expand_copysign_bit(), expand_ctz(), expand_DIVMOD(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_popcount(), expand_expr_divmod(), expand_expr_real_2(), expand_ffs(), expand_fix(), expand_fixed_convert(), expand_float(), expand_function_end(), expand_POPCOUNT(), expand_sdiv_pow2(), expand_twoval_binop_libfunc(), expand_unop(), expmed_mult_highpart_optab(), find_shift_sequence(), fix_crossing_unconditional_branches(), gen_call_used_regs_seq(), gen_clobber(), gen_cond_trap(), gen_move_insn(), gen_use(), get_arg_pointer_save_area(), get_uncond_jump_length(), hwasan_emit_untag_frame(), hwasan_frame_base(), inherit_in_ebb(), inherit_reload_reg(), init_set_costs(), initialize_uninitialized_regs(), inline_string_cmp(), insert_base_initialization(), insert_insn_on_edge(), insert_move_for_subreg(), insert_prologue_epilogue_for_components(), insert_value_copy_on_edge(), insert_var_expansion_initialization(), instantiate_virtual_regs_in_insn(), ira(), lra_process_new_insns(), make_epilogue_seq(), make_prologue_seq(), make_split_prologue_seq(), match_asm_constraints_1(), match_reload(), maybe_optimize_mod_cmp(), maybe_optimize_pow2p_mod_cmp(), noce_convert_multiple_sets(), noce_emit_cmove(), noce_emit_move_insn(), noce_emit_store_flag(), noce_process_if_block(), noce_try_abs(), noce_try_addcc(), noce_try_bitop(), noce_try_cmove(), noce_try_cmove_arith(), noce_try_cond_zero_arith(), noce_try_ifelse_collapse(), noce_try_inverse_constants(), noce_try_minmax(), noce_try_move(), noce_try_sign_mask(), noce_try_store_flag(), noce_try_store_flag_constants(), noce_try_store_flag_mask(), prepare_copy_insn(), prepare_float_lib_cmp(), prepend_insn_to_edge(), process_addr_reg(), process_address_1(), process_invariant_for_inheritance(), push_to_sequence(), push_to_sequence2(), push_topmost_sequence(), record_store(), remove_inheritance_pseudos(), replace_read(), resolve_shift_zext(), resolve_simple_move(), rtl_lv_add_condition_to_bb(), sjlj_emit_dispatch_table(), sjlj_emit_function_enter(), sjlj_emit_function_exit(), sjlj_mark_call_sites(), split_iv(), thread_prologue_and_epilogue_insns(), try_emit_cmove_seq(), and unroll_loop_runtime_iterations().
Return true iff X, assumed to be a SUBREG, refers to the least significant part of its containing reg. If X is not a SUBREG, always return true (it is its own low part!).
References GET_CODE, GET_MODE, known_eq, SUBREG_BYTE, subreg_lowpart_offset(), and SUBREG_REG.
Referenced by adjust_mems(), alter_subreg(), change_zero_ext(), dead_debug_insert_temp(), df_word_lr_mark_ref(), eliminate_regs_in_insn(), eliminate_regs_in_insn(), expand_compound_operation(), expand_field_assignment(), expand_shift_1(), ext_dce_process_uses(), force_to_mode(), forward_propagate_subreg(), get_biv_step_1(), get_last_value(), iv_analyze_op(), loc_descriptor(), make_compound_operation_int(), make_extraction(), make_field_assignment(), mark_pseudo_reg_dead(), mark_pseudo_reg_live(), mem_loc_descriptor(), move_plus_up(), notreg_cost(), push_reload(), record_dead_and_set_regs_1(), record_jump_cond(), set_reg_attrs_for_decl_rtl(), set_reg_attrs_from_value(), set_rtl(), simple_reg_p(), simplify_context::simplify_binary_operation_1(), simplify_comparison(), simplify_if_then_else(), simplify_context::simplify_relational_operation_1(), simplify_set(), simplify_shift_const_1(), simplify_context::simplify_subreg(), simplify_context::simplify_ternary_operation(), simplify_context::simplify_truncation(), simplify_context::simplify_unary_operation_1(), strip_address_mutations(), and try_combine().
poly_int64 subreg_memory_offset | ( | const_rtx | x | ) |
As above, but return the offset that existing subreg X would have if SUBREG_REG (X) were stored in memory. The only significant thing about the current SUBREG_REG is its mode.
References GET_MODE, SUBREG_BYTE, subreg_memory_offset(), and SUBREG_REG.
poly_int64 subreg_memory_offset | ( | machine_mode | outer_mode, |
machine_mode | inner_mode, | ||
poly_uint64 | offset ) |
Return the offset of (subreg:OUTER_MODE (mem:INNER_MODE X) OFFSET) from address X. For paradoxical big-endian subregs this is a negative value, otherwise it's the same as OFFSET.
References gcc_assert, known_eq, offset, paradoxical_subreg_p(), and subreg_lowpart_offset().
Referenced by simplify_context::simplify_binary_operation_1(), simplify_context::simplify_subreg(), store_bit_field_1(), subreg_memory_offset(), and undefined_operand_subword_p().
poly_uint64 subreg_size_highpart_offset | ( | poly_uint64 | outer_bytes, |
poly_uint64 | inner_bytes ) |
Return the SUBREG_BYTE for a highpart subreg whose outer mode has OUTER_BYTES bytes and whose inner mode has INNER_BYTES bytes.
References gcc_assert, known_ge, and subreg_size_offset_from_lsb().
Referenced by subreg_highpart_offset().
poly_uint64 subreg_size_lowpart_offset | ( | poly_uint64 | outer_bytes, |
poly_uint64 | inner_bytes ) |
Return the SUBREG_BYTE for a lowpart subreg whose outer mode has OUTER_BYTES bytes and whose inner mode has INNER_BYTES bytes.
References gcc_checking_assert, maybe_gt, and subreg_size_offset_from_lsb().
Referenced by alter_reg(), assign_mem_slot(), maybe_mode_change(), subreg_get_info(), and subreg_lowpart_offset().
Try splitting insns that can be split for better scheduling. PAT is the pattern which might split. TRIAL is the insn providing PAT. LAST is nonzero if we should return the last insn of the sequence produced. If this routine succeeds in splitting, it returns the first or last replacement insn depending on the value of LAST. Otherwise, it returns TRIAL. If the insn to be returned can be split, it will be.
References add_reg_br_prob_note(), add_reg_note(), any_condjump_p(), AUTO_INC_DEC, CALL_INSN_FUNCTION_USAGE, CALL_P, copy_frame_info_to_split_insn(), copy_reg_eh_region_note_backward(), CROSSING_JUMP_P, delete_insn(), rtx_insn::deleted(), emit_insn_after_setloc(), find_auto_inc(), FIND_REG_INC_NOTE, find_reg_note(), fixup_args_size_notes(), profile_probability::from_reg_br_prob_note(), gcc_assert, get_args_size(), get_last_insn(), profile_probability::initialized_p(), INSN_LOCATION(), INSN_P, JUMP_P, last, mark_jump_label(), mark_label_nuses(), NEXT_INSN(), NONJUMP_INSN_P, NULL, NULL_RTX, PATTERN(), PREV_INSN(), REG_NOTE_KIND, REG_NOTES, reload_completed, rtx_equal_p(), RTX_FRAME_RELATED_P, SIBLING_CALL_P, split_branch_probability, split_insns(), try_split(), profile_probability::uninitialized(), unshare_all_rtl_in_chain(), XEXP, and XINT.
Referenced by fill_simple_delay_slots(), fill_slots_from_thread(), final_scan_insn_1(), split_insn(), thread_prologue_and_epilogue_insns(), try_merge_delay_insns(), and try_split().
void unshare_all_rtl | ( | void | ) |
References cfun, copy_rtx_if_shared(), DECL_ARGUMENTS, DECL_CHAIN, DECL_INCOMING_RTL, DECL_RTL, DECL_RTL_SET_P, get_insns(), SET_DECL_RTL, and unshare_all_rtl_1().
|
static |
Go through all the RTL insn bodies and copy any invalid shared structure. This routine should only be called once.
References copy_rtx_if_shared(), FOR_EACH_VEC_SAFE_ELT, i, stack_slot_list, and unshare_all_rtl_in_chain().
Referenced by unshare_all_rtl(), and unshare_all_rtl_again().
void unshare_all_rtl_again | ( | rtx_insn * | insn | ) |
Go through all the RTL insn bodies and copy any invalid shared structure, again. This is a fairly expensive thing to do so it should be done sparingly.
References CALL_INSN_FUNCTION_USAGE, CALL_P, cfun, DECL_ARGUMENTS, DECL_CHAIN, DECL_INITIAL, DECL_RTL, FOR_EACH_VEC_SAFE_ELT, i, INSN_P, NEXT_INSN(), PATTERN(), REG_NOTES, reset_used_flags(), set_used_decls(), set_used_flags(), stack_slot_list, and unshare_all_rtl_1().
void unshare_all_rtl_in_chain | ( | rtx_insn * | insn | ) |
Go through all the RTL insn bodies and copy any invalid shared structure. Assumes the mark bits are cleared at entry.
References CALL_INSN_FUNCTION_USAGE, CALL_P, copy_rtx_if_shared(), INSN_P, NEXT_INSN(), PATTERN(), and REG_NOTES.
Referenced by add_test(), doloop_modify(), end_ifcvt_sequence(), noce_convert_multiple_sets(), noce_process_if_block(), try_split(), unroll_loop_runtime_iterations(), and unshare_all_rtl_1().
|
static |
Update NEW with the same attributes as REG, but with OFFSET added to the REG_OFFSET.
References get_reg_attrs(), offset, REG_ATTRS, REG_EXPR, and REG_OFFSET.
Referenced by adjust_reg_mode(), gen_reg_rtx_offset(), gen_rtx_REG_offset(), and set_reg_attrs_from_value().
Return true if X is a valid element for a CONST_VECTOR of the given mode.
References CONST_DOUBLE_AS_FLOAT_P, CONST_FIXED_P, CONST_POLY_INT_P, and CONST_SCALAR_INT_P.
Referenced by expand_vector_broadcast(), gen_const_vec_series(), gen_vec_duplicate(), gen_vec_series(), simplify_context::simplify_binary_operation_1(), simplify_const_binary_operation(), and simplify_const_unary_operation().
bool validate_subreg | ( | machine_mode | omode, |
machine_mode | imode, | ||
const_rtx | reg, | ||
poly_uint64 | offset ) |
We want to create (subreg:OMODE (obj:IMODE) OFFSET). Return true if this construct would be valid, and false otherwise.
References COMPLEX_MODE_P, FLOAT_MODE_P, GET_MODE_ALIGNMENT, GET_MODE_INNER, GET_MODE_SIZE(), GET_MODE_UNIT_SIZE, HARD_REGISTER_P, known_eq, known_ge, lra_in_progress, maybe_ge, maybe_gt, MEM_ALIGN, MEM_P, offset, REG_CAN_CHANGE_MODE_P, REG_P, REGMODE_NATURAL_SIZE, REGNO, subreg_offset_representable_p(), VECTOR_MODE_P, and word_mode.
Referenced by insn_propagation::apply_to_rvalue_1(), extract_low_bits(), gen_lowpart_if_possible(), gen_rtx_SUBREG(), get_stored_val(), make_extraction(), set_noop_p(), simplify_context::simplify_gen_subreg(), simplify_context::simplify_subreg(), store_bit_field_using_insv(), store_integral_bit_field(), use_narrower_mode_test(), and valid_multiword_target_p().
|
static |
Verify sharing in INSN.
References CALL_INSN_FUNCTION_USAGE, CALL_P, gcc_assert, INSN_P, PATTERN(), REG_NOTES, and verify_rtx_sharing().
Referenced by verify_rtl_sharing().
DEBUG_FUNCTION void verify_rtl_sharing | ( | void | ) |
Go through all the RTL insn bodies and check that there is no unexpected sharing in between the subexpressions.
References GET_CODE, get_insns(), i, INSN_P, NEXT_INSN(), PATTERN(), reset_all_used_flags(), timevar_pop(), timevar_push(), verify_insn_sharing(), XVECEXP, and XVECLEN.
Referenced by execute_function_todo().
Check that ORIG is not marked when it should not be and mark ORIG as in use, Recursively does the same for subexpressions.
References CASE_CONST_ANY, CONSTANT_ADDRESS_P, debug_rtx(), error(), gcc_assert, GET_CODE, GET_RTX_FORMAT, GET_RTX_LENGTH, HARD_REGISTER_NUM_P, i, internal_error(), NULL, ORIGINAL_REGNO, REG_P, REGNO, reload_completed, reload_in_progress, RTX_FLAG, SET, SET_DEST, SET_SRC, shared_const_p(), verify_rtx_sharing(), XEXP, XVEC, XVECEXP, and XVECLEN.
Referenced by verify_insn_sharing(), and verify_rtx_sharing().
rtx widen_memory_access | ( | rtx | memref, |
machine_mode | mode, | ||
poly_int64 | offset ) |
Return a memory reference like MEMREF, but with its mode widened to MODE and offset by OFFSET. This would be used by targets that e.g. cannot issue QImode memory operations and have to use SImode memory operations plus masking logic.
References adjust_address_1(), attrs, component_ref_field_offset(), DECL_FIELD_BIT_OFFSET, DECL_P, DECL_SIZE_UNIT, get_mem_attrs(), GET_MODE_SIZE(), known_ge, NULL_TREE, attrs::offset, offset, poly_int_tree_p(), set_mem_attrs(), mem_attrs::size, wi::to_poly_offset(), TREE_CODE, TREE_OPERAND, and tree_to_uhwi().
scalar_int_mode byte_mode |
Commonly used modes.
Referenced by get_traditional_extraction_insn(), init_derived_machine_modes(), and set_storage_via_setmem().
|
static |
Referenced by init_emit_once(), and lookup_const_double().
|
static |
Referenced by init_emit_once(), and lookup_const_fixed().
|
static |
Referenced by gen_rtx_CONST_INT(), and init_emit_once().
rtx const_int_rtx[MAX_SAVED_CONST_INT *2+1] |
We make one copy of (const_int C) where C is in [- MAX_SAVED_CONST_INT, MAX_SAVED_CONST_INT] to save space during the compilation and simplify comparisons of integers.
Referenced by gen_rtx_CONST_INT(), and init_emit_once().
|
static |
Referenced by immed_wide_int_const(), and init_emit_once().
rtx const_tiny_rtx[4][(int) MAX_MACHINE_MODE] |
We record floating-point CONST_DOUBLEs in each floating-point mode for the values of 0, 1, and 2. For the integer entries and VOIDmode, we record a copy of const[012]_rtx and constm1_rtx. CONSTM1_RTX is set only for MODE_INT and MODE_VECTOR_INT modes.
Referenced by gen_const_vector(), and init_emit_once().
rtx const_true_rtx |
Referenced by block_has_only_trap(), combine_simplify_rtx(), comparison_result(), condition_dominates_p(), determine_max_iter(), eliminate_implied_condition(), expand_debug_expr(), fill_eager_delay_slots(), fill_simple_delay_slots(), fill_slots_from_thread(), fold_rtx(), gen_rtx_CONST_INT(), get_branch_condition(), if_then_else_cond(), implies_p(), init_emit_once(), iv_number_of_iterations(), known_cond(), merge_if_block(), prepare_float_lib_cmp(), relational_result(), simplify_context::simplify_binary_operation_1(), simplify_const_relational_operation(), simplify_if_then_else(), simplify_context::simplify_logical_relational_operation(), simplify_using_condition(), simplify_using_initial_values(), steal_delay_list_from_fallthrough(), and steal_delay_list_from_target().
|
static |
Referenced by init_emit_once().
|
static |
Referenced by copy_insn(), and copy_insn_1().
|
static |
When an insn is being copied by copy_insn_1, this is nonzero if we have copied an ASM_OPERANDS. In that case, it is the copied input-operand vector.
Referenced by copy_insn(), and copy_insn_1().
|
static |
Referenced by copy_insn(), and copy_insn_1().
|
static |
Used by copy_insn_1 to avoid copying SCRATCHes more than once.
Referenced by copy_insn_1().
|
static |
Referenced by copy_insn_1().
|
static |
Hold current location information and last location information, so the datastructures are built lazily only when some instructions in given place are needed.
Referenced by branch_prob(), curr_insn_location(), insn_locations_finalize(), insn_locations_init(), and set_curr_insn_location().
REAL_VALUE_TYPE dconst0 |
**** End of software floating point emulator interface macros ****
Constant real values 0, 1, 2, -1 and 0.5.
Referenced by scev_dfs::add_to_evolution_1(), adjust_equivalence_range(), associate_equivalences_with_edges(), build_complex_inf(), build_real(), build_zero_cst(), const_binop(), contains_zero_p(), expand_builtin_cexpi(), expand_builtin_signbit(), expand_pow_as_sqrts(), float_binary_op_range_finish(), frange::flush_denormals_to_zero(), fold_builtin_fpclassify(), fold_builtin_interclass_mathfn(), fold_builtin_modf(), fold_const_call_cc(), fold_const_call_ss(), fold_const_call_sss(), fold_const_pow(), cfn_sqrt::fold_range(), operator_abs::fold_range(), get_component_ssa_name(), implicit_set_cond_p(), init_emit_once(), cfn_signbit::op1_range(), cfn_sqrt::op1_range(), operator_abs::op1_range(), real_maybe_zerop(), real_zerop(), record_equality(), representable_as_half_series_p(), operator_mult::rv_fold(), frange::set_nonnegative(), frange::set_zero(), simplify_context::simplify_binary_operation_1(), simplify_const_binary_operation(), some_nonzerop(), zero_range(), and zero_to_inf_range().
REAL_VALUE_TYPE dconst1 |
Referenced by build_one_cst(), build_real(), build_sinatan_real(), check_pow(), decimal_to_decnumber(), expand_complex_multiplication(), expand_pow_as_sqrts(), float_widen_lhs_range(), fold_const_call_ss(), cfn_sincos::fold_range(), gen_conditions_for_pow_cst_base(), gimple_expand_builtin_pow(), init_emit_once(), cfn_sincos::op1_range(), optimize_recip_sqrt(), powi_as_mults(), real_ceil(), real_onep(), real_powi(), simplify_context::simplify_binary_operation_1(), and ubsan_instrument_float_cast().
REAL_VALUE_TYPE dconst2 |
Referenced by build_real(), chrec_fold_multiply_poly_poly(), decimal_to_decnumber(), estimate_num_insns(), expand_mult(), expand_omp_for_init_vars(), float_widen_lhs_range(), gimple_expand_builtin_pow(), init_emit_once(), simplify_context::simplify_binary_operation_1(), and vect_recog_pow_pattern().
REAL_VALUE_TYPE dconsthalf |
REAL_VALUE_TYPE dconstinf |
Referenced by build_complex_inf(), float_widen_lhs_range(), fold_builtin_fpclassify(), fold_builtin_inf(), fold_const_call_cc(), cfn_sincos::fold_range(), cfn_sqrt::fold_range(), frange_mpfr_arg1(), frange_val_max(), inf_range(), init_emit_once(), omp_reduction_init_op(), cfn_sincos::op1_range(), cfn_sqrt::op1_range(), real_from_mpfr(), foperator_div::rv_fold(), operator_minus::rv_fold(), operator_mult::rv_fold(), operator_plus::rv_fold(), range_operator::rv_fold(), and zero_to_inf_range().
REAL_VALUE_TYPE dconstm0 |
REAL_VALUE_TYPE dconstm1 |
Referenced by scev_dfs::add_to_evolution(), build_minus_one_cst(), build_real(), chrec_fold_plus_1(), chrec_fold_plus_poly_poly(), decimal_to_decnumber(), float_widen_lhs_range(), fold_const_call_ss(), cfn_sincos::fold_range(), init_emit_once(), cfn_sincos::op1_range(), real_floor(), real_minus_onep(), real_roundeven(), simplify_context::simplify_binary_operation_1(), and ubsan_instrument_float_cast().
REAL_VALUE_TYPE dconstninf |
Referenced by float_widen_lhs_range(), cfn_sincos::fold_range(), cfn_sqrt::fold_range(), frange_mpfr_arg1(), frange_val_min(), inf_range(), init_emit_once(), cfn_sincos::op1_range(), cfn_sqrt::op1_range(), foperator_div::rv_fold(), operator_minus::rv_fold(), operator_mult::rv_fold(), operator_plus::rv_fold(), range_operator::rv_fold(), and zero_to_inf_range().
struct target_rtl default_target_rtl |
Emit RTL for the GCC expander. Copyright (C) 1987-2024 Free Software Foundation, Inc. This file is part of GCC. GCC is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3, or (at your option) any later version. GCC is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with GCC; see the file COPYING3. If not see <http://www.gnu.org/licenses/>.
Middle-to-low level generation of rtx code and insns. This file contains support functions for creating rtl expressions and manipulating them in the doubly-linked chain of insns. The patterns of the insns are created by machine-dependent routines in insn-emit.cc, which is generated automatically from the machine description. These routines make the individual rtx's of the pattern with `gen_rtx_fmt_ee' and others in genrtl.[ch], which are automatically generated from rtl.def; what is machine dependent is the kind of rtx's they make and what arguments they use.
location_t epilogue_location |
FIXED_VALUE_TYPE fconst0[MAX_FCONST0] |
Record fixed-point constant 0 and 1.
FIXED_VALUE_TYPE fconst1[MAX_FCONST1] |
|
static |
Space for free sequence stack entries.
Referenced by end_sequence(), and start_sequence().
|
static |
Referenced by gen_hard_reg_clobber().
rtx_insn* invalid_insn_rtx |
Marker used for denoting an INSN, which should never be accessed (i.e., this pointer should normally never be dereferenced), but is required to be distinct from NULL_RTX. Currently used by peephole2 pass.
Referenced by init_emit_once().
|
static |
This is *not* reset after each function. It gives each CODE_LABEL in the entire compilation a unique label number.
Referenced by gen_label_rtx(), init_emit(), max_label_num(), and maybe_set_max_label_num().
|
static |
Likewise for the constraints vector.
Referenced by copy_insn(), and copy_insn_1().
|
static |
When an insn is being copied by copy_insn_1, this is nonzero if we have copied an ASM_OPERANDS. In that case, it is the original input-operand vector.
Referenced by copy_insn(), and copy_insn_1().
rtx pc_rtx |
Standard pieces of rtx, to be substituted directly into things.
Referenced by add_scope_conflicts_1(), add_stack_var(), bypass_block(), combine_simplify_rtx(), computed_jump_p(), condjump_in_parallel_p(), condjump_label(), function_reader::consolidate_singletons(), convert_to_eh_region_ranges(), count_reg_usage(), cprop_jump(), cse_insn(), cselib_record_sets(), distribute_links(), distribute_notes(), doloop_condition_get(), dw2_asm_output_encoded_addr_rtx(), dwarf2out_flush_queued_reg_saves(), dwarf2out_frame_debug_cfa_offset(), dwarf2out_frame_debug_cfa_register(), emit_block_move_hints(), emit_library_call_value_1(), expand_builtin_memory_copy_args(), expand_call(), expand_stack_vars(), ext_dce_process_sets(), ext_dce_process_uses(), find_sets_in_insn(), get_branch_condition(), hide_operands(), init_emit_once(), initial_return_save(), internal_arg_pointer_based_exp(), internal_arg_pointer_based_exp_scan(), make_edges(), make_insn_raw(), mark_effect(), outgoing_edges_match(), prepare_call_arguments(), purge_dead_tablejump_edges(), record_jump_equiv(), redirect_exp_1(), set_label_offsets(), set_noop_p(), set_rtl(), simplify_if_then_else(), simplify_set(), tablejump_casesi_pattern(), thread_jump(), try_combine(), visit_conflict(), and visit_op().
location_t prologue_location |
scalar_int_mode ptr_mode |
Referenced by asan_emit_allocas_unpoison(), asan_emit_stack_protection(), default_addr_space_pointer_mode(), default_emit_call_builtin___clear_cache(), default_valid_pointer_mode(), emit_block_op_via_libcall(), expand_asan_emit_allocas_unpoison(), expand_atomic_compare_and_swap(), expand_atomic_fetch_op(), expand_BITINTTOFLOAT(), expand_builtin_adjust_descriptor(), expand_builtin_alloca(), expand_builtin_apply(), expand_builtin_eh_copy_values(), expand_builtin_eh_pointer(), expand_builtin_extend_pointer(), expand_builtin_frob_return_addr(), expand_builtin_init_descriptor(), expand_builtin_memory_copy_args(), expand_builtin_memset_args(), expand_builtin_next_arg(), expand_builtin_sincos(), expand_builtin_stack_address(), expand_builtin_strncpy(), expand_builtin_strub_enter(), expand_builtin_strub_leave(), expand_builtin_strub_update(), expand_DIVMODBITINT(), expand_dw2_landing_pad_for_region(), expand_expr_addr_expr(), expand_expr_real_2(), expand_FLOATTOBITINT(), expand_HWASAN_ALLOCA_UNPOISON(), expand_HWASAN_MARK(), expand_HWASAN_SET_TAG(), expand_MULBITINT(), expand_omp_atomic_mutex(), expand_omp_atomic_pipeline(), fold_builtin_memcmp(), get_memory_rtx(), get_nl_goto_field(), get_section_anchor(), gimple_fold_builtin_memory_op(), gimple_load_first_char(), strlen_pass::handle_builtin_memcmp(), hwasan_emit_prologue(), hwasan_emit_untag_frame(), init_derived_machine_modes(), maybe_emit_call_builtin___clear_cache(), maybe_emit_sync_lock_test_and_set(), mem_loc_descriptor(), nonzero_bits1(), num_sign_bit_copies1(), prepare_call_address(), process_addr_reg(), push_block(), set_stack_check_libfunc(), simplify_context::simplify_unary_operation_1(), sjlj_emit_dispatch_table(), sjlj_emit_function_enter(), stack_protect_epilogue(), try_store_by_multiple_pieces(), and verify_gimple_assign_unary().
|
static |
Referenced by get_reg_attrs(), init_emit_once(), and init_emit_regs().
rtx* regno_reg_rtx |
Indexed by pseudo register number, gives the rtx for that pseudo. Allocated in parallel with regno_pointer_align. FIXME: We could put it into emit_status struct, but gengtype is not able to deal with length attribute nested in top level structures.
Referenced by allocno_reload_assign(), allocnos_conflict_by_live_ranges_p(), alter_reg(), assign_by_spills(), assign_mem_slot(), assign_parm_setup_reg(), calculate_equiv_gains(), canon_reg(), combine_and_move_insns(), consolidate_reg(), cse_insn(), dead_debug_insert_temp(), decompose_multiword_subregs(), decompose_register(), df_bb_refs_collect(), df_entry_block_defs_collect(), df_exit_block_uses_collect(), df_get_call_refs(), df_insn_refs_collect(), df_ref_change_reg_with_loc_1(), df_ref_record(), df_set_dead_notes_for_mw(), df_set_unused_notes_for_mw(), distribute_notes(), do_input_reload(), dump_reg_info(), emit_reload_insns(), emit_status::ensure_regno_capacity(), equiv_can_be_consumed_p(), expand_asm_reg_clobber_mem_blockage(), find_costs_and_classes(), find_split_point(), free_after_compilation(), gen_reg_rtx(), gen_rtx_REG(), get_subreg_tracking_sizes(), inherit_in_ebb(), inherit_reload_reg(), init_alias_analysis(), init_emit(), init_virtual_regs(), ira_build_conflicts(), ira_emit(), lra_constraints(), lra_create_live_ranges_1(), lra_final_code_change(), make_reg_live(), move_deaths(), non_spilled_static_chain_regno_p(), process_alt_operands(), process_bb_lives(), record_operand_costs(), reload(), remove_inheritance_pseudos(), remove_init_insns(), replace_pseudos_in(), save_call_clobbered_regs(), setup_preferred_alternate_classes_for_new_pseudos(), setup_regno_cost_classes_by_aclass(), setup_save_areas(), simplify_operand_subreg(), simplify_set(), split_reg(), subst_mode(), substitute(), target_reinit(), try_combine(), undo_to_marker(), use_regs(), and zcur_select_mode_rtx().
rtx ret_rtx |
rtx simple_return_rtx |
|
static |
A fake decl that is used as the MEM_EXPR of spill slots.
Referenced by get_spill_slot_decl().
profile_probability split_branch_probability |
Probability of the conditional branch currently proceeded by try_split.
Referenced by init_emit_regs(), and try_split().
scalar_int_mode word_mode |
Referenced by adjust_bit_field_mem_for_reg(), anti_adjust_stack_and_probe_stack_clash(), assign_parm_setup_block(), build_word_mode_vector_type(), can_assign_to_reg_without_clobbers_p(), can_decompose_p(), compute_costs(), compute_splitting_shift(), convert_mode_scalar(), copy_blkmode_from_reg(), copy_blkmode_to_reg(), create_new_invariant(), decompose_register(), default_emutls_var_fields(), default_libgcc_cmp_return_mode(), default_libgcc_shift_count_mode(), default_preferred_simd_mode(), default_unwind_word_mode(), desired_pro_or_demotion_p(), do_jump_by_parts_equality_rtx(), do_jump_by_parts_greater_rtx(), do_jump_by_parts_zero_rtx(), do_output_reload(), doloop_optimize(), tree_switch_conversion::bit_test_cluster::emit(), emit_block_cmp_via_loop(), emit_block_move_via_loop(), emit_library_call_value_1(), emit_push_insn(), emit_stack_probe(), emit_store_flag_1(), emit_store_flag_force(), emit_store_flag_int(), emutls_common_1(), equiv_constant(), expand_binop(), expand_builtin_signbit(), expand_copysign_absneg(), expand_copysign_bit(), expand_debug_expr(), expand_DIVMOD(), expand_doubleword_bswap(), expand_doubleword_clz_ctz_ffs(), expand_doubleword_mod(), expand_doubleword_mult(), expand_doubleword_parity(), expand_doubleword_popcount(), expand_doubleword_shift(), expand_doubleword_shift_condmove(), expand_expr_real_2(), expand_SET_EDOM(), expand_subword_shift(), expand_superword_shift(), expand_unop(), expand_vector_parallel(), expression_expensive_p(), extract_high_half(), extract_integral_bit_field(), extract_split_bit_field(), find_decomposable_shift_zext(), find_decomposable_subregs(), find_if_header(), find_reloads_address_1(), force_const_mem(), get_absneg_bit_mode(), get_optab_extraction_insn(), get_traditional_extraction_insn(), strlen_pass::handle_builtin_memcmp(), init_caller_save(), init_derived_machine_modes(), init_expr_target(), init_lower_subreg(), init_reg_modes_target(), load_register_parameters(), lshift_cheap_p(), make_extraction(), mem_loc_descriptor(), move_block_from_reg(), move_block_to_reg(), operand_subword(), optimize_range_tests_to_bit_test(), push_reload(), reload_cse_regs_1(), reload_cse_simplify_operands(), reload_cse_simplify_set(), replace_read(), resolve_clobber(), resolve_shift_zext(), resolve_simple_move(), setup_prohibited_mode_move_regs(), simplify_and_const_int_1(), simplify_context::simplify_binary_operation_1(), simplify_const_binary_operation(), simplify_context::simplify_subreg(), simplify_while_replacing(), store_constructor(), store_integral_bit_field(), store_split_bit_field(), store_unaligned_arguments_into_pseudos(), try_combine(), valid_multiword_target_p(), validate_subreg(), and vectorizable_operation().
struct rtl_data x_rtl |
Datastructures maintained for currently processed function in RTL form.