bool
PCEventQueue::doService(ExecContext *xc)
{
- Addr pc = xc->regs.pc;
+ Addr pc = xc->regs.pc & ~0x3;
int serviced = 0;
range_t range = equal_range(pc);
for (iterator i = range.first; i != range.second; ++i) {
// another event. This for example, prevents two invocations
// of the SkipFuncEvent. Maybe we should have separate PC
// event queues for each processor?
- if (pc != xc->regs.pc)
+ if (pc != (xc->regs.pc & ~0x3))
continue;
DPRINTF(PCEvent, "PC based event serviced at %#x: %s\n",
printThreadEvent->schedule(addr + sizeof(MachInst) * 6);
intStartEvent = new InterruptStartEvent(&pcEventQueue, "intStartEvent");
- if (kernelSymtab->findAddress("do_entInt", addr))
+ if (palSymtab->findAddress("sys_int_21", addr))
intStartEvent->schedule(addr + sizeof(MachInst) * 2);
+ else
+ panic("could not find symbol\n");
- intEndEvent = new InterruptEndEvent(&pcEventQueue, "intStartEvent");
- if (palSymtab->findAddress("Call_Pal_Rti", addr))
+ intEndEvent = new InterruptEndEvent(&pcEventQueue, "intEndEvent");
+ if (palSymtab->findAddress("rti_to_kern", addr))
intEndEvent->schedule(addr + sizeof(MachInst));
else
panic("could not find symbol\n");
+
+ intEndEvent2 = new InterruptEndEvent(&pcEventQueue, "intEndEvent2");
+ if (palSymtab->findAddress("rti_to_user", addr))
+ intEndEvent2->schedule(addr + sizeof(MachInst));
+ else
+ panic("could not find symbol\n");
+
+
+ intEndEvent3 = new InterruptEndEvent(&pcEventQueue, "intEndEvent3");
+ if (kernelSymtab->findAddress("do_softirq", addr))
+ intEndEvent3->schedule(addr + sizeof(MachInst));
+ else
+ panic("could not find symbol\n");
}
LinuxSystem::~LinuxSystem()
delete idleStartEvent;
delete printThreadEvent;
delete intStartEvent;
+ delete intEndEvent;
+ delete intEndEvent2;
}
* Event to bin Interrupts seperately from kernel code
*/
InterruptEndEvent *intEndEvent;
+ InterruptEndEvent *intEndEvent2;
+ InterruptEndEvent *intEndEvent3;
/** Grab the PCBB of the idle process when it starts */
IdleStartEvent *idleStartEvent;