+2015-12-08 Uros Bizjak <ubizjak@gmail.com>
+
+ PR target/68701
+ * config/i386/i386.c (ix86_option_override_internal): Enable
+ -maccumulate-outgoing-args when %ebp is fixed due to stack
+ realignment requirements.
+
2015-12-08 Tom de Vries <tom@codesourcery.com>
PR tree-optimization/68640
opts->x_target_flags |= MASK_ACCUMULATE_OUTGOING_ARGS;
}
+ /* Stack realignment without -maccumulate-outgoing-args requires %ebp,
+ so enable -maccumulate-outgoing-args when %ebp is fixed. */
+ if (fixed_regs[BP_REG]
+ && !(opts->x_target_flags & MASK_ACCUMULATE_OUTGOING_ARGS))
+ {
+ if (opts_set->x_target_flags & MASK_ACCUMULATE_OUTGOING_ARGS)
+ warning (0, "fixed ebp register requires %saccumulate-outgoing-args%s",
+ prefix, suffix);
+ opts->x_target_flags |= MASK_ACCUMULATE_OUTGOING_ARGS;
+ }
+
/* Figure out what ASM_GENERATE_INTERNAL_LABEL builds as a prefix. */
{
char *p;
+2015-12-08 Uros Bizjak <ubizjak@gmail.com>
+
+ PR target/68701
+ * testsuite/gcc.target/i386/pr68701-1.c: New test.
+ * testsuite/gcc.target/i386/pr68701-2.c: Ditto.
+
2015-12-08 Uros Bizjak <ubizjak@gmail.com>
* gcc.target/i386/sse4_1-round.h (do_round): Fix inline asm statements.
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-O -ffixed-ebp -mno-accumulate-outgoing-args" } */
+
+/* { dg-warning "fixed ebp register requires" "" { target *-*-* } 0 } */
+
+void foo (void);
+
+int
+main (int argc, char *argv[])
+{
+ foo ();
+ return argc - 1;
+}
--- /dev/null
+/* { dg-do compile } */
+/* { dg-options "-O -ffixed-ebp -mno-accumulate-outgoing-args -mstackrealign -msse" } */
+
+/* { dg-warning "fixed ebp register requires" "" { target *-*-* } 0 } */
+
+typedef float V __attribute__((vector_size(16)));
+
+void bar (V a)
+{
+ volatile V b = a;
+}