Therefore, I'm going to have to limit the execution to some time slice then relinquish control back to OS.
The location where I'm going to have to check whether timeout has occurred is inside vm.c
Code: Select all
DISPATCH();
Code: Select all
do {
code_state->ip = ip; ;
goto *entry_table[*ip++];
} while (0);
Code: Select all
do {
code_state->ip = ip; ;
goto *entry_table[*ip++];
if(thread_timer_val == 0)
{
break;
}
} while (0);
Are there any other considerations or pointers anyone can think of?