20#ifndef GCC_OPTABS_QUERY_H
21#define GCC_OPTABS_QUERY_H
23#include "insn-opinit.h"
40 unsigned scode = (op << 20) | mode;
42 return raw_optab_handler (scode);
51 machine_mode from_mode)
53 unsigned scode = (op << 20) | (from_mode << 10) | to_mode;
55 return raw_optab_handler (scode);
78 return (unoptab == negv_optab
79 || unoptab == absv_optab);
87 return (binoptab == addv_optab
88 || binoptab == subv_optab
89 || binoptab == smulv_optab);
98 optab tab = uns ? vec_cmpu_optab : vec_cmp_optab;
146 unsigned HOST_WIDE_INT, machine_mode);
149 HOST_WIDE_INT, HOST_WIDE_INT, machine_mode);
151enum insn_code
can_extend_p (machine_mode, machine_mode,
int);
152enum insn_code
can_float_p (machine_mode, machine_mode,
int);
153enum insn_code
can_fix_p (machine_mode, machine_mode,
int,
bool *);
161#define find_widening_optab_handler(A, B, C) \
162 find_widening_optab_handler_and_mode (A, B, C, NULL)
186 const T &from_mode, T *found_mode)
190 (op, machine_mode (to_mode), machine_mode (from_mode), &tmp);
191 if (icode != CODE_FOR_nothing && found_mode)
Definition machmode.h:465
Definition machmode.h:437
Definition vec-perm-indices.h:51
optimization_type
Definition coretypes.h:282
@ unknown_optab
Definition gensupport.h:58
T as_a(U *p)
Definition is-a.h:253
bool trapv_binoptab_p(optab binoptab)
Definition optabs-query.h:85
bool can_implement_p(optab, machine_mode)
Definition optabs-query.cc:852
bool get_best_mem_extraction_insn(extraction_insn *, enum extraction_pattern, HOST_WIDE_INT, HOST_WIDE_INT, machine_mode)
Definition optabs-query.cc:262
enum insn_code find_widening_optab_handler_and_mode(optab, machine_mode, machine_mode, machine_mode *)
Definition optabs-query.cc:474
bool can_open_code_p(optab, machine_mode)
Definition optabs-query.cc:825
bool can_vec_perm_const_p(machine_mode, machine_mode, const vec_perm_indices &, bool=true)
Definition optabs-query.cc:424
bool lshift_cheap_p(bool)
Definition optabs-query.cc:650
enum insn_code get_vec_cmp_icode(machine_mode vmode, machine_mode mask_mode, bool uns)
Definition optabs-query.h:96
enum insn_code can_float_p(machine_mode, machine_mode, int)
Definition optabs-query.cc:295
bool can_vec_extract(machine_mode, machine_mode)
Definition optabs-query.cc:760
enum insn_code get_vec_cmp_eq_icode(machine_mode vmode, machine_mode mask_mode)
Definition optabs-query.h:106
enum insn_code can_extend_p(machine_mode, machine_mode, int)
Definition optabs-query.cc:280
bool can_vec_perm_var_p(machine_mode)
Definition optabs-query.cc:382
bool can_conditionally_move_p(machine_mode mode)
Definition optabs-query.cc:348
opt_machine_mode get_absneg_bit_mode(optab, machine_mode, scalar_float_mode, int *)
Definition optabs-query.cc:793
bool can_compare_and_swap_p(machine_mode, bool)
Definition optabs-query.cc:589
opt_machine_mode qimode_for_vec_perm(machine_mode)
Definition optabs-query.cc:359
enum insn_code can_fix_p(machine_mode, machine_mode, int, bool *)
Definition optabs-query.cc:310
enum insn_code convert_optab_handler(convert_optab op, machine_mode to_mode, machine_mode from_mode)
Definition optabs-query.h:50
enum insn_code optab_handler(optab op, machine_mode mode)
Definition optabs-query.h:38
bool convert_optab_p(optab op)
Definition optabs-query.h:29
int can_mult_highpart_p(machine_mode, bool)
Definition optabs-query.cc:520
extraction_pattern
Definition optabs-query.h:121
@ EP_extzv
Definition optabs-query.h:121
@ EP_insv
Definition optabs-query.h:121
@ EP_extv
Definition optabs-query.h:121
enum insn_code get_vcond_mask_icode(machine_mode vmode, machine_mode mmode)
Definition optabs-query.h:115
bool can_atomic_load_p(machine_mode)
Definition optabs-query.cc:632
bool trapv_unoptab_p(optab unoptab)
Definition optabs-query.h:76
enum insn_code direct_optab_handler(direct_optab op, machine_mode mode)
Definition optabs-query.h:65
bool get_best_reg_extraction_insn(extraction_insn *, enum extraction_pattern, unsigned HOST_WIDE_INT, machine_mode)
Definition optabs-query.cc:243
bool supports_vec_gather_load_p(machine_mode=E_VOIDmode, vec< int > *=nullptr)
Definition optabs-query.cc:704
bool supports_vec_scatter_store_p(machine_mode=E_VOIDmode)
Definition optabs-query.cc:738
bool selector_fits_mode_p(machine_mode, const vec_perm_indices &)
Definition optabs-query.cc:370
bool can_atomic_exchange_p(machine_mode, bool)
Definition optabs-query.cc:612
#define gcc_assert(EXPR)
Definition system.h:814