Chromium Code Reviews| Index: src/compiler/arm64/instruction-selector-arm64.cc |
| diff --git a/src/compiler/arm64/instruction-selector-arm64.cc b/src/compiler/arm64/instruction-selector-arm64.cc |
| index 8518b014eb0933e1fadcf72b20c411fcf6b29b4a..dc5d39ad5c70ec0e3a14ed149105767275243ae9 100644 |
| --- a/src/compiler/arm64/instruction-selector-arm64.cc |
| +++ b/src/compiler/arm64/instruction-selector-arm64.cc |
| @@ -436,14 +436,16 @@ void VisitBinop(InstructionSelector* selector, Node* node, |
| Matcher m_shift(right_node); |
| inputs[input_count++] = g.UseRegisterOrImmediateZero(left_node); |
| inputs[input_count++] = g.UseRegister(m_shift.left().node()); |
| - inputs[input_count++] = g.UseImmediate(m_shift.right().node()); |
| + inputs[input_count++] = |
| + g.UseImmediate(static_cast<int>(m_shift.right().Value())); |
|
martyn.capewell
2017/02/03 11:44:37
I think this cast is implementation defined; the i
ahaas
2017/02/03 12:46:11
Thanks. a uint32_t cast would not help either beca
|
| } else if (can_commute && TryMatchAnyShift(selector, node, left_node, &opcode, |
| !is_add_sub)) { |
| if (must_commute_cond) cont->Commute(); |
| Matcher m_shift(left_node); |
| inputs[input_count++] = g.UseRegisterOrImmediateZero(right_node); |
| inputs[input_count++] = g.UseRegister(m_shift.left().node()); |
| - inputs[input_count++] = g.UseImmediate(m_shift.right().node()); |
| + inputs[input_count++] = |
| + g.UseImmediate(static_cast<int>(m_shift.right().Value())); |
| } else { |
| inputs[input_count++] = g.UseRegisterOrImmediateZero(left_node); |
| inputs[input_count++] = g.UseRegister(right_node); |