mirror of
https://git.suyu.dev/suyu/dynarmic.git
synced 2026-02-19 14:52:57 +00:00
Prefer ASSERT to DEBUG_ASSERT
This commit is contained in:
@@ -255,13 +255,13 @@ Inst* Inst::GetAssociatedPseudoOperation(Opcode opcode) {
|
||||
// This is faster than doing a search through the block.
|
||||
switch (opcode) {
|
||||
case IR::Opcode::GetCarryFromOp:
|
||||
DEBUG_ASSERT(!carry_inst || carry_inst->GetOpcode() == Opcode::GetCarryFromOp);
|
||||
ASSERT(!carry_inst || carry_inst->GetOpcode() == Opcode::GetCarryFromOp);
|
||||
return carry_inst;
|
||||
case IR::Opcode::GetOverflowFromOp:
|
||||
DEBUG_ASSERT(!overflow_inst || overflow_inst->GetOpcode() == Opcode::GetOverflowFromOp);
|
||||
ASSERT(!overflow_inst || overflow_inst->GetOpcode() == Opcode::GetOverflowFromOp);
|
||||
return overflow_inst;
|
||||
case IR::Opcode::GetGEFromOp:
|
||||
DEBUG_ASSERT(!ge_inst || ge_inst->GetOpcode() == Opcode::GetGEFromOp);
|
||||
ASSERT(!ge_inst || ge_inst->GetOpcode() == Opcode::GetGEFromOp);
|
||||
return ge_inst;
|
||||
default:
|
||||
break;
|
||||
@@ -278,15 +278,15 @@ Type Inst::GetType() const {
|
||||
}
|
||||
|
||||
Value Inst::GetArg(size_t index) const {
|
||||
DEBUG_ASSERT(index < GetNumArgsOf(op));
|
||||
DEBUG_ASSERT(!args[index].IsEmpty());
|
||||
ASSERT(index < GetNumArgsOf(op));
|
||||
ASSERT(!args[index].IsEmpty());
|
||||
|
||||
return args[index];
|
||||
}
|
||||
|
||||
void Inst::SetArg(size_t index, Value value) {
|
||||
DEBUG_ASSERT(index < GetNumArgsOf(op));
|
||||
DEBUG_ASSERT(AreTypesCompatible(value.GetType(), GetArgTypeOf(op, index)));
|
||||
ASSERT(index < GetNumArgsOf(op));
|
||||
ASSERT(AreTypesCompatible(value.GetType(), GetArgTypeOf(op, index)));
|
||||
|
||||
if (!args[index].IsImmediate()) {
|
||||
UndoUse(args[index]);
|
||||
@@ -346,15 +346,15 @@ void Inst::UndoUse(const Value& value) {
|
||||
|
||||
switch (op){
|
||||
case Opcode::GetCarryFromOp:
|
||||
DEBUG_ASSERT(value.GetInst()->carry_inst->GetOpcode() == Opcode::GetCarryFromOp);
|
||||
ASSERT(value.GetInst()->carry_inst->GetOpcode() == Opcode::GetCarryFromOp);
|
||||
value.GetInst()->carry_inst = nullptr;
|
||||
break;
|
||||
case Opcode::GetOverflowFromOp:
|
||||
DEBUG_ASSERT(value.GetInst()->overflow_inst->GetOpcode() == Opcode::GetOverflowFromOp);
|
||||
ASSERT(value.GetInst()->overflow_inst->GetOpcode() == Opcode::GetOverflowFromOp);
|
||||
value.GetInst()->overflow_inst = nullptr;
|
||||
break;
|
||||
case Opcode::GetGEFromOp:
|
||||
DEBUG_ASSERT(value.GetInst()->ge_inst->GetOpcode() == Opcode::GetGEFromOp);
|
||||
ASSERT(value.GetInst()->ge_inst->GetOpcode() == Opcode::GetGEFromOp);
|
||||
value.GetInst()->ge_inst = nullptr;
|
||||
break;
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user