Hi Yonggang,
On 26/9/26 13:08, Yonggang Luo wrote:
A combined qemu-system binary cannot export the same C symbol from two targets.
This series prefixes TCG helpers and virt ACPI setup functions that still use a
short name another target already exports.
- Prefix leftover i386 TCG raise_exception to i386_raise_exception. Rename the C
raise_exception family globals to i386_raise_exception*, and keep the short
names as static inline wrappers in helper-tcg.h. Wrappers still call
raise_interrupt2.
- Prefix helper_wait on RX, Hexagon, and MIPS. Hexagon also takes the resume PC
as vaddr.
- Prefix ARM raise_exception to arm_raise_exception and keep the short name as a
static inline wrapper.
- Prefix virt_acpi_setup and virt_is_acpi_enabled on ARM, RISC-V, and LoongArch
virt. Leave the ARM trace event virt_acpi_setup unchanged. Leave RISC-V
file-local virt_acpi_build* names unchanged.
- Rename RISC-V TCG crc32, crc32c, and wfi to riscv_crc32, riscv_crc32c, and
riscv_wfi. ARM already exports helper_crc32, helper_crc32c, and helper_wfi.
This was our first quick-and-dirty approach to link a proof-of-concept
binary, but doesn't scale.
Our idea is to modify the macro expanded by the various DEF_HELPER_x()
(helper-gen.h.inc, helper-info.c.inc and helper-proto.h.inc in
include/exec/) to prepend the target name to the function name with
the glue() macro. Core TCG helpers (i.e. when TARGET_NAME is not
defined) would use "core" or "common" prefix.
Since you are motivated and keen in getting that binary linked, are
you interested to look at this?
Regards,
Phil.