+2012-01-08 Jakub Jelinek <jakub@redhat.com>
+ Uros Bizjak <ubizjak@gmail.com>
+
+ PR rtl-optimization/55845
+ * df-problems.c (can_move_insns_across): Stop scanning at
+ volatile_insn_p source instruction or give up if
+ across_from .. across_to range contains any volatile_insn_p
+ instructions.
+
2013-01-08 Tejas Belagod <tejas.belagod@arm.com>
* config/aarch64/aarch64-simd.md (vec_init<mode>): New.
/* Standard problems for dataflow support routines.
Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007,
- 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
+ 2008, 2009, 2010, 2011, 2012, 2013 Free Software Foundation, Inc.
Originally contributed by Michael P. Hayes
(m.hayes@elec.canterbury.ac.nz, mhayes@redhat.com)
Major rewrite contributed by Danny Berlin (dberlin@dberlin.org)
}
if (NONDEBUG_INSN_P (insn))
{
+ if (volatile_insn_p (PATTERN (insn)))
+ return false;
memrefs_in_across |= for_each_rtx (&PATTERN (insn), find_memory,
NULL);
note_stores (PATTERN (insn), find_memory_stores,
if (NONDEBUG_INSN_P (insn))
{
if (may_trap_or_fault_p (PATTERN (insn))
- && (trapping_insns_in_across || other_branch_live != NULL))
+ && (trapping_insns_in_across
+ || other_branch_live != NULL
+ || volatile_insn_p (PATTERN (insn))))
break;
/* We cannot move memory stores past each other, or move memory
+2012-01-08 Uros Bizjak <ubizjak@gmail.com>
+ Vladimir Yakovlev <vladimir.b.yakovlev@intel.com>
+
+ PR rtl-optimization/55845
+ * gcc.target/i386/pr55845.c: New test.
+
2013-01-08 Tejas Belagod <tejas.belagod@arm.com>
* gcc.target/aarch64/vect-mull-compile.c: Explicitly scan for
--- /dev/null
+/* { dg-do run } */
+/* { dg-require-effective-target avx } */
+/* { dg-options "-O3 -ffast-math -fschedule-insns -mavx -mvzeroupper" } */
+
+#include "avx-check.h"
+
+#define N 100
+
+double
+__attribute__((noinline))
+foo (int size, double *y, double *x)
+{
+ double sum = 0.0;
+ int i;
+ for (i = 0, sum = 0.; i < size; i++)
+ sum += y[i] * x[i];
+ return sum;
+}
+
+static void
+__attribute__ ((noinline))
+avx_test ()
+{
+ double x[N];
+ double y[N];
+ double s;
+ int i;
+
+ for (i = 0; i < N; i++)
+ {
+ x[i] = i;
+ y[i] = i;
+ }
+
+ s = foo (N, y, x);
+
+ if (s != 328350.0)
+ abort ();
+}