[clang] [llvm] [ARM] support -mlong-calls -fPIC on arm32 #39970 (PR #147313)

Eli Friedman via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 16 21:44:43 PDT 2026


================
@@ -173,6 +173,37 @@ class ARMTargetCodeGenInfo : public TargetCodeGenInfo {
       setBranchProtectionFnAttributes(BPI, (*Fn));
     }
 
+    if (FD) {
+      bool HasLongCalls = false, HasExecOnly = false;
+      if (Fn->hasFnAttribute("target-features")) {
----------------
efriedma-quic wrote:

This is pretty complicated code to catch an edge case that won't come up in practice, and the backend will correctly diagnose.  I don't think it's necessary.

https://github.com/llvm/llvm-project/pull/147313


More information about the cfe-commits mailing list