| Index: src/mips64/lithium-gap-resolver-mips64.cc
|
| diff --git a/src/mips64/lithium-gap-resolver-mips64.cc b/src/mips64/lithium-gap-resolver-mips64.cc
|
| index aa1c28c4de3356136685ddad2828a3ef273589be..d965f651a318867ce251d6996505d6c83e8bbfc6 100644
|
| --- a/src/mips64/lithium-gap-resolver-mips64.cc
|
| +++ b/src/mips64/lithium-gap-resolver-mips64.cc
|
| @@ -19,7 +19,7 @@ LGapResolver::LGapResolver(LCodeGen* owner)
|
|
|
|
|
| void LGapResolver::Resolve(LParallelMove* parallel_move) {
|
| - ASSERT(moves_.is_empty());
|
| + DCHECK(moves_.is_empty());
|
| // Build up a worklist of moves.
|
| BuildInitialMoveList(parallel_move);
|
|
|
| @@ -40,7 +40,7 @@ void LGapResolver::Resolve(LParallelMove* parallel_move) {
|
| // Perform the moves with constant sources.
|
| for (int i = 0; i < moves_.length(); ++i) {
|
| if (!moves_[i].IsEliminated()) {
|
| - ASSERT(moves_[i].source()->IsConstantOperand());
|
| + DCHECK(moves_[i].source()->IsConstantOperand());
|
| EmitMove(i);
|
| }
|
| }
|
| @@ -78,13 +78,13 @@ void LGapResolver::PerformMove(int index) {
|
| // An additional complication is that moves to MemOperands with large
|
| // offsets (more than 1K or 4K) require us to spill this spilled value to
|
| // the stack, to free up the register.
|
| - ASSERT(!moves_[index].IsPending());
|
| - ASSERT(!moves_[index].IsRedundant());
|
| + DCHECK(!moves_[index].IsPending());
|
| + DCHECK(!moves_[index].IsRedundant());
|
|
|
| // Clear this move's destination to indicate a pending move. The actual
|
| // destination is saved in a stack allocated local. Multiple moves can
|
| // be pending because this function is recursive.
|
| - ASSERT(moves_[index].source() != NULL); // Or else it will look eliminated.
|
| + DCHECK(moves_[index].source() != NULL); // Or else it will look eliminated.
|
| LOperand* destination = moves_[index].destination();
|
| moves_[index].set_destination(NULL);
|
|
|
| @@ -111,7 +111,7 @@ void LGapResolver::PerformMove(int index) {
|
| // a scratch register to break it.
|
| LMoveOperands other_move = moves_[root_index_];
|
| if (other_move.Blocks(destination)) {
|
| - ASSERT(other_move.IsPending());
|
| + DCHECK(other_move.IsPending());
|
| BreakCycle(index);
|
| return;
|
| }
|
| @@ -122,12 +122,12 @@ void LGapResolver::PerformMove(int index) {
|
|
|
|
|
| void LGapResolver::Verify() {
|
| -#ifdef ENABLE_SLOW_ASSERTS
|
| +#ifdef ENABLE_SLOW_DCHECKS
|
| // No operand should be the destination for more than one move.
|
| for (int i = 0; i < moves_.length(); ++i) {
|
| LOperand* destination = moves_[i].destination();
|
| for (int j = i + 1; j < moves_.length(); ++j) {
|
| - SLOW_ASSERT(!destination->Equals(moves_[j].destination()));
|
| + SLOW_DCHECK(!destination->Equals(moves_[j].destination()));
|
| }
|
| }
|
| #endif
|
| @@ -139,8 +139,8 @@ void LGapResolver::BreakCycle(int index) {
|
| // We save in a register the value that should end up in the source of
|
| // moves_[root_index]. After performing all moves in the tree rooted
|
| // in that move, we save the value to that source.
|
| - ASSERT(moves_[index].destination()->Equals(moves_[root_index_].source()));
|
| - ASSERT(!in_cycle_);
|
| + DCHECK(moves_[index].destination()->Equals(moves_[root_index_].source()));
|
| + DCHECK(!in_cycle_);
|
| in_cycle_ = true;
|
| LOperand* source = moves_[index].source();
|
| saved_destination_ = moves_[index].destination();
|
| @@ -161,8 +161,8 @@ void LGapResolver::BreakCycle(int index) {
|
|
|
|
|
| void LGapResolver::RestoreValue() {
|
| - ASSERT(in_cycle_);
|
| - ASSERT(saved_destination_ != NULL);
|
| + DCHECK(in_cycle_);
|
| + DCHECK(saved_destination_ != NULL);
|
|
|
| // Spilled value is in kLithiumScratchReg or kLithiumScratchDouble.
|
| if (saved_destination_->IsRegister()) {
|
| @@ -196,7 +196,7 @@ void LGapResolver::EmitMove(int index) {
|
| if (destination->IsRegister()) {
|
| __ mov(cgen_->ToRegister(destination), source_register);
|
| } else {
|
| - ASSERT(destination->IsStackSlot());
|
| + DCHECK(destination->IsStackSlot());
|
| __ sd(source_register, cgen_->ToMemOperand(destination));
|
| }
|
| } else if (source->IsStackSlot()) {
|
| @@ -204,7 +204,7 @@ void LGapResolver::EmitMove(int index) {
|
| if (destination->IsRegister()) {
|
| __ ld(cgen_->ToRegister(destination), source_operand);
|
| } else {
|
| - ASSERT(destination->IsStackSlot());
|
| + DCHECK(destination->IsStackSlot());
|
| MemOperand destination_operand = cgen_->ToMemOperand(destination);
|
| if (in_cycle_) {
|
| if (!destination_operand.OffsetIsInt16Encodable()) {
|
| @@ -240,8 +240,8 @@ void LGapResolver::EmitMove(int index) {
|
| double v = cgen_->ToDouble(constant_source);
|
| __ Move(result, v);
|
| } else {
|
| - ASSERT(destination->IsStackSlot());
|
| - ASSERT(!in_cycle_); // Constant moves happen after all cycles are gone.
|
| + DCHECK(destination->IsStackSlot());
|
| + DCHECK(!in_cycle_); // Constant moves happen after all cycles are gone.
|
| if (cgen_->IsSmi(constant_source)) {
|
| __ li(kLithiumScratchReg, Operand(cgen_->ToSmi(constant_source)));
|
| __ sd(kLithiumScratchReg, cgen_->ToMemOperand(destination));
|
| @@ -259,7 +259,7 @@ void LGapResolver::EmitMove(int index) {
|
| if (destination->IsDoubleRegister()) {
|
| __ mov_d(cgen_->ToDoubleRegister(destination), source_register);
|
| } else {
|
| - ASSERT(destination->IsDoubleStackSlot());
|
| + DCHECK(destination->IsDoubleStackSlot());
|
| MemOperand destination_operand = cgen_->ToMemOperand(destination);
|
| __ sdc1(source_register, destination_operand);
|
| }
|
| @@ -269,7 +269,7 @@ void LGapResolver::EmitMove(int index) {
|
| if (destination->IsDoubleRegister()) {
|
| __ ldc1(cgen_->ToDoubleRegister(destination), source_operand);
|
| } else {
|
| - ASSERT(destination->IsDoubleStackSlot());
|
| + DCHECK(destination->IsDoubleStackSlot());
|
| MemOperand destination_operand = cgen_->ToMemOperand(destination);
|
| if (in_cycle_) {
|
| // kLithiumScratchDouble was used to break the cycle,
|
|
|