Interactive Debugging QuickZoom : A State Alteration and Inspection-based Interactive Debugger

30
Interactive Debugging QuickZoom: A State Alteration and Inspection- based Interactive Debugger 1

description

Interactive Debugging QuickZoom : A State Alteration and Inspection-based Interactive Debugger. QZ DB Goal. QUICK:. State Inspection—Source Code Modification — Compile —Run From Beginning. State Inspection—State Rollback—State Alteration. QZ DB Goal. ZOOM:. Faulty Program. - PowerPoint PPT Presentation

Transcript of Interactive Debugging QuickZoom : A State Alteration and Inspection-based Interactive Debugger

SAID: State Alteration and Inspection-based Debugging

Interactive Debugging

QuickZoom: A State Alteration and Inspection-based Interactive Debugger

1QZDB GoalQUICK:2 State InspectionSource Code Modification Compile Run From Beginning State InspectionState RollbackState Alteration

3Faulty ProgramZoomFaulty FunctionFaulty Statement/VariableZoom ZOOM:QZDB GoalQZDB Overview4 State Inspection

State Alteration

State Rollback

ZOOM QUICKDebugging ProcessIncorrect Output or CrashERRORCorrect? 5State RollbackState AlterationState InspectionQZDB features State Alterationpredicate switching [ICSE 2006]execution suppression [TOPLAS 2010]

State Inspection record dynamic slice [TOPLAS 2005] prune sbreak conditional breakpoint

State Rollbackcheckpointrollback

6Add State Inspection Enabling CommandsSet Checkpoint Set Record regionSet breakpointsPerform State InspectionCompute Slice Navigate Slice Prune SliceIntroduce State Alteration CommandsSwitch CommandsSuppress CommandsExecute program from Begin pointIntroduce new State Inspection Enabling CommandsSbreak Set Record RegionSet CheckpointsSelect New Begin Point && Rollback ExecutionZOOMZOOMQUICKQZDBProgram StartPredicate Switching The predicate switching interface allows programmers to dynamically change the outcome of a branch. Benefitroot cause speculation avoid source code modification, recompilation and re-execution Interface switch fileName:lineNum [all|once|n]all: switch the result of all the execution instances of this predicateonce: only switch the result of next execution instancen: only switch the result of N-th execution instance

8Predicate Switching-Example (qzdb) 1: for(i=0; ij) 4: j++; 5: else 6: k++; 7: } (qzdb)

listswitch 3 all/once/4 9Execution Suppression The execution suppression interface allows programmers to dynamically suppress the execution of some statement or function invocation. Benefitbug isolation and root cause speculation avoid repeated source code modification, recompilation and re-execution Interface suppress fileName:lineNum [all|once|n]all: suppress all the execution instances of this statementonce: only suppress the next execution instancen: only suppress the N-th execution instance10Execution Suppression-Example (qzdb) 1: for(i=0; i