[PATCH] D15341: Separate CSRs into a subset handled via explicit copies and a subset handled by prologue/epilogue (AArch64)

Manman Ren via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 9 14:16:14 PST 2015


manmanren added inline comments.

================
Comment at: lib/Target/AArch64/AArch64ISelLowering.cpp:10055
@@ +10054,3 @@
+            TII->get(TargetOpcode::COPY), NewVR)
+        .addReg(*I);
+    BuildMI(*Exit, Exit->begin(), DebugLoc(),
----------------
hfinkel wrote:
> Do you need to emit any kind of CFI pseudo-instructions for these so that unwinding works?
This is a good point. I think we should but I am not so sure.

Maybe Nick is a better person to answer the question on Darwin platform.

Specific to C++-style TLS access functions, they should be nounwind.  Throwing an exception from the initializer of a thread-local variable is defined to immediately result in a call to std::terminate(); there’s no legal way for unwinding to actually leave such a function. (quote from John McCall) :]


http://reviews.llvm.org/D15341





More information about the llvm-commits mailing list