Skip to content

Commit

Permalink
Clarify that mtimecmp comparison is unsigned
Browse files Browse the repository at this point in the history
  • Loading branch information
aswaterman committed Apr 22, 2020
1 parent f8a13b7 commit a1c7d25
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/machine.tex
Original file line number Diff line number Diff line change
Expand Up @@ -1610,9 +1610,10 @@ \subsection{Machine Timer Registers ({\tt mtime} and {\tt mtimecmp})}

The {\tt mtime} register has a 64-bit precision on all RV32 and RV64
systems. Platforms provide a 64-bit memory-mapped machine-mode
timer compare register ({\tt mtimecmp}), which causes a timer
interrupt to be posted when the {\tt mtime} register contains a value
greater than or equal to the value in the {\tt mtimecmp} register.
timer compare register ({\tt mtimecmp}).
A timer interrupt becomes pending whenever {\tt mtime} contains
a value greater than or equal to {\tt mtimecmp}, treating the values
as unsigned integers.
The interrupt remains posted until {\tt mtimecmp} becomes greater than
{\tt mtime} (typically as a result of writing {\tt mtimecmp}).
The interrupt will only be taken if interrupts
Expand Down

0 comments on commit a1c7d25

Please sign in to comment.