Skip to content

Commit d2fb10a

Browse files
ARC QEMU developersabrodkin
ARC QEMU developers
authored andcommitted
Add support for ARCv2 architecture
Signed-off-by: ARC QEMU developers <[email protected]>
1 parent d8df308 commit d2fb10a

File tree

138 files changed

+48604
-3
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

138 files changed

+48604
-3
lines changed

arch_init.c

+2
Original file line numberDiff line numberDiff line change
@@ -91,6 +91,8 @@ int graphic_depth = 32;
9191
#define QEMU_ARCH QEMU_ARCH_UNICORE32
9292
#elif defined(TARGET_XTENSA)
9393
#define QEMU_ARCH QEMU_ARCH_XTENSA
94+
#elif defined(TARGET_ARC)
95+
#define QEMU_ARCH QEMU_ARCH_ARC
9496
#endif
9597

9698
const uint32_t arch_type = QEMU_ARCH;

configure

+8
Original file line numberDiff line numberDiff line change
@@ -7801,6 +7801,9 @@ case "$target_name" in
78017801
mttcg="yes"
78027802
TARGET_SYSTBL_ABI=common
78037803
;;
7804+
arc)
7805+
gdb_xml_files="arc-core-v2.xml arc-aux-minimal.xml arc-aux-other.xml"
7806+
;;
78047807
arm|armeb)
78057808
TARGET_ARCH=arm
78067809
TARGET_SYSTBL_ABI=common,oabi
@@ -8053,6 +8056,9 @@ for i in $ARCH $TARGET_BASE_ARCH ; do
80538056
disas_config "ARM_A64"
80548057
fi
80558058
;;
8059+
arc)
8060+
disas_config "ARC"
8061+
;;
80568062
arm)
80578063
disas_config "ARM"
80588064
if test -n "${cxx}"; then
@@ -8190,11 +8196,13 @@ fi
81908196
# directory and symlink the directory instead.
81918197
DIRS="tests tests/tcg tests/tcg/lm32 tests/qapi-schema tests/qtest/libqos"
81928198
DIRS="$DIRS tests/qtest tests/qemu-iotests tests/vm tests/fp tests/qgraph"
8199+
DIRS="$DIRS tests/tcg/arc"
81938200
DIRS="$DIRS docs docs/interop fsdev scsi"
81948201
DIRS="$DIRS pc-bios/optionrom pc-bios/s390-ccw"
81958202
DIRS="$DIRS roms/seabios roms/vgabios"
81968203
LINKS="Makefile"
81978204
LINKS="$LINKS tests/tcg/lm32/Makefile po/Makefile"
8205+
LINKS="$LINKS tests/tcg/arc/Makefile"
81988206
LINKS="$LINKS tests/tcg/Makefile.target tests/fp/Makefile"
81998207
LINKS="$LINKS tests/plugin/Makefile"
82008208
LINKS="$LINKS pc-bios/optionrom/Makefile pc-bios/keymaps"

default-configs/arc-softmmu.mak

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Default configuration for arc-softmmu
2+
3+
CONFIG_VIRTIO_MMIO=y
4+
CONFIG_SERIAL=y
5+
CONFIG_OPENCORES_ETH=y

disas.c

+2
Original file line numberDiff line numberDiff line change
@@ -662,6 +662,8 @@ void disas(FILE *out, void *code, unsigned long size)
662662
print_insn = print_insn_s390;
663663
#elif defined(__hppa__)
664664
print_insn = print_insn_hppa;
665+
#elif defined(__arc__)
666+
print_insn = print_insn_arc;
665667
#endif
666668

667669
if (s.info.cap_arch >= 0 && cap_disas_host(&s.info, code, size)) {

disas/Makefile.objs

+1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ common-obj-$(CONFIG_SH4_DIS) += sh4.o
2424
common-obj-$(CONFIG_SPARC_DIS) += sparc.o
2525
common-obj-$(CONFIG_LM32_DIS) += lm32.o
2626
common-obj-$(CONFIG_XTENSA_DIS) += xtensa.o
27+
common-obj-$(CONFIG_ARC_DIS) += arc.o
2728

2829
# TODO: As long as the TCG interpreter and its generated code depend
2930
# on the QEMU target, we cannot compile the disassembler here.

0 commit comments

Comments
 (0)