Skip to content

Commit

Permalink
mythmiscutil.h: remove unused rdtsc()
Browse files Browse the repository at this point in the history
This may have been for benchmarking the filters removed in 2019
in ead8718.
  • Loading branch information
ulmus-scott committed Jun 14, 2024
1 parent 358e9ad commit ba1680a
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 70 deletions.
41 changes: 0 additions & 41 deletions mythtv/contrib/development/tsc-calibrate/tsc-calibrate.c

This file was deleted.

29 changes: 0 additions & 29 deletions mythtv/libs/libmythbase/mythmiscutil.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,33 +59,4 @@ MBASE_PUBLIC bool MythRemoveDirectory(QDir &aDir);

MBASE_PUBLIC void setHttpProxy(void);

// CPU Tick timing function
#ifdef MMX
#ifdef _WIN32
#include "compat.h"
inline void rdtsc(uint64_t &x)
{
QueryPerformanceCounter((LARGE_INTEGER*)(&x));
}
#else
struct timing_ab_t {
uint a;
uint b;
};
inline void rdtsc(uint64_t &x)
{
auto &y = (timing_ab_t&) x;
asm("rdtsc \n"
"mov %%eax, %0 \n"
"mov %%edx, %1 \n"
:
: "m"(y.a), "m"(y.b)
: "%eax", "%edx");
}
#endif

#else // if !MMX
inline void rdtsc(uint64_t &x) { x = 0ULL; }
#endif // !MMX

#endif // MYTHMISCUTIL_H_

0 comments on commit ba1680a

Please sign in to comment.