From dfee432b27a5e03b91420d13e2dedae2ad0512ea Mon Sep 17 00:00:00 2001 From: Andrew Waterman Date: Thu, 30 Apr 2015 14:31:25 -0700 Subject: [PATCH] Fix commit log for CSR instructions --- riscv/processor.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/riscv/processor.cc b/riscv/processor.cc index 1fe0a9c..6277de0 100644 --- a/riscv/processor.cc +++ b/riscv/processor.cc @@ -191,8 +191,10 @@ inline void processor_t::update_histogram(size_t pc) static reg_t execute_insn(processor_t* p, reg_t pc, insn_fetch_t fetch) { reg_t npc = fetch.func(p, fetch.insn, pc); - commit_log(p->get_state(), pc, fetch.insn); - p->update_histogram(pc); + if (npc != PC_SERIALIZE) { + commit_log(p->get_state(), pc, fetch.insn); + p->update_histogram(pc); + } return npc; } -- 2.30.2