[PATCH] D45523: [CodeGen] Handle __func__ inside __finally

Shoaib Meenai via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Apr 11 08:56:35 PDT 2018


smeenai added inline comments.


================
Comment at: test/CodeGen/exceptions-seh-finally.c:281
+// CHECK-LABEL: define internal void @"?fin$0 at 0@finally_with_func@@"({{[^)]*}})
+// CHECK: call void @cleanup_with_func(i8* getelementptr inbounds ([18 x i8], [18 x i8]* @"??_C at _0BC@COAGBPGM at finally_with_func?$AA@", i32 0, i32 0))
+
----------------
How stable is the mangling here? I included the complete `call` instruction because I wanted to ensure that the value of `__func__` inside a `__finally` block reflects the parent function, not the outlined funclet, and both the `[18 x i8]` and the mangled string name are pretty good proxies for that. I can generalize it more if it'll make the test more reliable though.


Repository:
  rC Clang

https://reviews.llvm.org/D45523





More information about the cfe-commits mailing list