[poolalloc] r231377 - Fixes for DataLayout moved from pass to Module. NFC intended.
Will Dietz
wdietz2 at illinois.edu
Thu Mar 5 08:10:10 PST 2015
- Previous message: [poolalloc] r231376 - Minor lit cfg changes for cleaner diff, NFC.
- Next message: [llvm] r231378 - While reviewing the changes to Clang to add builtin support for the vsld, vsrd, and vsrad instructions, it was pointed out that the builtins are generating the LLVM opcodes (shl, lshr, and ashr) not calls to the intrinsics. This patch changes the implementation of the vsld, vsrd, and vsrad instructions from from intrinsics to VXForm_1 instructions and makes them legal with P8 Altivec. It also removes the definition of the int_ppc_altivec_vsld, int_ppc_altivec_vsrd, and int_ppc_altivec_vs...
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: wdietz2
Date: Thu Mar 5 10:10:09 2015
New Revision: 231377
URL: http://llvm.org/viewvc/llvm-project?rev=231377&view=rev
Log:
Fixes for DataLayout moved from pass to Module. NFC intended.
Modified:
poolalloc/trunk/include/assistDS/Devirt.h
poolalloc/trunk/include/assistDS/Int2PtrCmp.h
poolalloc/trunk/include/assistDS/MergeGEP.h
poolalloc/trunk/include/assistDS/SimplifyGEP.h
poolalloc/trunk/include/assistDS/TypeChecks.h
poolalloc/trunk/include/assistDS/TypeChecksOpt.h
poolalloc/trunk/include/dsa/DataStructure.h
poolalloc/trunk/include/dsa/TypeSafety.h
poolalloc/trunk/lib/AssistDS/Devirt.cpp
poolalloc/trunk/lib/AssistDS/DynCount.cpp
poolalloc/trunk/lib/AssistDS/Int2PtrCmp.cpp
poolalloc/trunk/lib/AssistDS/SimplifyExtractValue.cpp
poolalloc/trunk/lib/AssistDS/SimplifyGEP.cpp
poolalloc/trunk/lib/AssistDS/SimplifyInsertValue.cpp
poolalloc/trunk/lib/AssistDS/SimplifyLoad.cpp
poolalloc/trunk/lib/AssistDS/TypeChecks.cpp
poolalloc/trunk/lib/DSA/Basic.cpp
poolalloc/trunk/lib/DSA/DSGraph.cpp
poolalloc/trunk/lib/DSA/DataStructure.cpp
poolalloc/trunk/lib/DSA/DataStructureStats.cpp
poolalloc/trunk/lib/DSA/Local.cpp
poolalloc/trunk/lib/DSA/StdLibPass.cpp
poolalloc/trunk/lib/DSA/TypeSafety.cpp
poolalloc/trunk/lib/PoolAllocate/AllHeapNodesHeuristic.cpp
poolalloc/trunk/lib/PoolAllocate/Heuristic.cpp
poolalloc/trunk/lib/PoolAllocate/PAMultipleGlobalPool.cpp
poolalloc/trunk/lib/PoolAllocate/PASimple.cpp
poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp
poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
Modified: poolalloc/trunk/include/assistDS/Devirt.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/assistDS/Devirt.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/assistDS/Devirt.h (original)
+++ poolalloc/trunk/include/assistDS/Devirt.h Thu Mar 5 10:10:09 2015
@@ -22,7 +22,6 @@
#include "llvm/IR/Instructions.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/InstVisitor.h"
-#include "llvm/IR/DataLayout.h"
using namespace llvm;
@@ -40,9 +39,6 @@ namespace llvm {
// Access to analysis pass which finds targets of indirect function calls
dsa::CallTargetFinder<EQTDDataStructures> *CTF;
- // Access to the target data analysis pass
- const DataLayout * TD;
-
// Worklist of call sites to transform
std::vector<Instruction *> Worklist;
@@ -63,7 +59,6 @@ namespace llvm {
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
AU.addRequired<dsa::CallTargetFinder<EQTDDataStructures> >();
- AU.addRequired<DataLayoutPass>();
}
// Visitor methods for analyzing instructions
Modified: poolalloc/trunk/include/assistDS/Int2PtrCmp.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/assistDS/Int2PtrCmp.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/assistDS/Int2PtrCmp.h (original)
+++ poolalloc/trunk/include/assistDS/Int2PtrCmp.h Thu Mar 5 10:10:09 2015
@@ -13,7 +13,6 @@
//
//===----------------------------------------------------------------------===//
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
@@ -25,16 +24,10 @@ namespace llvm {
//
//
class Int2PtrCmp : public ModulePass {
- private:
- const DataLayout * TD;
public:
static char ID;
Int2PtrCmp() : ModulePass(ID) {}
virtual bool runOnModule(Module& M);
- virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
- }
-
};
}
Modified: poolalloc/trunk/include/assistDS/MergeGEP.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/assistDS/MergeGEP.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/assistDS/MergeGEP.h (original)
+++ poolalloc/trunk/include/assistDS/MergeGEP.h Thu Mar 5 10:10:09 2015
@@ -11,7 +11,6 @@
//
//===----------------------------------------------------------------------===//
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
Modified: poolalloc/trunk/include/assistDS/SimplifyGEP.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/assistDS/SimplifyGEP.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/assistDS/SimplifyGEP.h (original)
+++ poolalloc/trunk/include/assistDS/SimplifyGEP.h Thu Mar 5 10:10:09 2015
@@ -11,7 +11,6 @@
//
//===----------------------------------------------------------------------===//
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
@@ -21,15 +20,10 @@ namespace llvm {
// Class: SimplifyGEP
//
class SimplifyGEP : public ModulePass {
- private:
- const DataLayout * TD;
public:
static char ID;
SimplifyGEP() : ModulePass(ID) {}
virtual bool runOnModule(Module& M);
- virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
- }
};
}
Modified: poolalloc/trunk/include/assistDS/TypeChecks.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/assistDS/TypeChecks.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/assistDS/TypeChecks.h (original)
+++ poolalloc/trunk/include/assistDS/TypeChecks.h Thu Mar 5 10:10:09 2015
@@ -16,9 +16,9 @@
#include "dsa/AddressTakenAnalysis.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Function.h"
+#include "llvm/IR/Module.h"
#include "llvm/Pass.h"
#include "llvm/IR/CallSite.h"
#include "llvm/IR/Dominators.h"
@@ -100,7 +100,6 @@ public:
virtual void print(raw_ostream &OS, const Module *M) const;
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
AU.addRequired<DominatorTreeWrapperPass>();
AU.addRequired<LoopInfoWrapperPass>();
AU.addRequired<AddressTakenAnalysis>();
Modified: poolalloc/trunk/include/assistDS/TypeChecksOpt.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/assistDS/TypeChecksOpt.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/assistDS/TypeChecksOpt.h (original)
+++ poolalloc/trunk/include/assistDS/TypeChecksOpt.h Thu Mar 5 10:10:09 2015
@@ -17,7 +17,6 @@
#include "dsa/TypeSafety.h"
#include "llvm/Pass.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/CallSite.h"
Modified: poolalloc/trunk/include/dsa/DataStructure.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/dsa/DataStructure.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/dsa/DataStructure.h (original)
+++ poolalloc/trunk/include/dsa/DataStructure.h Thu Mar 5 10:10:09 2015
@@ -21,8 +21,8 @@
#include "dsa/AllocatorIdentification.h"
#include "llvm/Pass.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/CallSite.h"
+#include "llvm/IR/Module.h"
#include "llvm/ADT/EquivalenceClasses.h"
#include "llvm/ADT/DenseSet.h"
@@ -165,7 +165,6 @@ public:
/// getAnalysisUsage - This obviously provides a data structure graph.
///
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
AU.setPreservesAll();
}
};
@@ -188,7 +187,6 @@ public:
/// getAnalysisUsage - This obviously provides a data structure graph.
///
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
AU.addRequired<AddressTakenAnalysis>();
AU.setPreservesAll();
}
Modified: poolalloc/trunk/include/dsa/TypeSafety.h
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/include/dsa/TypeSafety.h?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/include/dsa/TypeSafety.h (original)
+++ poolalloc/trunk/include/dsa/TypeSafety.h Thu Mar 5 10:10:09 2015
@@ -65,7 +65,6 @@ struct TypeSafety : public ModulePass {
}
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
AU.addRequired<dsa>();
AU.setPreservesAll();
}
Modified: poolalloc/trunk/lib/AssistDS/Devirt.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/Devirt.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/Devirt.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/Devirt.cpp Thu Mar 5 10:10:09 2015
@@ -395,12 +395,6 @@ Devirtualize::runOnModule (Module & M) {
//
CTF = &getAnalysis<dsa::CallTargetFinder<EQTDDataStructures> >();
- //
- // Get information on the target system.
- //
- //
- TD = &getAnalysis<DataLayoutPass>().getDataLayout();
-
// Visit all of the call instructions in this function and record those that
// are indirect function calls.
//
Modified: poolalloc/trunk/lib/AssistDS/DynCount.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/DynCount.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/DynCount.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/DynCount.cpp Thu Mar 5 10:10:09 2015
@@ -16,7 +16,6 @@
#include "llvm/IR/Module.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Constants.h"
-#include "llvm/IR/DataLayout.h"
#include "dsa/TypeSafety.h"
using namespace llvm;
@@ -34,7 +33,6 @@ public:
}
virtual bool runOnModule (Module & M);
virtual void getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
AU.addRequired<dsa::TypeSafety<TDDataStructures> >();
}
};
Modified: poolalloc/trunk/lib/AssistDS/Int2PtrCmp.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/Int2PtrCmp.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/Int2PtrCmp.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/Int2PtrCmp.cpp Thu Mar 5 10:10:09 2015
@@ -45,7 +45,7 @@ using namespace PatternMatch;
// false - The module was not modified.
//
bool Int2PtrCmp::runOnModule(Module& M) {
- TD = &getAnalysis<DataLayoutPass>().getDataLayout();
+ const DataLayout &TD = M.getDataLayout();
for (Module::iterator F = M.begin(); F != M.end(); ++F) {
for (Function::iterator B = F->begin(), FE = F->end(); B != FE; ++B) {
for (BasicBlock::iterator I = B->begin(), BE = B->end(); I != BE;) {
@@ -71,8 +71,8 @@ bool Int2PtrCmp::runOnModule(Module& M)
if (Constant *RHSC = dyn_cast<Constant>(Op1)) {
if (Instruction *LHSI = dyn_cast<Instruction>(Op0)){
if(LHSI->getOpcode() == Instruction::IntToPtr) {
- if (RHSC->isNullValue() && TD &&
- TD->getIntPtrType(RHSC->getContext(), 0) ==
+ if (RHSC->isNullValue() &&
+ TD.getIntPtrType(RHSC->getContext(), 0) ==
LHSI->getOperand(0)->getType()){
ICmpInst *CI_new = new ICmpInst(CI, CI->getPredicate(), LHSI->getOperand(0),
Constant::getNullValue(LHSI->getOperand(0)->getType()));
Modified: poolalloc/trunk/lib/AssistDS/SimplifyExtractValue.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/SimplifyExtractValue.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/SimplifyExtractValue.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/SimplifyExtractValue.cpp Thu Mar 5 10:10:09 2015
@@ -21,7 +21,6 @@
#include "llvm/Support/FormattedStream.h"
#include "llvm/Support/Debug.h"
#include "llvm/IR/PatternMatch.h"
-#include "llvm/IR/DataLayout.h"
#include <set>
#include <map>
Modified: poolalloc/trunk/lib/AssistDS/SimplifyGEP.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/SimplifyGEP.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/SimplifyGEP.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/SimplifyGEP.cpp Thu Mar 5 10:10:09 2015
@@ -19,7 +19,7 @@
#include "llvm/Support/FormattedStream.h"
#include "llvm/Support/Debug.h"
#include "llvm/IR/Constants.h"
-#include "llvm/IR/DataLayout.h"
+#include "llvm/IR/Module.h"
#include "llvm/IR/Operator.h"
#include <vector>
@@ -75,7 +75,7 @@ static void preprocess(Module& M) {
// false - The module was not modified.
//
bool SimplifyGEP::runOnModule(Module& M) {
- TD = &getAnalysis<DataLayoutPass>().getDataLayout();
+ const DataLayout &TD = M.getDataLayout();
preprocess(M);
for (Module::iterator F = M.begin(); F != M.end(); ++F){
for (Function::iterator B = F->begin(), FE = F->end(); B != FE; ++B) {
@@ -133,9 +133,9 @@ bool SimplifyGEP::runOnModule(Module& M)
// into: %t1 = getelementptr [2 x i32]* %str, i32 0, i32 %V; bitcast
Type *SrcElTy = StrippedPtrTy->getElementType();
Type *ResElTy=cast<PointerType>(PtrOp->getType())->getElementType();
- if (TD && SrcElTy->isArrayTy() &&
- TD->getTypeAllocSize(cast<ArrayType>(SrcElTy)->getElementType()) ==
- TD->getTypeAllocSize(ResElTy)) {
+ if (SrcElTy->isArrayTy() &&
+ TD.getTypeAllocSize(cast<ArrayType>(SrcElTy)->getElementType()) ==
+ TD.getTypeAllocSize(ResElTy)) {
Value *Idx[2];
Idx[0] = Constant::getNullValue(Type::getInt32Ty(GEP->getContext()));
Idx[1] = GEP->getOperand(1);
@@ -151,9 +151,9 @@ bool SimplifyGEP::runOnModule(Module& M)
// (where tmp = 8*tmp2) into:
// getelementptr [100 x double]* %arr, i32 0, i32 %tmp2; bitcast
- if (TD && SrcElTy->isArrayTy() && ResElTy->isIntegerTy(8)) {
+ if (SrcElTy->isArrayTy() && ResElTy->isIntegerTy(8)) {
uint64_t ArrayEltSize =
- TD->getTypeAllocSize(cast<ArrayType>(SrcElTy)->getElementType());
+ TD.getTypeAllocSize(cast<ArrayType>(SrcElTy)->getElementType());
// Check to see if "tmp" is a scale by a multiple of ArrayEltSize. We
// allow either a mul, shift, or constant here.
Modified: poolalloc/trunk/lib/AssistDS/SimplifyInsertValue.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/SimplifyInsertValue.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/SimplifyInsertValue.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/SimplifyInsertValue.cpp Thu Mar 5 10:10:09 2015
@@ -19,7 +19,6 @@
#include "llvm/Support/FormattedStream.h"
#include "llvm/Support/Debug.h"
#include "llvm/IR/PatternMatch.h"
-#include "llvm/IR/DataLayout.h"
#include <set>
#include <map>
Modified: poolalloc/trunk/lib/AssistDS/SimplifyLoad.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/SimplifyLoad.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/SimplifyLoad.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/SimplifyLoad.cpp Thu Mar 5 10:10:09 2015
@@ -17,7 +17,6 @@
#include "llvm/Support/FormattedStream.h"
#include "llvm/Support/Debug.h"
#include "llvm/IR/PatternMatch.h"
-#include "llvm/IR/DataLayout.h"
#include <set>
#include <map>
Modified: poolalloc/trunk/lib/AssistDS/TypeChecks.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/AssistDS/TypeChecks.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/AssistDS/TypeChecks.cpp (original)
+++ poolalloc/trunk/lib/AssistDS/TypeChecks.cpp Thu Mar 5 10:10:09 2015
@@ -153,7 +153,7 @@ bool TypeChecks::runOnModule(Module &M)
bool modified = false; // Flags whether we modified the module.
bool transformIndirectCalls = true;
- TD = &getAnalysis<DataLayoutPass>().getDataLayout();
+ TD = &M.getDataLayout();
addrAnalysis = &getAnalysis<AddressTakenAnalysis>();
// Create the necessary prototypes
Modified: poolalloc/trunk/lib/DSA/Basic.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/Basic.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/Basic.cpp (original)
+++ poolalloc/trunk/lib/DSA/Basic.cpp Thu Mar 5 10:10:09 2015
@@ -33,7 +33,7 @@ X("dsa-basic", "Basic Data Structure Ana
char BasicDataStructures::ID = 0;
bool BasicDataStructures::runOnModule(Module &M) {
- init(&getAnalysis<DataLayoutPass>().getDataLayout());
+ init(&M.getDataLayout());
//
// Create a void pointer type. This is simply a pointer to an 8 bit value.
Modified: poolalloc/trunk/lib/DSA/DSGraph.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/DSGraph.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/DSGraph.cpp (original)
+++ poolalloc/trunk/lib/DSA/DSGraph.cpp Thu Mar 5 10:10:09 2015
@@ -24,7 +24,6 @@
#include "llvm/IR/GlobalVariable.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/DerivedTypes.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/ADT/DepthFirstIterator.h"
Modified: poolalloc/trunk/lib/DSA/DataStructure.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/DataStructure.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/DataStructure.cpp (original)
+++ poolalloc/trunk/lib/DSA/DataStructure.cpp Thu Mar 5 10:10:09 2015
@@ -23,7 +23,7 @@
#include "llvm/IR/GlobalVariable.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/DerivedTypes.h"
-#include "llvm/IR/DataLayout.h"
+#include "llvm/IR/Module.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/ADT/DepthFirstIterator.h"
Modified: poolalloc/trunk/lib/DSA/DataStructureStats.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/DataStructureStats.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/DataStructureStats.cpp (original)
+++ poolalloc/trunk/lib/DSA/DataStructureStats.cpp Thu Mar 5 10:10:09 2015
@@ -66,7 +66,6 @@ namespace {
class DSGraphStats : public FunctionPass, public InstVisitor<DSGraphStats> {
void countCallees(const Function &F);
const TDDataStructures *DS;
- const DataLayout *TD;
const DSGraph *TDGraph;
dsa::TypeSafety<TDDataStructures> *TS;
DSNodeHandle getNodeHandleForValue(Value *V);
@@ -82,7 +81,6 @@ namespace {
void getAnalysisUsage(AnalysisUsage &AU) const {
AU.setPreservesAll();
AU.addRequired<TDDataStructures>();
- AU.addRequired<DataLayoutPass>();
AU.addRequired<dsa::TypeSafety<TDDataStructures> >();
}
@@ -238,7 +236,6 @@ void DSGraphStats::visitStore(StoreInst
bool DSGraphStats::runOnFunction(Function& F) {
DS = &getAnalysis<TDDataStructures>();
- TD = &getAnalysis<DataLayoutPass>().getDataLayout();
TS = &getAnalysis<dsa::TypeSafety<TDDataStructures> >();
TDGraph = DS->getDSGraph(F);
countCallees(F);
Modified: poolalloc/trunk/lib/DSA/Local.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/Local.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/Local.cpp (original)
+++ poolalloc/trunk/lib/DSA/Local.cpp Thu Mar 5 10:10:09 2015
@@ -21,8 +21,8 @@
#include "llvm/ADT/DenseSet.h"
#include "llvm/ADT/Triple.h"
#include "llvm/IR/Constants.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/DerivedTypes.h"
+#include "llvm/IR/Module.h"
#include "llvm/IR/InlineAsm.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/IR/Instructions.h"
@@ -1442,7 +1442,7 @@ void handleMagicSections(DSGraph* Global
char LocalDataStructures::ID;
bool LocalDataStructures::runOnModule(Module &M) {
- init(&getAnalysis<DataLayoutPass>().getDataLayout());
+ init(&M.getDataLayout());
addrAnalysis = &getAnalysis<AddressTakenAnalysis>();
// First step, build the globals graph.
Modified: poolalloc/trunk/lib/DSA/StdLibPass.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/StdLibPass.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/StdLibPass.cpp (original)
+++ poolalloc/trunk/lib/DSA/StdLibPass.cpp Thu Mar 5 10:10:09 2015
@@ -18,10 +18,10 @@
#include "dsa/DSGraph.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/DerivedTypes.h"
+#include "llvm/IR/GetElementPtrTypeIterator.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Intrinsics.h"
-#include "llvm/IR/GetElementPtrTypeIterator.h"
-#include "llvm/IR/DataLayout.h"
+#include "llvm/IR/Module.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/Debug.h"
#include "llvm/Support/FormattedStream.h"
Modified: poolalloc/trunk/lib/DSA/TypeSafety.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/DSA/TypeSafety.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/DSA/TypeSafety.cpp (original)
+++ poolalloc/trunk/lib/DSA/TypeSafety.cpp Thu Mar 5 10:10:09 2015
@@ -333,7 +333,7 @@ TypeSafety<dsa>::runOnModule(Module & M)
//
// Get access to prerequisite passes.
//
- TD = &getAnalysis<DataLayoutPass>().getDataLayout();
+ TD = &M.getDataLayout();
dsaPass = &getAnalysis<dsa>();
//
Modified: poolalloc/trunk/lib/PoolAllocate/AllHeapNodesHeuristic.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/AllHeapNodesHeuristic.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/AllHeapNodesHeuristic.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/AllHeapNodesHeuristic.cpp Thu Mar 5 10:10:09 2015
@@ -25,7 +25,7 @@
#include "llvm/ADT/DepthFirstIterator.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/FormattedStream.h"
-#include "llvm/IR/DataLayout.h"
+#include "llvm/IR/Module.h"
#include <iostream>
using namespace llvm;
Modified: poolalloc/trunk/lib/PoolAllocate/Heuristic.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/Heuristic.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/Heuristic.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/Heuristic.cpp Thu Mar 5 10:10:09 2015
@@ -24,7 +24,6 @@
#include "llvm/ADT/DepthFirstIterator.h"
#include "llvm/Support/CommandLine.h"
#include "llvm/Support/FormattedStream.h"
-#include "llvm/IR/DataLayout.h"
#include <iostream>
using namespace llvm;
Modified: poolalloc/trunk/lib/PoolAllocate/PAMultipleGlobalPool.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/PAMultipleGlobalPool.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/PAMultipleGlobalPool.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/PAMultipleGlobalPool.cpp Thu Mar 5 10:10:09 2015
@@ -21,7 +21,6 @@
#include "poolalloc/PoolAllocate.h"
#include "llvm/IR/Constants.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Module.h"
@@ -74,7 +73,6 @@ castTo (Value * V, Type * Ty, const std:
}
void PoolAllocateMultipleGlobalPool::getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
assert(0 && "PoolAllocateMultipleGlobalPool doesn't work! Needs Steensgard-like analysis, which was removed!");
//AU.addRequiredTransitive<SteensgaardDataStructures>();
// It is a big lie.
@@ -96,7 +94,7 @@ bool PoolAllocateMultipleGlobalPool::run
Graphs = NULL;
assert (Graphs && "No DSA pass available!\n");
- const DataLayout & TD = getAnalysis<DataLayoutPass>().getDataLayout();
+ const DataLayout & TD = M.getDataLayout();
// Add the pool* prototypes to the module
AddPoolPrototypes(&M);
Modified: poolalloc/trunk/lib/PoolAllocate/PASimple.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/PASimple.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/PASimple.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/PASimple.cpp Thu Mar 5 10:10:09 2015
@@ -19,7 +19,6 @@
#include "dsa/CallTargets.h"
#include "poolalloc/PoolAllocate.h"
#include "llvm/IR/Constants.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Module.h"
@@ -70,7 +69,6 @@ castTo (Value * V, Type * Ty, std::strin
}
void PoolAllocateSimple::getAnalysisUsage(AnalysisUsage &AU) const {
- AU.addRequired<DataLayoutPass>();
// Get the Target Data information and the Graphs
if (CompleteDSA) {
AU.addRequiredTransitive<EQTDDataStructures>();
@@ -131,7 +129,7 @@ bool PoolAllocateSimple::runOnModule(Mod
Graphs = &getAnalysis<BasicDataStructures>();
}
assert (Graphs && "No DSA pass available!\n");
- const DataLayout & TD = getAnalysis<DataLayoutPass>().getDataLayout();
+ const DataLayout & TD = M.getDataLayout();
// Add the pool* prototypes to the module
AddPoolPrototypes(&M);
Modified: poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/PoolAllocate.cpp Thu Mar 5 10:10:09 2015
@@ -23,7 +23,6 @@
#include "poolalloc/RuntimeChecks.h"
#include "llvm/IR/Attributes.h"
#include "llvm/IR/Constants.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Module.h"
@@ -217,8 +216,6 @@ void PoolAllocate::getAnalysisUsage(Anal
// Preserve the pool information across passes
if (lie_preserve_passes == LIE_PRESERVE_ALL)
AU.setPreservesAll();
-
- AU.addRequired<DataLayoutPass>();
}
bool PoolAllocate::runOnModule(Module &M) {
Modified: poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp
URL: http://llvm.org/viewvc/llvm-project/poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp?rev=231377&r1=231376&r2=231377&view=diff
==============================================================================
--- poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp (original)
+++ poolalloc/trunk/lib/PoolAllocate/TransformFunctionBody.cpp Thu Mar 5 10:10:09 2015
@@ -22,7 +22,6 @@
#include "llvm/IR/DerivedTypes.h"
#include "llvm/IR/Constants.h"
#include "llvm/IR/Instructions.h"
-#include "llvm/IR/DataLayout.h"
#include "llvm/IR/InstVisitor.h"
#include "llvm/Support/FormattedStream.h"
#include "llvm/Support/Debug.h"
- Previous message: [poolalloc] r231376 - Minor lit cfg changes for cleaner diff, NFC.
- Next message: [llvm] r231378 - While reviewing the changes to Clang to add builtin support for the vsld, vsrd, and vsrad instructions, it was pointed out that the builtins are generating the LLVM opcodes (shl, lshr, and ashr) not calls to the intrinsics. This patch changes the implementation of the vsld, vsrd, and vsrad instructions from from intrinsics to VXForm_1 instructions and makes them legal with P8 Altivec. It also removes the definition of the int_ppc_altivec_vsld, int_ppc_altivec_vsrd, and int_ppc_altivec_vs...
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the llvm-commits
mailing list