From 055d76e0ae1b219b6b02ee56a449dffbfc4ca288 Mon Sep 17 00:00:00 2001 From: Sean McBride Date: Tue, 17 Mar 2020 15:12:45 -0400 Subject: [PATCH] fix: correct rdtsc edits --- runtime/include/util.h | 2 +- runtime/src/env.c | 2 +- runtime/tests/fibonacci/get_time.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/runtime/include/util.h b/runtime/include/util.h index d2b6be6..0f4f1a9 100644 --- a/runtime/include/util.h +++ b/runtime/include/util.h @@ -2,7 +2,7 @@ #define SFRT_UTIL_H /** - * Get CPU time in cycles using the Intel instruction util__rdtsc + * Get CPU time in cycles using the Intel instruction rdtsc * @return CPU time in cycles **/ static unsigned long long int diff --git a/runtime/src/env.c b/runtime/src/env.c index 7eb2580..21516f8 100644 --- a/runtime/src/env.c +++ b/runtime/src/env.c @@ -190,7 +190,7 @@ env_cos(double d) } INLINE unsigned long long -env_util__rdtsc(void) +env_rdtsc(void) { return util__rdtsc(); } diff --git a/runtime/tests/fibonacci/get_time.h b/runtime/tests/fibonacci/get_time.h index 90abb77..6b7ffb8 100644 --- a/runtime/tests/fibonacci/get_time.h +++ b/runtime/tests/fibonacci/get_time.h @@ -17,7 +17,7 @@ get_time() unsigned long long int ret = 0; unsigned int cycles_lo; unsigned int cycles_hi; - __asm__ volatile ("util__rdtsc" : "=a" (cycles_lo), "=d" (cycles_hi)); + __asm__ volatile ("rdtsc" : "=a" (cycles_lo), "=d" (cycles_hi)); ret = (unsigned long long int)cycles_hi << 32 | cycles_lo; return ret;