GCC Middle and Back End API Reference
|
Go to the source code of this file.
Data Structures | |
class | bit_field_mode_iterator |
Enumerations | |
enum | mode_class { MODE_CLASSES, MAX_MODE_CLASS, MODE_CLASSES, MAX_MODE_CLASS } |
Functions | |
enum machine_mode | mode_for_size (unsigned int, enum mode_class, int) |
enum machine_mode | smallest_mode_for_size (unsigned int, enum mode_class) |
enum machine_mode | int_mode_for_mode (enum machine_mode) |
enum machine_mode | mode_for_vector (enum machine_mode, unsigned) |
enum machine_mode | get_best_mode (int, int, unsigned HOST_WIDE_INT, unsigned HOST_WIDE_INT, unsigned int, enum machine_mode, bool) |
unsigned | get_mode_alignment (enum machine_mode) |
unsigned int | element_precision (enum machine_mode) |
void | init_adjust_machine_modes (void) |
Variables | |
const char *const | mode_name [NUM_MACHINE_MODES] |
const unsigned char | mode_class [NUM_MACHINE_MODES] |
CONST_MODE_SIZE unsigned char | mode_size [NUM_MACHINE_MODES] |
const unsigned short | mode_precision [NUM_MACHINE_MODES] |
CONST_MODE_IBIT unsigned char | mode_ibit [NUM_MACHINE_MODES] |
CONST_MODE_FBIT unsigned char | mode_fbit [NUM_MACHINE_MODES] |
const unsigned HOST_WIDE_INT | mode_mask_array [NUM_MACHINE_MODES] |
const unsigned char | mode_inner [NUM_MACHINE_MODES] |
const unsigned char | mode_nunits [NUM_MACHINE_MODES] |
const unsigned char | mode_wider [NUM_MACHINE_MODES] |
const unsigned char | mode_2xwider [NUM_MACHINE_MODES] |
CONST_MODE_BASE_ALIGN unsigned char | mode_base_align [NUM_MACHINE_MODES] |
const unsigned char | class_narrowest_mode [MAX_MODE_CLASS] |
enum machine_mode | byte_mode |
enum machine_mode | word_mode |
enum machine_mode | ptr_mode |
enum mode_class |
unsigned int element_precision | ( | enum | machine_mode | ) |
Get the precision of the mode or its inner mode if it has one.
Referenced by convert_to_integer(), fold_binary_loc(), and operand_equal_p().
enum machine_mode get_best_mode | ( | int | bitsize, |
int | bitpos, | ||
unsigned HOST_WIDE_INT | bitregion_start, | ||
unsigned HOST_WIDE_INT | bitregion_end, | ||
unsigned int | align, | ||
enum machine_mode | largest_mode, | ||
bool | volatilep | ||
) |
Find the best mode to use to access a bit field.
Find the best machine mode to use when referencing a bit field of length BITSIZE bits starting at BITPOS. BITREGION_START is the bit position of the first bit in this sequence of bit fields. BITREGION_END is the last bit in this sequence. If these two fields are non-zero, we should restrict the memory access to that range. Otherwise, we are allowed to touch any adjacent non bit-fields. The underlying object is known to be aligned to a boundary of ALIGN bits. If LARGEST_MODE is not VOIDmode, it means that we should not use a mode larger than LARGEST_MODE (usually SImode). If no mode meets all these conditions, we return VOIDmode. If VOLATILEP is false and SLOW_BYTE_ACCESS is false, we return the smallest mode meeting these conditions. If VOLATILEP is false and SLOW_BYTE_ACCESS is true, we return the largest mode (but a mode no wider than UNITS_PER_WORD) that meets all the conditions. If VOLATILEP is true the narrow_volatile_bitfields target hook is used to decide which of the above modes should be used.
References bit_field_mode_iterator::next_mode(), and bit_field_mode_iterator::prefer_smaller_modes().
Referenced by extract_fixed_bit_field(), fold_truth_andor_1(), optimize_bit_field_compare(), optimize_bitfield_assignment_op(), store_bit_field(), and store_fixed_bit_field().
unsigned get_mode_alignment | ( | enum | machine_mode | ) |
Referenced by emit_move_complex().
void init_adjust_machine_modes | ( | void | ) |
Target-dependent machine mode initialization - in insn-modes.c.
Referenced by do_compile().
enum machine_mode int_mode_for_mode | ( | enum | machine_mode | ) |
Return an integer mode of the exact same size as the input mode, or BLKmode on failure.
Referenced by emit_group_load_1(), emit_group_store(), emit_move_via_integer(), expand_absneg_bit(), expand_builtin_signbit(), expand_copysign_absneg(), expand_copysign_bit(), expand_debug_expr(), extract_bit_field_1(), extract_low_bits(), gen_lowpart_for_combine(), gen_lowpart_or_truncate(), get_stored_val(), prepare_call_arguments(), store_bit_field_1(), vect_gen_perm_mask(), and vect_transform_slp_perm_load().
enum machine_mode mode_for_size | ( | unsigned | int, |
enum | mode_class, | ||
int | |||
) |
Return the mode for data of a given size SIZE and mode class CLASS. If LIMIT is nonzero, then don't use modes bigger than MAX_FIXED_MODE_SIZE. The value is BLKmode if no other mode is found.
Referenced by alignment_for_piecewise_move(), alter_reg(), assemble_integer(), assign_mem_slot(), assign_parm_setup_block(), combine_instructions(), compute_argument_addresses(), convert_extracted_bit_field(), copy_blkmode_from_reg(), do_jump(), emit_library_call_value_1(), expand_builtin_atomic_clear(), expand_builtin_atomic_test_and_set(), expand_builtin_powi(), expand_expr_real_1(), expand_field_assignment(), expand_vector_parallel(), extract_bit_field_1(), fold_builtin_atomic_always_lock_free(), gen_lowpart_common(), get_builtin_sync_mode(), get_secondary_mem(), init_emit_once(), init_optabs(), int_mode_for_mode(), layout_type(), make_accum_type(), make_extraction(), make_fract_type(), mem_loc_descriptor(), mode_for_size_tree(), mode_for_vector(), resolve_simple_move(), save_fixed_argument_area(), set_builtin_user_assembler_name(), simple_move(), simplify_comparison(), simplify_shift_const_1(), simplify_subreg_concatn(), simplify_unary_operation_1(), store_one_arg(), subreg_get_info(), vect_lanes_optab_supported_p(), and vector_type_mode().
enum machine_mode mode_for_vector | ( | enum | machine_mode, |
unsigned | |||
) |
Return a mode that is suitable for representing a vector, or BLKmode on failure.
Referenced by can_vec_perm_p(), expand_expr_real_2(), expand_vec_perm(), get_vectype_for_scalar_type_and_size(), and layout_type().
enum machine_mode smallest_mode_for_size | ( | unsigned | int, |
enum | mode_class | ||
) |
Similar, but find the smallest mode for a given width.
Referenced by canonicalize_loop_ivs(), convert_move(), expand_debug_expr(), expand_twoval_binop_libfunc(), extract_bit_field_1(), find_shift_sequence(), get_best_extraction_insn(), initialize_sizetypes(), layout_type(), make_extraction(), max_precision_type(), store_bit_field_1(), store_field(), and type_for_interval().
enum machine_mode byte_mode |
Define the integer modes whose sizes are BITS_PER_UNIT and BITS_PER_WORD and the mode whose class is Pmode and whose size is POINTER_SIZE.
Commonly used modes.
Referenced by get_traditional_extraction_insn(), init_emit_once(), and set_storage_via_setmem().
const unsigned char class_narrowest_mode[MAX_MODE_CLASS] |
For each class, get the narrowest mode in that class.
const unsigned char mode_2xwider[NUM_MACHINE_MODES] |
For scalars, this is a mode with twice the precision. For vectors, this is a mode with the same inner mode but with twice the elements.
CONST_MODE_BASE_ALIGN unsigned char mode_base_align[NUM_MACHINE_MODES] |
Determine alignment, 1<=result<=BIGGEST_ALIGNMENT.
Referenced by get_mode_alignment().
const unsigned char mode_class[NUM_MACHINE_MODES] |
Get the general kind of object that mode MODE represents (integer, floating, complex, etc.)
CONST_MODE_FBIT unsigned char mode_fbit[NUM_MACHINE_MODES] |
Get the number of fractional bits of an object of mode MODE.
CONST_MODE_IBIT unsigned char mode_ibit[NUM_MACHINE_MODES] |
Get the number of integral bits of an object of mode MODE.
const unsigned char mode_inner[NUM_MACHINE_MODES] |
Return the mode of the inner elements in a vector.
const unsigned HOST_WIDE_INT mode_mask_array[NUM_MACHINE_MODES] |
Get a bitmask containing 1 for all bits in a word that fit within mode MODE.
const char* const mode_name[NUM_MACHINE_MODES] |
Make an enum class that gives all the machine modes.
Get the name of mode MODE as a string.
Referenced by write_predicate_expr().
const unsigned char mode_nunits[NUM_MACHINE_MODES] |
Get the number of units in the object.
const unsigned short mode_precision[NUM_MACHINE_MODES] |
Get the number of value bits of an object of mode MODE.
CONST_MODE_SIZE unsigned char mode_size[NUM_MACHINE_MODES] |
Get the size in bytes and bits of an object of mode MODE.
const unsigned char mode_wider[NUM_MACHINE_MODES] |
Get the next wider natural mode (eg, QI -> HI -> SI -> DI -> TI).
enum machine_mode ptr_mode |
Referenced by asan_emit_stack_protection(), default_addr_space_pointer_mode(), default_valid_pointer_mode(), emit_block_move_via_libcall(), expand_atomic_compare_and_swap(), expand_atomic_fetch_op(), 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_memcpy(), expand_builtin_mempcpy_args(), expand_builtin_memset_args(), expand_builtin_next_arg(), expand_builtin_sincos(), expand_builtin_strncpy(), expand_dw2_landing_pad_for_region(), expand_expr_addr_expr(), expand_expr_real_2(), expand_omp_atomic_pipeline(), fold_builtin_memcmp(), fold_builtin_memory_op(), fold_builtin_strcmp(), fold_builtin_strncmp(), get_builtin_sync_mem(), get_memory_rtx(), get_nl_goto_field(), get_section_anchor(), init_emit_once(), maybe_emit_sync_lock_test_and_set(), mem_loc_descriptor(), mudflap_init(), nonzero_bits1(), num_sign_bit_copies1(), push_block(), simplify_unary_operation_1(), sjlj_emit_dispatch_table(), stack_protect_epilogue(), and vect_create_data_ref_ptr().
enum machine_mode word_mode |
Referenced by adjust_bit_field_mem_for_reg(), 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_move(), 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(), do_jump_by_parts_equality_rtx(), do_jump_by_parts_greater_rtx(), do_jump_by_parts_zero_rtx(), do_output_reload(), doloop_optimize(), emit_block_move_via_loop(), emit_case_bit_tests(), emit_library_call_value_1(), emit_push_insn(), emit_stack_probe(), emit_store_flag(), emit_store_flag_1(), emit_store_flag_force(), emutls_common_1(), equiv_constant(), execute_optimize_bswap(), expand_absneg_bit(), expand_binop(), expand_builtin_signbit(), expand_copysign_absneg(), expand_copysign_bit(), expand_doubleword_bswap(), expand_doubleword_clz(), expand_doubleword_mult(), expand_doubleword_shift(), expand_doubleword_shift_condmove(), expand_errno_check(), expand_expr_real_2(), expand_subword_shift(), expand_superword_shift(), expand_switch_using_bit_tests_p(), expand_unop(), expand_vector_parallel(), extract_bit_field_1(), extract_fixed_bit_field(), extract_high_half(), extract_split_bit_field(), find_decomposable_shift_zext(), find_decomposable_subregs(), find_if_header(), find_reloads_address_1(), fold_truth_andor_1(), force_const_mem(), gen_int_libfunc(), get_optab_extraction_insn(), get_traditional_extraction_insn(), init_emit_once(), 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_bit_field_compare(), optimize_bitfield_assignment_op(), prepare_cmp_insn(), push_reload(), reload_cse_simplify_operands(), reload_cse_simplify_set(), resolve_clobber(), resolve_shift_zext(), resolve_simple_move(), simplify_while_replacing(), store_bit_field_1(), store_constructor(), store_fixed_bit_field(), store_split_bit_field(), store_unaligned_arguments_into_pseudos(), try_combine(), undefined_operand_subword_p(), valid_multiword_target_p(), and validate_subreg().