[llvm] [CGP] Undo constant propagation of pointers across calls (PR #102926)

Antonio Frighetto via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 27 05:39:52 PDT 2024


================
@@ -2686,6 +2686,47 @@ bool CodeGenPrepare::optimizeCallInst(CallInst *CI, ModifyDT &ModifiedDT) {
     return true;
   }
 
+  // SCCP may have propagated C++ static variables across calls. If this happens
----------------
antoniofrighetto wrote:

Comment adjusted, but I'd say this is primarily tailored for C++ getters/setters for the given use cases.

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


More information about the llvm-commits mailing list