From: Chris Lattner Date: Thu, 28 Mar 2002 18:08:31 +0000 (+0000) Subject: Initial checkin of Noop pass that will be the pool allocator X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=bda28f7c2aaae557c56a602117670263c8608a84;p=oota-llvm.git Initial checkin of Noop pass that will be the pool allocator git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@2014 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Transforms/IPO/OldPoolAllocate.cpp b/lib/Transforms/IPO/OldPoolAllocate.cpp new file mode 100644 index 00000000000..53c9c94e37c --- /dev/null +++ b/lib/Transforms/IPO/OldPoolAllocate.cpp @@ -0,0 +1,33 @@ +//===-- PoolAllocate.cpp - Pool Allocation Pass ---------------------------===// +// +// This transform changes programs so that disjoint data structures are +// allocated out of different pools of memory, increasing locality and shrinking +// pointer size. +// +//===----------------------------------------------------------------------===// + +#include "llvm/Transforms/IPO/PoolAllocate.h" +#include "llvm/Analysis/DataStructure.h" +#include "llvm/Pass.h" + + +namespace { + struct PoolAllocate : public Pass { + bool run(Module *M) { + DataStructure &DS = getAnalysis(); + return false; + } + + // getAnalysisUsageInfo - This function works on the call graph of a module. + // It is capable of updating the call graph to reflect the new state of the + // module. + // + virtual void getAnalysisUsageInfo(Pass::AnalysisSet &Required, + Pass::AnalysisSet &Destroyed, + Pass::AnalysisSet &Provided) { + Required.push_back(DataStructure::ID); + } + }; +} + +Pass *createPoolAllocatePass() { return new PoolAllocate(); }