diff options
Diffstat (limited to 'compiler/optimizing/nodes_shared.cc')
-rw-r--r-- | compiler/optimizing/nodes_shared.cc | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/compiler/optimizing/nodes_shared.cc b/compiler/optimizing/nodes_shared.cc index b3a7ad9a05..6216da8234 100644 --- a/compiler/optimizing/nodes_shared.cc +++ b/compiler/optimizing/nodes_shared.cc @@ -33,17 +33,22 @@ void HDataProcWithShifterOp::GetOpInfoFromInstruction(HInstruction* instruction, DCHECK(CanFitInShifterOperand(instruction)); if (instruction->IsShl()) { *op_kind = kLSL; - *shift_amount = instruction->AsShl()->GetRight()->AsIntConstant()->GetValue(); + // TODO: Remove "OrNull". + *shift_amount = instruction->AsShlOrNull()->GetRight()->AsIntConstantOrNull()->GetValue(); } else if (instruction->IsShr()) { *op_kind = kASR; - *shift_amount = instruction->AsShr()->GetRight()->AsIntConstant()->GetValue(); + // TODO: Remove "OrNull". + *shift_amount = instruction->AsShrOrNull()->GetRight()->AsIntConstantOrNull()->GetValue(); } else if (instruction->IsUShr()) { *op_kind = kLSR; - *shift_amount = instruction->AsUShr()->GetRight()->AsIntConstant()->GetValue(); + // TODO: Remove "OrNull". + *shift_amount = instruction->AsUShrOrNull()->GetRight()->AsIntConstantOrNull()->GetValue(); } else { DCHECK(instruction->IsTypeConversion()); - DataType::Type result_type = instruction->AsTypeConversion()->GetResultType(); - DataType::Type input_type = instruction->AsTypeConversion()->GetInputType(); + // TODO: Remove "OrNull". + DataType::Type result_type = instruction->AsTypeConversionOrNull()->GetResultType(); + // TODO: Remove "OrNull". + DataType::Type input_type = instruction->AsTypeConversionOrNull()->GetInputType(); int result_size = DataType::Size(result_type); int input_size = DataType::Size(input_type); int min_size = std::min(result_size, input_size); |