Skip to content

Commit

Permalink
Use microseconds for rdtime, as some programs have assumptions
Browse files Browse the repository at this point in the history
  • Loading branch information
fwsGonzo committed Nov 25, 2023
1 parent 622e648 commit 8833915
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/libriscv/machine_defaults.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ namespace riscv
template <int W>
uint64_t Machine<W>::default_rdtime(const Machine<W>&) {
auto now = std::chrono::steady_clock::now();
return std::chrono::duration_cast<std::chrono::milliseconds>(now.time_since_epoch()).count();
return std::chrono::duration_cast<std::chrono::microseconds>(now.time_since_epoch()).count();
}

#ifndef __GNUG__ /* Workaround for GCC bug */
Expand Down

0 comments on commit 8833915

Please sign in to comment.