aboutsummaryrefslogtreecommitdiff
path: root/src/bench/perf.h
diff options
context:
space:
mode:
authorThomas Snider <tjps636@gmail.com>2018-04-18 19:13:10 -0700
committerThomas Snider <tjps636@gmail.com>2018-04-18 19:53:10 -0700
commitb38200459f9611c315710c83528614fb244ca719 (patch)
tree6dd1127db252f0ee0cc10d22839cd63ec39ae5e5 /src/bench/perf.h
parent07825088f9cfd8abece774b9d978c36ab90ce3d1 (diff)
downloadbitcoin-b38200459f9611c315710c83528614fb244ca719.tar.xz
benchmark: Removed bench/perf.cpp
Diffstat (limited to 'src/bench/perf.h')
-rw-r--r--src/bench/perf.h37
1 files changed, 0 insertions, 37 deletions
diff --git a/src/bench/perf.h b/src/bench/perf.h
deleted file mode 100644
index 73ea8b9647..0000000000
--- a/src/bench/perf.h
+++ /dev/null
@@ -1,37 +0,0 @@
-// Copyright (c) 2016 The Bitcoin Core developers
-// Distributed under the MIT software license, see the accompanying
-// file COPYING or http://www.opensource.org/licenses/mit-license.php.
-
-/** Functions for measurement of CPU cycles */
-#ifndef BITCOIN_BENCH_PERF_H
-#define BITCOIN_BENCH_PERF_H
-
-#include <stdint.h>
-
-#if defined(__i386__)
-
-static inline uint64_t perf_cpucycles(void)
-{
- uint64_t x;
- __asm__ volatile (".byte 0x0f, 0x31" : "=A" (x));
- return x;
-}
-
-#elif defined(__x86_64__)
-
-static inline uint64_t perf_cpucycles(void)
-{
- uint32_t hi, lo;
- __asm__ __volatile__ ("rdtsc" : "=a"(lo), "=d"(hi));
- return ((uint64_t)lo)|(((uint64_t)hi)<<32);
-}
-#else
-
-uint64_t perf_cpucycles(void);
-
-#endif
-
-void perf_init(void);
-void perf_fini(void);
-
-#endif // BITCOIN_BENCH_PERF_H