diff options
author | Andrew Waterman <waterman@cs.berkeley.edu> | 2016-03-14 17:47:25 -0700 |
---|---|---|
committer | Andrew Waterman <waterman@cs.berkeley.edu> | 2016-03-14 17:47:25 -0700 |
commit | 35c6ac438af5086510fe120b575090cf8e9b917b (patch) | |
tree | 98ca945ba56dafb329224f88d7376a3860cb5ce5 /benchmarks/dhrystone/dhrystone.h | |
parent | 79e7914a4f33997b110c4a9dfe844561d927b9c0 (diff) | |
download | riscv-tests-35c6ac438af5086510fe120b575090cf8e9b917b.zip riscv-tests-35c6ac438af5086510fe120b575090cf8e9b917b.tar.gz riscv-tests-35c6ac438af5086510fe120b575090cf8e9b917b.tar.bz2 |
Rework benchmarks to run in M-mode
This broadens their utility and lets them use the M-mode counters directly.
Diffstat (limited to 'benchmarks/dhrystone/dhrystone.h')
-rw-r--r-- | benchmarks/dhrystone/dhrystone.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/benchmarks/dhrystone/dhrystone.h b/benchmarks/dhrystone/dhrystone.h index 37535e7..89616af 100644 --- a/benchmarks/dhrystone/dhrystone.h +++ b/benchmarks/dhrystone/dhrystone.h @@ -384,8 +384,8 @@ extern clock_t clock(); #define HZ 1000000 #define Too_Small_Time 1 #define CLOCK_TYPE "rdcycle()" -#define Start_Timer() Begin_Time = rdcycle() -#define Stop_Timer() End_Time = rdcycle() +#define Start_Timer() Begin_Time = read_csr(mcycle) +#define Stop_Timer() End_Time = read_csr(mcycle) #else /* Use times(2) time function unless */ |