-
- Downloads
Add vect_recog_cond_expr_convert_pattern.
The pattern converts (cond (cmp a b) (convert c) (convert d)) to (convert (cond (cmp a b) c d)) when 1) types_match (c, d) 2) single_use for (convert c) and (convert d) 3) TYPE_PRECISION (TREE_TYPE (c)) == TYPE_PRECISION (TREE_TYPE (a)) 4) INTEGERAL_TYPE_P (TREE_TYPE (c)) The pattern can save packing of mask and data(partial for data, 2 vs 1). gcc/ChangeLog: PR target/103771 * match.pd (cond_expr_convert_p): New match. * tree-vect-patterns.cc (gimple_cond_expr_convert_p): Declare. (vect_recog_cond_expr_convert_pattern): New. gcc/testsuite/ChangeLog: * gcc.target/i386/pr103771-2.c: New test. * gcc.target/i386/pr103771-3.c: New test.
Showing
- gcc/match.pd 14 additions, 0 deletionsgcc/match.pd
- gcc/testsuite/gcc.target/i386/pr103771-2.c 8 additions, 0 deletionsgcc/testsuite/gcc.target/i386/pr103771-2.c
- gcc/testsuite/gcc.target/i386/pr103771-3.c 21 additions, 0 deletionsgcc/testsuite/gcc.target/i386/pr103771-3.c
- gcc/tree-vect-patterns.cc 96 additions, 0 deletionsgcc/tree-vect-patterns.cc
Loading
Please register or sign in to comment