From 3f2212411de3917ab06d4a9f4f642a03bfd3f3f0 Mon Sep 17 00:00:00 2001 From: Richard Lowe Date: Wed, 7 Feb 2018 02:13:42 +0000 Subject: i386: use the new-style retpoline thunk names for external thunks, because nothing else will work --- gcc/config/i386/i386.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c index abe66923749..5b45cb17243 100644 --- a/gcc/config/i386/i386.c +++ b/gcc/config/i386/i386.c @@ -5677,7 +5677,9 @@ if (regno != INVALID_REGNUM && regno != CX_REG && ret_p) gcc_unreachable (); - if (USE_HIDDEN_LINKONCE) + if (USE_HIDDEN_LINKONCE || + (cfun && cfun->machine->indirect_branch_type == + indirect_branch_thunk_extern)) { const char *prefix;