[llvm] r308055 - [AMDGPU] Throw away more dead code. NFCI.
Davide Italiano via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 14 14:20:29 PDT 2017
Author: davide
Date: Fri Jul 14 14:20:29 2017
New Revision: 308055
URL: http://llvm.org/viewvc/llvm-project?rev=308055&view=rev
Log:
[AMDGPU] Throw away more dead code. NFCI.
Modified:
llvm/trunk/lib/Target/AMDGPU/AMDGPUAnnotateKernelFeatures.cpp
Modified: llvm/trunk/lib/Target/AMDGPU/AMDGPUAnnotateKernelFeatures.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/AMDGPU/AMDGPUAnnotateKernelFeatures.cpp?rev=308055&r1=308054&r2=308055&view=diff
==============================================================================
--- llvm/trunk/lib/Target/AMDGPU/AMDGPUAnnotateKernelFeatures.cpp (original)
+++ llvm/trunk/lib/Target/AMDGPU/AMDGPUAnnotateKernelFeatures.cpp Fri Jul 14 14:20:29 2017
@@ -35,8 +35,6 @@ private:
bool addFeatureAttributes(Function &F);
- void addAttrToCallers(Function &Intrin, StringRef AttrName);
-
public:
static char ID;
@@ -255,20 +253,6 @@ bool AMDGPUAnnotateKernelFeatures::addFe
return Changed;
}
-void AMDGPUAnnotateKernelFeatures::addAttrToCallers(Function &Intrin,
- StringRef AttrName) {
- SmallPtrSet<Function *, 4> SeenFuncs;
-
- for (User *U : Intrin.users()) {
- // CallInst is the only valid user for an intrinsic.
- CallInst *CI = cast<CallInst>(U);
-
- Function *CallingFunction = CI->getParent()->getParent();
- if (SeenFuncs.insert(CallingFunction).second)
- CallingFunction->addFnAttr(AttrName);
- }
-}
-
bool AMDGPUAnnotateKernelFeatures::runOnSCC(CallGraphSCC &SCC) {
Module &M = SCC.getCallGraph().getModule();
Triple TT(M.getTargetTriple());
More information about the llvm-commits
mailing list