1
+ # Board Configuration for QEMU RISC-V Emulator
2
+ # YAML format with hierarchical structure
3
+
4
+ # Board identification and defaults
5
+ board : qemu
6
+ defaults :
7
+ cc : riscv32-unknown-elf-gcc
8
+ cpu_mhz : 1
9
+ warmup_heat : 1
10
+ defines : [ "CPU_MHZ=1", "WARMUP_HEAT=1"]
11
+
12
+ # Architecture and platform specific configurations
13
+ architectures :
14
+ rv32 :
15
+ platforms :
16
+ baremetal :
17
+ cc : riscv32-unknown-elf-gcc
18
+ arch : rv32imafdc
19
+ abi : ilp32d
20
+ base_cflags : ["-march=rv32imafdc", "-mabi=ilp32d", "-mcmodel=medany", "-mno-relax", "-mstrict-align"]
21
+ base_ldflags : ["-march=rv32imafdc", "-mabi=ilp32d", "-nostartfiles", "-Wl,--no-warn-rwx-segments"]
22
+ linker_script : link.ld
23
+ libs : ["-lc", "-lm"]
24
+ includes : []
25
+
26
+ linux :
27
+ cc : riscv32-linux-gnu-gcc
28
+ arch : rv32imafdc
29
+ abi : ilp32d
30
+ base_cflags : ["-march=rv32imafdc", "-mabi=ilp32d", "-static", "-O2"]
31
+ base_ldflags : ["-march=rv32imafdc", "-mabi=ilp32d", "-static"]
32
+ libs : ["-lm"]
33
+ includes : []
34
+
35
+ rv64 :
36
+ platforms :
37
+ baremetal :
38
+ cc : riscv64-unknown-elf-gcc
39
+ arch : rv64imafdc
40
+ abi : lp64d
41
+ base_cflags : ["-march=rv64imafdc", "-mabi=lp64d", "-mcmodel=medany", "-mno-relax", "-mstrict-align"]
42
+ base_ldflags : ["-march=rv64imafdc", "-mabi=lp64d", "-nostartfiles", "-Wl,--no-warn-rwx-segments"]
43
+ linker_script : link.ld
44
+ libs : ["-lc", "-lm"]
45
+ includes : []
46
+
47
+ linux :
48
+ cc : riscv64-linux-gnu-gcc
49
+ arch : rv64imafdc
50
+ abi : lp64d
51
+ base_cflags : ["-march=rv64imafdc", "-mabi=lp64d", "-static", "-O2"]
52
+ base_ldflags : ["-march=rv64imafdc", "-mabi=lp64d", "-static"]
53
+ libs : ["-lm"]
54
+ includes : []
55
+
56
+ # Workload specific configurations
57
+ workloads :
58
+ embench-iot :
59
+ workload_cflags : ["-Dtrue=1", "-Dfalse=0", "-I/workloads/embench-iot/support/"]
60
+ workload_ldflags : []
61
+ workload_defines : []
62
+ workload_includes : []
63
+ workload_sources : ["/workloads/embench-iot/support/beebsc.c"]
64
+ environment_files : ["crt0.S", "main.c", "stub.c", "util.c"]
65
+
66
+ platforms :
67
+ linux :
68
+ workload_cflags : ["-std=gnu99"]
69
+ skip_environment : true
70
+
71
+ riscv-tests :
72
+ workload_cflags : ["-std=gnu99", "-Wno-implicit-int", "-Wno-implicit-function-declaration"]
73
+ workload_ldflags : []
74
+ workload_defines : []
75
+ workload_includes : ["benchmarks/common"]
76
+ environment_files : ["crt0.S", "main.c", "stub.c", "util.c"]
77
+
78
+ platforms :
79
+ linux :
80
+ workload_cflags : ["-std=gnu99"]
81
+ skip_common_files : ["syscalls.c"]
82
+ skip_environment : true
83
+
84
+ dhrystone :
85
+ # Inherits from riscv-tests configuration
86
+ parent : riscv-tests
87
+ workload_cflags : ["-std=gnu99", "-Wno-implicit-int", "-Wno-implicit-function-declaration"]
88
+
89
+ # Features and special configurations
90
+ features :
91
+ bbv :
92
+ bbv_cflags : ["-DBBV"]
93
+ bbv_ldflags : []
94
+
95
+ trace :
96
+ trace_cflags : ["-DTRACE"]
97
+ trace_ldflags : []
98
+
99
+ vector :
100
+ # Vector extension configuration for benchmarks starting with "vec-"
101
+ vector_rv32_arch : rv32gcv
102
+ vector_rv64_arch : rv64gcv
103
+ regular_rv32_arch : rv32gc
104
+ regular_rv64_arch : rv64gc
0 commit comments