
5 Sep
2008
5 Sep
'08
3:14 p.m.
AMDG gmail wrote:
Hello, I have used the timer class in my application. It works ok sometime but i think it dont work correctly. my code is: #include <iostream> #include "boost/timer.hpp" using namespace std; using namespace boost; int main() { int count=0; timer t; for(;count<1000000;++count); cout<
sometime the output is: 0 execute time :0.015s
It looks correct to me. boost::timer is implemented using std::clock() which has a resolution of about 16 ms on msvc. In Christ, Steven Watanabe