Skip to content
This repository was archived by the owner on Jan 25, 2022. It is now read-only.

Commit c32cff9

Browse files
committed
Clarify licensing information
1 parent ebf54c4 commit c32cff9

File tree

4 files changed

+11
-73
lines changed

4 files changed

+11
-73
lines changed

AUTHORS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
rv32emu is maintained by National Cheng Kung University, based on the
2+
following efforts:
3+
14
Fabrice Bellard - original code of RISC-V emulator:
25
https://bellard.org/tinyemu/
36

LICENSE

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
Original MIT License:
2-
1+
Copyright (c) 2019 National Cheng Kung University, Taiwan
2+
Copyright (c) 2018 Alexander Shabarshin
3+
Copyright (c) 2018 Frank Buss
34
Copyright (c) 2016-2017 Fabrice Bellard
45

56
Permission is hereby granted, free of charge, to any person obtaining a copy

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# RISC-V RV32I[MA] emulator with ELF support
22

3-
Emulator was originally created by Fabrice Bellard and then modified and shared on Hackaday by Frank Buss
4-
as a single C-file. Shaos added some additional statistics and macros.
3+
This is a RISC-V emulator for the RV32I architecture, based on [TinyEMU](https://bellard.org/tinyemu/)
4+
and stripped down for RV32I only.
55

66
Requires libelf-dev:
77
```shell

emu-rv32i.c

Lines changed: 3 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -1,74 +1,8 @@
1-
/* Modified by Shaos <[email protected]>
2-
24-DEC-2018 - Find top 5 instructions in DEBUG_EXTRA mode
3-
20-DEC-2018 - More statistical points
4-
22-NOV-2018 - Added saving HEX file with copy of the code in DEBUG_OUTPUT mode
5-
21-NOV-2018 - Some statistics added in DEBUG_EXTRA mode
6-
20-NOV-2018 - By default RV32M and RV32A extensions are disabled (STRICT_RV32I)
7-
18-NOV-2018 - Slghtly modified for pure C
8-
Source code taken from https://gist.github.com/FrankBuss/c974e59826d33e21d7cad54491ab50e8
9-
*/
10-
11-
/*
12-
RISCV emulator for the RV32I architecture
13-
based on TinyEMU by Fabrice Bellard, see https://bellard.org/tinyemu/
14-
stripped down for RV32I only, all "gotos" removed, and fixed some bugs for the compliance test
15-
by Frank Buss, 2018
16-
17-
Requires libelf-dev:
18-
19-
sudo apt-get install libelf-dev
20-
21-
22-
Compile it like this:
23-
24-
gcc -O3 -Wall -lelf emu-rv32i.c -o emu-rv32i
25-
26-
27-
It is compatible to Spike for the command line arguments, which means you can run
28-
the compliance test from https://github.com/riscv/riscv-compliance like this:
29-
30-
make RISCV_TARGET=spike RISCV_DEVICE=rv32i TARGET_SIM=/full/path/emulator variant
31-
32-
It is also compatible with qemu32, as it is used for Zephyr. You can compile the
33-
Zephyr examples for qemu like this:
34-
35-
cd zephyr
36-
source zephyr-env.sh
37-
cd samples/synchronization
38-
mkdir build && cd build
39-
cmake -GNinja -DBOARD=qemu_riscv32 ..
40-
ninja
41-
42-
After this you can run it with the emulator like this:
43-
44-
emu-rv32i zephyr/zephyr.elf
45-
46-
47-
original copyright:
48-
*/
49-
501
/*
51-
* RISCV emulator
52-
*
53-
* Copyright (c) 2016 Fabrice Bellard
54-
*
55-
* Permission is hereby granted, free of charge, to any person obtaining a copy
56-
* of this software and associated documentation files (the "Software"), to deal
57-
* in the Software without restriction, including without limitation the rights
58-
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
59-
* copies of the Software, and to permit persons to whom the Software is
60-
* furnished to do so, subject to the following conditions:
61-
*
62-
* The above copyright notice and this permission notice shall be included in
63-
* all copies or substantial portions of the Software.
2+
* A minimalist RISC-V emulator for the RV32I architecture.
643
*
65-
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
66-
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
67-
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
68-
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
69-
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
70-
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
71-
* THE SOFTWARE.
4+
* rv32emu is freely redistributable under the MIT License. See the file
5+
* "LICENSE" for information on usage and redistribution of this file.
726
*/
737

748
#define XLEN 32

0 commit comments

Comments
 (0)