re PR tree-optimization/55995 (vect increase_alignment notes missing from dump file)
authorSharad Singhai <singhai@google.com>
Fri, 18 Jan 2013 18:26:04 +0000 (18:26 +0000)
committerSharad Singhai <singhai@gcc.gnu.org>
Fri, 18 Jan 2013 18:26:04 +0000 (18:26 +0000)
2013-01-18  Sharad Singhai  <singhai@google.com>

PR tree-optimization/55995
* dumpfile.c (dump_loc): Print location only if available.
* tree-vectorizer.c (increase_alignment): Intialize vect_location.

testsuite/ChangeLog
PR tree-optimization/55995
* gcc.dg/vect/vect.exp: Use "details" flags for dump info.

From-SVN: r195303

gcc/ChangeLog
gcc/dumpfile.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/vect/vect.exp
gcc/tree-vectorizer.c

index 2be4cf37615ae7530cd41d8be61127832b048391..31132772e0154fe3ace7272d6632891debbcb50f 100644 (file)
@@ -1,3 +1,9 @@
+2013-01-18  Sharad Singhai  <singhai@google.com>
+
+       PR tree-optimization/55995
+       * dumpfile.c (dump_loc): Print location only if available.
+       * tree-vectorizer.c (increase_alignment): Intialize vect_location.
+
 2013-01-18  Vladimir Makarov  <vmakarov@redhat.com>
 
        PR target/55433
index 915948adc6ffd28bc943b05fbe455653929f95a3..ddd7c962cc2bc10005cb47eb98862db1cff807b6 100644 (file)
@@ -260,14 +260,13 @@ dump_loc (int dump_kind, FILE *dfile, source_location loc)
   /* Currently vectorization passes print location information.  */
   if (dump_kind)
     {
-      if (loc == UNKNOWN_LOCATION)
+      if (loc != UNKNOWN_LOCATION)
+        fprintf (dfile, "\n%s:%d: note: ", LOCATION_FILE (loc),
+                 LOCATION_LINE (loc));
+      else if (current_function_decl)
         fprintf (dfile, "\n%s:%d: note: ",
                  DECL_SOURCE_FILE (current_function_decl),
                  DECL_SOURCE_LINE (current_function_decl));
-     else
-        fprintf (dfile, "\n%s:%d: note: ",
-                 LOCATION_FILE (loc),
-                 LOCATION_LINE (loc));
     }
 }
 
index c2098a4ae7843cc32542062ec2161b5bda874c23..20ebbbb872af4e011cf31973fdaac415236b4662 100644 (file)
@@ -1,3 +1,8 @@
+2013-01-18  Sharad Singhai  <singhai@google.com>
+
+       PR tree-optimization/55995
+       * gcc.dg/vect/vect.exp: Use "details" flags for dump info.
+
 2013-01-18  Vladimir Makarov  <vmakarov@redhat.com>
 
        PR target/55433
index 1b474c37ee136fcbdc005f719631286616238ef4..bea7ee0064baeb99ea3ff131fd7d6dea3a275f2e 100644 (file)
@@ -156,7 +156,8 @@ dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/section-anchors-*.\[cS\]]]
 
 # alignment-sensitive -fsection-anchors tests
 set DEFAULT_VECTCFLAGS $SAVED_DEFAULT_VECTCFLAGS
-lappend DEFAULT_VECTCFLAGS "-fsection-anchors" "-fdump-ipa-increase_alignment"
+lappend DEFAULT_VECTCFLAGS "-fsection-anchors" \
+       "-fdump-ipa-increase_alignment-details"
 dg-runtest [lsort [glob -nocomplain $srcdir/$subdir/aligned-section-anchors-*.\[cS\]]]  \
        "" $DEFAULT_VECTCFLAGS
 
index 66b46a08b93b585f72168d9a6f806366f47f4504..42ebb8d250f5baefabac07af9a2bcb43907ae43f 100644 (file)
@@ -225,6 +225,8 @@ increase_alignment (void)
 {
   struct varpool_node *vnode;
 
+  vect_location = UNKNOWN_LOC;
+
   /* Increase the alignment of all global arrays for vectorization.  */
   FOR_EACH_DEFINED_VARIABLE (vnode)
     {