summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2010-05-01 00:33:16 +0000
committerDan Gohman <gohman@apple.com>2010-05-01 00:33:16 +0000
commit63f31115cdf1ca90e1e982b3d2be27e621eb526e (patch)
treed3c86b5bc0ecb9c75bac7eda7d301272a836a10d /llvm/lib/CodeGen
parent66561537f539a9b114f8fde39ef555704bdd4365 (diff)
downloadbcm5719-llvm-63f31115cdf1ca90e1e982b3d2be27e621eb526e.tar.gz
bcm5719-llvm-63f31115cdf1ca90e1e982b3d2be27e621eb526e.zip
Don't pass SDValues by non-const reference unless they may be
modified. llvm-svn: 102816
Diffstat (limited to 'llvm/lib/CodeGen')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp3
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h2
2 files changed, 3 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
index 19169f69a66..a38b204b247 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
@@ -3685,7 +3685,8 @@ static SDValue ExpandPowI(DebugLoc DL, SDValue LHS, SDValue RHS,
bool
SelectionDAGBuilder::EmitFuncArgumentDbgValue(const DbgValueInst &DI,
const Value *V, MDNode *Variable,
- uint64_t Offset, SDValue &N) {
+ uint64_t Offset,
+ const SDValue &N) {
if (!isa<Argument>(V))
return false;
diff --git a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h
index baed7e6677e..3fcd4b9dc43 100644
--- a/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h
+++ b/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.h
@@ -500,7 +500,7 @@ private:
/// the entry BB.
bool EmitFuncArgumentDbgValue(const DbgValueInst &DI,
const Value *V, MDNode *Variable,
- uint64_t Offset, SDValue &N);
+ uint64_t Offset, const SDValue &N);
};
} // end namespace llvm
OpenPOWER on IntegriCloud