Skip to content
Snippets Groups Projects
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
test_prog.c 375 B
#include <stdio.h>
#include <unistd.h>

int main(void)
{
    // Make sure program is not finished before pb scheduler takes control
    sleep(1);
    int a = 0;
    int b = 0;
    for (;b < 100; b++) {
      for (;a < 100000; a++){asm("");}
      // check if program runs && syscall to switch tasks
      printf("loop run: %d \n", b);
      usleep(1);
    }
    return 0;
}