Skip to content

Commit

Permalink
Use std::chrono to measure time
Browse files Browse the repository at this point in the history
Closes #39
  • Loading branch information
nakatamaho committed Sep 23, 2022
1 parent caba825 commit 1f64652
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions include/mplapack_benchmark.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
*
*/

#include <sys/time.h>
#include <sys/types.h>
#if !defined _WIN32
#include <sys/resource.h>
Expand Down Expand Up @@ -157,22 +156,6 @@ _Float128 randomnumber(_Float128 dummy) {
}
#endif

#if !defined _WIN32
unsigned long microseconds(void) {
rusage t;
timeval tv;
getrusage(RUSAGE_SELF, &t);
tv = t.ru_utime;
return ((unsigned long)tv.tv_sec) * 1000000 + tv.tv_usec;
}
#endif

inline double gettime(void) {
struct timeval tv;
gettimeofday(&tv, NULL);
return tv.tv_sec + (double)tv.tv_usec * 1e-6;
}

#if defined ___DOUBLE_BENCH___
double randomnumber(double dummy) {
#if defined _WIN32 // XXX
Expand Down

0 comments on commit 1f64652

Please sign in to comment.