summaryrefslogtreecommitdiff
path: root/lib/Transforms/Scalar/ScalarReplAggregates.cpp
diff options
context:
space:
mode:
authorBob Wilson <bob.wilson@apple.com>2009-12-08 18:27:03 +0000
committerBob Wilson <bob.wilson@apple.com>2009-12-08 18:27:03 +0000
commit65ab34f3f29f8e4efb10b2cc40e58c5ce63a76d7 (patch)
tree33cfb64681e414ef5e64d57929289d08a4344fbc /lib/Transforms/Scalar/ScalarReplAggregates.cpp
parent78c50b8cd68d266d4ed6f8eca443cf8142a01204 (diff)
downloadllvm-65ab34f3f29f8e4efb10b2cc40e58c5ce63a76d7.tar.gz
llvm-65ab34f3f29f8e4efb10b2cc40e58c5ce63a76d7.tar.bz2
llvm-65ab34f3f29f8e4efb10b2cc40e58c5ce63a76d7.tar.xz
Some superficial cleanups.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@90866 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Scalar/ScalarReplAggregates.cpp')
-rw-r--r--lib/Transforms/Scalar/ScalarReplAggregates.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/Transforms/Scalar/ScalarReplAggregates.cpp b/lib/Transforms/Scalar/ScalarReplAggregates.cpp
index abd4a77d34..e4ee46ef93 100644
--- a/lib/Transforms/Scalar/ScalarReplAggregates.cpp
+++ b/lib/Transforms/Scalar/ScalarReplAggregates.cpp
@@ -105,7 +105,7 @@ namespace {
void isSafeUseOfAllocation(Instruction *User, AllocaInst *AI,
AllocaInfo &Info);
void isSafeElementUse(Value *Ptr, bool isFirstElt, AllocaInst *AI,
- AllocaInfo &Info);
+ AllocaInfo &Info);
void isSafeMemIntrinsicOnAllocation(MemIntrinsic *MI, AllocaInst *AI,
unsigned OpNo, AllocaInfo &Info);
void isSafeUseOfBitCastedAllocation(BitCastInst *User, AllocaInst *AI,
@@ -362,7 +362,6 @@ void SROA::DoScalarReplacement(AllocaInst *AI,
// Now that we have created the alloca instructions that we want to use,
// expand the getelementptr instructions to use them.
- //
while (!AI->use_empty()) {
Instruction *User = cast<Instruction>(AI->use_back());
if (BitCastInst *BCInst = dyn_cast<BitCastInst>(User)) {
@@ -540,7 +539,7 @@ static bool AllUsersAreLoads(Value *Ptr) {
return true;
}
-/// isSafeUseOfAllocation - Check to see if this user is an allowed use for an
+/// isSafeUseOfAllocation - Check if this user is an allowed use for an
/// aggregate allocation.
void SROA::isSafeUseOfAllocation(Instruction *User, AllocaInst *AI,
AllocaInfo &Info) {
@@ -1216,7 +1215,7 @@ int SROA::isSafeAllocaToScalarRepl(AllocaInst *AI) {
return Info.needsCleanup ? 1 : 3;
}
-/// CleanupGEP - GEP is used by an Alloca, which can be prompted after the GEP
+/// CleanupGEP - GEP is used by an Alloca, which can be promoted after the GEP
/// is canonicalized here.
void SROA::CleanupGEP(GetElementPtrInst *GEPI) {
gep_type_iterator I = gep_type_begin(GEPI);