All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stuart Brady <sdbrady@ntlworld.com>
To: Carlos O'Donell <carlos@systemhalted.org>
Cc: parisc-linux@parisc-linux.org
Subject: Re: [parisc-linux] QEMU Port (Help needed)
Date: Mon, 5 Jun 2006 00:13:02 +0100	[thread overview]
Message-ID: <20060604231302.GA18282@miranda.arrow> (raw)
In-Reply-To: <119aab440606041448t3952e3dfwf85f926ffdc5e441@mail.gmail.com>

On Sun, Jun 04, 2006 at 05:48:17PM -0400, Carlos O'Donell wrote:
> On 6/4/06, Stuart Brady <sdbrady@ntlworld.com> wrote:
> >I've had a stab at porting QEMU to PA-RISC... I've uploaded a patch
> >against QEMU 0.8.1 to:
> >
> >  http://homepage.ntlworld.com/wholehog/stuart/qemu/qemu-hppa-guest.diff
> >
> >It compiles, but I can't figure out why it's crashing.  Any ideas?
> 
> That's awesome to hear that you are working on QEMU for PARISC!
> It would rock to have a fast simulator. Even a semi-hosted environment
> would be a cool toy to play with.

It would be nice.  But I'm not sure if I _can_ finish this. :(

> Does QEMU crash?
> Does the emulated userspace crash?

QEMU crashes.  So far, I've only tried system emulation, not userspace
emulation.

An illegal instruction is being executed, and this appears to be for the
very first instruction that is emulated.  I get the following:

Program received signal SIGILL, Illegal instruction.
[Switching to Thread 16384 (LWP 6905)]
0x00b30f40 in stdout ()
(gdb)

bt makes gdb hang! :(  Unfortunately, my gdb-fu is pretty weak.

> A couple of comments about your patch:
> 
> 1. Remember 32-bit PARISC executables have both function pointers and
> function descriptors.

Ow.  I really have no idea about how this works.

> 2. The "gp" is r19, the "dp" is r27. I don't know what your reference
> to the "__dlt" is?

I don't know, either.  I was mainly guessing, based on what I saw in the
PA ELF supplement.  After changing it to use r19, gcc warns that r19 is
call-clobbered, but I don't know whether that's relevant.  I see the
same behaviour as before, though...

> 3. You can copy testandset from glibc linuxthreads pthread.h

Okay, I will do.  (I don't think this is the immediate problem, though.)

> 4. flush_icache_range can probably be copied from the kernel implementation.

Probably.  Much of QEMU is LGPLed, though... but I can certainly try
using the kernel implementation.

> Other than that, there are *all* sorts of things which could be wrong :)

Hmm... and they probably *are* wrong, too! :)

Thanks,
-- 
Stuart Brady
_______________________________________________
parisc-linux mailing list
parisc-linux@lists.parisc-linux.org
http://lists.parisc-linux.org/mailman/listinfo/parisc-linux

  reply	other threads:[~2006-06-04 23:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-04 16:04 [parisc-linux] QEMU Port (Help needed) Stuart Brady
2006-06-04 21:48 ` Carlos O'Donell
2006-06-04 23:13   ` Stuart Brady [this message]
2006-06-04 23:19   ` Matthew Wilcox
2006-06-04 23:22     ` Carlos O'Donell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060604231302.GA18282@miranda.arrow \
    --to=sdbrady@ntlworld.com \
    --cc=carlos@systemhalted.org \
    --cc=parisc-linux@parisc-linux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.