Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16608
Modified Files: Tag: desiredata kernel.c Log Message: added code for measuring elapsed time for all t_gobj
Index: kernel.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/kernel.c,v retrieving revision 1.1.2.87 retrieving revision 1.1.2.88 diff -C2 -d -r1.1.2.87 -r1.1.2.88 *** kernel.c 18 Aug 2007 02:26:28 -0000 1.1.2.87 --- kernel.c 18 Aug 2007 07:06:10 -0000 1.1.2.88 *************** *** 385,391 **** t_call pd_stack[STACKSIZE];
! #define ENTER(SELECTOR) if(pd_stackn >= STACKSIZE) {stackerror(x); LEAVE; return;} \ ! pd_stack[pd_stackn].self = x; pd_stack[pd_stackn].s = SELECTOR; pd_stackn++; ! #define LEAVE pd_stackn--;
/* matju's 2007.07.14 inlet-based stack check needs to be implemented in: --- 385,395 ---- t_call pd_stack[STACKSIZE];
! static inline uint64 rdtsc() {uint64 x; __asm__ volatile (".byte 0x0f, 0x31":"=A"(x)); return x;} ! ! #define ENTER(SELECTOR) if(pd_stackn >= STACKSIZE) {stackerror(x); return;} \ ! pd_stack[pd_stackn].self = x; pd_stack[pd_stackn].s = SELECTOR; pd_stackn++; \ ! uint64 t = rdtsc(); ! #define LEAVE pd_stackn--; \ ! if (x->_class->gobj) ((t_gobj *)x)->dix->elapsed += rdtsc() - t;
/* matju's 2007.07.14 inlet-based stack check needs to be implemented in: