GCC Middle and Back End API Reference
complex_mul_pattern Class Reference
Inheritance diagram for complex_mul_pattern:
Collaboration diagram for complex_mul_pattern:

Public Member Functions

void build (vec_info *) final override
 

Static Public Member Functions

static internal_fn matches (complex_operation_t op, slp_tree_to_load_perm_map_t *, slp_compat_nodes_map_t *, slp_tree *, vec< slp_tree > *)
 
static vect_patternrecognize (slp_tree_to_load_perm_map_t *, slp_compat_nodes_map_t *, slp_tree *)
 
static vect_patternmkInstance (slp_tree *node, vec< slp_tree > *m_ops, internal_fn ifn)
 
static internal_fn matches (complex_operation_t op, slp_tree_to_load_perm_map_t *, slp_tree *, vec< slp_tree > *)
 

Protected Member Functions

 complex_mul_pattern (slp_tree *node, vec< slp_tree > *m_ops, internal_fn ifn)
 

Protected Attributes

auto_vec< slp_treem_workset
 
unsigned m_num_args
 
internal_fn m_ifn
 
slp_treem_node
 
vec< slp_treem_ops
 

Constructor & Destructor Documentation

◆ complex_mul_pattern()

complex_mul_pattern::complex_mul_pattern ( slp_tree * node,
vec< slp_tree > * m_ops,
internal_fn ifn )
inlineprotected

References vect_pattern::m_num_args.

Referenced by mkInstance(), and recognize().

Member Function Documentation

◆ build()

void complex_mul_pattern::build ( vec_info * vinfo)
finaloverridevirtual

◆ matches() [1/2]

internal_fn complex_mul_pattern::matches ( complex_operation_t op,
slp_tree_to_load_perm_map_t * perm_cache,
slp_compat_nodes_map_t * compat_cache,
slp_tree * node,
vec< slp_tree > * ops )
static
Pattern matcher for trying to match complex multiply and complex multiply
and accumulate pattern in SLP tree.  If the operation matches then IFN
is set to the operation it matched and the arguments to the two
replacement statements are put in m_ops.

If no match is found then IFN is set to IFN_LAST and m_ops is unchanged.

This function matches the patterns shaped as:

double ax = (b[i+1] * a[i]);
double bx = (a[i+1] * b[i]);

c[i] = c[i] - ax;
c[i+1] = c[i+1] + bx;

If a match occurred then TRUE is returned, else FALSE.  The initial match is
expected to be in OP1 and the initial match operands in args0.   

References CONJ_NONE, CONJ_SND, FLOAT_TYPE_P, FP_CONTRACT_FAST, IFN_LAST, linear_loads_p(), MINUS_PLUS, NULL, PERM_EVENEVEN, PERM_EVENODD, PERM_ODDEVEN, PERM_TOP, SLP_TREE_CHILDREN, SLP_TREE_VECTYPE, vect_match_expression_p(), vect_pattern_validate_optab(), and vect_validate_multiplication().

Referenced by recognize(), and complex_operations_pattern::recognize().

◆ matches() [2/2]

static internal_fn complex_pattern::matches ( complex_operation_t op,
slp_tree_to_load_perm_map_t * ,
slp_tree * ,
vec< slp_tree > *  )
staticinherited

◆ mkInstance()

static vect_pattern * complex_mul_pattern::mkInstance ( slp_tree * node,
vec< slp_tree > * m_ops,
internal_fn ifn )
inlinestatic

◆ recognize()

vect_pattern * complex_mul_pattern::recognize ( slp_tree_to_load_perm_map_t * perm_cache,
slp_compat_nodes_map_t * compat_cache,
slp_tree * node )
static
Attempt to recognize a complex mul pattern.   

References complex_mul_pattern(), IFN_LAST, matches(), NULL, and vect_detect_pair_op().

Field Documentation

◆ m_ifn

internal_fn vect_pattern::m_ifn
protectedinherited

◆ m_node

slp_tree* vect_pattern::m_node
protectedinherited

◆ m_num_args

◆ m_ops

◆ m_workset

auto_vec<slp_tree> complex_pattern::m_workset
protectedinherited

Referenced by complex_pattern::build().


The documentation for this class was generated from the following file: