diff options
author | Chris Lattner <sabre@nondot.org> | 2005-03-15 04:54:21 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2005-03-15 04:54:21 +0000 |
commit | 531f9e92d4d06d5cb1f250754c68e7d3b420df50 (patch) | |
tree | 741411707d21f866eb629b2449413d85b8b48667 /llvm/lib/Transforms/IPO/IPConstantPropagation.cpp | |
parent | 5ce25cdc6d8d274d9106280d861adaf4743e5f3d (diff) | |
download | bcm5719-llvm-531f9e92d4d06d5cb1f250754c68e7d3b420df50.tar.gz bcm5719-llvm-531f9e92d4d06d5cb1f250754c68e7d3b420df50.zip |
This mega patch converts us from using Function::a{iterator|begin|end} to
using Function::arg_{iterator|begin|end}. Likewise Module::g* -> Module::global_*.
This patch is contributed by Gabor Greif, thanks!
llvm-svn: 20597
Diffstat (limited to 'llvm/lib/Transforms/IPO/IPConstantPropagation.cpp')
-rw-r--r-- | llvm/lib/Transforms/IPO/IPConstantPropagation.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp b/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp index 65d507798b7..16839edff78 100644 --- a/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp +++ b/llvm/lib/Transforms/IPO/IPConstantPropagation.cpp @@ -69,10 +69,10 @@ bool IPCP::runOnModule(Module &M) { /// constant in for an argument, propagate that constant in as the argument. /// bool IPCP::PropagateConstantsIntoArguments(Function &F) { - if (F.aempty() || F.use_empty()) return false; // No arguments? Early exit. + if (F.arg_empty() || F.use_empty()) return false; // No arguments? Early exit. std::vector<std::pair<Constant*, bool> > ArgumentConstants; - ArgumentConstants.resize(F.asize()); + ArgumentConstants.resize(F.arg_size()); unsigned NumNonconstant = 0; @@ -87,7 +87,7 @@ bool IPCP::PropagateConstantsIntoArguments(Function &F) { // Check out all of the potentially constant arguments CallSite::arg_iterator AI = CS.arg_begin(); - Function::aiterator Arg = F.abegin(); + Function::arg_iterator Arg = F.arg_begin(); for (unsigned i = 0, e = ArgumentConstants.size(); i != e; ++i, ++AI, ++Arg) { if (*AI == &F) return false; // Passes the function into itself @@ -115,7 +115,7 @@ bool IPCP::PropagateConstantsIntoArguments(Function &F) { // If we got to this point, there is a constant argument! assert(NumNonconstant != ArgumentConstants.size()); - Function::aiterator AI = F.abegin(); + Function::arg_iterator AI = F.arg_begin(); bool MadeChange = false; for (unsigned i = 0, e = ArgumentConstants.size(); i != e; ++i, ++AI) // Do we have a constant argument!? |