ecos_kernel_test: removed crude workarounds for bugs that have been fixed lately
git-svn-id: https://www4.informatik.uni-erlangen.de/i4svn/danceos/trunk/devel/fail@1588 8c4709b5-6ec9-48aa-a5cd-a96041d1645a
This commit is contained in:
@ -44,21 +44,9 @@ char const * const traceinfo_name = "trace_info.txt";
|
|||||||
bool EcosKernelTestExperiment::retrieveGuestAddresses() {
|
bool EcosKernelTestExperiment::retrieveGuestAddresses() {
|
||||||
log << "STEP 0: record memory map with addresses of 'interesting' objects" << endl;
|
log << "STEP 0: record memory map with addresses of 'interesting' objects" << endl;
|
||||||
|
|
||||||
// workaround for 00002808875p[BIOS ] >>PANIC<< Keyboard error:21
|
// run until 'ECOS_FUNC_FINISH' is reached
|
||||||
// *** If the first listener is a TimerListener, FailBochs panics. ***
|
|
||||||
// *** Therefore, just wait one instruction before using a timer. ***
|
|
||||||
BPSingleListener bp;
|
BPSingleListener bp;
|
||||||
bp.setWatchInstructionPointer(ANY_ADDR);
|
bp.setWatchInstructionPointer(ECOS_FUNC_FINISH);
|
||||||
simulator.addListenerAndResume(&bp);
|
|
||||||
|
|
||||||
// run until 'ECOS_FUNC_FINISH' is reached //FIXME: [CPU0 ] prefetch: EIP [00010000] > CS.limit [0000ffff]
|
|
||||||
//BPSingleListener bp;
|
|
||||||
//bp.setWatchInstructionPointer(ECOS_FUNC_FINISH);
|
|
||||||
//simulator.addListener(&bp);
|
|
||||||
|
|
||||||
// 10000us = 500000 instructions
|
|
||||||
TimerListener record_timeout(50000000); //TODO: how long to wait?
|
|
||||||
simulator.addListener(&record_timeout);
|
|
||||||
|
|
||||||
// memory map serialization
|
// memory map serialization
|
||||||
ofstream mm(mm_filename, ios::out | ios::app);
|
ofstream mm(mm_filename, ios::out | ios::app);
|
||||||
@ -91,26 +79,21 @@ bool EcosKernelTestExperiment::retrieveGuestAddresses() {
|
|||||||
str->clear();
|
str->clear();
|
||||||
number_of_guest_events++;
|
number_of_guest_events++;
|
||||||
} else if (g.getData() == 'Q') {
|
} else if (g.getData() == 'Q') {
|
||||||
// ignore, see STEP 1
|
// when the guest system triggers the guest event 'Q',
|
||||||
|
// we can assume that we are in protected mode
|
||||||
|
simulator.addListener(&bp);
|
||||||
} else {
|
} else {
|
||||||
str->push_back(g.getData());
|
str->push_back(g.getData());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
assert(number_of_guest_events > 0);
|
assert(number_of_guest_events > 0);
|
||||||
//log << "Breakpoint at 'ECOS_FUNC_FINISH' reached: created memory map (" << number_of_guest_events << " entries)" << endl;
|
log << "Breakpoint at 'ECOS_FUNC_FINISH' reached: created memory map (" << number_of_guest_events << " entries)" << endl;
|
||||||
//TODO: check if ECOS_FUNC_FINISH was reached!!!
|
|
||||||
log << "Record timeout reached: created memory map (" << number_of_guest_events << " entries)" << endl;
|
|
||||||
delete str;
|
delete str;
|
||||||
|
|
||||||
// close serialized mm
|
// close serialized mm
|
||||||
mm.flush();
|
mm.flush();
|
||||||
mm.close();
|
mm.close();
|
||||||
|
|
||||||
// workaround for 00291674339e[CPU0 ] prefetch: EIP [00010000] > CS.limit [0000ffff]
|
|
||||||
// *** just wait some time here *** //FIXME
|
|
||||||
//TimerListener record_timeout(10000);
|
|
||||||
//simulator.addListenerAndResume(&record_timeout);
|
|
||||||
|
|
||||||
// clean up simulator
|
// clean up simulator
|
||||||
simulator.clearListeners();
|
simulator.clearListeners();
|
||||||
return true;
|
return true;
|
||||||
|
|||||||
Reference in New Issue
Block a user