C examples halts simulation

This commit is contained in:
mariusmonton 2018-11-19 17:22:18 +01:00
parent ed7be704f9
commit 9cd354b822
4 changed files with 9 additions and 2 deletions

View File

@ -213,7 +213,7 @@ void Execute::BLTU(Instruction &inst) {
}
log->SC_log(Log::INFO) << "BLTU x"
<< rs1 << "(" << regs->getValue(rs1) << ") < x"
<< dec << rs1 << "(" << regs->getValue(rs1) << ") < x"
<< rs2 << "(" << regs->getValue(rs2) << ")? -> PC (0x"
<< hex << new_pc << ")" << dec << endl;
}
@ -784,7 +784,7 @@ void Execute::FENCE(Instruction &inst) {
void Execute::ECALL(Instruction &inst) {
log->SC_log(Log::INFO) << "ECALL" << endl;
std::cout << "ECALL Instruction called, stopping simulation" << endl;
std::cout << endl << "ECALL Instruction called, stopping simulation" << endl;
regs->dump();
cout << "Simulation time " << sc_time_stamp() << endl;
perf->dump();

View File

@ -4,4 +4,6 @@
void main(void) {
TRACE = 'H';
TRACE = 'e';
asm volatile ("ecall");
}

View File

@ -6,4 +6,7 @@ void main(void) {
for(i=0;i<10;i++) {
TRACE = 'a' + i;
}
asm volatile ("ecall");
}

View File

@ -7,4 +7,6 @@ void main(void) {
for (i=0; i<5; i++) {
TRACE = msg[i];
}
asm volatile ("ecall");
}