summaryrefslogtreecommitdiff
path: root/gcc/tree-vectorizer.h
diff options
context:
space:
mode:
authordorit <dorit@138bc75d-0d04-0410-961f-82ee72b054a4>2005-02-17 08:47:28 +0000
committerdorit <dorit@138bc75d-0d04-0410-961f-82ee72b054a4>2005-02-17 08:47:28 +0000
commitf2983e95a3143759f0604692866729370d023b14 (patch)
tree156dba144110c82b3dd2deaad5f86c03a6dda30f /gcc/tree-vectorizer.h
parente9739f5f664c690b0e9c27b757ed7a19b8a2c265 (diff)
downloadgcc-f2983e95a3143759f0604692866729370d023b14.tar.gz
* Makefile.in (tree-vect-analyze.o, tree-vect-transform.o): New.
(tree-vectorizer.o): Added missing dependencies. * tree-vectorizer.h (vect_dump, vect_verbosity_level): Added extern decleration. (slpeel_tree_peel_loop_to_edge): Function externalized (had a static declaration in tree-vectorizer.c, now has an extern declaration in tree-vectorizer.h). (slpeel_make_loop_iterate_ntimes, slpeel_can_duplicate_loop_p, slpeel_verify_cfg_after_peeling, vect_strip_conversion, get_vectype_for_scalar_type, vect_is_simple_use, vect_is_simple_iv_evolution, vect_can_force_dr_alignment_p, vect_supportable_dr_alignment, new_loop_vec_info, destroy_loop_vec_info, new_stmt_vec_info, vect_analyze_loop, vectorizable_load, vectorizable_store, vectorizable_operation, vectorizable_assignment, vect_transform_loop, vect_print_dump_info, vect_set_verbosity_level, find_loop_location): Likewise. * tree-vectorizer.c (langhooks.h): #include removed. (slpeel_tree_peel_loop_to_edge): Function externalized. Declaration moved to tree-vectorized.h. (slpeel_make_loop_iterate_ntimes, slpeel_can_duplicate_loop_p, slpeel_verify_cfg_after_peeling, vect_strip_conversion, get_vectype_for_scalar_type, vect_is_simple_use, vect_is_simple_iv_evolution, vect_can_force_dr_alignment_p, vect_supportable_dr_alignment, new_loop_vec_info, destroy_loop_vec_info, new_stmt_vec_info, vect_print_dump_info, vect_set_verbosity_level, find_loop_location): Likewise. (vect_analyze_loop): Function externalized. Declaration moved to tree-vectorized.h. Function definition moved to tree-vect-analyze.c. (vect_analyze_loop_form): Moved to tree-vect-analyze.c. (vect_mark_stmts_to_be_vectorized, vect_analyze_scalar_cycles, vect_analyze_data_ref_accesses, vect_analyze_data_ref_dependences, vect_analyze_data_refs_alignment, vect_compute_data_refs_alignment, vect_enhance_data_refs_alignment, vect_analyze_operations, exist_non_indexing_operands_for_use_p, vect_mark_relevant, vect_stmt_relevant_p, vect_get_loop_niters, vect_analyze_data_ref_dependence, vect_compute_data_ref_alignment, vect_analyze_data_ref_access, vect_analyze_pointer_ref_access, vect_can_advance_ivs_p, vect_get_ptr_offset, vect_analyze_offset_expr, vect_base_addr_differ_p, vect_object_analysis, vect_address_analysis, vect_get_memtag): Likewise. (vectorizable_load): Function externalized. Declaration moved to tree-vectorized.h. Function definition moved to tree-vect-transform.c. (vectorizable_store, vectorizable_operation, vectorizable_assignment, vect_transform_loop): Likewise. (vect_transform_stmt): Moved to tree-vect-transform.c. (vect_align_data_ref, vect_create_destination_var, vect_create_data_ref_ptr, vect_create_index_for_vector_ref, vect_create_addr_base_for_vector_ref, vect_get_new_vect_var, vect_get_vec_def_for_operand, vect_init_vector, vect_finish_stmt_generation, vect_generate_tmps_on_preheader, vect_build_loop_niters, vect_update_ivs_after_vectorizer, vect_gen_niters_for_prolog_loop, vect_update_inits_of_dr, vect_update_inits_of_drs, vect_do_peeling_for_alignment, vect_do_peeling_for_loop_bound): Likewise. * tree-vect-analyze.c: New file. * tree-vect-transform.c: New file. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@95153 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-vectorizer.h')
-rw-r--r--gcc/tree-vectorizer.h57
1 files changed, 54 insertions, 3 deletions
diff --git a/gcc/tree-vectorizer.h b/gcc/tree-vectorizer.h
index 7876cb6d7cb..f974c708786 100644
--- a/gcc/tree-vectorizer.h
+++ b/gcc/tree-vectorizer.h
@@ -258,17 +258,68 @@ unknown_alignment_for_access_p (struct data_reference *data_ref_info)
/* Perform signed modulo, always returning a non-negative value. */
#define VECT_SMODULO(x,y) ((x) % (y) < 0 ? ((x) % (y) + (y)) : (x) % (y))
+/* vect_dump will be set to stderr or dump_file if exist. */
+extern FILE *vect_dump;
+extern enum verbosity_levels vect_verbosity_level;
/*-----------------------------------------------------------------*/
/* Function prototypes. */
/*-----------------------------------------------------------------*/
-/* Main driver. */
-extern void vectorize_loops (struct loops *);
+/*************************************************************************
+ Simple Loop Peeling Utilities - in tree-vectorizer.c
+ *************************************************************************/
+/* Entry point for peeling of simple loops.
+ Peel the first/last iterations of a loop.
+ It can be used outside of the vectorizer for loops that are simple enough
+ (see function documentation). In the vectorizer it is used to peel the
+ last few iterations when the loop bound is unknown or does not evenly
+ divide by the vectorization factor, and to peel the first few iterations
+ to force the alignment of data references in the loop. */
+extern struct loop *slpeel_tree_peel_loop_to_edge
+ (struct loop *, struct loops *, edge, tree, tree, bool);
+extern void slpeel_make_loop_iterate_ntimes (struct loop *, tree);
+extern bool slpeel_can_duplicate_loop_p (struct loop *, edge);
+#ifdef ENABLE_CHECKING
+extern void slpeel_verify_cfg_after_peeling (struct loop *, struct loop *);
+#endif
+
-/* creation and deletion of loop and stmt info structs. */
+/*************************************************************************
+ General Vectorization Utilities
+ *************************************************************************/
+/** In tree-vectorizer.c **/
+extern tree vect_strip_conversion (tree);
+extern tree get_vectype_for_scalar_type (tree);
+extern bool vect_is_simple_use (tree , loop_vec_info, tree *);
+extern bool vect_is_simple_iv_evolution (unsigned, tree, tree *, tree *);
+extern bool vect_can_force_dr_alignment_p (tree, unsigned int);
+extern enum dr_alignment_support vect_supportable_dr_alignment
+ (struct data_reference *);
+/* Creation and deletion of loop and stmt info structs. */
extern loop_vec_info new_loop_vec_info (struct loop *loop);
extern void destroy_loop_vec_info (loop_vec_info);
extern stmt_vec_info new_stmt_vec_info (tree stmt, loop_vec_info);
+/* Main driver. */
+extern void vectorize_loops (struct loops *);
+
+/** In tree-vect-analyze.c **/
+/* Driver for analysis stage. */
+extern loop_vec_info vect_analyze_loop (struct loop *);
+
+/** In tree-vect-transform.c **/
+extern bool vectorizable_load (tree, block_stmt_iterator *, tree *);
+extern bool vectorizable_store (tree, block_stmt_iterator *, tree *);
+extern bool vectorizable_operation (tree, block_stmt_iterator *, tree *);
+extern bool vectorizable_assignment (tree, block_stmt_iterator *, tree *);
+/* Driver for transformation stage. */
+extern void vect_transform_loop (loop_vec_info, struct loops *);
+
+/*************************************************************************
+ Vectorization Debug Information - in tree-vectorizer.c
+ *************************************************************************/
+extern bool vect_print_dump_info (enum verbosity_levels, LOC);
+extern void vect_set_verbosity_level (const char *);
+extern LOC find_loop_location (struct loop *);
#endif /* GCC_TREE_VECTORIZER_H */