| Index: src/arm/simulator-arm.cc
|
| diff --git a/src/arm/simulator-arm.cc b/src/arm/simulator-arm.cc
|
| index cfcc5b16c566b91430d5b6a137c8fe0cca038caf..11a49997e892e98be211e094cded9c4d7b7dd358 100644
|
| --- a/src/arm/simulator-arm.cc
|
| +++ b/src/arm/simulator-arm.cc
|
| @@ -2886,26 +2886,24 @@ void Simulator::DecodeType3(Instruction* instr) {
|
| return;
|
| }
|
| }
|
| - if (FLAG_enable_sudiv) {
|
| - if (instr->Bits(5, 4) == 0x1) {
|
| - if ((instr->Bit(22) == 0x0) && (instr->Bit(20) == 0x1)) {
|
| - // (s/u)div (in V8 notation matching ARM ISA format) rn = rm/rs
|
| - // Format(instr, "'(s/u)div'cond'b 'rn, 'rm, 'rs);
|
| - int rm = instr->RmValue();
|
| - int32_t rm_val = get_register(rm);
|
| - int rs = instr->RsValue();
|
| - int32_t rs_val = get_register(rs);
|
| - int32_t ret_val = 0;
|
| - // udiv
|
| - if (instr->Bit(21) == 0x1) {
|
| - ret_val = bit_cast<int32_t>(base::bits::UnsignedDiv32(
|
| - bit_cast<uint32_t>(rm_val), bit_cast<uint32_t>(rs_val)));
|
| - } else {
|
| - ret_val = base::bits::SignedDiv32(rm_val, rs_val);
|
| - }
|
| - set_register(rn, ret_val);
|
| - return;
|
| + if (instr->Bits(5, 4) == 0x1) {
|
| + if ((instr->Bit(22) == 0x0) && (instr->Bit(20) == 0x1)) {
|
| + // (s/u)div (in V8 notation matching ARM ISA format) rn = rm/rs
|
| + // Format(instr, "'(s/u)div'cond'b 'rn, 'rm, 'rs);
|
| + int rm = instr->RmValue();
|
| + int32_t rm_val = get_register(rm);
|
| + int rs = instr->RsValue();
|
| + int32_t rs_val = get_register(rs);
|
| + int32_t ret_val = 0;
|
| + // udiv
|
| + if (instr->Bit(21) == 0x1) {
|
| + ret_val = bit_cast<int32_t>(base::bits::UnsignedDiv32(
|
| + bit_cast<uint32_t>(rm_val), bit_cast<uint32_t>(rs_val)));
|
| + } else {
|
| + ret_val = base::bits::SignedDiv32(rm_val, rs_val);
|
| }
|
| + set_register(rn, ret_val);
|
| + return;
|
| }
|
| }
|
| // Format(instr, "'memop'cond'b 'rd, ['rn, -'shift_rm]'w");
|
|
|