[PATCH] D82343: Preserve GlobalsAA analysis result in InjectTLIMappings

Ryan Santhirarajan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 22 19:52:53 PDT 2020


rsanthir.quic created this revision.
rsanthir.quic added reviewers: fpetrogalli, joerg, fhahn.
Herald added subscribers: llvm-commits, hiraditya.
Herald added a project: LLVM.

InjectTLIMappings fails to preserve the analysis result of GlobalsAA. Not preserving the analysis might affect benchmark performance. This change fixes this issue.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D82343

Files:
  llvm/lib/Transforms/Utils/InjectTLIMappings.cpp


Index: llvm/lib/Transforms/Utils/InjectTLIMappings.cpp
===================================================================
--- llvm/lib/Transforms/Utils/InjectTLIMappings.cpp
+++ llvm/lib/Transforms/Utils/InjectTLIMappings.cpp
@@ -14,6 +14,7 @@
 #include "llvm/Transforms/Utils/InjectTLIMappings.h"
 #include "llvm/ADT/Statistic.h"
 #include "llvm/Analysis/DemandedBits.h"
+#include "llvm/Analysis/GlobalsModRef.h"
 #include "llvm/Analysis/OptimizationRemarkEmitter.h"
 #include "llvm/Analysis/VectorUtils.h"
 #include "llvm/IR/InstIterator.h"
@@ -144,6 +145,7 @@
   AU.addPreserved<LoopAccessLegacyAnalysis>();
   AU.addPreserved<DemandedBitsWrapperPass>();
   AU.addPreserved<OptimizationRemarkEmitterWrapperPass>();
+  AU.addPreserved<GlobalsAAWrapperPass>();
 }
 
 ////////////////////////////////////////////////////////////////////////////////


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D82343.272587.patch
Type: text/x-patch
Size: 850 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200623/f010ab63/attachment.bin>


More information about the llvm-commits mailing list