GCC Middle and Back End API Reference
builtins.c File Reference

Functions

static tree do_mpc_arg1 (tree, tree, int(*)(mpc_ptr, mpc_srcptr, mpc_rnd_t))
static const char * c_getstr (tree)
static rtx c_readstr (const char *, enum machine_mode)
static int target_char_cast (tree, char *)
static rtx get_memory_rtx (tree, tree)
static int apply_args_size (void)
static int apply_result_size (void)
static rtx result_vector (int, rtx)
static void expand_builtin_update_setjmp_buf (rtx)
static void expand_builtin_prefetch (tree)
static rtx expand_builtin_apply_args (void)
static rtx expand_builtin_apply_args_1 (void)
static rtx expand_builtin_apply (rtx, rtx, rtx)
static void expand_builtin_return (rtx)
static enum type_class type_to_class (tree)
static rtx expand_builtin_classify_type (tree)
static void expand_errno_check (tree, rtx)
static rtx expand_builtin_mathfn (tree, rtx, rtx)
static rtx expand_builtin_mathfn_2 (tree, rtx, rtx)
static rtx expand_builtin_mathfn_3 (tree, rtx, rtx)
static rtx expand_builtin_mathfn_ternary (tree, rtx, rtx)
static rtx expand_builtin_interclass_mathfn (tree, rtx)
static rtx expand_builtin_sincos (tree)
static rtx expand_builtin_cexpi (tree, rtx)
static rtx expand_builtin_int_roundingfn (tree, rtx)
static rtx expand_builtin_int_roundingfn_2 (tree, rtx)
static rtx expand_builtin_next_arg (void)
static rtx expand_builtin_va_start (tree)
static rtx expand_builtin_va_end (tree)
static rtx expand_builtin_va_copy (tree)
static rtx expand_builtin_memcmp (tree, rtx, enum machine_mode)
static rtx expand_builtin_strcmp (tree, rtx)
static rtx expand_builtin_strncmp (tree, rtx, enum machine_mode)
static rtx builtin_memcpy_read_str (void *, HOST_WIDE_INT, enum machine_mode)
static rtx expand_builtin_memcpy (tree, rtx)
static rtx expand_builtin_mempcpy (tree, rtx, enum machine_mode)
static rtx expand_builtin_mempcpy_args (tree, tree, tree, rtx, enum machine_mode, int)
static rtx expand_builtin_strcpy (tree, rtx)
static rtx expand_builtin_strcpy_args (tree, tree, rtx)
static rtx expand_builtin_stpcpy (tree, rtx, enum machine_mode)
static rtx expand_builtin_strncpy (tree, rtx)
static rtx builtin_memset_gen_str (void *, HOST_WIDE_INT, enum machine_mode)
static rtx expand_builtin_memset (tree, rtx, enum machine_mode)
static rtx expand_builtin_memset_args (tree, tree, tree, rtx, enum machine_mode, tree)
static rtx expand_builtin_bzero (tree)
static rtx expand_builtin_strlen (tree, rtx, enum machine_mode)
static rtx expand_builtin_alloca (tree, bool)
static rtx expand_builtin_unop (enum machine_mode, tree, rtx, rtx, optab)
static rtx expand_builtin_frame_address (tree, tree)
static tree stabilize_va_list_loc (location_t, tree, int)
static rtx expand_builtin_expect (tree, rtx)
static tree fold_builtin_constant_p (tree)
static tree fold_builtin_expect (location_t, tree, tree)
static tree fold_builtin_classify_type (tree)
static tree fold_builtin_strlen (location_t, tree, tree)
static tree fold_builtin_inf (location_t, tree, int)
static tree fold_builtin_nan (tree, tree, int)
static tree rewrite_call_expr (location_t, tree, int, tree, int,...)
static bool validate_arg (const_tree, enum tree_code code)
static bool integer_valued_real_p (tree)
static tree fold_trunc_transparent_mathfn (location_t, tree, tree)
static bool readonly_data_expr (tree)
static rtx expand_builtin_fabs (tree, rtx, rtx)
static rtx expand_builtin_signbit (tree, rtx)
static tree fold_builtin_sqrt (location_t, tree, tree)
static tree fold_builtin_cbrt (location_t, tree, tree)
static tree fold_builtin_pow (location_t, tree, tree, tree, tree)
static tree fold_builtin_powi (location_t, tree, tree, tree, tree)
static tree fold_builtin_cos (location_t, tree, tree, tree)
static tree fold_builtin_cosh (location_t, tree, tree, tree)
static tree fold_builtin_tan (tree, tree)
static tree fold_builtin_trunc (location_t, tree, tree)
static tree fold_builtin_floor (location_t, tree, tree)
static tree fold_builtin_ceil (location_t, tree, tree)
static tree fold_builtin_round (location_t, tree, tree)
static tree fold_builtin_int_roundingfn (location_t, tree, tree)
static tree fold_builtin_bitop (tree, tree)
static tree fold_builtin_memory_op (location_t, tree, tree, tree, tree, bool, int)
static tree fold_builtin_strchr (location_t, tree, tree, tree)
static tree fold_builtin_memchr (location_t, tree, tree, tree, tree)
static tree fold_builtin_memcmp (location_t, tree, tree, tree)
static tree fold_builtin_strcmp (location_t, tree, tree)
static tree fold_builtin_strncmp (location_t, tree, tree, tree)
static tree fold_builtin_signbit (location_t, tree, tree)
static tree fold_builtin_copysign (location_t, tree, tree, tree, tree)
static tree fold_builtin_isascii (location_t, tree)
static tree fold_builtin_toascii (location_t, tree)
static tree fold_builtin_isdigit (location_t, tree)
static tree fold_builtin_fabs (location_t, tree, tree)
static tree fold_builtin_abs (location_t, tree, tree)
static tree fold_builtin_unordered_cmp (location_t, tree, tree, tree, enum tree_code, enum tree_code)
static tree fold_builtin_n (location_t, tree, tree *, int, bool)
static tree fold_builtin_0 (location_t, tree, bool)
static tree fold_builtin_1 (location_t, tree, tree, bool)
static tree fold_builtin_2 (location_t, tree, tree, tree, bool)
static tree fold_builtin_3 (location_t, tree, tree, tree, tree, bool)
static tree fold_builtin_4 (location_t, tree, tree, tree, tree, tree, bool)
static tree fold_builtin_varargs (location_t, tree, tree, bool)
static tree fold_builtin_strpbrk (location_t, tree, tree, tree)
static tree fold_builtin_strstr (location_t, tree, tree, tree)
static tree fold_builtin_strrchr (location_t, tree, tree, tree)
static tree fold_builtin_strcat (location_t, tree, tree)
static tree fold_builtin_strncat (location_t, tree, tree, tree)
static tree fold_builtin_strspn (location_t, tree, tree)
static tree fold_builtin_strcspn (location_t, tree, tree)
static tree fold_builtin_sprintf (location_t, tree, tree, tree, int)
static tree fold_builtin_snprintf (location_t, tree, tree, tree, tree, int)
static rtx expand_builtin_object_size (tree)
static rtx expand_builtin_memory_chk (tree, rtx, enum machine_mode, enum built_in_function)
static void maybe_emit_chk_warning (tree, enum built_in_function)
static void maybe_emit_sprintf_chk_warning (tree, enum built_in_function)
static void maybe_emit_free_warning (tree)
static tree fold_builtin_object_size (tree, tree)
static tree fold_builtin_strcat_chk (location_t, tree, tree, tree, tree)
static tree fold_builtin_strncat_chk (location_t, tree, tree, tree, tree, tree)
static tree fold_builtin_sprintf_chk (location_t, tree, enum built_in_function)
static tree fold_builtin_printf (location_t, tree, tree, tree, bool, enum built_in_function)
static tree fold_builtin_fprintf (location_t, tree, tree, tree, tree, bool, enum built_in_function)
static bool init_target_chars (void)
static tree do_mpfr_arg1 (tree, tree, int(*)(mpfr_ptr, mpfr_srcptr, mp_rnd_t), const REAL_VALUE_TYPE *, const REAL_VALUE_TYPE *, bool)
static tree do_mpfr_arg2 (tree, tree, tree, int(*)(mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mp_rnd_t))
static tree do_mpfr_arg3 (tree, tree, tree, tree, int(*)(mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_srcptr, mp_rnd_t))
static tree do_mpfr_sincos (tree, tree, tree)
static tree do_mpfr_bessel_n (tree, tree, tree, int(*)(mpfr_ptr, long, mpfr_srcptr, mp_rnd_t), const REAL_VALUE_TYPE *, bool)
static tree do_mpfr_remquo (tree, tree, tree)
static tree do_mpfr_lgamma_r (tree, tree, tree)
static void expand_builtin_sync_synchronize (void)
static bool is_builtin_name ()
bool is_builtin_fn ()
bool default_libc_has_function ()
bool gnu_libc_has_function ()
bool no_c99_libc_has_function ()
static bool called_as_built_in ()
static bool get_object_alignment_2 (tree exp, unsigned int *alignp, unsigned HOST_WIDE_INT *bitposp, bool addr_p)
bool get_object_alignment_1 (tree exp, unsigned int *alignp, unsigned HOST_WIDE_INT *bitposp)
unsigned int get_object_alignment ()
bool get_pointer_alignment_1 (tree exp, unsigned int *alignp, unsigned HOST_WIDE_INT *bitposp)
unsigned int get_pointer_alignment ()
tree c_strlen ()
static const char * c_getstr ()
static rtx c_readstr ()
static int target_char_cast ()
static tree builtin_save_expr ()
static rtx expand_builtin_return_addr ()
void expand_builtin_setjmp_setup ()
void expand_builtin_setjmp_receiver ()
static void expand_builtin_longjmp ()
static rtx expand_builtin_nonlocal_goto ()
static void expand_builtin_update_setjmp_buf ()
static void expand_builtin_prefetch ()
static rtx get_memory_rtx ()
static rtx result_vector ()
static rtx expand_builtin_apply ()
static void expand_builtin_return ()
static enum type_class type_to_class ()
static rtx expand_builtin_classify_type ()
static tree mathfn_built_in_1 ()
tree mathfn_built_in ()
static void expand_errno_check ()
static rtx expand_builtin_mathfn ()
static rtx expand_builtin_mathfn_2 ()
static rtx expand_builtin_mathfn_ternary ()
static rtx expand_builtin_mathfn_3 ()
static enum insn_code interclass_mathfn_icode ()
static rtx expand_builtin_interclass_mathfn ()
static rtx expand_builtin_sincos ()
static rtx expand_builtin_cexpi ()
static tree build_call_nofold_loc ()
static rtx expand_builtin_int_roundingfn ()
static rtx expand_builtin_int_roundingfn_2 ()
static rtx expand_builtin_powi ()
static rtx expand_builtin_memcpy ()
static rtx expand_builtin_mempcpy ()
static rtx expand_movstr ()
static rtx expand_builtin_strcpy ()
static rtx expand_builtin_strcpy_args ()
static rtx expand_builtin_stpcpy ()
rtx builtin_strncpy_read_str (void *data, HOST_WIDE_INT offset, enum machine_mode mode)
static rtx expand_builtin_strncpy ()
rtx builtin_memset_read_str (void *data, HOST_WIDE_INT offset, enum machine_mode mode)
static rtx expand_builtin_memset ()
static rtx expand_builtin_bzero ()
static rtx expand_builtin_strcmp ()
rtx expand_builtin_saveregs ()
static tree stabilize_va_list_loc ()
tree std_build_builtin_va_list ()
tree std_fn_abi_va_list ()
tree std_canonical_va_list_type ()
void std_expand_builtin_va_start ()
static rtx expand_builtin_va_start ()
tree std_gimplify_va_arg_expr (tree valist, tree type, gimple_seq *pre_p, gimple_seq *post_p)
tree build_va_arg_indirect_ref ()
static tree dummy_object ()
enum gimplify_status gimplify_va_arg_expr ()
static rtx expand_builtin_va_end ()
static rtx expand_builtin_va_copy ()
static rtx expand_builtin_frame_address ()
static rtx expand_builtin_alloca ()
static rtx expand_builtin_bswap (enum machine_mode target_mode, tree exp, rtx target, rtx subtarget)
static rtx expand_builtin_expect ()
static rtx expand_builtin_assume_aligned ()
void expand_builtin_trap ()
static void expand_builtin_unreachable ()
static rtx expand_builtin_fabs ()
static rtx expand_builtin_copysign ()
tree build_string_literal ()
static rtx expand_builtin___clear_cache ()
static rtx round_trampoline_addr ()
static rtx expand_builtin_init_trampoline ()
static rtx expand_builtin_adjust_trampoline ()
static rtx expand_builtin_signbit ()
static rtx expand_builtin_fork_or_exec ()
static enum machine_mode get_builtin_sync_mode ()
static rtx get_builtin_sync_mem ()
static rtx expand_expr_force_mode ()
static rtx expand_builtin_sync_operation (enum machine_mode mode, tree exp, enum rtx_code code, bool after, rtx target)
static rtx expand_builtin_compare_and_swap (enum machine_mode mode, tree exp, bool is_bool, rtx target)
static rtx expand_builtin_sync_lock_test_and_set (enum machine_mode mode, tree exp, rtx target)
static void expand_builtin_sync_lock_release ()
static enum memmodel get_memmodel ()
static rtx expand_builtin_atomic_exchange ()
static rtx expand_builtin_atomic_compare_exchange (enum machine_mode mode, tree exp, rtx target)
static rtx expand_builtin_atomic_load ()
static rtx expand_builtin_atomic_store ()
static rtx expand_builtin_atomic_fetch_op (enum machine_mode mode, tree exp, rtx target, enum rtx_code code, bool fetch_after, bool ignore, enum built_in_function ext_call)
static rtx expand_builtin_atomic_clear ()
static rtx expand_builtin_atomic_test_and_set ()
static tree fold_builtin_atomic_always_lock_free ()
static rtx expand_builtin_atomic_always_lock_free ()
static tree fold_builtin_atomic_is_lock_free ()
static rtx expand_builtin_atomic_is_lock_free ()
static void expand_builtin_atomic_thread_fence ()
static void expand_builtin_atomic_signal_fence ()
static rtx expand_builtin_thread_pointer ()
static void expand_builtin_set_thread_pointer ()
rtx expand_builtin (tree exp, rtx target, rtx subtarget, enum machine_mode mode, int ignore)
enum built_in_function builtin_mathfn_code ()
static tree fold_builtin_constant_p ()
static tree build_builtin_expect_predicate ()
static tree fold_builtin_expect ()
static tree fold_builtin_classify_type ()
static tree fold_builtin_strlen ()
static tree fold_builtin_inf ()
static tree fold_builtin_nan ()
static bool integer_valued_real_p ()
static tree fold_trunc_transparent_mathfn ()
static tree fold_fixed_mathfn ()
static tree fold_builtin_cabs ()
static tree build_complex_cproj ()
static tree fold_builtin_cproj ()
static tree fold_builtin_sqrt ()
static tree fold_builtin_cbrt ()
static tree fold_builtin_cosh ()
static tree fold_builtin_ccos (location_t loc, tree arg, tree type, tree fndecl, bool hyper)
static tree fold_builtin_tan ()
static tree fold_builtin_sincos (location_t loc, tree arg0, tree arg1, tree arg2)
static tree fold_builtin_cexp ()
static tree fold_builtin_trunc ()
static tree fold_builtin_floor ()
static tree fold_builtin_ceil ()
static tree fold_builtin_round ()
static tree fold_builtin_int_roundingfn ()
static tree fold_builtin_bitop ()
static tree fold_builtin_bswap ()
static tree fold_builtin_logarithm (location_t loc, tree fndecl, tree arg, int(*func)(mpfr_ptr, mpfr_srcptr, mp_rnd_t))
static tree fold_builtin_hypot (location_t loc, tree fndecl, tree arg0, tree arg1, tree type)
static tree fold_builtin_pow ()
static tree fold_builtin_exponent (location_t loc, tree fndecl, tree arg, int(*func)(mpfr_ptr, mpfr_srcptr, mp_rnd_t))
static bool var_decl_component_p ()
static tree fold_builtin_memset (location_t loc, tree dest, tree c, tree len, tree type, bool ignore)
static tree fold_builtin_bzero ()
tree fold_builtin_strcpy ()
static tree fold_builtin_stpcpy ()
tree fold_builtin_strncpy (location_t loc, tree fndecl, tree dest, tree src, tree len, tree slen)
static tree fold_builtin_memchr ()
static tree fold_builtin_memcmp ()
static tree fold_builtin_strcmp ()
static tree fold_builtin_strncmp ()
static tree fold_builtin_signbit ()
static tree fold_builtin_isascii ()
static tree fold_builtin_toascii ()
static tree fold_builtin_isdigit ()
static tree fold_builtin_fabs ()
static tree fold_builtin_abs ()
tree fold_fma (location_t loc, tree type, tree arg0, tree arg1, tree arg2)
static tree fold_builtin_fma ()
static tree fold_builtin_fmin_fmax (location_t loc, tree arg0, tree arg1, tree type, bool max)
static tree fold_builtin_carg ()
static tree fold_builtin_logb ()
static tree fold_builtin_significand ()
static tree fold_builtin_frexp ()
static tree fold_builtin_load_exponent (location_t loc, tree arg0, tree arg1, tree type, bool ldexp)
static tree fold_builtin_modf ()
static tree fold_builtin_interclass_mathfn ()
static tree fold_builtin_classify ()
static tree fold_builtin_fpclassify ()
static tree fold_builtin_0 ()
static tree fold_builtin_1 ()
static tree fold_builtin_2 ()
static tree fold_builtin_n ()
bool avoid_folding_inline_builtin ()
tree fold_call_expr ()
tree build_call_expr_loc_array ()
tree build_call_expr_loc_vec ()
tree build_call_expr_loc ()
tree build_call_expr ()
tree fold_builtin_call_array (location_t loc, tree type, tree fn, int n, tree *argarray)
static tree rewrite_call_expr_valist (location_t loc, int oldnargs, tree *args, int skip, tree fndecl, int n, va_list newargs)
static tree rewrite_call_expr_array (location_t loc, int oldnargs, tree *args, int skip, tree fndecl, int n,...)
static tree rewrite_call_expr ()
static bool validate_arg ()
bool validate_gimple_arglist ()
bool validate_arglist ()
rtx default_expand_builtin (tree exp, rtx target, rtx subtarget, enum machine_mode mode, int ignore)
static bool readonly_data_expr ()
static tree fold_builtin_strstr ()
static tree fold_builtin_strchr ()
static tree fold_builtin_strrchr ()
static tree fold_builtin_strpbrk ()
static tree fold_builtin_strcat ()
static tree fold_builtin_strncat ()
static tree fold_builtin_strspn ()
static tree fold_builtin_strcspn ()
tree fold_builtin_fputs (location_t loc, tree arg0, tree arg1, bool ignore, bool unlocked, tree len)
bool fold_builtin_next_arg ()
rtx expand_builtin_object_size ()
static void maybe_emit_chk_warning ()
static void maybe_emit_sprintf_chk_warning ()
static void maybe_emit_free_warning ()
tree fold_builtin_object_size ()
tree fold_builtin_memory_chk (location_t loc, tree fndecl, tree dest, tree src, tree len, tree size, tree maxlen, bool ignore, enum built_in_function fcode)
tree fold_builtin_stxcpy_chk (location_t loc, tree fndecl, tree dest, tree src, tree size, tree maxlen, bool ignore, enum built_in_function fcode)
tree fold_builtin_stxncpy_chk (location_t loc, tree dest, tree src, tree len, tree size, tree maxlen, bool ignore, enum built_in_function fcode)
static tree fold_builtin_sprintf_chk_1 (location_t loc, int nargs, tree *args, enum built_in_function fcode)
static tree fold_builtin_snprintf_chk_1 (location_t loc, int nargs, tree *args, tree maxlen, enum built_in_function fcode)
tree fold_builtin_snprintf_chk (location_t loc, tree exp, tree maxlen, enum built_in_function fcode)
static tree do_mpfr_ckconv ()
static tree do_mpc_ckconv ()
static tree do_mpfr_sincos ()
static tree do_mpfr_remquo ()
static tree do_mpfr_lgamma_r ()
tree do_mpc_arg2 (tree arg0, tree arg1, tree type, int do_nonfinite, int(*func)(mpc_ptr, mpc_srcptr, mpc_srcptr, mpc_rnd_t))
static tree gimple_fold_builtin_sprintf_chk ()
tree gimple_fold_builtin_snprintf_chk (gimple stmt, tree maxlen, enum built_in_function fcode)
static tree gimple_fold_builtin_varargs (tree fndecl, gimple stmt, bool ignore)
tree fold_call_stmt ()
void set_builtin_user_assembler_name ()
bool is_simple_builtin ()
bool is_inexpensive_builtin ()

Variables

struct target_builtins default_target_builtins
struct target_builtinsthis_target_builtins = &default_target_builtins
const char *const built_in_class_names [4] = {"NOT_BUILT_IN", "BUILT_IN_FRONTEND", "BUILT_IN_MD", "BUILT_IN_NORMAL"}
const char * built_in_names [(int) END_BUILTINS]
builtin_info_type builtin_info
bool force_folding_builtin_constant_p
static unsigned HOST_WIDE_INT target_newline
static unsigned HOST_WIDE_INT target_percent
static unsigned HOST_WIDE_INT target_c
static unsigned HOST_WIDE_INT target_s
static char target_percent_c [3]
static char target_percent_s [3]
static char target_percent_s_newline [4]
static alias_set_type setjmp_alias_set = -1

Function Documentation

static int apply_args_size ( )
static
Return the size required for the block returned by __builtin_apply_args,
   and initialize apply_args_mode.   

References cfun, function::decl, and targetm.

Referenced by expand_builtin_apply(), and expand_builtin_apply_args_1().

static int apply_result_size ( )
static
Return the size required for the block returned by __builtin_apply,
   and initialize apply_result_mode.   

References targetm.

Referenced by expand_builtin_apply(), and expand_builtin_return().

bool avoid_folding_inline_builtin ( )
Return true if FNDECL shouldn't be folded right now.
   If a built-in function has an inline attribute always_inline
   wrapper, defer folding it after always_inline functions have
   been inlined, otherwise e.g. -D_FORTIFY_SOURCE checking
   might not be performed.   

References function::always_inline_functions_inlined, cfun, and lookup_attribute().

Referenced by fold_builtin_call_array(), fold_call_expr(), fold_call_stmt(), and gimple_fold_builtin().

static tree build_builtin_expect_predicate ( )
static
Create builtin_expect with PRED and EXPECTED as its arguments and
   return it as a truthvalue.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_explicit(), and fold_convert_loc().

Referenced by fold_builtin_expect().

tree build_call_expr_loc ( )
Conveniently construct a function call expression.  FNDECL names the
   function to be called, N is the number of arguments, and the "..."
   parameters are the argument expressions.   

References build_call_expr_loc_array().

Referenced by build_builtin_expect_predicate(), build_tm_abort_call(), expand_omp_atomic_fetch_op(), expand_omp_atomic_load(), expand_omp_atomic_store(), expand_parallel_call(), fold_binary_loc(), fold_builtin_2(), fold_builtin_cabs(), fold_builtin_carg(), fold_builtin_cbrt(), fold_builtin_ccos(), fold_builtin_cexp(), fold_builtin_classify(), fold_builtin_copysign(), fold_builtin_cos(), fold_builtin_cosh(), fold_builtin_floor(), fold_builtin_fprintf(), fold_builtin_fputs(), fold_builtin_hypot(), fold_builtin_logarithm(), fold_builtin_memory_chk(), fold_builtin_memory_op(), fold_builtin_pow(), fold_builtin_printf(), fold_builtin_sincos(), fold_builtin_snprintf(), fold_builtin_sprintf(), fold_builtin_sqrt(), fold_builtin_stpcpy(), fold_builtin_strcat(), fold_builtin_strcat_chk(), fold_builtin_strcpy(), fold_builtin_strcspn(), fold_builtin_strncat(), fold_builtin_strncat_chk(), fold_builtin_strncpy(), fold_builtin_strpbrk(), fold_builtin_strrchr(), fold_builtin_strstr(), fold_builtin_stxcpy_chk(), fold_builtin_stxncpy_chk(), fold_fixed_mathfn(), fold_negate_expr(), fold_strip_sign_ops(), fold_trunc_transparent_mathfn(), fold_unary_loc(), gimplify_va_arg_expr(), gimplify_variable_sized_compare(), lower_omp_critical(), lower_omp_master(), lower_omp_single_copy(), lower_rec_input_clauses(), and optimize_stdarg_builtin().

tree build_call_expr_loc_array ( )
Conveniently construct a function call expression.  FNDECL names the
   function to be called and N arguments are passed in the array
   ARGARRAY.   

References build_pointer_type(), and fold_builtin_call_array().

Referenced by build_call_expr(), build_call_expr_loc(), build_call_expr_loc_vec(), and rewrite_call_expr_valist().

tree build_call_expr_loc_vec ( )
Conveniently construct a function call expression.  FNDECL names the
   function to be called and the arguments are passed in the vector
   VEC.   

References build_call_expr_loc_array(), vec_safe_address(), and vec_safe_length().

Referenced by expand_parallel_call(), and self_referential_size().

static tree build_call_nofold_loc ( )
static
Conveniently construct a function call expression.  FNDECL names the
   function to be called, N is the number of arguments, and the "..."
   parameters are the argument expressions.  Unlike build_call_exr
   this doesn't fold the call, hence it will always return a CALL_EXPR.   

References build_call_valist(), and build_pointer_type().

Referenced by expand_builtin_int_roundingfn(), expand_builtin_int_roundingfn_2(), expand_builtin_memory_chk(), expand_builtin_mempcpy_args(), expand_builtin_memset_args(), expand_builtin_stpcpy(), expand_builtin_strcmp(), and expand_builtin_strncmp().

static tree build_complex_cproj ( )
static
Build a complex (inf +- 0i) for the result of cproj.  TYPE is the
   complex tree type of the result.  If NEG is true, the imaginary
   zero is negative.   

References build_complex(), build_real(), dconst0, and real_inf().

Referenced by fold_builtin_cproj().

tree build_string_literal ( )
Create a new constant string literal and return a char* pointer to it.
   The STRING_CST value is the LEN characters at STR.   

References build_array_type(), build_index_type(), build_pointer_type(), build_string(), and type().

Referenced by fold_builtin_printf(), gimplify_call_expr(), simplify_builtin_call(), and verify_bb_vtables().

tree build_va_arg_indirect_ref ( )
Build an indirect-ref expression over the given TREE, which represents a
   piece of a va_arg() expansion.   

References build_simple_mem_ref_loc(), and mf_mark().

Referenced by std_gimplify_va_arg_expr().

enum built_in_function builtin_mathfn_code ( )
Determine whether a tree node represents a call to a built-in
   function.  If the tree T is a call to a built-in function with
   the right number of arguments of the appropriate types, return
   the DECL_FUNCTION_CODE of the call, e.g. BUILT_IN_SQRT.
   Otherwise the return value is END_BUILTINS.   

References BUILT_IN_MD, END_BUILTINS, get_callee_fndecl(), init_const_call_expr_arg_iterator(), more_const_call_expr_args_p(), and next_const_call_expr_arg().

Referenced by convert_to_integer(), convert_to_real(), fold_binary_loc(), fold_builtin_cbrt(), fold_builtin_exponent(), fold_builtin_logarithm(), fold_builtin_pow(), fold_builtin_sqrt(), fold_builtin_tan(), fold_comparison(), fold_negate_expr(), fold_strip_sign_ops(), fold_trunc_transparent_mathfn(), integer_valued_real_p(), and negate_expr_p().

static rtx builtin_memcpy_read_str ( void *  data,
HOST_WIDE_INT  offset,
enum machine_mode  mode 
)
static
Callback routine for store_by_pieces.  Read GET_MODE_BITSIZE (MODE)
   bytes from constant string DATA + OFFSET and return it as target
   constant.   

References c_readstr(), HOST_WIDE_INT, and strlen().

Referenced by expand_builtin_memcpy(), and expand_builtin_mempcpy_args().

static rtx builtin_memset_gen_str ( void *  data,
HOST_WIDE_INT  offset,
enum machine_mode  mode 
)
static
Callback routine for store_by_pieces.  Return the RTL of a register
   containing GET_MODE_SIZE (MODE) consecutive copies of the unsigned
   char value given in the RTL register data.  For example, if mode is
   4 bytes wide, return the RTL for 0x01010101*data.   

References c_readstr(), convert_to_mode(), expand_mult(), force_reg(), and memset().

Referenced by expand_builtin_memset_args().

rtx builtin_memset_read_str ( void *  data,
HOST_WIDE_INT  offset,
enum machine_mode  mode 
)
Callback routine for store_by_pieces.  Read GET_MODE_BITSIZE (MODE)
   bytes from constant string DATA + OFFSET and return it as target
   constant.   

References c_readstr(), and memset().

Referenced by expand_builtin_memset_args(), and gimple_stringops_transform().

rtx builtin_strncpy_read_str ( void *  data,
HOST_WIDE_INT  offset,
enum machine_mode  mode 
)
Callback routine for store_by_pieces.  Read GET_MODE_BITSIZE (MODE)
   bytes from constant string DATA + OFFSET and return it as target
   constant.   

References c_readstr(), HOST_WIDE_INT, and strlen().

Referenced by expand_builtin_strncpy(), simplify_builtin_call(), and store_expr().

static const char* c_getstr ( )
static
Return a char pointer for a C string if it is a string constant
   or sum of string constant and integer constant.   

References compare_tree_int(), host_integerp(), string_constant(), and tree_low_cst().

static rtx c_readstr ( const char *  ,
enum  machine_mode 
)
static
static rtx c_readstr ( )
static
Return a CONST_INT or CONST_DOUBLE corresponding to target reading
   GET_MODE_BITSIZE (MODE) bits from string constant STR.   

References HOST_BITS_PER_WIDE_INT, HOST_WIDE_INT, and immed_double_const().

tree c_strlen ( )
Compute the length of a C string.  TREE_STRING_LENGTH is not the right
   way, because it could contain a zero byte in the middle.
   TREE_STRING_LENGTH is the size of the character array, not the string.

   ONLY_VALUE should be nonzero if the result is not going to be emitted
   into the instruction stream and zero if it is going to be expanded.
   E.g. with i++ ? "foo" : "bar", if ONLY_VALUE is nonzero, constant 3
   is returned, otherwise NULL, since
   len = c_strlen (src, 1); if (len) expand_expr (len, ...); would not
   evaluate the side-effects.

   The value returned is of type `ssizetype'.

   Unfortunately, string_constant can't access the values of const char
   arrays with initializers, so neither can we do so here.   

References host_integerp(), HOST_WIDE_INT, offset, size_diffop_loc(), string_constant(), strlen(), tree_int_cst_equal(), tree_low_cst(), and warning_at().

Referenced by expand_builtin_stpcpy(), expand_builtin_strcmp(), expand_builtin_strlen(), expand_builtin_strncmp(), expand_builtin_strncpy(), fold_builtin_fputs(), fold_builtin_snprintf(), fold_builtin_sprintf(), fold_builtin_sprintf_chk_1(), fold_builtin_stpcpy(), fold_builtin_strcat(), fold_builtin_strcpy(), fold_builtin_strlen(), fold_builtin_strncat_chk(), fold_builtin_strncpy(), fold_builtin_stxcpy_chk(), get_maxval_strlen(), maybe_emit_chk_warning(), and maybe_emit_sprintf_chk_warning().

static bool called_as_built_in ( )
static
Return true if NODE should be considered for inline expansion regardless
   of the optimization level.  This means whenever a function is invoked with
   its "internal" name, which normally contains the prefix "__builtin".   

References is_builtin_name().

Referenced by expand_builtin().

rtx default_expand_builtin ( tree  exp,
rtx  target,
rtx  subtarget,
enum machine_mode  mode,
int  ignore 
)
Default target-specific builtin expander that does nothing.   
bool default_libc_has_function ( )
By default we assume that c99 functions are present at the runtime,
   but sincos is not.   

References function_c94, function_c99_math_complex, and function_c99_misc.

static tree do_mpc_arg1 ( tree  arg,
tree  type,
int(*)(mpc_ptr, mpc_srcptr, mpc_rnd_t)  func 
)
static
If argument ARG is a COMPLEX_CST, call the one-argument mpc
   function FUNC on it and return the resulting value as a tree with
   type TYPE.  The mpfr precision is set to the precision of TYPE.  We
   assume that function FUNC returns zero if the result could be
   calculated exactly within the requested precision.   

References real_format::b, do_mpc_ckconv(), mpfr_from_real(), real_format::p, real_isfinite(), and real_format::round_towards_zero.

Referenced by fold_builtin_1(), fold_builtin_ccos(), and fold_builtin_cexp().

tree do_mpc_arg2 ( tree  arg0,
tree  arg1,
tree  type,
int  do_nonfinite,
int(*)(mpc_ptr, mpc_srcptr, mpc_srcptr, mpc_rnd_t)  func 
)
If arguments ARG0 and ARG1 are a COMPLEX_CST, call the two-argument
   mpc function FUNC on it and return the resulting value as a tree
   with type TYPE.  The mpfr precision is set to the precision of
   TYPE.  We assume that function FUNC returns zero if the result
   could be calculated exactly within the requested precision.  If
   DO_NONFINITE is true, then fold expressions containing Inf or NaN
   in the arguments and/or results.   

References real_format::b, do_mpc_ckconv(), mpfr_from_real(), real_format::p, real_isfinite(), and real_format::round_towards_zero.

Referenced by const_binop(), and fold_builtin_2().

static tree do_mpc_ckconv ( )
static
Helper function for do_mpc_arg*().  Ensure M is a normal complex
   number and no overflow/underflow occurred.  INEXACT is true if M
   was not exactly calculated.  TYPE is the tree type for the result.
   This function assumes that you cleared the MPFR flags and then
   calculated M to see if anything subsequently set a flag prior to
   entering this function.  Return NULL_TREE if any checks fail, if
   FORCE_CONVERT is true, then bypass the checks.   

References build_complex(), build_real(), real_convert(), real_from_mpfr(), real_identical(), real_isfinite(), and rvc_zero.

Referenced by do_mpc_arg1(), and do_mpc_arg2().

static tree do_mpfr_arg1 ( tree  arg,
tree  type,
int(*)(mpfr_ptr, mpfr_srcptr, mp_rnd_t)  func,
const REAL_VALUE_TYPE *  min,
const REAL_VALUE_TYPE *  max,
bool  inclusive 
)
static
If argument ARG is a REAL_CST, call the one-argument mpfr function
   FUNC on it and return the resulting value as a tree with type TYPE.
   If MIN and/or MAX are not NULL, then the supplied ARG must be
   within those bounds.  If INCLUSIVE is true, then MIN/MAX are
   acceptable values, otherwise they are not.  The mpfr precision is
   set to the precision of TYPE.  We assume that function FUNC returns
   zero if the result could be calculated exactly within the requested
   precision.   

References do_mpfr_ckconv(), mpfr_from_real(), real_format::p, real_compare(), real_isfinite(), and real_format::round_towards_zero.

Referenced by fold_builtin_1(), fold_builtin_cbrt(), fold_builtin_cos(), fold_builtin_cosh(), fold_builtin_exponent(), fold_builtin_logarithm(), fold_builtin_sqrt(), and fold_builtin_tan().

static tree do_mpfr_arg2 ( tree  arg1,
tree  arg2,
tree  type,
int(*)(mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mp_rnd_t)  func 
)
static
If argument ARG is a REAL_CST, call the two-argument mpfr function
   FUNC on it and return the resulting value as a tree with type TYPE.
   The mpfr precision is set to the precision of TYPE.  We assume that
   function FUNC returns zero if the result could be calculated
   exactly within the requested precision.   

References real_format::b, do_mpfr_ckconv(), mpfr_from_real(), real_format::p, real_isfinite(), and real_format::round_towards_zero.

Referenced by fold_builtin_2(), fold_builtin_cabs(), fold_builtin_fmin_fmax(), fold_builtin_hypot(), and fold_builtin_pow().

static tree do_mpfr_arg3 ( tree  arg1,
tree  arg2,
tree  arg3,
tree  type,
int(*)(mpfr_ptr, mpfr_srcptr, mpfr_srcptr, mpfr_srcptr, mp_rnd_t)  func 
)
static
If argument ARG is a REAL_CST, call the three-argument mpfr function
   FUNC on it and return the resulting value as a tree with type TYPE.
   The mpfr precision is set to the precision of TYPE.  We assume that
   function FUNC returns zero if the result could be calculated
   exactly within the requested precision.   

References real_format::b, do_mpfr_ckconv(), mpfr_from_real(), real_format::p, real_isfinite(), and real_format::round_towards_zero.

Referenced by fold_fma().

static tree do_mpfr_bessel_n ( tree  arg1,
tree  arg2,
tree  type,
int(*)(mpfr_ptr, long, mpfr_srcptr, mp_rnd_t)  func,
const REAL_VALUE_TYPE *  min,
bool  inclusive 
)
static
If argument ARG1 is an INTEGER_CST and ARG2 is a REAL_CST, call the
   two-argument mpfr order N Bessel function FUNC on them and return
   the resulting value as a tree with type TYPE.  The mpfr precision
   is set to the precision of TYPE.  We assume that function FUNC
   returns zero if the result could be calculated exactly within the
   requested precision.   

References real_format::b, do_mpfr_ckconv(), host_integerp(), HOST_WIDE_INT, mpfr_from_real(), real_format::p, real_compare(), real_isfinite(), real_format::round_towards_zero, and tree_low_cst().

Referenced by fold_builtin_2().

static tree do_mpfr_ckconv ( )
static
Helper function for do_mpfr_arg*().  Ensure M is a normal number
   and no overflow/underflow occurred.  INEXACT is true if M was not
   exactly calculated.  TYPE is the tree type for the result.  This
   function assumes that you cleared the MPFR flags and then
   calculated M to see if anything subsequently set a flag prior to
   entering this function.  Return NULL_TREE if any checks fail.   

References build_real(), real_convert(), real_from_mpfr(), real_identical(), real_isfinite(), and rvc_zero.

Referenced by do_mpfr_arg1(), do_mpfr_arg2(), do_mpfr_arg3(), do_mpfr_bessel_n(), do_mpfr_lgamma_r(), do_mpfr_remquo(), and do_mpfr_sincos().

static tree do_mpfr_lgamma_r ( tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree do_mpfr_lgamma_r ( )
static
If ARG is a REAL_CST, call mpfr_lgamma() on it and return the
   resulting value as a tree with type TYPE.  The mpfr precision is
   set to the precision of TYPE.  We assume that this mpfr function
   returns zero if the result could be calculated exactly within the
   requested precision.  In addition, the integer pointer represented
   by ARG_SG will be dereferenced and set to the appropriate signgam
   (-1,1) value.   

References real_format::b, build_int_cst(), do_mpfr_ckconv(), mpfr_from_real(), real_format::p, real_isfinite(), real_isinteger(), real_isneg(), real_format::round_towards_zero, and rvc_zero.

static tree do_mpfr_remquo ( tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_3().

static tree do_mpfr_remquo ( )
static
If arguments ARG0 and ARG1 are REAL_CSTs, call mpfr_remquo() to set
   the pointer *(ARG_QUO) and return the result.  The type is taken
   from the type of ARG0 and is used for setting the precision of the
   calculation and results.   

References real_format::b, build_int_cst(), do_mpfr_ckconv(), mpfr_from_real(), real_format::p, real_isfinite(), and real_format::round_towards_zero.

static tree do_mpfr_sincos ( tree  ,
tree  ,
tree   
)
static
static tree do_mpfr_sincos ( )
static
If argument ARG is a REAL_CST, call mpfr_sin_cos() on it and set
   the pointers *(ARG_SINP) and *(ARG_COSP) to the resulting values.
   If ARG_SINP and ARG_COSP are NULL then the result is returned
   as a complex value.
   The type is taken from the type of ARG and is used for setting the
   precision of the calculation and results.   

References real_format::b, build_complex(), build_complex_type(), do_mpfr_ckconv(), mpfr_from_real(), real_format::p, real_isfinite(), and real_format::round_towards_zero.

static tree dummy_object ( )
static
Return a dummy expression of type TYPE in order to keep going after an
   error.   

References build_int_cst(), and build_pointer_type().

Referenced by gimplify_va_arg_expr().

rtx expand_builtin ( tree  exp,
rtx  target,
rtx  subtarget,
enum machine_mode  mode,
int  ignore 
)
Expand an expression EXP that calls a built-in function,
   with result going to TARGET if that's convenient
   (and in mode MODE if that's convenient).
   SUBTARGET may be used as the target for computing one of EXP's operands.
   IGNORE is nonzero if the value is to be ignored.   

References build_call_vec(), BUILT_IN_MD, called_as_built_in(), current_function_decl, error(), expand_builtin___clear_cache(), expand_builtin_adjust_trampoline(), expand_builtin_alloca(), expand_builtin_apply(), expand_builtin_apply_args(), expand_builtin_assume_aligned(), expand_builtin_atomic_always_lock_free(), expand_builtin_atomic_clear(), expand_builtin_atomic_compare_exchange(), expand_builtin_atomic_exchange(), expand_builtin_atomic_fetch_op(), expand_builtin_atomic_is_lock_free(), expand_builtin_atomic_load(), expand_builtin_atomic_signal_fence(), expand_builtin_atomic_store(), expand_builtin_atomic_test_and_set(), expand_builtin_atomic_thread_fence(), expand_builtin_bswap(), expand_builtin_bzero(), expand_builtin_cexpi(), expand_builtin_classify_type(), expand_builtin_compare_and_swap(), expand_builtin_copysign(), expand_builtin_dwarf_sp_column(), expand_builtin_eh_copy_values(), expand_builtin_eh_filter(), expand_builtin_eh_pointer(), expand_builtin_eh_return(), expand_builtin_eh_return_data_regno(), expand_builtin_expect(), expand_builtin_extend_pointer(), expand_builtin_extract_return_addr(), expand_builtin_fabs(), expand_builtin_fork_or_exec(), expand_builtin_frame_address(), expand_builtin_frob_return_addr(), expand_builtin_init_dwarf_reg_sizes(), expand_builtin_init_trampoline(), expand_builtin_int_roundingfn(), expand_builtin_int_roundingfn_2(), expand_builtin_interclass_mathfn(), expand_builtin_longjmp(), expand_builtin_mathfn(), expand_builtin_mathfn_2(), expand_builtin_mathfn_3(), expand_builtin_mathfn_ternary(), expand_builtin_memcmp(), expand_builtin_memcpy(), expand_builtin_memory_chk(), expand_builtin_mempcpy(), expand_builtin_memset(), expand_builtin_next_arg(), expand_builtin_nonlocal_goto(), expand_builtin_object_size(), expand_builtin_powi(), expand_builtin_prefetch(), expand_builtin_return(), expand_builtin_saveregs(), expand_builtin_set_thread_pointer(), expand_builtin_setjmp_receiver(), expand_builtin_setjmp_setup(), expand_builtin_signbit(), expand_builtin_sincos(), expand_builtin_stpcpy(), expand_builtin_strcmp(), expand_builtin_strcpy(), expand_builtin_strlen(), expand_builtin_strncmp(), expand_builtin_strncpy(), expand_builtin_sync_lock_release(), expand_builtin_sync_lock_test_and_set(), expand_builtin_sync_operation(), expand_builtin_sync_synchronize(), expand_builtin_thread_pointer(), expand_builtin_trap(), expand_builtin_unop(), expand_builtin_unreachable(), expand_builtin_unwind_init(), expand_builtin_update_setjmp_buf(), expand_builtin_va_copy(), expand_builtin_va_end(), expand_builtin_va_start(), expand_call(), expand_expr(), EXPAND_NORMAL, expand_normal(), expand_stack_restore(), expand_stack_save(), flags_from_decl_or_type(), fold_builtin_next_arg(), gen_reg_rtx(), get_builtin_sync_mode(), get_callee_fndecl(), label_rtx(), maybe_emit_chk_warning(), maybe_emit_free_warning(), maybe_emit_sprintf_chk_warning(), register_operand(), remove_node_from_expr_list(), targetm, validate_arglist(), expand_operand::value, and vec_alloc().

Referenced by expand_expr_real_1(), and expand_expr_real_2().

static rtx expand_builtin___clear_cache ( )
static
Expand a call to __builtin___clear_cache.   

References create_address_operand(), error(), exp(), expand_expr(), EXPAND_NORMAL, maybe_expand_insn(), and validate_arglist().

Referenced by expand_builtin().

static rtx expand_builtin_adjust_trampoline ( )
static
static rtx expand_builtin_alloca ( tree  ,
bool   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_alloca ( )
static
Expand EXP, a call to the alloca builtin.  Return NULL_RTX if we
   failed and the caller should emit a normal call.  CANNOT_ACCUMULATE
   is the same as for allocate_dynamic_stack_space.   

References allocate_dynamic_stack_space(), expand_normal(), get_callee_fndecl(), ptr_mode, and validate_arglist().

static rtx expand_builtin_apply ( rtx  ,
rtx  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_apply_args ( )
static
__builtin_apply_args returns block of memory allocated on
   the stack into which is stored the arg pointer, structure
   value address, static chain, and all the registers that might
   possibly be used in performing a function call.  The code is
   moved to the start of the function so the incoming values are
   saved.   

References emit_insn_before(), end_sequence(), entry_of_function(), expand_builtin_apply_args_1(), get_insns(), pop_topmost_sequence(), push_topmost_sequence(), and start_sequence().

Referenced by expand_builtin().

static rtx expand_builtin_apply_args_1 ( )
static
Save the state required to perform an untyped call with the same
   arguments as were passed to the current function.   

References apply_args_size(), assign_stack_local(), cfun, copy_addr_to_reg(), copy_to_reg(), function::decl, emit_move_insn(), force_operand(), gen_rtx_REG(), plus_constant(), and targetm.

Referenced by expand_builtin_apply_args().

static rtx expand_builtin_assume_aligned ( )
static
Expand a call to __builtin_assume_aligned.  We just return our first
   argument as the builtin_assume_aligned semantic should've been already
   executed by CCP.   

References expand_expr(), and EXPAND_NORMAL.

Referenced by expand_builtin().

static rtx expand_builtin_atomic_always_lock_free ( )
static
Return true if the parameters to call EXP represent an object which will
   always generate lock free instructions.  The first argument represents the
   size of the object, and the second parameter is a pointer to the object 
   itself.  If NULL is passed for the object, then the result is based on 
   typical alignment for an object of the specified size.  Otherwise return 
   false.   

References error(), and fold_builtin_atomic_always_lock_free().

Referenced by expand_builtin().

static rtx expand_builtin_atomic_clear ( )
static
Expand an atomic clear operation.
        void _atomic_clear (BOOL *obj, enum memmodel)
   EXP is the call expression.   

References emit_insn(), emit_move_insn(), error(), expand_atomic_store(), get_builtin_sync_mem(), get_memmodel(), MEMMODEL_ACQ_REL, MEMMODEL_ACQUIRE, and mode_for_size().

Referenced by expand_builtin().

static rtx expand_builtin_atomic_compare_exchange ( enum machine_mode  mode,
tree  exp,
rtx  target 
)
static
Expand the __atomic_compare_exchange intrinsic:
        bool __atomic_compare_exchange (TYPE *object, TYPE *expect, 
                                        TYPE desired, BOOL weak, 
                                        enum memmodel success,
                                        enum memmodel failure)
   EXP is the CALL_EXPR.
   TARGET is an optional place for us to store the results.   

References emit_move_insn(), error(), expand_atomic_compare_and_swap(), expand_expr_force_mode(), expand_normal(), failure, gen_rtx_MEM(), get_builtin_sync_mem(), get_memmodel(), host_integerp(), MEMMODEL_ACQ_REL, MEMMODEL_RELEASE, and tree_low_cst().

Referenced by expand_builtin().

static rtx expand_builtin_atomic_exchange ( )
static
Expand the __atomic_exchange intrinsic:
        TYPE __atomic_exchange (TYPE *object, TYPE desired, enum memmodel)
   EXP is the CALL_EXPR.
   TARGET is an optional place for us to store the results.   

References error(), expand_atomic_exchange(), expand_expr_force_mode(), get_builtin_sync_mem(), get_memmodel(), and MEMMODEL_CONSUME.

Referenced by expand_builtin().

static rtx expand_builtin_atomic_fetch_op ( enum machine_mode  mode,
tree  exp,
rtx  target,
enum rtx_code  code,
bool  fetch_after,
bool  ignore,
enum built_in_function  ext_call 
)
static
Expand the __atomic_fetch_XXX intrinsic:
        TYPE __atomic_fetch_XXX (TYPE *object, TYPE val, enum memmodel)
   EXP is the CALL_EXPR.
   TARGET is an optional place for us to store the results.
   CODE is the operation, PLUS, MINUS, ADD, XOR, or IOR.
   FETCH_AFTER is true if returning the result of the operation.
   FETCH_AFTER is false if returning the value before the operation.
   IGNORE is true if the result is not used.
   EXT_CALL is the correct builtin for an external call if this cannot be
   resolved to an instruction sequence.   

References builtin_decl_explicit(), expand_atomic_fetch_op(), expand_call(), expand_expr_force_mode(), expand_simple_binop(), expand_simple_unop(), get_builtin_sync_mem(), get_callee_fndecl(), get_memmodel(), and OPTAB_LIB_WIDEN.

Referenced by expand_builtin().

static rtx expand_builtin_atomic_is_lock_free ( )
static
Return true if the parameters to call EXP represent an object which will
   always generate lock free instructions.  The first argument represents the
   size of the object, and the second parameter is a pointer to the object 
   itself.  If NULL is passed for the object, then the result is based on 
   typical alignment for an object of the specified size.  Otherwise return 
   NULL 

References error(), and fold_builtin_atomic_is_lock_free().

Referenced by expand_builtin().

static rtx expand_builtin_atomic_load ( )
static
Expand the __atomic_load intrinsic:
        TYPE __atomic_load (TYPE *object, enum memmodel)
   EXP is the CALL_EXPR.
   TARGET is an optional place for us to store the results.   

References error(), expand_atomic_load(), get_builtin_sync_mem(), get_memmodel(), MEMMODEL_ACQ_REL, and MEMMODEL_RELEASE.

Referenced by expand_builtin().

static void expand_builtin_atomic_signal_fence ( )
static
Expand the __atomic_signal_fence intrinsic:
        void __atomic_signal_fence (enum memmodel)
   EXP is the CALL_EXPR.   

References expand_mem_signal_fence(), and get_memmodel().

Referenced by expand_builtin().

static rtx expand_builtin_atomic_store ( )
static
Expand the __atomic_store intrinsic:
        void __atomic_store (TYPE *object, TYPE desired, enum memmodel)
   EXP is the CALL_EXPR.
   TARGET is an optional place for us to store the results.   

References error(), expand_atomic_store(), expand_expr_force_mode(), get_builtin_sync_mem(), get_memmodel(), MEMMODEL_RELAXED, MEMMODEL_RELEASE, and MEMMODEL_SEQ_CST.

Referenced by expand_builtin().

static rtx expand_builtin_atomic_test_and_set ( )
static
Expand an atomic test_and_set operation.
        bool _atomic_test_and_set (BOOL *obj, enum memmodel)
   EXP is the call expression.   

References expand_atomic_test_and_set(), get_builtin_sync_mem(), get_memmodel(), and mode_for_size().

Referenced by expand_builtin().

static void expand_builtin_atomic_thread_fence ( )
static
Expand the __atomic_thread_fence intrinsic:
        void __atomic_thread_fence (enum memmodel)
   EXP is the CALL_EXPR.   

References expand_mem_thread_fence(), and get_memmodel().

Referenced by expand_builtin().

static rtx expand_builtin_bswap ( enum machine_mode  target_mode,
tree  exp,
rtx  target,
rtx  subtarget 
)
static
Expand a call to bswap builtin in EXP.
   Return NULL_RTX if a normal call should be emitted rather than expanding the
   function in-line.  If convenient, the result should be placed in TARGET.
   SUBTARGET may be used as the target for computing one of EXP's operands.   

References convert_to_mode(), expand_expr(), EXPAND_NORMAL, expand_unop(), and validate_arglist().

Referenced by expand_builtin().

static rtx expand_builtin_bzero ( tree  )
static

Referenced by expand_builtin().

static rtx expand_builtin_bzero ( )
static
Expand expression EXP, which is a call to the bzero builtin.  Return
   NULL_RTX if we failed the caller should emit a normal call.   

References expand_builtin_memset_args(), fold_convert_loc(), and validate_arglist().

static rtx expand_builtin_cexpi ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_cexpi ( )
static
Expand a call to the internal cexpi builtin to the sincos math function.
   EXP is the expression that is a call to the builtin function; if convenient,
   the result should be placed in TARGET.   

References assign_temp(), build_call_nary(), build_complex_type(), build_fn_decl(), build_function_type_list(), build_pointer_type(), build_real(), builtin_decl_explicit(), copy_addr_to_reg(), dconst0, expand_expr(), EXPAND_NORMAL, expand_normal(), expand_twoval_unop(), function_sincos, gen_reg_rtx(), get_callee_fndecl(), make_tree(), optab_handler(), targetm, type(), and validate_arglist().

static rtx expand_builtin_classify_type ( tree  )
static

Referenced by expand_builtin().

static rtx expand_builtin_classify_type ( )
static
Expand a call EXP to __builtin_classify_type.   

References no_type_class, and type_to_class().

static rtx expand_builtin_compare_and_swap ( enum machine_mode  mode,
tree  exp,
bool  is_bool,
rtx  target 
)
static
Expand the __sync_val_compare_and_swap and __sync_bool_compare_and_swap
   intrinsics. EXP is the CALL_EXPR.  IS_BOOL is
   true if this is the boolean form.  TARGET is a place for us to store the
   results; this is NOT optional if IS_BOOL is true.   

References expand_atomic_compare_and_swap(), expand_expr_force_mode(), get_builtin_sync_mem(), and MEMMODEL_SEQ_CST.

Referenced by expand_builtin().

static rtx expand_builtin_copysign ( )
static
Expand EXP, a call to copysign, copysignf, or copysignl.
   Return NULL is a normal call should be emitted rather than expanding the
   function inline.  If convenient, the result should be placed in TARGET.
   SUBTARGET may be used as the target for computing the operand.   

References expand_copysign(), expand_expr(), EXPAND_NORMAL, expand_normal(), and validate_arglist().

Referenced by expand_builtin().

static rtx expand_builtin_expect ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_expect ( )
static
Expand a call to __builtin_expect.  We just return our argument
   as the builtin_expect semantic should've been already executed by
   tree branch prediction pass.  

References expand_expr(), EXPAND_NORMAL, and seen_error().

static rtx expand_builtin_fabs ( tree  ,
rtx  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_fabs ( )
static
Expand EXP, a call to fabs, fabsf or fabsl.
   Return NULL_RTX if a normal call should be emitted rather than expanding
   the function inline.  If convenient, the result should be placed
   in TARGET.  SUBTARGET may be used as the target for computing
   the operand.   

References builtin_save_expr(), expand_abs(), expand_expr(), EXPAND_NORMAL, safe_from_p(), and validate_arglist().

static rtx expand_builtin_fork_or_exec ( )
static
Expand fork or exec calls.  TARGET is the desired target of the
   call.  EXP is the call. FN is the
   identificator of the actual function.  IGNORE is nonzero if the
   value is to be ignored.   

References expand_call(), get_identifier(), rewrite_call_expr(), and VISIBILITY_DEFAULT.

Referenced by expand_builtin().

static rtx expand_builtin_frame_address ( tree  ,
tree   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_frame_address ( )
static
Expand a call to one of the builtin functions __builtin_frame_address or
   __builtin_return_address.   

References copy_addr_to_reg(), error(), expand_builtin_return_addr(), host_integerp(), tree_low_cst(), and warning().

static rtx expand_builtin_int_roundingfn ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_int_roundingfn ( )
static
Expand a call to one of the builtin rounding functions gcc defines
   as an extension (lfloor and lceil).  As these are gcc extensions we
   do not need to worry about setting errno to EDOM.
   If expanding via optab fails, lower expression to (int)(floor(x)).
   EXP is the expression that is a call to the builtin function;
   if convenient, the result should be placed in TARGET.   

References build_call_nofold_loc(), build_fn_decl(), build_function_type_list(), builtin_save_expr(), emit_insn(), end_sequence(), expand_expr(), expand_fix(), EXPAND_NORMAL, expand_normal(), expand_sfix_optab(), gen_reg_rtx(), get_callee_fndecl(), get_insns(), mathfn_built_in(), maybe_emit_group_store(), start_sequence(), and validate_arglist().

static rtx expand_builtin_int_roundingfn_2 ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_int_roundingfn_2 ( )
static
Expand a call to one of the builtin math functions doing integer
   conversion (lrint).
   Return 0 if a normal call should be emitted rather than expanding the
   function in-line.  EXP is the expression that is a call to the builtin
   function; if convenient, the result should be placed in TARGET.   

References build_call_nofold_loc(), builtin_save_expr(), convert_to_mode(), emit_insn(), end_sequence(), expand_call(), expand_expr(), EXPAND_NORMAL, expand_sfix_optab(), gen_reg_rtx(), get_callee_fndecl(), get_insns(), mathfn_built_in_1(), maybe_emit_group_store(), start_sequence(), and validate_arglist().

static rtx expand_builtin_interclass_mathfn ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_interclass_mathfn ( )
static
Expand a call to one of the builtin math functions that operate on
   floating point argument and output an integer result (ilogb, isinf,
   isnan, etc).
   Return 0 if a normal call should be emitted rather than expanding the
   function in-line.  EXP is the expression that is a call to the builtin
   function; if convenient, the result should be placed in TARGET.   

References builtin_save_expr(), convert_to_mode(), create_output_operand(), delete_insns_since(), expand_expr(), EXPAND_NORMAL, get_callee_fndecl(), get_last_insn(), interclass_mathfn_icode(), last, maybe_emit_unop_insn(), maybe_legitimize_operands(), validate_arglist(), and expand_operand::value.

static void expand_builtin_longjmp ( )
static
__builtin_longjmp is passed a pointer to an array of five words (not
   all will be used on all machines).  It operates similarly to the C
   library function of the same name, but is more efficient.  Much of
   the code below is copied from the handling of non-local gotos.   

References add_reg_note(), copy_to_reg(), emit_clobber(), emit_indirect_jump(), emit_insn(), emit_move_insn(), emit_stack_restore(), emit_use(), force_reg(), gen_rtx_MEM(), get_last_insn(), last, new_alias_set(), plus_constant(), SAVE_NONLOCAL, set_mem_alias_set(), and stack.

Referenced by expand_builtin().

static rtx expand_builtin_mathfn ( tree  ,
rtx  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_mathfn ( )
static
Expand a call to one of the builtin math functions (sqrt, exp, or log).
   Return NULL_RTX if a normal call should be emitted rather than expanding
   the function in-line.  EXP is the expression that is a call to the builtin
   function; if convenient, the result should be placed in TARGET.
   SUBTARGET may be used as the target for computing one of EXP's operands.   

References builtin_save_expr(), emit_insn(), end_sequence(), excess_precision_type(), expand_call(), expand_errno_check(), expand_expr(), EXPAND_NORMAL, expand_unop(), gen_reg_rtx(), get_callee_fndecl(), get_insns(), optab_handler(), optimize_insn_for_size_p(), start_sequence(), tree_expr_nonnegative_p(), and validate_arglist().

static rtx expand_builtin_mathfn_2 ( tree  ,
rtx  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_mathfn_2 ( )
static
Expand a call to the builtin binary math functions (pow and atan2).
   Return NULL_RTX if a normal call should be emitted rather than expanding the
   function in-line.  EXP is the expression that is a call to the builtin
   function; if convenient, the result should be placed in TARGET.
   SUBTARGET may be used as the target for computing one of EXP's
   operands.   

References builtin_save_expr(), emit_insn(), end_sequence(), expand_binop(), expand_call(), expand_errno_check(), expand_expr(), EXPAND_NORMAL, expand_normal(), gen_reg_rtx(), get_callee_fndecl(), get_insns(), OPTAB_DIRECT, optab_handler(), optimize_insn_for_size_p(), start_sequence(), and validate_arglist().

static rtx expand_builtin_mathfn_3 ( tree  ,
rtx  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_mathfn_3 ( )
static
Expand a call to the builtin sin and cos math functions.
   Return NULL_RTX if a normal call should be emitted rather than expanding the
   function in-line.  EXP is the expression that is a call to the builtin
   function; if convenient, the result should be placed in TARGET.
   SUBTARGET may be used as the target for computing one of EXP's
   operands.   

References builtin_save_expr(), emit_insn(), end_sequence(), expand_call(), expand_expr(), EXPAND_NORMAL, expand_twoval_unop(), expand_unop(), gen_reg_rtx(), get_callee_fndecl(), get_insns(), optab_handler(), start_sequence(), and validate_arglist().

static rtx expand_builtin_mathfn_ternary ( tree  ,
rtx  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_mathfn_ternary ( )
static
Expand a call to the builtin trinary math functions (fma).
   Return NULL_RTX if a normal call should be emitted rather than expanding the
   function in-line.  EXP is the expression that is a call to the builtin
   function; if convenient, the result should be placed in TARGET.
   SUBTARGET may be used as the target for computing one of EXP's
   operands.   

References builtin_save_expr(), emit_insn(), end_sequence(), expand_call(), expand_expr(), EXPAND_NORMAL, expand_normal(), expand_ternary_op(), gen_reg_rtx(), get_callee_fndecl(), get_insns(), optab_handler(), start_sequence(), and validate_arglist().

static rtx expand_builtin_memcmp ( tree  exp,
rtx  target,
enum machine_mode  mode 
)
static
Expand expression EXP, which is a call to the memcmp built-in function.
   Return NULL_RTX if we failed and the caller should emit a normal call,
   otherwise try to get the result in TARGET, if convenient (and in mode
   MODE, if that's convenient).   

References convert_move(), convert_to_mode(), emit_insn(), emit_library_call_value(), expand_normal(), fold_convert_loc(), gen_reg_rtx(), get_memory_rtx(), get_pointer_alignment(), insn_data, LCT_PURE, len, set_mem_size(), and validate_arglist().

Referenced by expand_builtin().

static rtx expand_builtin_memcpy ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_memcpy ( )
static
Expand a call EXP to the memcpy builtin.
   Return NULL_RTX if we failed, the caller should emit a normal call,
   otherwise try to get the result in TARGET, if convenient (and in
   mode MODE if that's convenient).   

References BLOCK_OP_NORMAL, BLOCK_OP_TAILCALL, builtin_memcpy_read_str(), c_getstr(), can_store_by_pieces(), currently_expanding_gimple_stmt, emit_block_move_hints(), expand_normal(), force_operand(), get_memory_rtx(), get_pointer_alignment(), HOST_WIDE_INT, len, ptr_mode, set_mem_align(), store_by_pieces(), stringop_block_profile(), strlen(), and validate_arglist().

static rtx expand_builtin_memory_chk ( tree  exp,
rtx  target,
enum machine_mode  mode,
enum built_in_function  fcode 
)
static
Expand EXP, a call to the __mem{cpy,pcpy,move,set}_chk builtin.
   FCODE is the BUILT_IN_* to use.
   Return NULL_RTX if we failed; the caller should emit a normal call,
   otherwise try to get the result in TARGET, if convenient (and in
   mode MODE if that's convenient).   

References build_call_nofold_loc(), builtin_decl_explicit(), expand_expr(), EXPAND_NORMAL, get_callee_fndecl(), get_pointer_alignment(), host_integerp(), integer_all_onesp(), len, operand_equal_p(), readonly_data_expr(), tree_int_cst_lt(), tree_nonartificial_location(), validate_arglist(), and warning_at().

Referenced by expand_builtin().

static rtx expand_builtin_mempcpy ( tree  ,
rtx  ,
enum  machine_mode 
)
static

Referenced by expand_builtin().

static rtx expand_builtin_mempcpy ( )
static
Expand a call EXP to the mempcpy builtin.
   Return NULL_RTX if we failed; the caller should emit a normal call,
   otherwise try to get the result in TARGET, if convenient (and in
   mode MODE if that's convenient).  If ENDP is 0 return the
   destination pointer, if ENDP is 1 return the end pointer ala
   mempcpy, and if ENDP is 2 return the end pointer minus one ala
   stpcpy.   

References expand_builtin_mempcpy_args(), len, and validate_arglist().

static rtx expand_builtin_mempcpy_args ( tree  dest,
tree  src,
tree  len,
rtx  target,
enum machine_mode  mode,
int  endp 
)
static
Helper function to do the actual work for expand_builtin_mempcpy.  The
   arguments to the builtin_mempcpy call DEST, SRC, and LEN are broken out
   so that this can also be called without constructing an actual CALL_EXPR.
   The other arguments and return value are the same as for
   expand_builtin_mempcpy.   

References build_call_nofold_loc(), builtin_decl_implicit(), builtin_decl_implicit_p(), builtin_memcpy_read_str(), c_getstr(), can_move_by_pieces(), can_store_by_pieces(), expand_expr(), EXPAND_NORMAL, expand_normal(), force_operand(), get_memory_rtx(), get_pointer_alignment(), host_integerp(), HOST_WIDE_INT, move_by_pieces(), ptr_mode, set_mem_align(), store_by_pieces(), and strlen().

Referenced by expand_builtin_mempcpy(), and expand_builtin_stpcpy().

static rtx expand_builtin_memset ( tree  ,
rtx  ,
enum  machine_mode 
)
static

Referenced by expand_builtin().

static rtx expand_builtin_memset ( )
static
Expand expression EXP, which is a call to the memset builtin.  Return
   NULL_RTX if we failed the caller should emit a normal call, otherwise
   try to get the result in TARGET, if convenient (and in mode MODE if that's
   convenient).   

References expand_builtin_memset_args(), len, and validate_arglist().

static rtx expand_builtin_memset_args ( tree  dest,
tree  val,
tree  len,
rtx  target,
enum machine_mode  mode,
tree  orig_exp 
)
static
Helper function to do the actual work for expand_builtin_memset.  The
   arguments to the builtin_memset call DEST, VAL, and LEN are broken out
   so that this can also be called without constructing an actual CALL_EXPR.
   The other arguments and return value are the same as for
   expand_builtin_memset.   

References BLOCK_OP_NORMAL, BLOCK_OP_TAILCALL, build_call_nofold_loc(), builtin_memset_gen_str(), builtin_memset_read_str(), builtin_save_expr(), can_store_by_pieces(), clear_storage_hints(), convert_to_mode(), currently_expanding_gimple_stmt, expand_call(), expand_expr(), EXPAND_NORMAL, expand_normal(), force_operand(), force_reg(), gen_int_mode(), get_callee_fndecl(), get_memory_rtx(), get_pointer_alignment(), host_integerp(), HOST_WIDE_INT, integer_zerop(), ptr_mode, set_mem_align(), set_storage_via_setmem(), store_by_pieces(), stringop_block_profile(), target_char_cast(), and tree_low_cst().

Referenced by expand_builtin_bzero(), and expand_builtin_memset().

static rtx expand_builtin_next_arg ( )
static
Expand a call to __builtin_next_arg.   

References expand_binop(), OPTAB_LIB_WIDEN, and ptr_mode.

Referenced by expand_builtin(), and expand_builtin_va_start().

static rtx expand_builtin_nonlocal_goto ( )
static
Expand a call to __builtin_nonlocal_goto.  We're passed the target label
   and the address of the save area.   

References add_reg_note(), copy_to_reg(), emit_clobber(), emit_indirect_jump(), emit_insn(), emit_move_insn(), emit_stack_restore(), emit_use(), expand_normal(), gen_rtx_MEM(), get_last_insn(), plus_constant(), SAVE_NONLOCAL, and validate_arglist().

Referenced by expand_builtin().

static rtx expand_builtin_object_size ( tree  )
static

Referenced by expand_builtin().

rtx expand_builtin_object_size ( )
static rtx expand_builtin_powi ( )
static
Expand a call to the powi built-in mathematical function.  Return NULL_RTX if
   a normal call should be emitted rather than expanding the function
   in-line.  EXP is the expression that is a call to the builtin
   function; if convenient, the result should be placed in TARGET.   

References convert_to_mode(), emit_library_call_value(), expand_expr(), EXPAND_NORMAL, gen_reg_rtx(), LCT_CONST, mode_for_size(), optab_libfunc(), and validate_arglist().

Referenced by expand_builtin().

static void expand_builtin_prefetch ( tree  )
static

Referenced by expand_builtin().

static void expand_builtin_prefetch ( )
static
Expand a call to __builtin_prefetch.  For a target that does not support
   data prefetch, evaluate the memory address argument in case it has side
   effects.   

References create_address_operand(), create_integer_operand(), emit_insn(), error(), expand_expr(), EXPAND_NORMAL, expand_normal(), maybe_expand_insn(), side_effects_p(), validate_arglist(), and warning().

static void expand_builtin_return ( rtx  )
static

Referenced by expand_builtin().

static rtx expand_builtin_return_addr ( )
static
Given TEM, a pointer to a stack frame, follow the dynamic chain COUNT
   times to get the address of either a higher stack frame, or a return
   address located within it (depending on FNDECL_CODE).   

References copy_to_reg(), count, gen_frame_mem(), and plus_constant().

Referenced by expand_builtin_frame_address().

rtx expand_builtin_saveregs ( void  )
Expand a call to __builtin_saveregs, generating the result in TARGET,
   if that's convenient.   

References emit_insn_after(), end_sequence(), entry_of_function(), get_insns(), pop_topmost_sequence(), push_topmost_sequence(), start_sequence(), and targetm.

Referenced by expand_builtin().

static void expand_builtin_set_thread_pointer ( )
static
void expand_builtin_setjmp_receiver ( )
Construct the trailing part of a __builtin_setjmp call.  This is
   also called directly by the SJLJ exception handling code.
   If RECEIVER_LABEL is NULL, instead contruct a nonlocal goto handler.   

References copy_to_reg(), current_function_decl, emit_clobber(), emit_insn(), emit_move_insn(), emit_use(), gen_blockage(), get_arg_pointer_save_area(), and targetm.

Referenced by expand_builtin(), expand_label(), and sjlj_emit_dispatch_table().

void expand_builtin_setjmp_setup ( )
Construct the leading half of a __builtin_setjmp call.  Control will
   return to RECEIVER_LABEL.  This is also called directly by the SJLJ
   exception handling code.   

References cfun, emit_insn(), emit_move_insn(), emit_stack_save(), force_operand(), force_reg(), gen_rtx_MEM(), function::has_nonlocal_label, new_alias_set(), plus_constant(), SAVE_NONLOCAL, set_mem_alias_set(), targetm, and validize_mem().

Referenced by expand_builtin(), and sjlj_emit_function_enter().

static rtx expand_builtin_signbit ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_signbit ( )
static
Expand the call EXP to the built-in signbit, signbitf or signbitl
   function.  The function first checks whether the back end provides
   an insn to implement signbit for the respective mode.  If not, it
   checks whether the floating point format of the value is such that
   the sign bit can be extracted.  If that is not the case, the
   function returns NULL_RTX to indicate that a normal call should be
   emitted rather than expanding the function in-line.  EXP is the
   expression that is a call to the builtin function; if convenient,
   the result should be placed in TARGET.   

References build_real(), builtin_save_expr(), dconst0, delete_insns_since(), expand_binop(), expand_expr(), EXPAND_NORMAL, expand_normal(), expand_shift(), force_reg(), gen_reg_rtx(), get_last_insn(), real_format::has_signed_zero, immed_double_int_const(), int_mode_for_mode(), last, maybe_emit_unop_insn(), operand_subword_force(), optab_handler(), OPTAB_LIB_WIDEN, double_int::set_bit(), real_format::signbit_ro, validate_arglist(), and word_mode.

static rtx expand_builtin_sincos ( tree  )
static

Referenced by expand_builtin().

static rtx expand_builtin_sincos ( )
static
Expand a call to the builtin sincos math function.
   Return NULL_RTX if a normal call should be emitted rather than expanding the
   function in-line.  EXP is the expression that is a call to the builtin
   function.   

References build_int_cst(), build_pointer_type_for_mode(), emit_move_insn(), expand_normal(), expand_twoval_unop(), gen_reg_rtx(), optab_handler(), ptr_mode, and validate_arglist().

static rtx expand_builtin_stpcpy ( tree  ,
rtx  ,
enum  machine_mode 
)
static

Referenced by expand_builtin().

static rtx expand_builtin_stpcpy ( )
static
Expand a call EXP to the stpcpy builtin.
   Return NULL_RTX if we failed the caller should emit a normal call,
   otherwise try to get the result in TARGET, if convenient (and in
   mode MODE if that's convenient).   

References build_call_nofold_loc(), builtin_decl_implicit(), c_getstr(), c_strlen(), emit_move_insn(), expand_builtin_mempcpy_args(), expand_builtin_strcpy_args(), expand_expr(), expand_movstr(), EXPAND_NORMAL, expand_normal(), force_operand(), gen_reg_rtx(), len, plus_constant(), size_binop_loc(), and validate_arglist().

static rtx expand_builtin_strcmp ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_strcmp ( )
static
Expand expression EXP, which is a call to the strcmp builtin.  Return NULL_RTX
   if we failed the caller should emit a normal call, otherwise try to get
   the result in TARGET, if convenient.   

References build_call_nofold_loc(), builtin_save_expr(), c_strlen(), convert_move(), convert_to_mode(), direct_optab_handler(), emit_insn(), expand_call(), expand_normal(), gen_reg_rtx(), get_callee_fndecl(), get_memory_rtx(), get_pointer_alignment(), insn_data, len, tree_int_cst_lt(), and validate_arglist().

static rtx expand_builtin_strcpy ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_strcpy ( )
static
Expand expression EXP, which is a call to the strcpy builtin.  Return
   NULL_RTX if we failed the caller should emit a normal call, otherwise
   try to get the result in TARGET, if convenient (and in mode MODE if that's
   convenient).   

References expand_builtin_strcpy_args(), and validate_arglist().

static rtx expand_builtin_strcpy_args ( tree  ,
tree  ,
rtx   
)
static
static rtx expand_builtin_strcpy_args ( )
static
Helper function to do the actual work for expand_builtin_strcpy.  The
   arguments to the builtin_strcpy call DEST and SRC are broken out
   so that this can also be called without constructing an actual CALL_EXPR.
   The other arguments and return value are the same as for
   expand_builtin_strcpy.   

References expand_movstr().

static rtx expand_builtin_strlen ( tree  exp,
rtx  target,
enum machine_mode  target_mode 
)
static
Expand expression EXP which is a call to the strlen builtin.  Return
   NULL_RTX if we failed the caller should emit a normal call, otherwise
   try to get the result in TARGET, if convenient.   

References c_strlen(), convert_move(), convert_to_mode(), create_fixed_operand(), create_integer_operand(), create_output_operand(), emit_insn_after(), emit_insn_before(), emit_move_insn(), end_sequence(), expand_expr(), EXPAND_NORMAL, gen_reg_rtx(), gen_rtx_MEM(), get_insns(), get_last_insn(), get_pointer_alignment(), len, maybe_expand_insn(), optab_handler(), start_sequence(), validate_arglist(), and expand_operand::value.

Referenced by expand_builtin().

static rtx expand_builtin_strncmp ( tree  exp,
rtx  target,
enum machine_mode  mode 
)
static
Expand expression EXP, which is a call to the strncmp builtin. Return
   NULL_RTX if we failed the caller should emit a normal call, otherwise try to get
   the result in TARGET, if convenient.   

References build_call_nofold_loc(), builtin_save_expr(), c_strlen(), convert_move(), convert_to_mode(), emit_insn(), expand_call(), expand_normal(), fold_convert_loc(), gen_reg_rtx(), get_callee_fndecl(), get_memory_rtx(), get_pointer_alignment(), insn_data, len, size_binop_loc(), tree_int_cst_lt(), and validate_arglist().

Referenced by expand_builtin().

static rtx expand_builtin_strncpy ( tree  ,
rtx   
)
static

Referenced by expand_builtin().

static rtx expand_builtin_strncpy ( )
static
Expand expression EXP, which is a call to the strncpy builtin.  Return
   NULL_RTX if we failed the caller should emit a normal call.   

References builtin_strncpy_read_str(), c_getstr(), c_strlen(), can_store_by_pieces(), force_operand(), get_memory_rtx(), get_pointer_alignment(), host_integerp(), len, ptr_mode, size_binop_loc(), store_by_pieces(), tree_int_cst_lt(), tree_low_cst(), and validate_arglist().

static void expand_builtin_sync_lock_release ( )
static
Expand the __sync_lock_release intrinsic.  EXP is the CALL_EXPR.   

References expand_atomic_store(), get_builtin_sync_mem(), and MEMMODEL_RELEASE.

Referenced by expand_builtin().

static rtx expand_builtin_sync_lock_test_and_set ( enum machine_mode  mode,
tree  exp,
rtx  target 
)
static
Expand the __sync_lock_test_and_set intrinsic.  Note that the most
   general form is actually an atomic exchange, and some targets only
   support a reduced form with the second argument being a constant 1.
   EXP is the CALL_EXPR; TARGET is an optional place for us to store
   the results.   

References expand_expr_force_mode(), expand_sync_lock_test_and_set(), and get_builtin_sync_mem().

Referenced by expand_builtin().

static rtx expand_builtin_sync_operation ( enum machine_mode  mode,
tree  exp,
enum rtx_code  code,
bool  after,
rtx  target 
)
static
Expand the __sync_xxx_and_fetch and __sync_fetch_and_xxx intrinsics.
   EXP is the CALL_EXPR.  CODE is the rtx code
   that corresponds to the arithmetic or logical operation from the name;
   an exception here is that NOT actually means NAND.  TARGET is an optional
   place for us to store the results; AFTER is true if this is the
   fetch_and_xxx form.   

References builtin_decl_implicit(), expand_atomic_fetch_op(), expand_expr_force_mode(), get_builtin_sync_mem(), get_callee_fndecl(), inform(), and MEMMODEL_SEQ_CST.

Referenced by expand_builtin().

static void expand_builtin_sync_synchronize ( )
static
Expand the __sync_synchronize intrinsic.   

References expand_mem_thread_fence(), and MEMMODEL_SEQ_CST.

Referenced by expand_builtin().

static rtx expand_builtin_thread_pointer ( )
static
static rtx expand_builtin_unop ( enum machine_mode  target_mode,
tree  exp,
rtx  target,
rtx  subtarget,
optab  op_optab 
)
static
Expand a call to a unary builtin in EXP.
   Return NULL_RTX if a normal call should be emitted rather than expanding the
   function in-line.  If convenient, the result should be placed in TARGET.
   SUBTARGET may be used as the target for computing one of EXP's operands.   

References convert_to_mode(), expand_expr(), EXPAND_NORMAL, expand_unop(), and validate_arglist().

Referenced by expand_builtin().

static void expand_builtin_unreachable ( )
static
Expand a call to __builtin_unreachable.  We do nothing except emit
   a barrier saying that control flow will not pass here.

   It is the responsibility of the program being compiled to ensure
   that control flow does never reach __builtin_unreachable.   

References emit_barrier().

Referenced by expand_builtin().

static void expand_builtin_update_setjmp_buf ( rtx  )
static

Referenced by expand_builtin().

static void expand_builtin_update_setjmp_buf ( )
static
__builtin_update_setjmp_buf is passed a pointer to an array of five words
   (not all will be used on all machines) that was passed to __builtin_setjmp.
   It updates the stack pointer in that block to correspond to the current
   stack pointer.   

References emit_stack_save(), gen_rtx_MEM(), plus_constant(), and SAVE_NONLOCAL.

static rtx expand_builtin_va_copy ( tree  )
static

Referenced by expand_builtin().

static rtx expand_builtin_va_copy ( )
static
Expand EXP, a call to __builtin_va_copy.  We do this as a
   builtin rather than just as an assignment in stdarg.h because of the
   nastiness of array-type va_list types.   

References BLOCK_OP_NORMAL, cfun, function::decl, emit_block_move(), expand_expr(), EXPAND_NORMAL, gen_rtx_MEM(), get_alias_set(), set_mem_alias_set(), set_mem_align(), stabilize_va_list_loc(), and targetm.

static rtx expand_builtin_va_end ( tree  )
static

Referenced by expand_builtin().

static rtx expand_builtin_va_end ( )
static
Expand EXP, a call to __builtin_va_end.   

References expand_expr(), and EXPAND_NORMAL.

static rtx expand_builtin_va_start ( tree  )
static

Referenced by expand_builtin().

static rtx expand_builtin_va_start ( )
static
static void expand_errno_check ( tree  ,
rtx   
)
static
static void expand_errno_check ( )
static
If errno must be maintained, expand the RTL to check if the result,
   TARGET, of a built-in function call, EXP, is NaN, and if so set
   errno to EDOM.   

References do_compare_rtx_and_jump(), emit_label(), emit_move_insn(), expand_call(), gen_label_rtx(), gen_rtx_MEM(), and word_mode.

static rtx expand_expr_force_mode ( )
static
static rtx expand_movstr ( )
static
Expand into a movstr instruction, if one is available.  Return NULL_RTX if
   we failed, the caller should emit a normal call, otherwise try to
   get the result in TARGET, if convenient.  If ENDP is 0 return the
   destination pointer, if ENDP is 1 return the end pointer ala
   mempcpy, and if ENDP is 2 return the end pointer minus one ala
   stpcpy.   

References create_fixed_operand(), create_output_operand(), emit_move_insn(), expand_insn(), force_operand(), force_reg(), get_memory_rtx(), plus_constant(), replace_equiv_address(), and expand_operand::value.

Referenced by expand_builtin_stpcpy(), and expand_builtin_strcpy_args().

static tree fold_builtin_0 ( location_t  ,
tree  ,
bool   
)
static

Referenced by fold_builtin_n().

static tree fold_builtin_0 ( )
static
Fold a call to built-in function FNDECL with 0 arguments.
   IGNORE is true if the result of the function call is ignored.  This
   function returns NULL_TREE if no simplification was possible.   

References fold_builtin_classify_type(), and fold_builtin_inf().

static tree fold_builtin_1 ( location_t  ,
tree  ,
tree  ,
bool   
)
static

Referenced by fold_builtin_n().

static tree fold_builtin_2 ( location_t  ,
tree  ,
tree  ,
tree  ,
bool   
)
static

Referenced by fold_builtin_n().

static tree fold_builtin_3 ( location_t  loc,
tree  fndecl,
tree  arg0,
tree  arg1,
tree  arg2,
bool  ignore 
)
static
Fold a call to built-in function FNDECL with 3 arguments, ARG0, ARG1,
   and ARG2.  IGNORE is true if the result of the function call is ignored.
   This function returns NULL_TREE if no simplification was possible.   

References do_mpfr_remquo(), fold_builtin_fma(), fold_builtin_fprintf(), fold_builtin_memchr(), fold_builtin_memcmp(), fold_builtin_memory_op(), fold_builtin_memset(), fold_builtin_printf(), fold_builtin_sincos(), fold_builtin_snprintf(), fold_builtin_sprintf(), fold_builtin_strcat_chk(), fold_builtin_strncat(), fold_builtin_strncmp(), fold_builtin_strncpy(), fold_builtin_stxcpy_chk(), and validate_arg().

Referenced by fold_builtin_n().

static tree fold_builtin_4 ( location_t  loc,
tree  fndecl,
tree  arg0,
tree  arg1,
tree  arg2,
tree  arg3,
bool  ignore 
)
static
Fold a call to built-in function FNDECL with 4 arguments, ARG0, ARG1,
   ARG2, and ARG3.  IGNORE is true if the result of the function call is
   ignored.  This function returns NULL_TREE if no simplification was
   possible.   

References fold_builtin_fprintf(), fold_builtin_memory_chk(), fold_builtin_snprintf(), fold_builtin_strncat_chk(), fold_builtin_stxncpy_chk(), and validate_arg().

Referenced by fold_builtin_n().

static tree fold_builtin_abs ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_abs ( )
static
Fold a call to abs, labs, llabs or imaxabs with argument ARG.   

References fold_abs_const(), fold_convert_loc(), and validate_arg().

static tree fold_builtin_atomic_always_lock_free ( )
static
Return true if (optional) argument ARG1 of size ARG0 is always lock free on
   this architecture.  If ARG1 is NULL, use typical alignment for size ARG0.   

References can_compare_and_swap_p(), expand_normal(), and mode_for_size().

Referenced by expand_builtin_atomic_always_lock_free(), fold_builtin_2(), and fold_builtin_atomic_is_lock_free().

static tree fold_builtin_atomic_is_lock_free ( )
static
Return a one or zero if it can be determined that object ARG1 of size ARG 
   is lock free on this architecture.   

References fold_builtin_atomic_always_lock_free().

Referenced by expand_builtin_atomic_is_lock_free(), and fold_builtin_2().

static tree fold_builtin_bitop ( tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_bitop ( )
static
Fold function call to builtin ffs, clz, ctz, popcount and parity
   and their long and long long variants (i.e. ffsl and ffsll).  ARG is
   the argument to the call.  Return NULL_TREE if no simplification can
   be made.   

References build_int_cst(), ctz_hwi(), ffs_hwi(), floor_log2(), HOST_BITS_PER_WIDE_INT, HOST_WIDE_INT, HOST_WIDE_INT_M1U, type(), and validate_arg().

static tree fold_builtin_bswap ( )
static
Fold function call to builtin_bswap and the short, long and long long
   variants.  Return NULL_TREE if no simplification can be made.   

References build_int_cst(), build_int_cst_wide(), HOST_BITS_PER_WIDE_INT, HOST_WIDE_INT, and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_bzero ( )
static
Fold function call to builtin memset.  Return
   NULL_TREE if no simplification can be made.   

References fold_builtin_memset(), fold_convert_loc(), and validate_arg().

Referenced by fold_builtin_2().

static tree fold_builtin_cabs ( )
static
Fold call to builtin cabs, cabsf or cabsl with argument ARG.  TYPE is the
   return type.  Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_real(), builtin_save_expr(), cfun, do_mpfr_arg2(), mathfn_built_in(), OEP_PURE_SAME, operand_equal_p(), optimize_function_for_speed_p(), real_value_truncate(), real_zerop(), and validate_arg().

Referenced by fold_builtin_1().

tree fold_builtin_call_array ( location_t  loc,
tree  type,
tree  fn,
int  n,
tree argarray 
)
Construct a CALL_EXPR with type TYPE with FN as the function expression.
   N arguments are passed in the array ARGARRAY.   

References avoid_folding_inline_builtin(), build_call_array_loc(), BUILT_IN_MD, BUILT_IN_NORMAL, exp(), fold_builtin_n(), fold_builtin_varargs(), get_callee_fndecl(), and targetm.

Referenced by build_call_expr_loc_array(), and fold_build_call_array_loc().

static tree fold_builtin_carg ( )
static
Fold a call to builtin carg(a+bi) -> atan2(b,a).   

References build_call_expr_loc(), builtin_save_expr(), mathfn_built_in(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_cbrt ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_cbrt ( )
static
Fold a builtin function call to cbrt, cbrtf, or cbrtl with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_real(), builtin_mathfn_code(), dconst_third_ptr(), do_mpfr_arg1(), mathfn_built_in(), real_arithmetic(), real_value_truncate(), tree_expr_nonnegative_p(), and validate_arg().

static tree fold_builtin_ccos ( location_t  loc,
tree  arg,
tree  type,
tree  fndecl,
bool  hyper 
)
static
Fold function call to builtin ccos (or ccosh if HYPER is TRUE) with
   argument ARG.  TYPE is the type of the return value.  Return
   NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), do_mpc_arg1(), fold_strip_sign_ops(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_ceil ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_ceil ( )
static
Fold function call to builtin ceil, ceilf or ceill with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_real(), fold_trunc_transparent_mathfn(), real_ceil(), and validate_arg().

static tree fold_builtin_cexp ( )
static
Fold function call to builtin cexp, cexpf, or cexpl.  Return
   NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), builtin_save_expr(), do_mpc_arg1(), fold_unary_loc(), function_c99_math_complex, mathfn_built_in(), real_zerop(), targetm, and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_classify ( )
static
Fold a call to __builtin_isnan(), __builtin_isinf, __builtin_finite.
   ARG is the argument for the call.   

References build_call_expr_loc(), builtin_decl_explicit(), builtin_save_expr(), dconst0, mathfn_built_in_1(), omit_one_operand_loc(), real_compare(), real_isfinite(), real_isinf(), real_isnan(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_classify_type ( tree  )
static

Referenced by fold_builtin_0(), and fold_builtin_1().

static tree fold_builtin_classify_type ( )
static
Fold a call to __builtin_classify_type with argument ARG.   

References build_int_cst(), no_type_class, and type_to_class().

static tree fold_builtin_constant_p ( tree  )
static

Referenced by fold_builtin_1().

static tree fold_builtin_constant_p ( )
static
Fold a call to __builtin_constant_p, if we know its argument ARG will
   evaluate to a constant.   

References cfun, folding_initializer, and integer_zerop().

static tree fold_builtin_copysign ( location_t  loc,
tree  fndecl,
tree  arg1,
tree  arg2,
tree  type 
)
static
Fold function call to builtin copysign, copysignf or copysignl with
   arguments ARG1 and ARG2.  Return NULL_TREE if no simplification can
   be made.   

References build_call_expr_loc(), build_real(), fold_convert_loc(), fold_strip_sign_ops(), omit_one_operand_loc(), operand_equal_p(), real_copysign(), tree_expr_nonnegative_p(), and validate_arg().

Referenced by fold_builtin_2().

static tree fold_builtin_cos ( location_t  loc,
tree  arg,
tree  type,
tree  fndecl 
)
static
Fold function call to builtin cos, cosf, or cosl with argument ARG.
   TYPE is the type of the return value.  Return NULL_TREE if no
   simplification can be made.   

References build_call_expr_loc(), do_mpfr_arg1(), fold_strip_sign_ops(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_cosh ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_cosh ( )
static
Fold function call to builtin cosh, coshf, or coshl with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), do_mpfr_arg1(), fold_strip_sign_ops(), and validate_arg().

static tree fold_builtin_cproj ( )
static
Fold call to builtin cproj, cprojf or cprojl with argument ARG.  TYPE is the
   return type.  Return NULL_TREE if no simplification can be made.   

References build_complex_cproj(), non_lvalue_loc(), omit_one_operand_loc(), real_isinf(), tree_expr_nonnegative_p(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_expect ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_expect ( )
static
Fold a call to builtin_expect with arguments ARG0 and ARG1.  Return
   NULL_TREE if no simplification is possible.   

References build_builtin_expect_predicate(), BUILT_IN_NORMAL, fold_convert_loc(), and get_callee_fndecl().

static tree fold_builtin_exponent ( location_t  loc,
tree  fndecl,
tree  arg,
int(*)(mpfr_ptr, mpfr_srcptr, mp_rnd_t)  func 
)
static
A subroutine of fold_builtin to fold the various exponent
   functions.  Return NULL_TREE if no simplification can be made.
   FUNC is the corresponding MPFR exponent function.   

References builtin_mathfn_code(), do_mpfr_arg1(), fold_convert_loc(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_fabs ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_fabs ( )
static
Fold a call to fabs, fabsf or fabsl with argument ARG.   

References fold_abs_const(), fold_convert_loc(), and validate_arg().

static tree fold_builtin_floor ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_floor ( )
static
Fold function call to builtin floor, floorf or floorl with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_real(), fold_trunc_transparent_mathfn(), mathfn_built_in(), real_floor(), tree_expr_nonnegative_p(), and validate_arg().

static tree fold_builtin_fma ( )
static
Fold a call to fma, fmaf, or fmal with arguments ARG[012].   

References fold_fma(), optab_handler(), and validate_arg().

Referenced by fold_builtin_3().

static tree fold_builtin_fmin_fmax ( location_t  loc,
tree  arg0,
tree  arg1,
tree  type,
bool  max 
)
static
static tree fold_builtin_fpclassify ( )
static
Fold a call to __builtin_fpclassify(int, int, int, int, int, ...).
   This builtin will generate code to return the appropriate floating
   point classification depending on the value of the floating point
   number passed in.  The possible return values must be supplied as
   int arguments to the call in the following order: FP_NAN, FP_INFINITE,
   FP_NORMAL, FP_SUBNORMAL and FP_ZERO.  The ellipses is for exactly
   one floating point argument which is "type generic".   

References build_real(), builtin_save_expr(), dconst0, real_from_string(), real_inf(), type(), and validate_arglist().

Referenced by fold_builtin_varargs().

static tree fold_builtin_fprintf ( location_t  loc,
tree  fndecl,
tree  fp,
tree  fmt,
tree  arg,
bool  ignore,
enum built_in_function  fcode 
)
static
Fold a call to the {,v}fprintf{,_unlocked} and __{,v}printf_chk builtins.
   FP, FMT, and ARG are the arguments to the call.  We don't fold calls with
   more than 3 arguments, and ARG may be null in the 2-argument case.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.  FCODE is the BUILT_IN_*
   code of the function to be simplified.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_explicit(), builtin_decl_implicit(), c_getstr(), fold_convert_loc(), init_target_chars(), and validate_arg().

Referenced by fold_builtin_2(), fold_builtin_3(), and fold_builtin_4().

tree fold_builtin_fputs ( location_t  loc,
tree  arg0,
tree  arg1,
bool  ignore,
bool  unlocked,
tree  len 
)
Fold a call to the fputs builtin.  ARG0 and ARG1 are the arguments
   to the call.  IGNORE is true if the value returned
   by the builtin will be ignored.  UNLOCKED is true is true if this
   actually a call to fputs_unlocked.  If LEN in non-NULL, it represents
   the known length of the string.  Return NULL_TREE if no simplification
   was possible.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_explicit(), builtin_decl_implicit(), c_getstr(), c_strlen(), cfun, compare_tree_int(), omit_one_operand_loc(), optimize_function_for_size_p(), and validate_arg().

Referenced by fold_builtin_2(), and gimple_fold_builtin().

static tree fold_builtin_frexp ( )
static
Fold a call to builtin frexp, we can assume the base is 2.   

References build_fold_indirect_ref_loc(), build_int_cst(), build_real(), exp(), omit_one_operand_loc(), rvc_inf, rvc_nan, rvc_normal, rvc_zero, validate_arg(), and expand_operand::value.

Referenced by fold_builtin_2().

static tree fold_builtin_hypot ( location_t  loc,
tree  fndecl,
tree  arg0,
tree  arg1,
tree  type 
)
static
Fold a builtin function call to hypot, hypotf, or hypotl.  Return
   NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_real(), do_mpfr_arg2(), fold_strip_sign_ops(), OEP_PURE_SAME, operand_equal_p(), real_value_truncate(), real_zerop(), and validate_arg().

Referenced by fold_builtin_2().

static tree fold_builtin_inf ( location_t  ,
tree  ,
int   
)
static

Referenced by fold_builtin_0().

static tree fold_builtin_inf ( )
static
Fold a call to __builtin_inf or __builtin_huge_val.   

References build_real(), pedwarn(), and real_inf().

static tree fold_builtin_int_roundingfn ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_int_roundingfn ( )
static
Fold function call to builtin lround, lroundf or lroundl (or the
   corresponding long long versions) and other rounding functions.  ARG
   is the argument to the call.  Return NULL_TREE if no simplification
   can be made.   

References double_int_fits_to_tree_p(), double_int_to_tree(), fold_fixed_mathfn(), double_int::high, HOST_WIDE_INT, double_int::low, real_ceil(), real_floor(), real_isfinite(), real_round(), real_to_integer2(), tree_expr_nonnegative_p(), and validate_arg().

static tree fold_builtin_interclass_mathfn ( )
static
Given a location LOC, an interclass builtin function decl FNDECL
   and its single argument ARG, return an folded expression computing
   the same, or NULL_TREE if we either couldn't or didn't want to fold
   (the latter happen if there's an RTL instruction available).   

References build_call_expr(), build_real(), builtin_decl_explicit(), builtin_save_expr(), get_max_float(), interclass_mathfn_icode(), real_from_string(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_isascii ( location_t  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_isascii ( )
static
Fold a call to builtin isascii with argument ARG.   

References build_int_cst(), HOST_WIDE_INT, and validate_arg().

static tree fold_builtin_isdigit ( location_t  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_isdigit ( )
static
Fold a call to builtin isdigit with argument ARG.   

References build_int_cst(), fold_convert_loc(), HOST_WIDE_INT, lang_hooks::to_target_charset, and validate_arg().

static tree fold_builtin_load_exponent ( location_t  loc,
tree  arg0,
tree  arg1,
tree  type,
bool  ldexp 
)
static
Fold a call to builtin ldexp or scalbn/scalbln.  If LDEXP is true
   then we can assume the base is two.  If it's false, then we have to
   check the mode of the TYPE parameter in certain cases.   

References build_real(), host_integerp(), HOST_WIDE_INT, integer_zerop(), omit_one_operand_loc(), real_isfinite(), real_isinf(), real_ldexp(), real_value_truncate(), real_zerop(), tree_low_cst(), and validate_arg().

Referenced by fold_builtin_2().

static tree fold_builtin_logarithm ( location_t  loc,
tree  fndecl,
tree  arg,
int(*)(mpfr_ptr, mpfr_srcptr, mp_rnd_t)  func 
)
static
A subroutine of fold_builtin to fold the various logarithmic
   functions.  Return NULL_TREE if no simplification can me made.
   FUNC is the corresponding MPFR logarithm function.   

References build_call_expr_loc(), build_real(), builtin_mathfn_code(), dconst0, dconst2, dconsthalf, do_mpfr_arg1(), fold_convert_loc(), real_from_integer(), real_value_truncate(), and validate_arg().

Referenced by fold_builtin_1().

static tree fold_builtin_logb ( )
static
static tree fold_builtin_memchr ( location_t  ,
tree  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_3().

static tree fold_builtin_memchr ( )
static
Fold function call to builtin memchr.  ARG1, ARG2 and LEN are the
   arguments to the call, and TYPE is its return type.
   Return NULL_TREE if no simplification can be made.   

References build_int_cst(), c_getstr(), compare_tree_int(), fold_build_pointer_plus_hwi_loc(), fold_convert_loc(), host_integerp(), strlen(), target_char_cast(), tree_low_cst(), and validate_arg().

static tree fold_builtin_memcmp ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_3().

static tree fold_builtin_memcmp ( )
static
Fold function call to builtin memcmp with arguments ARG1 and ARG2.
   Return NULL_TREE if no simplification can be made.   

References build_pointer_type_for_mode(), c_getstr(), compare_tree_int(), fold_convert_loc(), host_integerp(), integer_zerop(), omit_one_operand_loc(), omit_two_operands_loc(), operand_equal_p(), ptr_mode, strlen(), tree_low_cst(), and validate_arg().

tree fold_builtin_memory_chk ( location_t  loc,
tree  fndecl,
tree  dest,
tree  src,
tree  len,
tree  size,
tree  maxlen,
bool  ignore,
enum built_in_function  fcode 
)
Fold a call to the __mem{cpy,pcpy,move,set}_chk builtin.
   DEST, SRC, LEN, and SIZE are the arguments to the call.
   IGNORE is true, if return value can be ignored.  FCODE is the BUILT_IN_*
   code of the builtin.  If MAXLEN is not NULL, it is maximum length
   passed as third argument.   

References build_call_expr_loc(), builtin_decl_explicit(), fold_build_pointer_plus_loc(), fold_convert_loc(), host_integerp(), integer_all_onesp(), len, omit_one_operand_loc(), operand_equal_p(), tree_int_cst_lt(), and validate_arg().

Referenced by fold_builtin_4(), and gimple_fold_builtin().

static tree fold_builtin_memory_op ( location_t  loc,
tree  dest,
tree  src,
tree  len,
tree  type,
bool  ignore,
int  endp 
)
static
static tree fold_builtin_memset ( location_t  loc,
tree  dest,
tree  c,
tree  len,
tree  type,
bool  ignore 
)
static
static tree fold_builtin_modf ( )
static
static tree fold_builtin_n ( location_t  ,
tree  ,
tree ,
int  ,
bool   
)
static
static tree fold_builtin_n ( )
static
static tree fold_builtin_nan ( tree  ,
tree  ,
int   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_nan ( )
static
Fold a call to __builtin_nan or __builtin_nans with argument ARG.   

References build_real(), c_getstr(), real_nan(), and validate_arg().

bool fold_builtin_next_arg ( )
Fold the next_arg or va_start call EXP. Returns true if there was an error
   produced.  False otherwise.  This is done so that we don't output the error
   or warning twice or three times.   

References current_function_decl, error(), input_location, integer_zerop(), line_table, stdarg_p(), tree_last(), and warning_at().

Referenced by expand_builtin(), expand_builtin_va_start(), and gimplify_call_expr().

static tree fold_builtin_object_size ( tree  ,
tree   
)
static

Referenced by fold_builtin_2().

tree fold_builtin_object_size ( )
static tree fold_builtin_pow ( location_t  ,
tree  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_powi ( location_t  loc,
tree  fndecl,
tree  arg0,
tree  arg1,
tree  type 
)
static
Fold a builtin function call to powi, powif, or powil with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_real(), dconst1, host_integerp(), HOST_WIDE_INT, omit_one_operand_loc(), real_onep(), real_powi(), and validate_arg().

Referenced by fold_builtin_2().

static tree fold_builtin_printf ( location_t  loc,
tree  fndecl,
tree  fmt,
tree  arg,
bool  ignore,
enum built_in_function  fcode 
)
static
Fold a call to the {,v}printf{,_unlocked} and __{,v}printf_chk builtins.
   FMT and ARG are the arguments to the call; we don't fold cases with
   more than 2 arguments, and ARG may be null if this is a 1-argument case.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.  FCODE is the BUILT_IN_*
   code of the function to be simplified.   

References build_call_expr_loc(), build_int_cst(), build_string_literal(), builtin_decl_explicit(), builtin_decl_implicit(), c_getstr(), fold_convert_loc(), init_target_chars(), integer_zerop(), len, string_constant(), strlen(), and validate_arg().

Referenced by fold_builtin_1(), fold_builtin_2(), and fold_builtin_3().

static tree fold_builtin_round ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_round ( )
static
Fold function call to builtin round, roundf or roundl with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_real(), fold_trunc_transparent_mathfn(), real_round(), and validate_arg().

static tree fold_builtin_signbit ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_signbit ( )
static
Fold function call to builtin signbit, signbitf or signbitl with argument
   ARG.  Return NULL_TREE if no simplification can be made.   

References build_one_cst(), build_real(), build_zero_cst(), dconst0, omit_one_operand_loc(), tree_expr_nonnegative_p(), and validate_arg().

static tree fold_builtin_significand ( )
static
Fold a call to builtin significand, if radix == 2.   

References build_real(), fold_convert_loc(), rvc_inf, rvc_nan, rvc_normal, rvc_zero, validate_arg(), and expand_operand::value.

Referenced by fold_builtin_1().

static tree fold_builtin_sincos ( location_t  loc,
tree  arg0,
tree  arg1,
tree  arg2 
)
static
Fold function call to builtin sincos, sincosf, or sincosl.  Return
   NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_fold_indirect_ref_loc(), builtin_save_expr(), do_mpfr_sincos(), function_c99_math_complex, mathfn_built_in(), targetm, type(), and validate_arg().

Referenced by fold_builtin_3().

static tree fold_builtin_snprintf ( location_t  loc,
tree  dest,
tree  destsize,
tree  fmt,
tree  orig,
int  ignored 
)
static
Simplify a call to the snprintf builtin with arguments DEST, DESTSIZE,
   FMT, and ORIG.  ORIG may be null if this is a 3-argument call.  We don't
   attempt to simplify calls with more than 4 arguments.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.  If IGNORED is true, it means that
   the caller does not use the returned value of the function.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_explicit(), builtin_decl_implicit(), c_getstr(), c_strlen(), fold_convert_loc(), host_integerp(), HOST_WIDE_INT, init_target_chars(), len, strlen(), tree_low_cst(), and validate_arg().

Referenced by fold_builtin_3(), and fold_builtin_4().

tree fold_builtin_snprintf_chk ( location_t  loc,
tree  exp,
tree  maxlen,
enum built_in_function  fcode 
)
Fold a call EXP to {,v}snprintf.  Return NULL_TREE if
   a normal call should be emitted rather than expanding the function
   inline.  FCODE is either BUILT_IN_SNPRINTF_CHK or
   BUILT_IN_VSNPRINTF_CHK.  If MAXLEN is not NULL, it is maximum length
   passed as second argument.   

References fold_builtin_snprintf_chk_1().

Referenced by fold_builtin_varargs().

static tree fold_builtin_snprintf_chk_1 ( location_t  loc,
int  nargs,
tree args,
tree  maxlen,
enum built_in_function  fcode 
)
static
Fold a call EXP to {,v}snprintf having NARGS passed as ARGS.  Return
   NULL_TREE if a normal call should be emitted rather than expanding
   the function inline.  FCODE is either BUILT_IN_SNPRINTF_CHK or
   BUILT_IN_VSNPRINTF_CHK.  If MAXLEN is not NULL, it is maximum length
   passed as second argument.   

References builtin_decl_explicit(), c_getstr(), host_integerp(), init_target_chars(), integer_all_onesp(), integer_zerop(), len, rewrite_call_expr_array(), tree_int_cst_lt(), and validate_arg().

Referenced by fold_builtin_snprintf_chk(), and gimple_fold_builtin_snprintf_chk().

static tree fold_builtin_sprintf ( location_t  loc,
tree  dest,
tree  fmt,
tree  orig,
int  ignored 
)
static
Simplify a call to the sprintf builtin with arguments DEST, FMT, and ORIG.
   ORIG may be null if this is a 2-argument call.  We don't attempt to
   simplify calls with more than 3 arguments.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.  If IGNORED is true, it means that
   the caller does not use the returned value of the function.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_implicit(), c_getstr(), c_strlen(), fold_convert_loc(), init_target_chars(), strlen(), and validate_arg().

Referenced by fold_builtin_2(), and fold_builtin_3().

static tree fold_builtin_sprintf_chk ( location_t  loc,
tree  exp,
enum built_in_function  fcode 
)
static
Fold a call EXP to __{,v}sprintf_chk.  Return NULL_TREE if
   a normal call should be emitted rather than expanding the function
   inline.  FCODE is either BUILT_IN_SPRINTF_CHK or BUILT_IN_VSPRINTF_CHK.   

References fold_builtin_sprintf_chk_1().

Referenced by fold_builtin_varargs().

static tree fold_builtin_sprintf_chk_1 ( location_t  loc,
int  nargs,
tree args,
enum built_in_function  fcode 
)
static
Fold a call EXP to __{,v}sprintf_chk having NARGS passed as ARGS.
   Return NULL_TREE if a normal call should be emitted rather than
   expanding the function inline.  FCODE is either BUILT_IN_SPRINTF_CHK
   or BUILT_IN_VSPRINTF_CHK.   

References build_int_cstu(), builtin_decl_explicit(), c_getstr(), c_strlen(), host_integerp(), init_target_chars(), integer_all_onesp(), integer_zerop(), len, rewrite_call_expr_array(), strlen(), tree_int_cst_lt(), and validate_arg().

Referenced by fold_builtin_sprintf_chk(), and gimple_fold_builtin_sprintf_chk().

static tree fold_builtin_sqrt ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_sqrt ( )
static
Fold a builtin function call to sqrt, sqrtf, or sqrtl with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_real(), builtin_mathfn_code(), dconst0, dconsthalf, do_mpfr_arg1(), mathfn_built_in(), real_value_truncate(), tree_expr_nonnegative_p(), and validate_arg().

static tree fold_builtin_stpcpy ( )
static
Fold function call to builtin stpcpy with arguments DEST and SRC.
   Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_implicit(), builtin_save_expr(), c_strlen(), cfun, fold_build_pointer_plus_loc(), fold_convert_loc(), integer_zerop(), len, omit_one_operand_loc(), optimize_function_for_size_p(), size_binop_loc(), type(), and validate_arg().

Referenced by fold_builtin_2().

static tree fold_builtin_strcat ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strcat ( )
static
Simplify a call to the strcat builtin.  DST and SRC are the arguments
   to the call.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_call_expr_loc(), builtin_decl_implicit(), builtin_save_expr(), c_getstr(), c_strlen(), fold_build_pointer_plus_loc(), len, optimize_insn_for_speed_p(), and validate_arg().

static tree fold_builtin_strcat_chk ( location_t  loc,
tree  fndecl,
tree  dest,
tree  src,
tree  size 
)
static
Fold a call to the __strcat_chk builtin FNDECL.  DEST, SRC, and SIZE
   are the arguments to the call.   

References build_call_expr_loc(), builtin_decl_explicit(), c_getstr(), host_integerp(), integer_all_onesp(), omit_one_operand_loc(), and validate_arg().

Referenced by fold_builtin_3().

static tree fold_builtin_strchr ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strchr ( )
static
Simplify a call to the strchr builtin.  S1 and S2 are the arguments to
   the call, and TYPE is its return type.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_int_cst(), c_getstr(), fold_build_pointer_plus_hwi_loc(), fold_convert_loc(), target_char_cast(), and validate_arg().

static tree fold_builtin_strcmp ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strcmp ( )
static
Fold function call to builtin strcmp with arguments ARG1 and ARG2.
   Return NULL_TREE if no simplification can be made.   

References build_pointer_type_for_mode(), c_getstr(), fold_convert_loc(), operand_equal_p(), ptr_mode, and validate_arg().

tree fold_builtin_strcpy ( )
Fold function call to builtin strcpy with arguments DEST and SRC.
   If LEN is not NULL, it represents the length of the string to be
   copied.  Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_implicit(), c_strlen(), cfun, fold_convert_loc(), operand_equal_p(), optimize_function_for_size_p(), size_binop_loc(), and validate_arg().

Referenced by fold_builtin_2(), and gimple_fold_builtin().

static tree fold_builtin_strcspn ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strcspn ( )
static
Simplify a call to the strcspn builtin.  S1 and S2 are the arguments
   to the call.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_implicit(), c_getstr(), omit_one_operand_loc(), and validate_arg().

static tree fold_builtin_strlen ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_strlen ( )
static
Fold a call to __builtin_strlen with argument ARG.   

References c_strlen(), fold_convert_loc(), len, and validate_arg().

static tree fold_builtin_strncat ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_3().

static tree fold_builtin_strncat ( )
static
Simplify a call to the strncat builtin.  DST, SRC, and LEN are the
   arguments to the call.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_call_expr_loc(), builtin_decl_implicit(), c_getstr(), compare_tree_int(), integer_zerop(), omit_two_operands_loc(), strlen(), and validate_arg().

static tree fold_builtin_strncat_chk ( location_t  loc,
tree  fndecl,
tree  dest,
tree  src,
tree  len,
tree  size 
)
static
Fold a call to the __strncat_chk builtin with arguments DEST, SRC,
   LEN, and SIZE.   

References build_call_expr_loc(), builtin_decl_explicit(), c_getstr(), c_strlen(), host_integerp(), integer_all_onesp(), integer_zerop(), omit_one_operand_loc(), tree_int_cst_lt(), and validate_arg().

Referenced by fold_builtin_4().

static tree fold_builtin_strncmp ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_3().

static tree fold_builtin_strncmp ( )
static
Fold function call to builtin strncmp with arguments ARG1, ARG2, and LEN.
   Return NULL_TREE if no simplification can be made.   

References build_pointer_type_for_mode(), c_getstr(), fold_convert_loc(), host_integerp(), integer_zerop(), omit_one_operand_loc(), omit_two_operands_loc(), operand_equal_p(), ptr_mode, tree_int_cst_sgn(), tree_low_cst(), and validate_arg().

tree fold_builtin_strncpy ( location_t  loc,
tree  fndecl,
tree  dest,
tree  src,
tree  len,
tree  slen 
)
Fold function call to builtin strncpy with arguments DEST, SRC, and LEN.
   If SLEN is not NULL, it represents the length of the source string.
   Return NULL_TREE if no simplification can be made.   

References build_call_expr_loc(), builtin_decl_implicit(), c_strlen(), fold_convert_loc(), integer_zerop(), omit_one_operand_loc(), size_binop_loc(), tree_int_cst_lt(), and validate_arg().

Referenced by fold_builtin_3(), and gimple_fold_builtin().

static tree fold_builtin_strpbrk ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strpbrk ( )
static
Simplify a call to the strpbrk builtin.  S1 and S2 are the arguments
   to the call, and TYPE is its return type.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_implicit(), c_getstr(), fold_build_pointer_plus_hwi_loc(), fold_convert_loc(), omit_one_operand_loc(), and validate_arg().

static tree fold_builtin_strrchr ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strrchr ( )
static
Simplify a call to the strrchr builtin.  S1 and S2 are the arguments to
   the call, and TYPE is its return type.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_implicit(), c_getstr(), fold_build_pointer_plus_hwi_loc(), fold_convert_loc(), integer_zerop(), target_char_cast(), and validate_arg().

static tree fold_builtin_strspn ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strspn ( )
static
Simplify a call to the strspn builtin.  S1 and S2 are the arguments
   to the call.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_int_cst(), c_getstr(), omit_two_operands_loc(), and validate_arg().

static tree fold_builtin_strstr ( location_t  ,
tree  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_2().

static tree fold_builtin_strstr ( )
static
Simplify a call to the strstr builtin.  S1 and S2 are the arguments
   to the call, and TYPE is its return type.

   Return NULL_TREE if no simplification was possible, otherwise return the
   simplified form of the call as a tree.

   The simplified form may be a constant or other expression which
   computes the same value, but in a more efficient manner (including
   calls to other builtin functions).

   The call may contain arguments which need to be evaluated, but
   which are not useful to determine the result of the call.  In
   this case we return a chain of COMPOUND_EXPRs.  The LHS of each
   COMPOUND_EXPR will be an argument which must be evaluated.
   COMPOUND_EXPRs are chained through their RHS.  The RHS of the last
   COMPOUND_EXPR in the chain will contain the tree for the simplified
   form of the builtin function call.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_implicit(), c_getstr(), fold_build_pointer_plus_hwi_loc(), fold_convert_loc(), strstr(), and validate_arg().

tree fold_builtin_stxcpy_chk ( location_t  loc,
tree  fndecl,
tree  dest,
tree  src,
tree  size,
tree  maxlen,
bool  ignore,
enum built_in_function  fcode 
)
Fold a call to the __st[rp]cpy_chk builtin.
   DEST, SRC, and SIZE are the arguments to the call.
   IGNORE is true if return value can be ignored.  FCODE is the BUILT_IN_*
   code of the builtin.  If MAXLEN is not NULL, it is maximum length of
   strings passed as second argument.   

References build_call_expr_loc(), build_int_cst(), builtin_decl_explicit(), c_strlen(), fold_convert_loc(), host_integerp(), integer_all_onesp(), len, operand_equal_p(), size_binop_loc(), tree_int_cst_lt(), and validate_arg().

Referenced by fold_builtin_3(), and gimple_fold_builtin().

tree fold_builtin_stxncpy_chk ( location_t  loc,
tree  dest,
tree  src,
tree  len,
tree  size,
tree  maxlen,
bool  ignore,
enum built_in_function  fcode 
)
Fold a call to the __st{r,p}ncpy_chk builtin.  DEST, SRC, LEN, and SIZE
   are the arguments to the call.  If MAXLEN is not NULL, it is maximum
   length passed as third argument. IGNORE is true if return value can be
   ignored. FCODE is the BUILT_IN_* code of the builtin.  

References build_call_expr_loc(), builtin_decl_explicit(), host_integerp(), integer_all_onesp(), len, tree_int_cst_lt(), and validate_arg().

Referenced by fold_builtin_4(), and gimple_fold_builtin().

static tree fold_builtin_tan ( tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_tan ( )
static
Fold function call to builtin tan, tanf, or tanl with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References builtin_mathfn_code(), do_mpfr_arg1(), and validate_arg().

static tree fold_builtin_toascii ( location_t  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_toascii ( )
static
Fold a call to builtin toascii with argument ARG.   

References build_int_cst(), and validate_arg().

static tree fold_builtin_trunc ( location_t  ,
tree  ,
tree   
)
static

Referenced by fold_builtin_1().

static tree fold_builtin_trunc ( )
static
Fold function call to builtin trunc, truncf or truncl with argument ARG.
   Return NULL_TREE if no simplification can be made.   

References build_real(), fold_trunc_transparent_mathfn(), real_trunc(), and validate_arg().

static tree fold_builtin_unordered_cmp ( location_t  loc,
tree  fndecl,
tree  arg0,
tree  arg1,
enum tree_code  unordered_code,
enum tree_code  ordered_code 
)
static
Fold a call to an unordered comparison function such as
   __builtin_isgreater().  FNDECL is the FUNCTION_DECL for the function
   being called and ARG0 and ARG1 are the arguments for the call.
   UNORDERED_CODE and ORDERED_CODE are comparison codes that give
   the opposite of the desired result.  UNORDERED_CODE is used
   for modes that can hold NaNs and ORDERED_CODE is used for
   the rest.   

References fold_convert_loc(), and omit_two_operands_loc().

Referenced by fold_builtin_2().

static tree fold_builtin_varargs ( location_t  loc,
tree  fndecl,
tree  exp,
bool  ignore 
)
static
Builtins with folding operations that operate on "..." arguments
   need special handling; we need to store the arguments in a convenient
   data structure before attempting any folding.  Fortunately there are
   only a few builtins that fall into this category.  FNDECL is the
   function, EXP is the CALL_EXPR for the call, and IGNORE is true if the
   result of the function call is ignored.   

References fold_builtin_fpclassify(), fold_builtin_snprintf_chk(), and fold_builtin_sprintf_chk().

Referenced by fold_builtin_call_array(), and fold_call_expr().

tree fold_call_expr ( )
A wrapper function for builtin folding that prevents warnings for
   "statement without effect" and the like, caused by removing the
   call node earlier than the warning is generated.   

References avoid_folding_inline_builtin(), BUILT_IN_MD, BUILT_IN_NORMAL, fold_builtin_n(), fold_builtin_varargs(), get_callee_fndecl(), and targetm.

Referenced by fold(), gimple_fold_stmt_to_constant_1(), and gimplify_call_expr().

tree fold_call_stmt ( )
A wrapper function for builtin folding that prevents warnings for
   "statement without effect" and the like, caused by removing the
   call node earlier than the warning is generated.   

References avoid_folding_inline_builtin(), BUILT_IN_MD, fold_builtin_n(), gimple_call_arg_ptr(), gimple_call_fndecl(), gimple_call_num_args(), gimple_call_va_arg_pack_p(), gimple_fold_builtin_varargs(), gimple_has_location(), gimple_location(), and targetm.

Referenced by compute_object_sizes(), gimple_fold_builtin(), and record_temporary_equivalences_from_stmts_at_dest().

static tree fold_fixed_mathfn ( )
static
FNDECL is assumed to be builtin which can narrow the FP type of
   the argument, for instance lround((double)f) -> lroundf (f).
   Do the transformation for a call with argument ARG.   

References build_call_expr_loc(), fold_convert_loc(), integer_valued_real_p(), mathfn_built_in(), strip_float_extensions(), and validate_arg().

Referenced by fold_builtin_1(), and fold_builtin_int_roundingfn().

tree fold_fma ( location_t  loc,
tree  type,
tree  arg0,
tree  arg1,
tree  arg2 
)
Fold a fma operation with arguments ARG[012].   

References do_mpfr_arg3().

Referenced by fold_builtin_fma(), and fold_ternary_loc().

static tree fold_trunc_transparent_mathfn ( location_t  ,
tree  ,
tree   
)
static
static tree fold_trunc_transparent_mathfn ( )
static
FNDECL is assumed to be a builtin where truncation can be propagated
   across (for instance floor((double)f) == (double)floorf (f).
   Do the transformation for a call with argument ARG.   

References build_call_expr_loc(), builtin_mathfn_code(), fold_convert_loc(), integer_valued_real_p(), mathfn_built_in(), strip_float_extensions(), and validate_arg().

static enum machine_mode get_builtin_sync_mode ( )
inlinestatic
Reconstitute a mode for a __sync intrinsic operation.  Since the type of
   the pointer in these functions is void*, the tree optimizers may remove
   casts.  The mode computed in expand_builtin isn't reliable either, due
   to __sync_bool_compare_and_swap.

   FCODE_DIFF should be fcode - base, where base is the FOO_1 code for the
   group of builtins.  This gives us log2 of the mode size.   

References mode_for_size().

Referenced by expand_builtin().

static rtx get_memory_rtx ( )
static
Get a MEM rtx for expression EXP which is the address of an operand
   to be used in a string instruction (cmpstrsi, movmemsi, ..).  LEN is
   the maximum length of the block of memory that might be accessed or
   NULL if unknown.   

References build_array_type(), build_int_cst(), build_range_type(), exp(), expand_expr(), EXPAND_NORMAL, gen_rtx_MEM(), get_base_address(), is_gimple_mem_ref_addr(), ptr_mode, set_mem_alias_set(), and set_mem_attributes().

unsigned int get_object_alignment ( )
Return the alignment in bits of EXP, an object.   

References get_object_alignment_1(), and HOST_WIDE_INT.

Referenced by access_precludes_ipa_sra_p(), expand_assignment(), expand_expr_real_1(), may_be_unaligned_p(), and not_size_aligned().

bool get_object_alignment_1 ( tree  exp,
unsigned int *  alignp,
unsigned HOST_WIDE_INT bitposp 
)
For a memory reference expression EXP compute values M and N such that M
   divides (&EXP - N) and such that N < M.  If these numbers can be determined,
   store M in alignp and N in *BITPOSP and return true.  Otherwise return false
   and store BITS_PER_UNIT to *alignp and any bit-offset to *bitposp.   

References get_object_alignment_2().

Referenced by build_ref_for_offset(), get_object_alignment(), get_pointer_modulus_and_residue(), replace_ref(), and set_mem_attributes_minus_bitpos().

static bool get_object_alignment_2 ( tree  exp,
unsigned int *  alignp,
unsigned HOST_WIDE_INT bitposp,
bool  addr_p 
)
static
Compute values M and N such that M divides (address of EXP - N) and such
   that N < M.  If these numbers can be determined, store M in alignp and N in
   *BITPOSP and return true.  Otherwise return false and store BITS_PER_UNIT to
   *alignp and any bit-offset to *bitposp.

   Note that the address (and thus the alignment) computed here is based
   on the address to which a symbol resolves, whereas DECL_ALIGN is based
   on the address at which an object is actually located.  These two
   addresses are not always the same.  For example, on ARM targets,
   the address &foo of a Thumb function foo() has the lowest bit set,
   whereas foo() itself starts on an even address.

   If ADDR_P is true we are taking the address of the memory reference EXP
   and thus cannot rely on the access taking place.   

References get_inner_reference(), get_pointer_alignment_1(), host_integerp(), HOST_WIDE_INT, double_int::low, mem_ref_offset(), offset, ptrmemfunc_vbit_in_pfn, and tree_low_cst().

Referenced by get_object_alignment_1(), and get_pointer_alignment_1().

unsigned int get_pointer_alignment ( )
Return the alignment in bits of EXP, a pointer valued expression.
   The alignment returned is, by default, the alignment of the thing that
   EXP points to.  If it is not a POINTER_TYPE, 0 is returned.

   Otherwise, look at the expression to see if we can do better, i.e., if the
   expression is actually pointing at an object whose alignment is tighter.   

References ptr_info_def::align, get_pointer_alignment_1(), and HOST_WIDE_INT.

Referenced by expand_builtin_memcmp(), expand_builtin_memcpy(), expand_builtin_memory_chk(), expand_builtin_mempcpy_args(), expand_builtin_memset_args(), expand_builtin_strcmp(), expand_builtin_strlen(), expand_builtin_strncmp(), expand_builtin_strncpy(), expand_one_register_var(), fold_builtin_memory_op(), fold_builtin_memset(), get_builtin_sync_mem(), gimple_expand_cfg(), gimple_stringops_transform(), simplify_builtin_call(), and vect_compute_data_ref_alignment().

bool get_pointer_alignment_1 ( tree  exp,
unsigned int *  alignp,
unsigned HOST_WIDE_INT bitposp 
)
For a pointer valued expression EXP compute values M and N such that M
   divides (EXP - N) and such that N < M.  If these numbers can be determined,
   store M in alignp and N in *BITPOSP and return true.  Return false if
   the results are just a conservative approximation.

   If EXP is not a pointer, false is returned too.   

References get_object_alignment_2(), and get_ptr_info_alignment().

Referenced by get_object_alignment_2(), get_pointer_alignment(), get_value_from_alignment(), and ipa_modify_call_arguments().

tree gimple_fold_builtin_snprintf_chk ( gimple  stmt,
tree  maxlen,
enum built_in_function  fcode 
)
Fold a call STMT to {,v}snprintf.  Return NULL_TREE if
   a normal call should be emitted rather than expanding the function
   inline.  FCODE is either BUILT_IN_SNPRINTF_CHK or
   BUILT_IN_VSNPRINTF_CHK.  If MAXLEN is not NULL, it is maximum length
   passed as second argument.   

References fold_builtin_snprintf_chk_1(), gimple_call_arg_ptr(), gimple_call_num_args(), and gimple_location().

Referenced by gimple_fold_builtin(), and gimple_fold_builtin_varargs().

static tree gimple_fold_builtin_sprintf_chk ( )
static
Fold a call STMT to __{,v}sprintf_chk.  Return NULL_TREE if
   a normal call should be emitted rather than expanding the function
   inline.  FCODE is either BUILT_IN_SPRINTF_CHK or BUILT_IN_VSPRINTF_CHK.   

References fold_builtin_sprintf_chk_1(), gimple_call_arg_ptr(), gimple_call_num_args(), and gimple_location().

Referenced by gimple_fold_builtin_varargs().

static tree gimple_fold_builtin_varargs ( tree  fndecl,
gimple  stmt,
bool  ignore 
)
static
Builtins with folding operations that operate on "..." arguments
   need special handling; we need to store the arguments in a convenient
   data structure before attempting any folding.  Fortunately there are
   only a few builtins that fall into this category.  FNDECL is the
   function, EXP is the CALL_EXPR for the call, and IGNORE is true if the
   result of the function call is ignored.   

References gimple_fold_builtin_snprintf_chk(), and gimple_fold_builtin_sprintf_chk().

Referenced by fold_call_stmt().

bool gnu_libc_has_function ( )
static bool integer_valued_real_p ( tree  )
static
static bool integer_valued_real_p ( )
static
Return true if the floating point expression T has an integer value.
   We also allow +Inf, -Inf and NaN to be considered integer values.   

References builtin_mathfn_code(), integer_valued_real_p(), and real_isinteger().

static enum insn_code interclass_mathfn_icode ( )
static
Given an interclass math builtin decl FNDECL and it's argument ARG
   return an RTL instruction code that implements the functionality.
   If that isn't possible or available return CODE_FOR_nothing.   

References optab_handler(), and unknown_optab.

Referenced by expand_builtin_interclass_mathfn(), and fold_builtin_interclass_mathfn().

bool is_builtin_fn ( )
Return true if DECL is a function symbol representing a built-in.   

Referenced by instrument_strlen_call(), is_gimple_builtin_call(), lto_symtab_prevailing_decl(), and write_symbol().

static bool is_builtin_name ( )
static
Return true if NAME starts with __builtin_ or __sync_.   

Referenced by called_as_built_in().

bool is_inexpensive_builtin ( )
Return true if DECL is a builtin that is not expensive, i.e., they are
   most probably expanded inline into reasonably simple code.  This is a
   superset of is_simple_builtin.   

References BUILT_IN_MD, BUILT_IN_NORMAL, and is_simple_builtin().

Referenced by estimate_num_insns(), loop_body_includes_call(), num_calls(), and tree_estimate_loop_size().

bool is_simple_builtin ( )
Return true if DECL is a builtin that expands to a constant or similarly
   simple code.   

References BUILT_IN_NORMAL.

Referenced by estimate_num_insns(), and is_inexpensive_builtin().

static tree mathfn_built_in_1 ( )
static
Return mathematic function equivalent to FN but operating directly on TYPE,
   if available.  If IMPLICIT is true use the implicit builtin declaration,
   otherwise use the explicit declaration.  If we can't do the conversion,
   return zero.   

References builtin_decl_explicit(), and builtin_decl_implicit_p().

Referenced by expand_builtin_int_roundingfn_2(), fold_builtin_classify(), and mathfn_built_in().

static void maybe_emit_chk_warning ( tree  ,
enum  built_in_function 
)
static

Referenced by expand_builtin().

static void maybe_emit_chk_warning ( )
static
Emit warning if a buffer overflow is detected at compile time.   

References c_strlen(), get_callee_fndecl(), host_integerp(), integer_all_onesp(), len, tree_int_cst_lt(), tree_nonartificial_location(), and warning_at().

static void maybe_emit_free_warning ( tree  )
static

Referenced by expand_builtin().

static void maybe_emit_free_warning ( )
static
Emit warning if a free is called with address of a variable.   

References get_base_address(), tree_nonartificial_location(), and warning_at().

static void maybe_emit_sprintf_chk_warning ( tree  ,
enum  built_in_function 
)
static

Referenced by expand_builtin().

static void maybe_emit_sprintf_chk_warning ( )
static
Emit warning if a buffer overflow is detected at compile time
   in __sprintf_chk/__vsprintf_chk calls.   

References build_int_cstu(), c_getstr(), c_strlen(), get_callee_fndecl(), host_integerp(), init_target_chars(), integer_all_onesp(), len, strlen(), tree_int_cst_lt(), tree_nonartificial_location(), and warning_at().

bool no_c99_libc_has_function ( )
static bool readonly_data_expr ( tree  )
static
static bool readonly_data_expr ( )
static
Returns true is EXP represents data that would potentially reside
   in a readonly section.   

References decl_readonly_section(), and get_base_address().

static rtx result_vector ( int  ,
rtx   
)
static
static rtx result_vector ( )
static
Create a vector describing the result block RESULT.  If SAVEP is true,
   the result block is used to save the values; otherwise it is used to
   restore the values.   

References gen_rtvec_v(), and gen_rtx_REG().

static tree rewrite_call_expr ( location_t  ,
tree  ,
int  ,
tree  ,
int  ,
  ... 
)
static
static tree rewrite_call_expr ( )
static
Construct a new CALL_EXPR using the tail of the argument list of EXP
   along with N new arguments specified as the "..." parameters.  SKIP
   is the number of arguments in EXP to be omitted.  This function is used
   to do varargs-to-varargs transformations.   

References rewrite_call_expr_valist().

static tree rewrite_call_expr_array ( location_t  loc,
int  oldnargs,
tree args,
int  skip,
tree  fndecl,
int  n,
  ... 
)
static
Construct a new CALL_EXPR to FNDECL using the tail of the argument
   list ARGS along with N new arguments specified as the "..."
   parameters.  SKIP is the number of arguments in ARGS to be omitted.
   OLDNARGS is the number of elements in ARGS.   

References rewrite_call_expr_valist().

Referenced by fold_builtin_snprintf_chk_1(), and fold_builtin_sprintf_chk_1().

static tree rewrite_call_expr_valist ( location_t  loc,
int  oldnargs,
tree args,
int  skip,
tree  fndecl,
int  n,
va_list  newargs 
)
static
Construct a new CALL_EXPR to FNDECL using the tail of the argument
   list ARGS along with N new arguments in NEWARGS.  SKIP is the number
   of arguments in ARGS to be omitted.  OLDNARGS is the number of
   elements in ARGS.   

References buffer, and build_call_expr_loc_array().

Referenced by rewrite_call_expr(), and rewrite_call_expr_array().

static rtx round_trampoline_addr ( )
static
Given a trampoline address, make sure it satisfies TRAMPOLINE_ALIGNMENT.   

References expand_simple_binop(), gen_reg_rtx(), and OPTAB_LIB_WIDEN.

Referenced by expand_builtin_adjust_trampoline(), and expand_builtin_init_trampoline().

void set_builtin_user_assembler_name ( )
Look up the function in builtin_decl that corresponds to DECL
   and set ASMSPEC as its user assembler name.  DECL must be a
   function decl that declares a builtin.   

References BUILT_IN_NORMAL, builtin_decl_explicit(), init_block_clear_fn(), init_block_move_fn(), mode_for_size(), set_optab_libfunc(), set_user_assembler_libfunc(), and set_user_assembler_name().

Referenced by streamer_get_builtin_tree().

static tree stabilize_va_list_loc ( location_t  ,
tree  ,
int   
)
static
static tree stabilize_va_list_loc ( )
static
Make it easier for the backends by protecting the valist argument
   from multiple evaluations.   

References build_fold_addr_expr_with_type_loc(), build_int_cst(), build_pointer_type(), cfun, function::decl, save_expr(), and targetm.

tree std_build_builtin_va_list ( void  )
The "standard" definition of va_list is void*.   
tree std_canonical_va_list_type ( )
The "standard" type of va_list is va_list_type_node.   

References type().

void std_expand_builtin_va_start ( )
The "standard" implementation of va_start: just assign `nextarg' to
   the variable.   

References convert_move(), expand_expr(), and EXPAND_WRITE.

Referenced by expand_builtin_va_start().

tree std_fn_abi_va_list ( )
The "standard" abi va_list is va_list_type_node.   
tree std_gimplify_va_arg_expr ( tree  valist,
tree  type,
gimple_seq pre_p,
gimple_seq post_p 
)
The "standard" implementation of va_arg: read the value from the
   current (padded) address and increment by the (padded) size.   

References build_int_cst(), build_pointer_type(), build_va_arg_indirect_ref(), build_variant_type_copy(), fb_rvalue, get_initialized_tmp_var(), gimplify_and_add(), gimplify_expr(), HOST_WIDE_INT, input_location, integer_zerop(), is_gimple_val(), pass_by_reference(), size_in_bytes(), and targetm.

static int target_char_cast ( tree  ,
char *   
)
static
static int target_char_cast ( )
static
Cast a target constant CST to target CHAR and if that value fits into
   host char type, return zero and put that value into variable pointed to by
   P.   

References HOST_BITS_PER_CHAR, HOST_BITS_PER_WIDE_INT, and HOST_WIDE_INT.

static enum type_class type_to_class ( tree  )
static
static bool validate_arg ( const_tree  ,
enum tree_code  code 
)
static

Referenced by fold_builtin_1(), fold_builtin_2(), fold_builtin_3(), fold_builtin_4(), fold_builtin_abs(), fold_builtin_bitop(), fold_builtin_bswap(), fold_builtin_bzero(), fold_builtin_cabs(), fold_builtin_carg(), fold_builtin_cbrt(), fold_builtin_ccos(), fold_builtin_ceil(), fold_builtin_cexp(), fold_builtin_classify(), fold_builtin_copysign(), fold_builtin_cos(), fold_builtin_cosh(), fold_builtin_cproj(), fold_builtin_exponent(), fold_builtin_fabs(), fold_builtin_floor(), fold_builtin_fma(), fold_builtin_fmin_fmax(), fold_builtin_fprintf(), fold_builtin_fputs(), fold_builtin_frexp(), fold_builtin_hypot(), fold_builtin_int_roundingfn(), fold_builtin_interclass_mathfn(), fold_builtin_isascii(), fold_builtin_isdigit(), fold_builtin_load_exponent(), fold_builtin_logarithm(), fold_builtin_logb(), fold_builtin_memchr(), fold_builtin_memcmp(), fold_builtin_memory_chk(), fold_builtin_memory_op(), fold_builtin_memset(), fold_builtin_modf(), fold_builtin_nan(), fold_builtin_object_size(), fold_builtin_pow(), fold_builtin_powi(), fold_builtin_printf(), fold_builtin_round(), fold_builtin_signbit(), fold_builtin_significand(), fold_builtin_sincos(), fold_builtin_snprintf(), fold_builtin_snprintf_chk_1(), fold_builtin_sprintf(), fold_builtin_sprintf_chk_1(), fold_builtin_sqrt(), fold_builtin_stpcpy(), fold_builtin_strcat(), fold_builtin_strcat_chk(), fold_builtin_strchr(), fold_builtin_strcmp(), fold_builtin_strcpy(), fold_builtin_strcspn(), fold_builtin_strlen(), fold_builtin_strncat(), fold_builtin_strncat_chk(), fold_builtin_strncmp(), fold_builtin_strncpy(), fold_builtin_strpbrk(), fold_builtin_strrchr(), fold_builtin_strspn(), fold_builtin_strstr(), fold_builtin_stxcpy_chk(), fold_builtin_stxncpy_chk(), fold_builtin_tan(), fold_builtin_toascii(), fold_builtin_trunc(), fold_fixed_mathfn(), fold_trunc_transparent_mathfn(), validate_arglist(), and validate_gimple_arglist().

static bool validate_arg ( )
static
Validate a single argument ARG against a tree code CODE representing
   a type.   
bool validate_gimple_arglist ( )
This function validates the types of a function call argument list
   against a specified list of tree_codes.  If the last specifier is a 0,
   that represents an ellipses, otherwise the last specifier must be a
   VOID_TYPE.

   This is the GIMPLE version of validate_arglist.  Eventually we want to
   completely convert builtins.c to work from GIMPLEs and the tree based
   validate_arglist will then be removed.   

References gimple_call_arg(), gimple_call_num_args(), and validate_arg().

Referenced by interesting_stringop_to_profile_p().

static bool var_decl_component_p ( )
static
Return true if VAR is a VAR_DECL or a component thereof.   

References handled_component_p().

Referenced by fold_builtin_memory_op(), and fold_builtin_memset().


Variable Documentation

const char* const built_in_class_names[4] = {"NOT_BUILT_IN", "BUILT_IN_FRONTEND", "BUILT_IN_MD", "BUILT_IN_NORMAL"}
Define the names of the builtin function types and codes.   

Referenced by print_node().

const char* built_in_names[(int) END_BUILTINS]
Initial value:
{
#include "builtins.def"
}
Names for the above.   

Referenced by build_common_builtin_nodes(), and print_node().

builtin_info_type builtin_info
Setup an array of _DECL trees, make sure each element is
   initialized to NULL_TREE.   
struct target_builtins default_target_builtins
bool force_folding_builtin_constant_p
Non-zero if __builtin_constant_p should be folded right away.   
alias_set_type setjmp_alias_set = -1
static
Alias set used for setjmp buffer.   
unsigned HOST_WIDE_INT target_c
static

Referenced by init_target_chars().

unsigned HOST_WIDE_INT target_newline
static

Referenced by init_target_chars().

unsigned HOST_WIDE_INT target_percent
static

Referenced by init_target_chars().

char target_percent_c[3]
static
char target_percent_s[3]
static
char target_percent_s_newline[4]
static
unsigned HOST_WIDE_INT target_s
static

Referenced by init_target_chars().

struct target_builtins* this_target_builtins = &default_target_builtins