summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@intel.com>2017-06-21 19:39:33 +0000
committerCraig Topper <craig.topper@intel.com>2017-06-21 19:39:33 +0000
commit99a2e8992046431709205f63452d8bf53cf99081 (patch)
tree6551b9e9df1b6247b23ef9dc4ab4ec732cc9bb18 /llvm/lib/Transforms
parent258927e3da21c393dda09a6173dbf2912e3f81cd (diff)
downloadbcm5719-llvm-99a2e8992046431709205f63452d8bf53cf99081.tar.gz
bcm5719-llvm-99a2e8992046431709205f63452d8bf53cf99081.zip
[Reassociate] Const correct a helper function. NFC
llvm-svn: 305945
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/Scalar/Reassociate.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Transforms/Scalar/Reassociate.cpp b/llvm/lib/Transforms/Scalar/Reassociate.cpp
index 99c46ae8cbe..bd896c012e8 100644
--- a/llvm/lib/Transforms/Scalar/Reassociate.cpp
+++ b/llvm/lib/Transforms/Scalar/Reassociate.cpp
@@ -957,8 +957,8 @@ static BinaryOperator *ConvertShiftToMul(Instruction *Shl) {
/// Scan backwards and forwards among values with the same rank as element i
/// to see if X exists. If X does not exist, return i. This is useful when
/// scanning for 'x' when we see '-x' because they both get the same rank.
-static unsigned FindInOperandList(SmallVectorImpl<ValueEntry> &Ops, unsigned i,
- Value *X) {
+static unsigned FindInOperandList(const SmallVectorImpl<ValueEntry> &Ops,
+ unsigned i, Value *X) {
unsigned XRank = Ops[i].Rank;
unsigned e = Ops.size();
for (unsigned j = i+1; j != e && Ops[j].Rank == XRank; ++j) {
OpenPOWER on IntegriCloud