Dynamic Debugging Interface for Embedded Systems
120 likes | 218 Vues
This project aims to define a debug interface for components in embedded systems, enabling tracing, checkpointing, and replay functionalities tailored to specific debugging needs. The focus is on efficient resource usage and flexibility in debugging methods.
Dynamic Debugging Interface for Embedded Systems
E N D
Presentation Transcript
Work Package 5 – DebuggingTask 5.2 - Generic Debug Interface K. De Bosschere e.a.
Goals • Define a debug-interface for components • Trace behaviour of components • Limit trace information • Checkpointing and replay of components • Must always be applicable to the system, not just during development
Types of Debugging • Many types of debugging are possible • correctness debugging: where is the bug? • performance debugging: why is it so slow? (or fast?) • 'exploratory' debugging: what does it do? How does it do it? • ... • Many types of programs to debug • own source or third party libraries? • IO intensive or CPU bound? • text interface or GUI? • ... • Many types of hardware to debug on/with • large workstations or small embedded systems • network access, GUI or text • ...
Requirements • Many types of information are required: • tracing of events: • method calls • accesses to objects • I/O • events from the component system • timing: • methods • I/O • resources: • heap • stack • locks
Problems: Conclusions • So, the approach to debugging is linked to: • the type of debugging • the type of application being debugged • the type of hardware available • Requirements are varied and sometimes consume large amounts of resources • We need a flexible debugging solution: • all types of debugging must be possible • it must be possible to select only the debugging mechanisms we need
Standard embedded JVM configuration • Normal operation of embedded system + JVM Embedded System JVM Class Input/Output
Debugging Configuration on Board • Specialised instrumentation of class files • On the embedded system Embedded System JVM Class Input/Output Debug JVM
Debugging Configuration on Two Systems • Specialised instrumentation of class files • Debugger is different system: minimal interference while maintaining high flexibility i.e. a component Embedded System JVM Class Input/Output Cache Instrumentor Debug JVM
Potential Applications • Simple: • Print out activation tree • Time method calls • ... • More complex: • Patch erroneous code • Analyse memory allocation • Trace arguments • Execution replay of non-deterministic multi-threaded applications • Tracing of some or all IO • ...
Developping Debugger module: Record/Replay A=5 A=9 A=9 A=5 • Multiple threads • Interleaving produces different results • Non-deterministic • Record all non-deterministic behaviour to trace and replay with this trace
Future • Perfect the instrumentation layer • Implement a number of modules on top of this layer with useful functionality • Integrate with the component communication system • Further development of record/replay module
Conclusions • Debugging is a very specific activity for which the requirements can vary greatly • Embedded systems have only a limited amount of resources • We propose to dynamically alter the bytecode to tailor the debugging facilities to the debug problem and the available hardware • We are currently developing debug facilities on top of this module