int top2 (int q) { do_stuff (200); do_other_stuff (); return bah (16, q); }
void *thread_mmain(void * arg) { int tid = * ((int *) arg); threadIDs[tid] = pthread_self(); while(1==1) { do_other_stuff(); man_enter(); } }
void *thread_fmain(void * arg) { int tid = *((int *) arg); threadIDs[tid] = pthread_self(); while(1==1) { do_other_stuff(); woman_enter(); use_rr(); woman_leave(); } }
void other_stuff() { high_level_func(); do_other_stuff(); }
int main() { std::future<int> the_answer = std::async(find_the_answer_to_ltuae); do_other_stuff(); std::cout << "The answer is " << the_answer.get() << std::endl; }
int top1 (int q) { do_other_stuff (); return bah (0, q); }