Index: src/compiler/simplified-lowering.cc |
diff --git a/src/compiler/simplified-lowering.cc b/src/compiler/simplified-lowering.cc |
index c4b1b57d1fb0804ce16e50cb69856ced06e3f6e8..74ddb53dd1d9142aa8463858aeadcd21b02afe6c 100644 |
--- a/src/compiler/simplified-lowering.cc |
+++ b/src/compiler/simplified-lowering.cc |
@@ -1147,14 +1147,18 @@ void SimplifiedLowering::DoLoadBuffer(Node* node, MachineType output_type, |
Node* const length = node->InputAt(2); |
Node* const effect = node->InputAt(3); |
Node* const control = node->InputAt(4); |
+ Node* const index = |
+ machine()->Is64() |
+ ? graph()->NewNode(machine()->ChangeUint32ToUint64(), offset) |
+ : offset; |
Node* check = graph()->NewNode(machine()->Uint32LessThan(), offset, length); |
Node* branch = |
graph()->NewNode(common()->Branch(BranchHint::kTrue), check, control); |
Node* if_true = graph()->NewNode(common()->IfTrue(), branch); |
- Node* etrue = graph()->NewNode(machine()->Load(type), buffer, offset, |
- effect, if_true); |
+ Node* etrue = |
+ graph()->NewNode(machine()->Load(type), buffer, index, effect, if_true); |
Node* vtrue = changer->GetRepresentationFor(etrue, type, output_type); |
Node* if_false = graph()->NewNode(common()->IfFalse(), branch); |