Branch: Tag:

2001-05-16

2001-05-16 23:34:38 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>

stack profiling code (use --with-profiling and then run pike -ps)

Rev: src/interpret.h:1.78
Rev: src/main.c:1.113
Rev: src/threads.c:1.154

1:   #include "global.h" - RCSID("$Id: threads.c,v 1.153 2001/02/06 17:54:44 grubba Exp $"); + RCSID("$Id: threads.c,v 1.154 2001/05/16 23:34:38 hubbe Exp $");      PMOD_EXPORT int num_threads = 1;   PMOD_EXPORT int threads_disabled = 0;
591:    SWAP_IN_THREAD(OBJ2THREAD(arg.id)); /* Init struct */    init_interpreter();    Pike_interpreter.thread_id=arg.id; + #ifdef PROFILING +  Pike_interpreter.stack_bottom=((char *)&data); + #endif    Pike_interpreter.stack_top=((char *)&data)+ (thread_stack_size-16384) * STACK_DIRECTION;    Pike_interpreter.recoveries = NULL;    SWAP_OUT_THREAD(OBJ2THREAD(Pike_interpreter.thread_id)); /* Init struct */