summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2015-02-18 03:44:20 +0000
committerAdam Nemet <anemet@apple.com>2015-02-18 03:44:20 +0000
commit8b12afbeee3e6ac2f2dea1988d814aab4489cbb9 (patch)
treedac320db316ce7f3709e71ae257a128cfdf2b579 /llvm/lib
parent450d417ecfeaacabd625e1959325dc240bc9d670 (diff)
downloadbcm5719-llvm-8b12afbeee3e6ac2f2dea1988d814aab4489cbb9.tar.gz
bcm5719-llvm-8b12afbeee3e6ac2f2dea1988d814aab4489cbb9.zip
[LoopAccesses] Add missing const to APIs in VectorizationReport
When I split out LoopAccessReport from this, I need to create some temps so constness becomes necessary. This is part of the patchset that converts LoopAccessAnalysis into an actual analysis pass. llvm-svn: 229631
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Analysis/LoopAccessAnalysis.cpp4
-rw-r--r--llvm/lib/Transforms/Vectorize/LoopVectorize.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/Analysis/LoopAccessAnalysis.cpp b/llvm/lib/Analysis/LoopAccessAnalysis.cpp
index ba2f9b8e427..68f9ee1cb4e 100644
--- a/llvm/lib/Analysis/LoopAccessAnalysis.cpp
+++ b/llvm/lib/Analysis/LoopAccessAnalysis.cpp
@@ -25,12 +25,12 @@ using namespace llvm;
#define DEBUG_TYPE "loop-accesses"
-void VectorizationReport::emitAnalysis(VectorizationReport &Message,
+void VectorizationReport::emitAnalysis(const VectorizationReport &Message,
const Function *TheFunction,
const Loop *TheLoop,
const char *PassName) {
DebugLoc DL = TheLoop->getStartLoc();
- if (Instruction *I = Message.getInstr())
+ if (const Instruction *I = Message.getInstr())
DL = I->getDebugLoc();
emitOptimizationRemarkAnalysis(TheFunction->getContext(), PassName,
*TheFunction, DL, Message.str());
diff --git a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
index efbc746ef62..a6dbeed6bc8 100644
--- a/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
+++ b/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
@@ -836,7 +836,7 @@ private:
/// Report an analysis message to assist the user in diagnosing loops that are
/// not vectorized.
- void emitAnalysis(VectorizationReport &Message) {
+ void emitAnalysis(const VectorizationReport &Message) {
VectorizationReport::emitAnalysis(Message, TheFunction, TheLoop, LV_NAME);
}
@@ -973,7 +973,7 @@ private:
/// Report an analysis message to assist the user in diagnosing loops that are
/// not vectorized.
- void emitAnalysis(VectorizationReport &Message) {
+ void emitAnalysis(const VectorizationReport &Message) {
VectorizationReport::emitAnalysis(Message, TheFunction, TheLoop, LV_NAME);
}
OpenPOWER on IntegriCloud