diff options
author | Ali Saidi <saidi@eecs.umich.edu> | 2004-09-03 14:12:59 -0400 |
---|---|---|
committer | Ali Saidi <saidi@eecs.umich.edu> | 2004-09-03 14:12:59 -0400 |
commit | af620e118709e1a5272661c94641c3adf19fa524 (patch) | |
tree | 3b8919d166664a2a3c7d6c09c919bb554d4f02c2 /kern/linux | |
parent | 8efb592e0b8a51056d75565cb970a99ef895ada5 (diff) | |
download | gem5-af620e118709e1a5272661c94641c3adf19fa524.tar.xz |
added system option to bin interrupt code seperately.
arch/alpha/ev5.cc:
set the mode explictly rather than having a bool user/notuser
cpu/simple_cpu/simple_cpu.hh:
there is no class Kernel
kern/kernel_stats.cc:
use cpu_mode_num
kern/kernel_stats.hh:
add interrupt mode and use cpu_mode_num rather than constant
kern/linux/linux_system.cc:
kern/linux/linux_system.hh:
kern/system_events.cc:
kern/system_events.hh:
add events to change the mode to/from interrupt
sim/system.cc:
sim/system.hh:
add a pal symbol table
--HG--
extra : convert_revision : 9d30e826b72122062a5ea12d094f94760e75c66a
Diffstat (limited to 'kern/linux')
-rw-r--r-- | kern/linux/linux_system.cc | 18 | ||||
-rw-r--r-- | kern/linux/linux_system.hh | 14 |
2 files changed, 30 insertions, 2 deletions
diff --git a/kern/linux/linux_system.cc b/kern/linux/linux_system.cc index 10641de87..91ad45157 100644 --- a/kern/linux/linux_system.cc +++ b/kern/linux/linux_system.cc @@ -143,6 +143,16 @@ LinuxSystem::LinuxSystem(Params *p) printThreadEvent = new PrintThreadInfo(&pcEventQueue, "threadinfo"); if (kernelSymtab->findAddress("alpha_switch_to", addr) && DTRACE(Thread)) printThreadEvent->schedule(addr + sizeof(MachInst) * 6); + + intStartEvent = new InterruptStartEvent(&pcEventQueue, "intStartEvent"); + if (kernelSymtab->findAddress("do_entInt", addr)) + intStartEvent->schedule(addr + sizeof(MachInst) * 2); + + intEndEvent = new InterruptEndEvent(&pcEventQueue, "intStartEvent"); + if (palSymtab->findAddress("Call_Pal_Rti", addr)) + intEndEvent->schedule(addr + sizeof(MachInst)); + else + panic("could not find symbol\n"); } LinuxSystem::~LinuxSystem() @@ -155,6 +165,8 @@ LinuxSystem::~LinuxSystem() delete skipCacheProbeEvent; delete debugPrintkEvent; delete idleStartEvent; + delete printThreadEvent; + delete intStartEvent; } @@ -193,6 +205,7 @@ BEGIN_DECLARE_SIM_OBJECT_PARAMS(LinuxSystem) Param<bool> bin; VectorParam<string> binned_fns; + Param<bool> bin_int; END_DECLARE_SIM_OBJECT_PARAMS(LinuxSystem) @@ -210,7 +223,8 @@ BEGIN_INIT_SIM_OBJECT_PARAMS(LinuxSystem) INIT_PARAM_DFLT(system_type, "Type of system we are emulating", 34), INIT_PARAM_DFLT(system_rev, "Revision of system we are emulating", 1<<10), INIT_PARAM_DFLT(bin, "is this system to be binned", false), - INIT_PARAM(binned_fns, "functions to be broken down and binned") + INIT_PARAM(binned_fns, "functions to be broken down and binned"), + INIT_PARAM_DFLT(bin_int, "is interrupt code binned seperately?", false) END_INIT_SIM_OBJECT_PARAMS(LinuxSystem) @@ -230,7 +244,7 @@ CREATE_SIM_OBJECT(LinuxSystem) p->system_rev = system_rev; p->bin = bin; p->binned_fns = binned_fns; - + p->bin_int = bin_int; return new LinuxSystem(p); } diff --git a/kern/linux/linux_system.hh b/kern/linux/linux_system.hh index 707204607..f5fd2b06b 100644 --- a/kern/linux/linux_system.hh +++ b/kern/linux/linux_system.hh @@ -83,8 +83,22 @@ class LinuxSystem : public System */ LinuxSkipDelayLoopEvent *skipDelayLoopEvent; + /** + * Event to print information about thread switches if the trace flag + * Thread is set + */ PrintThreadInfo *printThreadEvent; + /** + * Event to bin Interrupts seperately from kernel code + */ + InterruptStartEvent *intStartEvent; + + /** + * Event to bin Interrupts seperately from kernel code + */ + InterruptEndEvent *intEndEvent; + /** Grab the PCBB of the idle process when it starts */ IdleStartEvent *idleStartEvent; |