This is an archive of the discontinued LLVM Phabricator instance.

[Driver] Use --android-tls for Android ARM/AArch64 when lld is used
AbandonedPublic

Authored by MaskRay on May 14 2019, 11:21 PM.

Details

Summary

See D61825 for the temporary lld option --android-tls.

Diff Detail

Event Timeline

MaskRay created this revision.May 14 2019, 11:21 PM
rprichard added inline comments.May 15 2019, 12:02 AM
lib/Driver/ToolChains/Gnu.cpp
404

The logic used for Fuschia is more precise:

const char *Exec = Args.MakeArgString(ToolChain.GetLinkerPath());
if (llvm::sys::path::filename(Exec).equals_lower("ld.lld") ||
    llvm::sys::path::stem(Exec).equals_lower("ld.lld")) {
  CmdArgs.push_back("-z");
  CmdArgs.push_back("rodynamic");
}
MaskRay updated this revision to Diff 199574.May 15 2019, 3:36 AM

Use Args.MakeArgString(ToolChain.GetLinkerPath());

MaskRay marked an inline comment as done.May 15 2019, 3:36 AM

This LGTM if Ryan is happy with it. Thanks for taking care of getting a workaround implemented until this can be fixed.

MaskRay abandoned this revision.May 17 2019, 8:32 PM

Abandon in favor of D62055