Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ CFLAGS += -D ENABLE_Zicsr
CFLAGS += -D ENABLE_Zifencei
CFLAGS += -D ENABLE_RV32A
CFLAGS += -D DEFAULT_STACK_ADDR=0xFFFFF000
CFLAGS += -D ENABLE_RV32C

# Experimental SDL oriented system calls
CFLAGS += -D ENABLE_SDL
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# RISC-V RV32I[MA] emulator with ELF support
# RISC-V RV32I[MAC] emulator with ELF support

`rv32emu` is an instruction set architecture (ISA) emulator implementing the 32 bit RISC-V processor model.

Expand Down Expand Up @@ -35,6 +35,7 @@ should appear when Doom is loaded and executed.
`rv32emu` is configurable, and you can modify `Makefile` to fit your expectations:
* `ENABLE_RV32M`: Standard Extension for Integer Multiplication and Division
* `ENABLE_RV32A`: Standard Extension for Atomic Instructions
* `ENABLE_RV32C`: Standard Extension for Compressed Instructions (RV32C.F excluded)
* `Zicsr`: Control and Status Register (CSR)
* `Zifencei`: Instruction-Fetch Fence

Expand Down
2 changes: 1 addition & 1 deletion io.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ uint32_t memory_read_str(memory_t *m, uint8_t *dst, uint32_t addr, uint32_t max)
uint32_t memory_read_ifetch(memory_t *m, uint32_t addr)
{
const uint32_t addr_lo = addr & mask_lo;
assert((addr_lo & 3) == 0);
assert((addr_lo & 1) == 0);

chunk_t *c = m->chunks[addr >> 16];
assert(c);
Expand Down
Loading