Skip to content

Commit

Permalink
Write down the requirement for the Zaamo extension
Browse files Browse the repository at this point in the history
Since 2eead36 ("Run a hart lottery on SMP") the kernel is making
use of the 'amoadd.w' instruction, which requires the Zaamo
extension (included in the base A extension). This is notable and is
worth a mention on the list of requirements.

Signed-off-by: Miquel Sabaté Solà <[email protected]>
  • Loading branch information
mssola committed Dec 3, 2024
1 parent 2eead36 commit 75fc0bb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,8 @@ things simple. Hence, here there are some limitations/requirements:
target, and that's what you are supposed to be passing to the kernel.
- RISC-V is ambivalent on the endianness. Not this kernel. Out of simplicity we
require a little-endian RISC-V system.
- This kernel makes use of the `Zaamo` Extension for Atomic Memory Operations,
which is included under the `A` Extension for Atomic Instructions.

## Special thanks to

Expand Down
2 changes: 1 addition & 1 deletion include/fbos/init.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
// This greatly simplifies the specification and the hardware, but for the
// kernel this means that harts will appear randomly. In order to know which
// hart runs first, in Linux they run a "lottery": an atomic value holds how
// many harts hav already been seen. The first hart to appear will actually
// many harts have already been seen. The first hart to appear will actually
// initialize things before bringing the others up, while the others will simply
// wait until the first hart frees the lock for them.
//
Expand Down

0 comments on commit 75fc0bb

Please sign in to comment.