This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] [4.2 projects] vectorize type conversions - 6/6
- From: Dorit Nuzman <DORIT at il dot ibm dot com>
- To: Diego Novillo <dnovillo at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org, Richard Henderson <rth at redhat dot com>, Janis Johnson <janis187 at us dot ibm dot com>
- Date: Sat, 19 Aug 2006 00:56:30 +0300
- Subject: Re: [patch] [4.2 projects] vectorize type conversions - 6/6
Diego Novillo <dnovillo@redhat.com> wrote on 18/08/2006 06:19:41 PM:
> Dorit Nuzman wrote on 02/17/06 11:36:
>
> > + /* Widening vector multiplication.
> > + The two operands are vectors with N elements of size S.
Multiplying the
> > + elements of the two vectors will result in N products of size 2*S.
> > + VEC_WIDEN_MULT_HI_EXPR computes the N/2 high products.
> > + VEC_WIDEN_MULT_LO_EXPR computes the N/2 low products. */
> > + DEFTREECODE (VEC_WIDEN_MULT_HI_EXPR, "widen_mult_hi_expr",
tcc_binary, 2)
> > + DEFTREECODE (VEC_WIDEN_MULT_LO_EXPR, "widen_mult_hi_expr",
tcc_binary, 2)
> > +
> > + /* Unpack (extract and promote/widen) the high/low elements of
> the input vector
> > + into the output vector. The input vector has twice as many
elements
> > + as the output vector, that are half the size of the elements
> > + of the output vector. This is used to support type promotion. */
> > + DEFTREECODE (VEC_UNPACK_HI_EXPR, "vec_unpack_hi_expr", tcc_unary, 1)
> > + DEFTREECODE (VEC_UNPACK_LO_EXPR, "vec_unpack_lo_expr", tcc_unary, 1)
> > +
> How many more codes do you folks are planning to add? We already had to
> resort to sub-codes for OpenMP clauses. We need to move to a 16-bit
> type for the code field, but in the meantime I think we are getting very
> close to 255 (around 230, IIRC).
>
The strided-accesses patch adds 4 more tree-codes (extract-even/odd,
interleave-high/low). We haven't finalized our plans for 4.3, but most of
the enhancements we're considering do not involve new tree-codes (e.g.
basic-block vectorization (like SLP), outer-loop vectorization, adding a
cost-model) .
In autovect branch we have one more tree code that we haven't merged to
mainline - a subtract and saturate. It's not on our top priority list, but
others may be intersted in adding more saturation tree-codes.
We also never got around to implementing misalignment for stores, which
would require adding a realign_store (like the realign_load).
Other than that - there's the tree-codes proposed here -
http://gcc.gnu.org/ml/gcc/2004-08/msg00317.html, that we'd potentially want
to add in the future.
>
> > *************** dump_generic_node (pretty_printer *buffe
> > *** 1858,1863 ****
> > --- 1858,1891 ----
> > pp_string (buffer, " > ");
> > break;
> >
> > + case VEC_WIDEN_MULT_HI_EXPR:
> > + pp_string (buffer, " VEC_WIDEN_MULT_HI_EXPR < ");
> > + dump_generic_node (buffer, TREE_OPERAND (node, 0), spc,
> flags, false);
> > + pp_string (buffer, " , ");
> >
> s/" , "/", "/ everywhere.
>
>
> > /* Utility functions for the analyses. */
> > static bool exist_non_indexing_operands_for_use_p (tree, tree);
> > ! static void vect_mark_relevant
> > ! (VEC(tree,heap) **, tree, enum vect_relevant, bool);
> > ! static bool vect_stmt_relevant_p
> > ! (tree, loop_vec_info, enum vect_relevant *, bool *);
> > static tree vect_get_loop_niters (struct loop *, tree *);
> > static bool vect_analyze_data_ref_dependence
> > (struct data_dependence_relation *, loop_vec_info);
> >
> No forward declarations, if you can avoid them. Only when circularity
> requires it.
>
> > --- 1447,1460 ----
> >
> > static void
> > vect_mark_relevant (VEC(tree,heap) **worklist, tree stmt,
> > ! enum vect_relevant relevant, bool live_p)
> > {
> > stmt_vec_info stmt_info = vinfo_for_stmt (stmt);
> > ! enum vect_relevant save_relevant = STMT_VINFO_RELEVANT (stmt_info);
> > bool save_live_p = STMT_VINFO_LIVE_P (stmt_info);
> >
> > if (vect_print_dump_info (REPORT_DETAILS))
> > ! fprintf (vect_dump, "mark relevant %d, live %d.",relevant,
live_p);
> >
> s/,relevant/, relevant/
>
>
> > + enum vect_relevant {
> > + vect_unused_in_loop = 0,
> > + vect_used_by_reduction,
> > + vect_used_in_loop
> > + };
> > +
> >
> Missing documentation comment.
>
> > /* Indicates whether this stmts is part of a computation
whoseresult is
> > used outside the loop. */
> > --- 193,199 ----
> > /* Not all stmts in the loop need to be vectorized. e.g, the
> incrementation
> >
> s/incrementation/increment/
>
>
> > *************** static bool vect_is_simple_cond (tree, l
> > *** 63,68 ****
> > --- 63,70 ----
> > static void update_vuses_to_preheader (tree, struct loop*);
> > static void vect_create_epilog_for_reduction (tree, tree, enum
> tree_code, tree);
> > static tree get_initial_def_for_reduction (tree, tree, tree *);
> > + static tree vect_gen_widened_results_half (enum tree_code, tree,
> tree, tree,
> > + tree, int, tree, block_stmt_iterator *, tree);
> >
> Forward declaration of static functions again.
>
> > + }
> > + new_stmt = build2 (MODIFY_EXPR, vectype, vec_dest, expr);
> >
> s/vectype/void_type_node/
>
>
> > + scalar_dest = TREE_OPERAND (stmt, 0);
> > + vectype_out = get_vectype_for_scalar_type (TREE_TYPE
(scalar_dest));
> > + nunits_out = TYPE_VECTOR_SUBPARTS (vectype_out);
> > + if (nunits_out != nunits_in/2) /* FORNOW */
> > + return false;
> > +
> nunits_in / 2
>
> > + if (!vec_stmt) /* transformation not required. */
> > + {
> >
> Comment inside the if().
>
> > + STMT_VINFO_TYPE (stmt_info) = type_promotion_vec_info_type;
> > + return true;
> > + }
> > +
> > + /** Transform. **/
> > +
> /* Transform. */
>
> > + /* Arguments are ready. Create the new vector stmt. We
> are creating
> > + two vector defs because the widened result does not fit
> in one vector.
> > + The vectorized stmt can be expressed as a call to a
> taregt builtin,
> > + or a using a tree-code.
> > + */
> >
> Closing comment should be '. */'
>
>
> > + CODE1 and CODE2 are CALL_EXPR.
> > + */
> > +
> >
> Likewise.
>
>
> > + of {mult_even,mult_odd} generate the following vectors:
> > + vect1: [res1,res3,res5,res7], vect2: [res2,res4,res6,res8].
> > + */
> > +
> Likewise.
>
> The comment lines seem a bit too wide. Do they fit in 80 columns?
>
>
> > + c2 = VEC_WIDEN_MULT_HI_EXPR;
> > + c1 = VEC_WIDEN_MULT_LO_EXPR;
> > + }
> > + break;
> > + case NOP_EXPR:
> > + if (BYTES_BIG_ENDIAN)
> >
> Vertical spacing between cases.
>
> > + switch (TYPE_MODE (type))
> > + {
> > + case V8HImode:
> > + return TYPE_UNSIGNED (type) ?
> > + rs6000_builtin_decls[ALTIVEC_BUILTIN_VMULEUH] :
> > + rs6000_builtin_decls[ALTIVEC_BUILTIN_VMULESH];
> > + case V16QImode:
> >
> Likewise.
>
> > + case V8HImode:
> > + return TYPE_UNSIGNED (type) ?
> > + rs6000_builtin_decls[ALTIVEC_BUILTIN_VMULOUH] :
> > + rs6000_builtin_decls[ALTIVEC_BUILTIN_VMULOSH];
> > + case V16QImode:
> >
> Likewise.
>
> > + If this hook is defined, the autovectorizer will use it along with
the
> > + @code{TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_ODD} target hook when
vectorizing
> > + widening multiplication in cases that the order of the results
> does not have to be
> > + preserved (e.g. used only by a reuction computation). Otherwise, the
> >
> s/reuction/reduction/
>
>
> > + If this hook is defined, the autovectorizer will use it along with
the
> > + @code{TARGET_VECTORIZE_BUILTIN_MUL_WIDEN_EVEN} target hook when
> vectorizing
> > + widening multiplication in cases that the order of the results
> does not have to be
> > + preserved (e.g. used only by a reuction computation). Otherwise, the
> >
> s/reuction/reduction/
>
> You are missing documentation on the new tree codes. In c-tree.texi.
>
>
> > Index: testsuite/lib/target-supports.exp
> > ===================================================================
> > *** testsuite/lib/target-supports.exp (revision 111135)
> > --- testsuite/lib/target-supports.exp (working copy)
> > *************** proc check_effective_target_vect_no_bitw
> > *** 1436,1451 ****
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *short* args into *int* result, 0 otherwise.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_hi_to_si { } {
> > global et_vect_widen_sum_hi_to_si
> > !
> > if [info exists et_vect_widen_sum_hi_to_si_saved] {
> > verbose "check_effective_target_vect_widen_sum_hi_to_si:
> using cached result" 2
> > } else {
> > ! set et_vect_widen_sum_hi_to_si_saved 0
> > if { [istarget powerpc*-*-*]
> > || [istarget ia64-*-*] } {
> > set et_vect_widen_sum_hi_to_si_saved 1
> > --- 1436,1453 ----
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *short* args into *int* result, 0 otherwise.
> > + # A target can also support this widening summation if it can support
> > + # promotion (unpacking) from shorts to ints.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_hi_to_si { } {
> > global et_vect_widen_sum_hi_to_si
> > !
> > if [info exists et_vect_widen_sum_hi_to_si_saved] {
> > verbose "check_effective_target_vect_widen_sum_hi_to_si:
> using cached result" 2
> > } else {
> > ! set et_vect_widen_sum_hi_to_si_saved
> [check_effective_target_vect_unpack]
> > if { [istarget powerpc*-*-*]
> > || [istarget ia64-*-*] } {
> > set et_vect_widen_sum_hi_to_si_saved 1
> > *************** proc check_effective_target_vect_widen_s
> > *** 1457,1472 ****
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *char* args into *short* result, 0 otherwise.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_qi_to_hi { } {
> > global et_vect_widen_sum_qi_to_hi
> > !
> > if [info exists et_vect_widen_sum_qi_to_hi_saved] {
> > verbose "check_effective_target_vect_widen_sum_qi_to_hi:
> using cached result" 2
> > } else {
> > set et_vect_widen_sum_qi_to_hi_saved 0
> > if { [istarget ia64-*-*] } {
> > set et_vect_widen_sum_qi_to_hi_saved 1
> > }
> > --- 1459,1479 ----
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *char* args into *short* result, 0 otherwise.
> > + # A target can also support this widening summation if it can support
> > + # promotion (unpacking) from chars to shorts.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_qi_to_hi { } {
> > global et_vect_widen_sum_qi_to_hi
> > !
> > if [info exists et_vect_widen_sum_qi_to_hi_saved] {
> > verbose "check_effective_target_vect_widen_sum_qi_to_hi:
> using cached result" 2
> > } else {
> > set et_vect_widen_sum_qi_to_hi_saved 0
> > + if { [check_effective_target_vect_unpack] } {
> > + set et_vect_widen_sum_qi_to_hi_saved 1
> > + }
> > if { [istarget ia64-*-*] } {
> > set et_vect_widen_sum_qi_to_hi_saved 1
> > }
> > *************** proc check_effective_target_vect_widen_s
> > *** 1517,1522 ****
> > --- 1524,1589 ----
> > }
> >
> > # Return 1 if the target plus current options supports a vector
> > + # widening multiplication of *char* args into *short* result, 0
otherwise.
> > + # A target can also support this widening multplication if it can
support
> > + # promotion (unpacking) from chars to shorts, and
> vect_short_mult (non-widening
> > + # multiplication of shorts).
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > +
> > + proc check_effective_target_vect_widen_mult_qi_to_hi { } {
> > + global et_vect_widen_mult_qi_to_hi
> > +
> > + if [info exists et_vect_widen_mult_qi_to_hi_saved] {
> > + verbose
> "check_effective_target_vect_widen_mult_qi_to_hi: using cached result" 2
> > + } else {
> > + if { [check_effective_target_vect_unpack]
> > + && [check_effective_target_vect_short_mult] } {
> > + set et_vect_widen_mult_qi_to_hi_saved 1
> > + } else {
> > + set et_vect_widen_mult_qi_to_hi_saved 0
> > + }
> > + if { [istarget powerpc*-*-*] } {
> > + set et_vect_widen_mult_qi_to_hi_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_widen_mult_qi_to_hi:
> returning $et_vect_widen_mult_qi_to_hi_saved" 2
> > + return $et_vect_widen_mult_qi_to_hi_saved
> > + }
> > +
> > + # Return 1 if the target plus current options supports a vector
> > + # widening multiplication of *short* args into *int* result, 0
otherwise.
> > + # A target can also support this widening multplication if it can
support
> > + # promotion (unpacking) from shorts to ints, and vect_int_mult
> (non-widening
> > + # multiplication of ints).
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > +
> > + proc check_effective_target_vect_widen_mult_hi_to_si { } {
> > + global et_vect_widen_mult_hi_to_si
> > +
> > + if [info exists et_vect_widen_mult_hi_to_si_saved] {
> > + verbose
> "check_effective_target_vect_widen_mult_hi_to_si: using cached result" 2
> > + } else {
> > + if { [check_effective_target_vect_unpack]
> > + && [check_effective_target_vect_int_mult] } {
> > + set et_vect_widen_mult_hi_to_si_saved 1
> > + } else {
> > + set et_vect_widen_mult_hi_to_si_saved 0
> > + }
> > + if { [istarget powerpc*-*-*]
> > + || [istarget i?86-*-*]
> > + || [istarget x86_64-*-*] } {
> > + set et_vect_widen_mult_hi_to_si_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_widen_mult_hi_to_si:
> returning $et_vect_widen_mult_hi_to_si_saved" 2
> > + return $et_vect_widen_mult_hi_to_si_saved
> > + }
> > +
> > + # Return 1 if the target plus current options supports a vector
> > # dot-product of signed chars, 0 otherwise.
> > #
> > # This won't change for different subtargets so cache the result.
> > *************** proc check_effective_target_vect_udot_hi
> > *** 1601,1606 ****
> > --- 1668,1720 ----
> > }
> >
> >
> > + # Return 1 if the target plus current options supports a vector
> > + # demotion (packing) of shorts (to chars) and ints (to shorts)
> > + # using modulo arithmetic, 0 otherwise.
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > + proc check_effective_target_vect_pack_mod { } {
> > + global et_vect_pack_mod
> > +
> > + if [info exists et_vect_pack_mod_saved] {
> > + verbose "check_effective_target_vect_pack_mod: using
> cached result" 2
> > + } else {
> > + set et_vect_pack_mod_saved 0
> > + if { [istarget powerpc*-*-*]
> > + || [istarget i?86-*-*]
> > + || [istarget x86_64-*-*]
> > + || [istarget ia64-*-*] } {
> > + set et_vect_pack_mod_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_pack_mod: returning
> $et_vect_pack_mod_saved" 2
> > + return $et_vect_pack_mod_saved
> > + }
> > +
> > + # Return 1 if the target plus current options supports a vector
> > + # promotion (unpacking) of chars (to shorts) and shorts (to
> ints), 0 otherwise.
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > + proc check_effective_target_vect_unpack { } {
> > + global et_vect_unpack
> > +
> > + if [info exists et_vect_unpack_saved] {
> > + verbose "check_effective_target_vect_unpack: using
> cached result" 2
> > + } else {
> > + set et_vect_unpack_saved 0
> > + if { [istarget powerpc*-*-*]
> > + || [istarget i?86-*-*]
> > + || [istarget x86_64-*-*]
> > + || [istarget ia64-*-*] } {
> > + set et_vect_unpack_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_unpack: returning
> $et_vect_unpack_saved" 2
> > + return $et_vect_unpack_saved
> > + }
> > +
> > # Return 1 if the target plus current options does not support a
vector
> > # alignment mechanism, 0 otherwise.
> > #
> >
> > Index: testsuite/lib/target-supports.exp
> > ===================================================================
> > *** testsuite/lib/target-supports.exp (revision 111135)
> > --- testsuite/lib/target-supports.exp (working copy)
> > *************** proc check_effective_target_vect_no_bitw
> > *** 1436,1451 ****
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *short* args into *int* result, 0 otherwise.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_hi_to_si { } {
> > global et_vect_widen_sum_hi_to_si
> > !
> > if [info exists et_vect_widen_sum_hi_to_si_saved] {
> > verbose "check_effective_target_vect_widen_sum_hi_to_si:
> using cached result" 2
> > } else {
> > ! set et_vect_widen_sum_hi_to_si_saved 0
> > if { [istarget powerpc*-*-*]
> > || [istarget ia64-*-*] } {
> > set et_vect_widen_sum_hi_to_si_saved 1
> > --- 1436,1453 ----
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *short* args into *int* result, 0 otherwise.
> > + # A target can also support this widening summation if it can support
> > + # promotion (unpacking) from shorts to ints.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_hi_to_si { } {
> > global et_vect_widen_sum_hi_to_si
> > !
> > if [info exists et_vect_widen_sum_hi_to_si_saved] {
> > verbose "check_effective_target_vect_widen_sum_hi_to_si:
> using cached result" 2
> > } else {
> > ! set et_vect_widen_sum_hi_to_si_saved
> [check_effective_target_vect_unpack]
> > if { [istarget powerpc*-*-*]
> > || [istarget ia64-*-*] } {
> > set et_vect_widen_sum_hi_to_si_saved 1
> > *************** proc check_effective_target_vect_widen_s
> > *** 1457,1472 ****
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *char* args into *short* result, 0 otherwise.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_qi_to_hi { } {
> > global et_vect_widen_sum_qi_to_hi
> > !
> > if [info exists et_vect_widen_sum_qi_to_hi_saved] {
> > verbose "check_effective_target_vect_widen_sum_qi_to_hi:
> using cached result" 2
> > } else {
> > set et_vect_widen_sum_qi_to_hi_saved 0
> > if { [istarget ia64-*-*] } {
> > set et_vect_widen_sum_qi_to_hi_saved 1
> > }
> > --- 1459,1479 ----
> >
> > # Return 1 if the target plus current options supports a vector
> > # widening summation of *char* args into *short* result, 0 otherwise.
> > + # A target can also support this widening summation if it can support
> > + # promotion (unpacking) from chars to shorts.
> > #
> > # This won't change for different subtargets so cache the result.
> >
> > proc check_effective_target_vect_widen_sum_qi_to_hi { } {
> > global et_vect_widen_sum_qi_to_hi
> > !
> > if [info exists et_vect_widen_sum_qi_to_hi_saved] {
> > verbose "check_effective_target_vect_widen_sum_qi_to_hi:
> using cached result" 2
> > } else {
> > set et_vect_widen_sum_qi_to_hi_saved 0
> > + if { [check_effective_target_vect_unpack] } {
> > + set et_vect_widen_sum_qi_to_hi_saved 1
> > + }
> > if { [istarget ia64-*-*] } {
> > set et_vect_widen_sum_qi_to_hi_saved 1
> > }
> > *************** proc check_effective_target_vect_widen_s
> > *** 1517,1522 ****
> > --- 1524,1589 ----
> > }
> >
> > # Return 1 if the target plus current options supports a vector
> > + # widening multiplication of *char* args into *short* result, 0
otherwise.
> > + # A target can also support this widening multplication if it can
support
> > + # promotion (unpacking) from chars to shorts, and
> vect_short_mult (non-widening
> > + # multiplication of shorts).
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > +
> > + proc check_effective_target_vect_widen_mult_qi_to_hi { } {
> > + global et_vect_widen_mult_qi_to_hi
> > +
> > + if [info exists et_vect_widen_mult_qi_to_hi_saved] {
> > + verbose
> "check_effective_target_vect_widen_mult_qi_to_hi: using cached result" 2
> > + } else {
> > + if { [check_effective_target_vect_unpack]
> > + && [check_effective_target_vect_short_mult] } {
> > + set et_vect_widen_mult_qi_to_hi_saved 1
> > + } else {
> > + set et_vect_widen_mult_qi_to_hi_saved 0
> > + }
> > + if { [istarget powerpc*-*-*] } {
> > + set et_vect_widen_mult_qi_to_hi_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_widen_mult_qi_to_hi:
> returning $et_vect_widen_mult_qi_to_hi_saved" 2
> > + return $et_vect_widen_mult_qi_to_hi_saved
> > + }
> > +
> > + # Return 1 if the target plus current options supports a vector
> > + # widening multiplication of *short* args into *int* result, 0
otherwise.
> > + # A target can also support this widening multplication if it can
support
> > + # promotion (unpacking) from shorts to ints, and vect_int_mult
> (non-widening
> > + # multiplication of ints).
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > +
> > + proc check_effective_target_vect_widen_mult_hi_to_si { } {
> > + global et_vect_widen_mult_hi_to_si
> > +
> > + if [info exists et_vect_widen_mult_hi_to_si_saved] {
> > + verbose
> "check_effective_target_vect_widen_mult_hi_to_si: using cached result" 2
> > + } else {
> > + if { [check_effective_target_vect_unpack]
> > + && [check_effective_target_vect_int_mult] } {
> > + set et_vect_widen_mult_hi_to_si_saved 1
> > + } else {
> > + set et_vect_widen_mult_hi_to_si_saved 0
> > + }
> > + if { [istarget powerpc*-*-*]
> > + || [istarget i?86-*-*]
> > + || [istarget x86_64-*-*] } {
> > + set et_vect_widen_mult_hi_to_si_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_widen_mult_hi_to_si:
> returning $et_vect_widen_mult_hi_to_si_saved" 2
> > + return $et_vect_widen_mult_hi_to_si_saved
> > + }
> > +
> > + # Return 1 if the target plus current options supports a vector
> > # dot-product of signed chars, 0 otherwise.
> > #
> > # This won't change for different subtargets so cache the result.
> > *************** proc check_effective_target_vect_udot_hi
> > *** 1601,1606 ****
> > --- 1668,1720 ----
> > }
> >
> >
> > + # Return 1 if the target plus current options supports a vector
> > + # demotion (packing) of shorts (to chars) and ints (to shorts)
> > + # using modulo arithmetic, 0 otherwise.
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > + proc check_effective_target_vect_pack_mod { } {
> > + global et_vect_pack_mod
> > +
> > + if [info exists et_vect_pack_mod_saved] {
> > + verbose "check_effective_target_vect_pack_mod: using
> cached result" 2
> > + } else {
> > + set et_vect_pack_mod_saved 0
> > + if { [istarget powerpc*-*-*]
> > + || [istarget i?86-*-*]
> > + || [istarget x86_64-*-*]
> > + || [istarget ia64-*-*] } {
> > + set et_vect_pack_mod_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_pack_mod: returning
> $et_vect_pack_mod_saved" 2
> > + return $et_vect_pack_mod_saved
> > + }
> > +
> > + # Return 1 if the target plus current options supports a vector
> > + # promotion (unpacking) of chars (to shorts) and shorts (to
> ints), 0 otherwise.
> > + #
> > + # This won't change for different subtargets so cache the result.
> > +
> > + proc check_effective_target_vect_unpack { } {
> > + global et_vect_unpack
> > +
> > + if [info exists et_vect_unpack_saved] {
> > + verbose "check_effective_target_vect_unpack: using
> cached result" 2
> > + } else {
> > + set et_vect_unpack_saved 0
> > + if { [istarget powerpc*-*-*]
> > + || [istarget i?86-*-*]
> > + || [istarget x86_64-*-*]
> > + || [istarget ia64-*-*] } {
> > + set et_vect_unpack_saved 1
> > + }
> > + }
> > + verbose "check_effective_target_vect_unpack: returning
> $et_vect_unpack_saved" 2
> > + return $et_vect_unpack_saved
> > + }
> > +
> > # Return 1 if the target plus current options does not support a
vector
> > # alignment mechanism, 0 otherwise.
> > #
> >
> Again. This part is somewhat obscure to me, but it looks decent. Janis?
thanks,
dorit