+2018-01-03 Martin Liska <mliska@suse.cz>
+
+ PR ipa/83549
+ * cif-code.def (VARIADIC_THUNK): New enum value.
+ * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
+ thunks.
+
2018-01-03 Jan Beulich <jbeulich@suse.com>
* sse.md (mov<mode>_internal): Tighten condition for when to use
DEFCIFCODE(LTO_MISMATCHED_DECLARATIONS, CIF_FINAL_ERROR,
N_("mismatched declarations during linktime optimization"))
+/* Caller is variadic thunk. */
+DEFCIFCODE(VARIADIC_THUNK, CIF_FINAL_ERROR,
+ N_("variadic thunk call"))
+
/* Call was originally indirect. */
DEFCIFCODE(ORIGINALLY_INDIRECT_CALL, CIF_FINAL_NORMAL,
N_("originally indirect function call not considered for inlining"))
info->inlinable = false;
node->callees->inline_failed = CIF_CHKP;
}
+ else if (stdarg_p (TREE_TYPE (node->decl)))
+ {
+ info->inlinable = false;
+ node->callees->inline_failed = CIF_VARIADIC_THUNK;
+ }
else
info->inlinable = true;
}
+2018-01-03 Martin Liska <mliska@suse.cz>
+
+ PR ipa/83549
+ * g++.dg/ipa/pr83549.C: New test.
+
2018-01-03 Marek Polacek <polacek@redhat.com>
PR c++/83592
--- /dev/null
+// PR ipa/83549
+// { dg-do compile }
+// { dg-options "-O2" }
+
+struct A { virtual ~A (); };
+struct B { virtual void foo (...); };
+struct C : A, B { void foo (...) {} };
+C c;