Skip to content

Commit b333b1d

Browse files
authored
difftest: fix init of mstatus (#4)
1 parent 71de241 commit b333b1d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

difftest/difftest.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ void DifftestRef::set_regs(diff_context_t *ctx, bool on_demand) {
131131
if (!on_demand || state->pc != ctx->pc) {
132132
state->pc = ctx->pc;
133133
}
134-
if (!on_demand || state->mstatus->read() != ctx->pc) {
134+
if (!on_demand || state->mstatus->read() != ctx->mstatus) {
135135
state->mstatus->write(ctx->mstatus);
136136
}
137137
if (!on_demand || state->mcause->read() != ctx->mcause) {

0 commit comments

Comments
 (0)