[PATCH] D19518: Add optimization bisect opt-in calls for NVPTX passes

Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 26 16:50:26 PDT 2016


This revision was automatically updated to reflect the committed changes.
Closed by commit rL267635: Add optimization bisect opt-in calls for NVPTX passes (authored by akaylor).

Changed prior to commit:
  http://reviews.llvm.org/D19518?vs=55069&id=55129#toc

Repository:
  rL LLVM

http://reviews.llvm.org/D19518

Files:
  llvm/trunk/lib/Target/NVPTX/NVPTXFavorNonGenericAddrSpaces.cpp
  llvm/trunk/lib/Target/NVPTX/NVPTXImageOptimizer.cpp
  llvm/trunk/lib/Target/NVPTX/NVPTXInferAddressSpaces.cpp
  llvm/trunk/lib/Target/NVPTX/NVPTXLowerAlloca.cpp
  llvm/trunk/lib/Target/NVPTX/NVPTXPeephole.cpp

Index: llvm/trunk/lib/Target/NVPTX/NVPTXFavorNonGenericAddrSpaces.cpp
===================================================================
--- llvm/trunk/lib/Target/NVPTX/NVPTXFavorNonGenericAddrSpaces.cpp
+++ llvm/trunk/lib/Target/NVPTX/NVPTXFavorNonGenericAddrSpaces.cpp
@@ -266,7 +266,7 @@
 }
 
 bool NVPTXFavorNonGenericAddrSpaces::runOnFunction(Function &F) {
-  if (DisableFavorNonGeneric)
+  if (DisableFavorNonGeneric || skipFunction(F))
     return false;
 
   bool Changed = false;
Index: llvm/trunk/lib/Target/NVPTX/NVPTXLowerAlloca.cpp
===================================================================
--- llvm/trunk/lib/Target/NVPTX/NVPTXLowerAlloca.cpp
+++ llvm/trunk/lib/Target/NVPTX/NVPTXLowerAlloca.cpp
@@ -62,6 +62,9 @@
 // Main function for this pass.
 // =============================================================================
 bool NVPTXLowerAlloca::runOnBasicBlock(BasicBlock &BB) {
+  if (skipBasicBlock(BB))
+    return false;
+
   bool Changed = false;
   for (auto &I : BB) {
     if (auto allocaInst = dyn_cast<AllocaInst>(&I)) {
Index: llvm/trunk/lib/Target/NVPTX/NVPTXPeephole.cpp
===================================================================
--- llvm/trunk/lib/Target/NVPTX/NVPTXPeephole.cpp
+++ llvm/trunk/lib/Target/NVPTX/NVPTXPeephole.cpp
@@ -125,6 +125,9 @@
 }
 
 bool NVPTXPeephole::runOnMachineFunction(MachineFunction &MF) {
+  if (skipFunction(*MF.getFunction()))
+    return false;
+
   bool Changed = false;
   // Loop over all of the basic blocks.
   for (auto &MBB : MF) {
Index: llvm/trunk/lib/Target/NVPTX/NVPTXInferAddressSpaces.cpp
===================================================================
--- llvm/trunk/lib/Target/NVPTX/NVPTXInferAddressSpaces.cpp
+++ llvm/trunk/lib/Target/NVPTX/NVPTXInferAddressSpaces.cpp
@@ -419,6 +419,9 @@
 }
 
 bool NVPTXInferAddressSpaces::runOnFunction(Function &F) {
+  if (skipFunction(F))
+    return false;
+
   // Collects all generic address expressions in postorder.
   std::vector<Value *> Postorder = collectGenericAddressExpressions(F);
 
Index: llvm/trunk/lib/Target/NVPTX/NVPTXImageOptimizer.cpp
===================================================================
--- llvm/trunk/lib/Target/NVPTX/NVPTXImageOptimizer.cpp
+++ llvm/trunk/lib/Target/NVPTX/NVPTXImageOptimizer.cpp
@@ -50,6 +50,9 @@
   : FunctionPass(ID) {}
 
 bool NVPTXImageOptimizer::runOnFunction(Function &F) {
+  if (skipFunction(F))
+    return false;
+
   bool Changed = false;
   InstrToDelete.clear();
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D19518.55129.patch
Type: text/x-patch
Size: 2483 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160426/ac780266/attachment.bin>


More information about the llvm-commits mailing list