[PATCH] D136998: Try to implement lambdas with inalloca parameters by inlining the call operator function.

Eli Friedman via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Nov 3 17:23:19 PDT 2022


efriedma added a comment.

Should we try to use this codepath for variadic lambdas as well?

Do we want to try to unify our cloning code?  CodeGenFunction::GenerateVarArgsThunk has code doing something similar.  (It's at least worth comparing to see if you're doing something significantly different...)



================
Comment at: clang/lib/CodeGen/CGClass.cpp:3063
+    // Don't copy the %this argument.
+    if (I.getName().equals("this")) {
+      VMap[&I] = llvm::Constant::getNullValue(I.getType());
----------------
Checking the name doesn't work; -fdiscard-value-names is on by default in Release builds


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D136998/new/

https://reviews.llvm.org/D136998



More information about the cfe-commits mailing list