Commit graph mini-rv32ima/mini-rv32ima
Author SHA1 Message Date
2634265166 ch81: add cache support 2025-10-11 15:59:02 +02:00
4f25ecf40d ch81: add an approximate clang-format 2025-10-11 15:56:36 +02:00
Daniil
aec5728d73 Update mini-rv32ima.c 2025-05-04 09:25:30 +09:00
cnlohr
415c6dbcd3 Closes #49 making OS selection possible. 2025-02-03 17:21:50 -08:00
cnlohr
6fdcdea9bf
Merge pull request #48 from cleverca22/fix-post-exec
fix MINIRV32_POSTEXEC during trap
2024-12-09 02:48:56 -08:00
Michael Bishop
2a6ca5da21 fix MINIRV32_POSTEXEC during trap 2024-12-09 00:42:21 -04:00
Michael Bishop
f311641f2a move WFI to a case block 2024-12-08 20:05:39 -04:00
Nick Brassel
d64e184e97
Use conditional define instead, allowing for disjoint ranges. 2024-07-10 22:36:06 +10:00
Nick Brassel
c9b04ccd09
Parameterisation of MMIO, move handlers to .c file. 2024-06-04 22:18:54 +10:00
cnlohr
361cee7000 * Change default to use ttyS0
* Update configs to use new buildroot.
2023-11-27 19:06:22 -08:00
cnlohr
7b783ed6de Fix incorrect translation to HLSL. 2023-04-25 15:07:33 -04:00
cnlohr
f4bedf74ca * Make cache test work in HLSL.
* Get started on a cache test.
2023-04-13 04:00:32 -04:00
cnlohr
46968fd572 Trying with /bin/sh login 2023-03-28 03:43:19 -04:00
cnlohr
71a015eaa0 Update scripting to use new image. 2023-03-25 21:06:21 -04:00
cnlohr
80d36841ca Reword break. 2023-03-25 20:56:39 -04:00
cnlohr
4d25f34144 Significant perf improvement - don't rewrite CSRs, and restructure trap capture. 2023-03-25 20:54:38 -04:00
cnlohr
c01ed7d391 Fix rare bug when interrupting from userspace. 2023-03-25 19:35:42 -04:00
cnlohr
ad36240707 Fix spaces/tabs 2023-03-25 10:03:05 -04:00
cnlohr
2d4c56d56f Allow selection of hvc0 or ttyS0 depending on kernel command line parameters. 2023-03-25 09:54:17 -04:00
cnlohr
3f41f4821a Switch to the HVC terminal for fast output. 2023-03-25 09:20:48 -04:00
Vlad Tomoiaga
cd9d13eb41 fix bitshift on arm32 2023-02-27 21:29:05 +02:00
Hirosh Dabui
3fd160bb22 fixed signed overflow for div/rem referred to
https://five-embeddev.com/riscv-isa-manual/latest/m.html
https://five-embeddev.com/riscv-isa-manual/latest/m.html#tab:divby0
2023-02-19 09:16:48 +01:00
CNLohr
0f694606aa
Merge pull request #22 from xvuko/master
fix control memory address calculations
2023-01-31 15:58:05 -08:00
Jcodefox
17067a6d08 Fix dtb load address calculation. 2023-01-31 17:04:51 -05:00
Jan Wiśniewski
206b9b3ccf fix control memory address calculations
Note that this was working correctly only with default RAM offset.
In uint32 field (x - 2^31 - 2^31) is equal x.
2023-01-24 03:05:55 +01:00
CNLohr
f73fa22698
Merge pull request #20 from alexshpilkin/fix-optimization
Switch from -O3 optimization to -O2
2023-01-18 13:30:40 -08:00
Alexander Shpilkin
78fbee622e
Switch from -O3 optimization to -O2
GCC rounds off -O4 to the maximum supported -O3, which is known to be
hit and miss.  On my (fairly modest) laptop it yields a CoreMark score
of 425.  Using -O2 instead I get 470, so do that.
2023-01-02 00:09:42 +02:00
cnlohr
75002ee142 Break RV32A reservations on interrupt. 2022-12-12 17:34:43 -08:00
cnlohr
3a1ed10819 Merge branch 'master' of https://github.com/cnlohr/mini-rv32ima 2022-12-05 14:28:02 -08:00
cnlohr
27eb672b5f Update doom demo. 2022-12-05 14:27:50 -08:00
gagachang
3cfb2a79c9 Fix minor comment
The bit 7 of CSR mip should be MTIP not MSIP.
2022-12-05 13:31:11 +08:00
cnlohr
c67d26ee1e Bump system ram 2022-12-04 05:25:22 -05:00
cnlohr
a755b6d90e Improve EOF behavior 2022-12-03 03:57:32 -05:00
cnlohr
6f34daa0e7 Fix issue with mulh and negative numbers that caused DOOM to crash. 2022-12-02 08:02:01 -05:00
cnlohr
9a1dd4ace4 Fix logic for null string debug printing. 2022-12-02 03:29:10 -05:00
cnlohr
c6a2f570e5 * Fix timing bug from incorrect uint64_t casting
* Fix profiling.
2022-12-01 05:07:09 -05:00
cnlohr
091bdbeca2 Make debugging much more powerful + able to pipe in data (at least in Linux) 2022-12-01 04:09:58 -05:00
cnlohr
e34add9c25 Improve end-of-file behavior, and report detailed info on crash. 2022-12-01 03:03:32 -05:00
cnlohr
5f4a4bd5a7 Update notes, improve CLI 2022-11-30 18:42:17 -08:00
cnlohr
a5191aa853 Only tweak DTB ram if using the embedded DTB. 2022-11-30 00:41:50 -05:00
cnlohr
18fe04790d Update -t to allow negative divisors to disable sleeping. 2022-11-29 23:03:43 -05:00
cnlohr
483e7a8a9d Optimize inner emulator 2022-11-29 22:28:07 -05:00
cnlohr
faa8d882e5 * Check for failed allocation.
* Add time dialation divisor.
2022-11-29 18:23:39 -08:00
cnlohr
e3c74a66c9 Fix bintoh newline issue. 2022-11-29 15:21:09 -08:00
czarnobylu
11d5ab21c4 mini-rv32ima: Makefile: Added -e flag to bintoh.c echo
Added an -e flag to the echo statement so the \n character would print
as a newline in the file

Signed-off-by: czarnobylu <jbylicki@hotmail.com>
2022-11-29 17:46:38 +01:00
cnlohr
92136baf19 Update ram image size dynamically. 2022-11-28 16:05:46 -08:00
CNLohr
9bfd121ec7 Improve Win building. 2022-11-27 20:55:15 -08:00
CNLohr
50f869e2c5 * Add platform independent code, so the emulator works in Windows or Linux
* add a "winbuild" bat.
2022-11-27 19:43:01 -08:00
cnlohr
e711778b25 Embed DTB image into emulator. 2022-11-27 08:07:46 -05:00
cnlohr
00cc6efc2d Cleanup + add ability to get image from internet. 2022-11-27 07:36:06 -05:00