Squashed commit of the following:

commit 2d9587f26b
Author: WangLiangpu <wangjingpu17@mails.ucas.ac.cn>
Date:   Wed Nov 1 21:36:35 2023 +0800

    fix: fix tcg_out_dupi_vec interface conflicts

commit b957324d3d
Author: zhaodongru <zhaodongru@yeah.net>
Date:   Mon Oct 23 18:15:01 2023 +0800

    start loongarch compile

    fix: modify the code to pass compile

    add: add code for tcg_out_op, tcg_can_emit_vec_op, tcg_target_op_def to support new tcg_op

    fix: fix bugs related to epilogue and ret_addr

    fix: fix bug in qemu_ld_slow_path, the return register is wrong
This commit is contained in:
WangLiangpu
2025-04-14 23:05:49 +08:00
committed by lazymio
parent fd1bf224e9
commit 0cd8b83f5b
7 changed files with 9944 additions and 0 deletions

16
qemu/configure vendored
View File

@@ -491,6 +491,8 @@ elif check_define __aarch64__ ; then
cpu="aarch64"
elif check_define __tricore__ ; then
cpu="tricore"
elif check_define __loongarch64 ; then
cpu="loongarch64"
else
cpu=$(uname -m)
fi
@@ -534,6 +536,10 @@ case "$cpu" in
cpu="tricore"
supported_cpu="yes"
;;
loongarch64)
cpu="loongarch64"
supported_cpu="yes"
;;
*)
# This will result in either an error or falling back to TCI later
ARCH=unknown
@@ -844,6 +850,11 @@ case "$cpu" in
CPU_CFLAGS="-m64 -mcx16"
QEMU_LDFLAGS="-m64 $QEMU_LDFLAGS"
;;
loongarch*)
CPU_CFLAGS=""
QEMU_LDFLAGS=" $QEMU_LDFLAGS"
;;
x32)
CPU_CFLAGS="-mx32"
QEMU_LDFLAGS="-mx32 $QEMU_LDFLAGS"
@@ -2659,6 +2670,11 @@ case "$target_name" in
mttcg="yes"
TARGET_SYSTBL_ABI=i386
;;
loongarch64)
mttcg="yes"
TARGET_ARCH=loongarch64
TARGET_SYSTBL_ABI=common,64
;;
x86_64)
TARGET_BASE_ARCH=i386
TARGET_SYSTBL_ABI=common,64