[PATCH] D41318: Start setting dso_local in clang

Rafael Avila de Espindola via cfe-commits cfe-commits at lists.llvm.org
Wed Jan 31 14:29:47 PST 2018


Sean Fertile via Phabricator <reviews at reviews.llvm.org> writes:

> sfertile added inline comments.
>
>
> ================
> Comment at: clang/lib/CodeGen/CodeGenModule.cpp:750
> +  // If we can use a plt entry as the symbol address we can assume it
> +  // is local.
> +  if (isa<FunctionDecl>(D) && !CGOpts.NoPLT)
> ----------------
> I don't think this is the case. I think this would break ppc, where we need to restore the toc pointer after the plt stubs returns to the original call site.

Excellent catch. I will update the patch to handle the ppc special case.

Thanks,
Rafael


More information about the cfe-commits mailing list