void evalInstr();
void execInstr();
std::string toString();
+ Iinstr* getNew();
};
/**
return new Csubi();
}
+Iinstr* Csubi::getNew() {
+ return new Csubi();
+}
+
/**
* Name: destroy_instruction
* Purpose: if compiled as shared library, this functions destoys the
void Csubi::execInstr()
{
cout << "should exec " << this->toString() << endl;
+ CDat reg = this->m_cpu->getRegister(m_ra) - this->m_imm;
+ this->m_cpu->setRegister(m_rd, reg);
+ this->m_cpu->updateFlags(reg);
}
std::string Csubi::toString()