qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [PATCH] HPPA (PA-RISC) host support [v2]


From: Stuart Brady
Subject: [Qemu-devel] [PATCH] HPPA (PA-RISC) host support [v2]
Date: Sat, 12 Apr 2008 01:36:52 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

Hi,

The attached patch adds partially working HPPA (PA-RISC) Linux host
support.  As hppa-dis.c is quite large, and is unchanged, I haven't
attached it.  It was attached separately with the initial version
of this patch, submitted on 2008-03-23.

Changes from the initial version of the patch include the following:

 * The instruction masks and values for dyngen prologue/epilogue
   removal have been corrected and are now properly commented.

 * tcg/hppa/relocs.h has been moved into tcg/hppa/tcg-target.h,
   as there seemed to be no real benefit in having an extra header.

 * hppa_process_stubs() and related code has been moved from
   tcg-target.h into tcg-dyngen.c, as that is the only place in
   which it is used.

 * tcg_out_call() has been implemented.

 * tcg_out_qemu_ld() and tcg_out_qemu_st() have been partially
   implemented.  Unaligned loads/stores are not yet handled for
   linux-user targets, and 64-bit loads/stores and loads/stores
   with 64-bit target addresses need testing.

 * op_sar_i32 had the source/target registers for VEXTRS swapped.

 * r3 is now marked as reserved, as it is used as the frame pointer.

 * r1, r3 and r18 have been removed from tcg_target_reg_alloc_order[]
   as they are reserved, and r17, r14, r15, r16 (the dyngen 'AREG'
   registers) have been added to the end.

 * r20 is now used as a temporary register instead of r26, as r26
   is used to pass the first argument in a helper call.

 * tcg_out_mov() now uses the OR insn instead of LDO, as hppa-dis.c
   only disassembles the OR form into the COPY psuedo-insn.

Unfortunately, I have found that mips-softmmu emulation only works with
this patch if MIPS_SINGLE_STEP is defined.  I do not yet understand how
this could make a difference.

The i386-softmmu target now starts booting the linux-0.2.img test, but
it crashes when entering userspace.  Strangely, upon examining the core
dump and comparing this to the -d out_asm output in /tmp/qemu.log, it
seems that a small section of code is sometimes 'cut out' of the code
buffer -- I am not sure why this is happening, but I should probably
try the ARM target to eliminate any problems involving dyngen.

I had previously forgotten to mention that sparc32plus-linux-user,
sparc64-linux-user and ppc64-softmmu do not yet build, due to problems
regarding GCC (and possibly binutils).

Once again, thanks to Randolph Chung for a lot of the dyngen work.

Here's a diffstat of the changes:

 Makefile.target         |    8 
 configure               |    7 
 cpu-all.h               |   11 
 cpu-exec.c              |   29 +
 dis-asm.h               |    4 
 disas.c                 |    2 
 dyngen-exec.h           |    7 
 dyngen.c                |  129 ++++++
 hppa.ld                 |  214 ++++++++++
 tcg/hppa/tcg-target.c   |  980 ++++++++++++++++++++++++++++++++++++++++++++++++
 tcg/hppa/tcg-target.h   |  204 +++++++++
 tcg/i386/tcg-target.c   |    3 
 tcg/sparc/tcg-target.c  |    3 
 tcg/tcg-dyngen.c        |   50 ++
 tcg/tcg.c               |   30 +
 tcg/x86_64/tcg-target.c |    3 
 16 files changed, 1671 insertions(+), 13 deletions(-)

Cheers,
-- 
Stuart Brady

Attachment: qemu-host-hppa-v2.diff
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]