//Example code showing TAU monitoring a threaded application. //Threading example code updated to include Windows Threads. //October 1999 ... Robert Ansell-Bell. //Original code by Sameer Shende. #ifdef TAU_DOT_H_LESS_HEADERS #include using namespace std; #else /* TAU_DOT_H_LESS_HEADERS */ #include #endif /* TAU_DOT_H_LESS_HEADERS */ #if (!defined(TAU_WINDOWS)) #include #include #include #endif //TAU_WINDOWS #include #ifdef TAU_WINDOWS #include #endif //TAU_WINDOWS #include int fourth(void) { TAU_REGISTER_EVENT(iters, "Number of Iterates"); TAU_REGISTER_EVENT(mem, "Memory allocated by arrays"); TAU_PROFILE("fourth()", "int ()", TAU_DEFAULT); TAU_EVENT(iters, 1); cout <<"Reached fourth " << endl; return 0; } int third(void) { TAU_REGISTER_EVENT(iters, "Number of Iterates"); TAU_REGISTER_EVENT(mem, "Memory allocated by arrays"); TAU_PROFILE("third()", "int ()", TAU_DEFAULT); cout <<"third calling fourth " <