[clang] [llvm] [AArch64][SME] Save VG for unwind info when changing streaming-mode (PR #83301)

Kerry McLaughlin via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 3 09:56:10 PDT 2024


================
@@ -8287,6 +8289,13 @@ AArch64TargetLowering::LowerCall(CallLoweringInfo &CLI,
 
   SDValue InGlue;
   if (RequiresSMChange) {
+
+    if (Subtarget->hasSVE()) {
----------------
kmclaughlin-arm wrote:

> when I compile some code with -fno-asynchronous-unwind-tables, it will still generate these directives. Perhaps this should have a diagnostic in Clang?

I'm happy to add such a diagnostic, but I want to make sure I have the reason for this requirement correct.
If I understand correctly, enabling asychronous unwind tables is required now that I am emitting the save and restore of VG at the point of each call in the function which changes streaming-mode.

> we want debuggers to be able to unwind the stack even if a function is nounwind.

Given this, I'm not entirely sure why we would expect to be able to unwind if `-fno-asynchronous-unwind-tables` was used or if the function has been marked as nounwind? I might have misunderstood something though!

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


More information about the llvm-commits mailing list