[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Execution replay for Qt/KDE applications
From:       "Oliver Oppitz" <o.oppitz () web ! de>
Date:       2004-10-13 23:10:38
Message-ID: opsftzz0bcli378s () smtp ! web ! de
[Download RAW message or body]

Hi all,

I am currently investigating the possibility to use execution replay for  
Qt based applications. The basic idea is to record all QEvents (key  
pressed, mouse events, redraw, ...) during the lifetime of an application  
(and all data read from files). By feeding these events/data back to the  
application in a second run, the application should behave identically.

I believe the feature could be very useful for debugging sporadic errors.  
Even a non-technically adept users can mail the recorded traces to the  
developer who can then replay the events that lead to the problem. There  
is simply is no better bug description than having the application show  
itself what went wrong. A second use of execution replay could be  
regression testing.

The implementation should be fairly easy, either using event filters or  
reimplementing QApplication.notify().

- Has anyone done work along these lines so far?
- Any opinions?
- Do you think this would be useful?

Bye, Oliver


PS: There is a limitation to the approach: with multi-threaded  
applications the replay may produce different results due to race  
conditions.

Regarding this a (silly?) question: do KDE applications usually use  
multi-threading? It does not seem so. Did I miss something?

$:~/src/kde/kdebase$ grep -r pthread_t . | wc -l
0
$:~/src/kde/kdebase$ grep -r QThread . | wc -l
0
ooppitz@sanctuary:~/src/kde/kdelibs$ grep -r pthread_t . | wc -l
0
ooppitz@sanctuary:~/src/kde/kdelibs$ grep -r QThread .
[...]
./kdecore/network/kresolver_p.h:    class KResolverThread: public QThread
[...]
./kspell2/backgroundthread.cpp:    : QThread(), m_broker( 0 ), m_dict( 0 )
./kspell2/backgroundthread.h:    class BackgroundThread : public QThread
[...]



-- 

----------------------------------------------------------------------------
"To dare is to lose foothold a moment
  not to dare os to lose one self" by S.Kierkegaard

 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic