summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Scalar
diff options
context:
space:
mode:
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>2015-04-21 18:44:06 +0000
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>2015-04-21 18:44:06 +0000
commit60635e39b669713fe8d7b40bf8b4b10fb7fb34d6 (patch)
treea0a124c763e644d915844e862e6216375674137f /llvm/lib/Transforms/Scalar
parentdadc2b627d834acda6def76209db2c2001a079a9 (diff)
downloadbcm5719-llvm-60635e39b669713fe8d7b40bf8b4b10fb7fb34d6.tar.gz
bcm5719-llvm-60635e39b669713fe8d7b40bf8b4b10fb7fb34d6.zip
DebugInfo: Drop rest of DIDescriptor subclasses
Delete the remaining subclasses of (the already deleted) `DIDescriptor`. Part of PR23080. llvm-svn: 235404
Diffstat (limited to 'llvm/lib/Transforms/Scalar')
-rw-r--r--llvm/lib/Transforms/Scalar/SROA.cpp12
-rw-r--r--llvm/lib/Transforms/Scalar/SampleProfile.cpp2
-rw-r--r--llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp6
3 files changed, 10 insertions, 10 deletions
diff --git a/llvm/lib/Transforms/Scalar/SROA.cpp b/llvm/lib/Transforms/Scalar/SROA.cpp
index 59dc52811c9..e11ab33b0fb 100644
--- a/llvm/lib/Transforms/Scalar/SROA.cpp
+++ b/llvm/lib/Transforms/Scalar/SROA.cpp
@@ -1166,9 +1166,9 @@ public:
} else {
continue;
}
- DIB.insertDbgValueIntrinsic(Arg, 0, DIVariable(DVI->getVariable()),
- DIExpression(DVI->getExpression()),
- DVI->getDebugLoc(), Inst);
+ DIB.insertDbgValueIntrinsic(Arg, 0, DVI->getVariable(),
+ DVI->getExpression(), DVI->getDebugLoc(),
+ Inst);
}
}
};
@@ -4181,15 +4181,15 @@ bool SROA::splitAlloca(AllocaInst &AI, AllocaSlices &AS) {
// Migrate debug information from the old alloca to the new alloca(s)
// and the individial partitions.
if (DbgDeclareInst *DbgDecl = FindAllocaDbgDeclare(&AI)) {
- DIVariable Var(DbgDecl->getVariable());
- DIExpression Expr(DbgDecl->getExpression());
+ auto *Var = DbgDecl->getVariable();
+ auto *Expr = DbgDecl->getExpression();
DIBuilder DIB(*AI.getParent()->getParent()->getParent(),
/*AllowUnresolved*/ false);
bool IsSplit = Pieces.size() > 1;
for (auto Piece : Pieces) {
// Create a piece expression describing the new partition or reuse AI's
// expression if there is only one partition.
- DIExpression PieceExpr = Expr;
+ auto *PieceExpr = Expr;
if (IsSplit || Expr->isBitPiece()) {
// If this alloca is already a scalar replacement of a larger aggregate,
// Piece.Offset describes the offset inside the scalar.
diff --git a/llvm/lib/Transforms/Scalar/SampleProfile.cpp b/llvm/lib/Transforms/Scalar/SampleProfile.cpp
index f99fe3f5512..f4936b57062 100644
--- a/llvm/lib/Transforms/Scalar/SampleProfile.cpp
+++ b/llvm/lib/Transforms/Scalar/SampleProfile.cpp
@@ -224,7 +224,7 @@ unsigned SampleProfileLoader::getInstWeight(Instruction &Inst) {
if (Lineno < HeaderLineno)
return 0;
- DILocation DIL = DLoc.get();
+ const MDLocation *DIL = DLoc;
int LOffset = Lineno - HeaderLineno;
unsigned Discriminator = DIL->getDiscriminator();
unsigned Weight = Samples->samplesAt(LOffset, Discriminator);
diff --git a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp
index 693c5ae9708..03fff1df5d9 100644
--- a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp
+++ b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp
@@ -1117,9 +1117,9 @@ public:
} else {
continue;
}
- DIB->insertDbgValueIntrinsic(Arg, 0, DIVariable(DVI->getVariable()),
- DIExpression(DVI->getExpression()),
- DVI->getDebugLoc(), Inst);
+ DIB->insertDbgValueIntrinsic(Arg, 0, DVI->getVariable(),
+ DVI->getExpression(), DVI->getDebugLoc(),
+ Inst);
}
}
};
OpenPOWER on IntegriCloud