comparison gcc/tree-vectorizer.c @ 67:f6334be47118

update gcc from gcc-4.6-20100522 to gcc-4.6-20110318
author nobuyasu <dimolto@cr.ie.u-ryukyu.ac.jp>
date Tue, 22 Mar 2011 17:18:12 +0900
parents b7f97abdc517
children 04ced10e8804
comparison
equal deleted inserted replaced
65:65488c3d617d 67:f6334be47118
59 #include "system.h" 59 #include "system.h"
60 #include "coretypes.h" 60 #include "coretypes.h"
61 #include "tm.h" 61 #include "tm.h"
62 #include "ggc.h" 62 #include "ggc.h"
63 #include "tree.h" 63 #include "tree.h"
64 #include "diagnostic.h"
65 #include "tree-pretty-print.h" 64 #include "tree-pretty-print.h"
66 #include "tree-flow.h" 65 #include "tree-flow.h"
67 #include "tree-dump.h" 66 #include "tree-dump.h"
68 #include "cfgloop.h" 67 #include "cfgloop.h"
69 #include "cfglayout.h" 68 #include "cfglayout.h"
74 /* vect_dump will be set to stderr or dump_file if exist. */ 73 /* vect_dump will be set to stderr or dump_file if exist. */
75 FILE *vect_dump; 74 FILE *vect_dump;
76 75
77 /* vect_verbosity_level set to an invalid value 76 /* vect_verbosity_level set to an invalid value
78 to mark that it's uninitialized. */ 77 to mark that it's uninitialized. */
79 static enum verbosity_levels vect_verbosity_level = MAX_VERBOSITY_LEVEL; 78 static enum vect_verbosity_levels vect_verbosity_level = MAX_VERBOSITY_LEVEL;
80 static enum verbosity_levels user_vect_verbosity_level = MAX_VERBOSITY_LEVEL;
81 79
82 /* Loop or bb location. */ 80 /* Loop or bb location. */
83 LOC vect_location; 81 LOC vect_location;
84 82
85 /* Vector mapping GIMPLE stmt to stmt_vec_info. */ 83 /* Vector mapping GIMPLE stmt to stmt_vec_info. */
86 VEC(vec_void_p,heap) *stmt_vec_info_vec; 84 VEC(vec_void_p,heap) *stmt_vec_info_vec;
87 85
88 86
89
90 /* Function vect_set_verbosity_level.
91
92 Called from opts.c upon detection of the
93 -ftree-vectorizer-verbose=N option. */
94
95 void
96 vect_set_verbosity_level (const char *val)
97 {
98 unsigned int vl;
99
100 vl = atoi (val);
101 if (vl < MAX_VERBOSITY_LEVEL)
102 user_vect_verbosity_level = (enum verbosity_levels) vl;
103 else
104 user_vect_verbosity_level
105 = (enum verbosity_levels) (MAX_VERBOSITY_LEVEL - 1);
106 }
107
108 87
109 /* Function vect_set_dump_settings. 88 /* Function vect_set_dump_settings.
110 89
111 Fix the verbosity level of the vectorizer if the 90 Fix the verbosity level of the vectorizer if the
112 requested level was not set explicitly using the flag 91 requested level was not set explicitly using the flag
160 /* Function debug_loop_details. 139 /* Function debug_loop_details.
161 140
162 For vectorization debug dumps. */ 141 For vectorization debug dumps. */
163 142
164 bool 143 bool
165 vect_print_dump_info (enum verbosity_levels vl) 144 vect_print_dump_info (enum vect_verbosity_levels vl)
166 { 145 {
167 if (vl > vect_verbosity_level) 146 if (vl > vect_verbosity_level)
168 return false; 147 return false;
169 148
170 if (!current_function_decl || !vect_dump) 149 if (!current_function_decl || !vect_dump)
207 init_stmt_vec_info_vec (); 186 init_stmt_vec_info_vec ();
208 187
209 /* ----------- Analyze loops. ----------- */ 188 /* ----------- Analyze loops. ----------- */
210 189
211 /* If some loop was duplicated, it gets bigger number 190 /* If some loop was duplicated, it gets bigger number
212 than all previously defined loops. This fact allows us to run 191 than all previously defined loops. This fact allows us to run
213 only over initial loops skipping newly generated ones. */ 192 only over initial loops skipping newly generated ones. */
214 FOR_EACH_LOOP (li, loop, 0) 193 FOR_EACH_LOOP (li, loop, 0)
215 if (optimize_loop_nest_for_speed_p (loop)) 194 if (optimize_loop_nest_for_speed_p (loop))
216 { 195 {
217 loop_vec_info loop_vinfo; 196 loop_vec_info loop_vinfo;
382 gate_increase_alignment, /* gate */ 361 gate_increase_alignment, /* gate */
383 increase_alignment, /* execute */ 362 increase_alignment, /* execute */
384 NULL, /* sub */ 363 NULL, /* sub */
385 NULL, /* next */ 364 NULL, /* next */
386 0, /* static_pass_number */ 365 0, /* static_pass_number */
387 TV_NONE, /* tv_id */ 366 TV_IPA_OPT, /* tv_id */
388 0, /* properties_required */ 367 0, /* properties_required */
389 0, /* properties_provided */ 368 0, /* properties_provided */
390 0, /* properties_destroyed */ 369 0, /* properties_destroyed */
391 0, /* todo_flags_start */ 370 0, /* todo_flags_start */
392 0 /* todo_flags_finish */ 371 0 /* todo_flags_finish */