From 90408b7d029b94eae03121d913777f616ac1ce77 Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Tue, 7 Nov 2006 23:33:59 -0500 Subject: [PATCH] Fixed to account for branch delay slots. --HG-- extra : convert_revision : 36a91ad4ed56c61b6754548034a13c02cf580fc6 --- src/kern/system_events.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/kern/system_events.cc b/src/kern/system_events.cc index a6337a2fd..6fd9e1563 100644 --- a/src/kern/system_events.cc +++ b/src/kern/system_events.cc @@ -29,6 +29,8 @@ * Nathan Binkert */ +//For ISA_HAS_DELAY_SLOT +#include "arch/isa_traits.hh" #include "base/trace.hh" #include "cpu/thread_context.hh" #include "kern/system_events.hh" @@ -45,4 +47,7 @@ SkipFuncEvent::process(ThreadContext *tc) tc->setPC(newpc); tc->setNextPC(tc->readPC() + sizeof(TheISA::MachInst)); +#if ISA_HAS_DELAY_SLOT + tc->setNextPC(tc->readNextPC() + sizeof(TheISA::MachInst)); +#endif } -- 2.30.2