cleanup, add gettimeofday for WIN32