#ifdef CHANGED #include "syscall.h" void f(int c) { /* Since our stack is shared with other threads, we've got * a problem here, when executing a thread there is not 8 iterations. * This is like synchronisation */ volatile int i; for (i=0;i<16;i++){ PutChar((char)c); } ThreadExit(); } int main(){ int i; for (i=65; i < 68; i++){ ThreadCreate(f, i); } // PutString("end of main()\n"); ThreadExit(); //return 0; } #endif