summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/AliasSetTracker.cpp
diff options
context:
space:
mode:
authorPhilip Reames <listmail@philipreames.com>2019-02-06 03:46:40 +0000
committerPhilip Reames <listmail@philipreames.com>2019-02-06 03:46:40 +0000
commit00ae46ba5291628d6a8433d370b900c8543e10d2 (patch)
tree0f328b7cbf79eb4f1cf3e90c9b409503c8750f27 /llvm/lib/Analysis/AliasSetTracker.cpp
parentb5bb4a4ec6f3f0f6c023771a17be92de20d9582f (diff)
downloadbcm5719-llvm-00ae46ba5291628d6a8433d370b900c8543e10d2.tar.gz
bcm5719-llvm-00ae46ba5291628d6a8433d370b900c8543e10d2.zip
[AliasSetTracker] Minor style tweak to avoid a variable w/two distinct live ranges [NFC]
llvm-svn: 353267
Diffstat (limited to 'llvm/lib/Analysis/AliasSetTracker.cpp')
-rw-r--r--llvm/lib/Analysis/AliasSetTracker.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/llvm/lib/Analysis/AliasSetTracker.cpp b/llvm/lib/Analysis/AliasSetTracker.cpp
index 6b4240c108d..b0d38e85188 100644
--- a/llvm/lib/Analysis/AliasSetTracker.cpp
+++ b/llvm/lib/Analysis/AliasSetTracker.cpp
@@ -428,14 +428,12 @@ void AliasSetTracker::addUnknown(Instruction *Inst) {
if (!Inst->mayReadOrWriteMemory())
return; // doesn't alias anything
- AliasSet *AS = findAliasSetForUnknownInst(Inst);
- if (AS) {
+ if (AliasSet *AS = findAliasSetForUnknownInst(Inst)) {
AS->addUnknownInst(Inst, AA);
return;
}
AliasSets.push_back(new AliasSet());
- AS = &AliasSets.back();
- AS->addUnknownInst(Inst, AA);
+ AliasSets.back().addUnknownInst(Inst, AA);
}
void AliasSetTracker::add(Instruction *I) {
OpenPOWER on IntegriCloud