summaryrefslogtreecommitdiff
path: root/gcc/tree-stdarg.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tree-stdarg.c')
-rw-r--r--gcc/tree-stdarg.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/gcc/tree-stdarg.c b/gcc/tree-stdarg.c
index 17d51a20fd3..0c70790f3eb 100644
--- a/gcc/tree-stdarg.c
+++ b/gcc/tree-stdarg.c
@@ -705,6 +705,13 @@ public:
virtual bool gate (function *fun)
{
return (flag_stdarg_opt
+#ifdef ACCEL_COMPILER
+ /* Disable for GCC5 in the offloading compilers, as
+ va_list and gpr/fpr counter fields are not merged.
+ In GCC6 when stdarg is lowered late this shouldn't be
+ an issue. */
+ && !in_lto_p
+#endif
/* This optimization is only for stdarg functions. */
&& fun->stdarg != 0);
}