qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Blue Swirl" <blauwirbel@gmail.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] and now bus error for i386 guest
Date: Tue, 4 Dec 2007 20:54:03 +0200	[thread overview]
Message-ID: <f43fc5580712041054u117c5315t4112bc9f599a4202@mail.gmail.com> (raw)
In-Reply-To: <475554E1.5070509@shaddybaddah.name>

On 12/4/07, Shaddy Baddah <shaddy.baddah@shaddybaddah.name> wrote:
> HI,
>
> Blue Swirl wrote:
> > On 11/14/07, Shaddy Baddah <shaddy.baddah@shaddybaddah.name> wrote:
> >> Hi again,
> >>
> >> After further culling the target list, I was able to install qemu on my
> >> sun4u host.
> >>
> >> However, running it, I get a bus error. See below for details:
> >>
> >> $ /opt/qemu-cvs/bin/qemu -m 128 -cdrom
> >> ~/KNOPPIX_V5.1.1CD-2007-01-04-EN.iso -vnc :1
> >> Bus error
> >
> > For some reason, Sparc Linux host is not working. I think Sparc Solaris is OK.
>
> Yes, I do recall that I was able to get this working on Sparc Solaris.
> Anyway, when I get more time, I will have a better stab at debugging
> this. I got a start on this today, and here is a bit of cut and paste
> that may or may not be insightful. The address for env1 looks questionable:
>
> shaddy@localhost:~/qemu-cvs/qemu-build$ gdb --args ./i386-softmmu/qemu
> -hda ../../KNOPPIX_V5.1.1CD-2007-01-04-EN.iso -L ../qemu/pc-bios
> GNU gdb 6.6.90.20070912-debian
> Copyright (C) 2007 Free Software Foundation, Inc.
> License GPLv3+: GNU GPL version 3 or later
> <http://gnu.org/licenses/gpl.html>
> This is free software: you are free to change and redistribute it.
> There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
> and "show warranty" for details.
> This GDB was configured as "sparc-linux-gnu"...
> Using host libthread_db library "/lib/libthread_db.so.1".
> (gdb) run
> Starting program: /home/shaddy/qemu-cvs/qemu-build/i386-softmmu/qemu
> -hda ../../KNOPPIX_V5.1.1CD-2007-01-04-EN.iso -L ../qemu/pc-bios
> [Thread debugging using libthread_db enabled]
> [New Thread 0xf7f7b550 (LWP 9363)]
>
> Program received signal SIGBUS, Bus error.
> [Switching to Thread 0xf7f7b550 (LWP 9363)]
> cpu_x86_exec (env1=0x2) at /home/shaddy/qemu-cvs/qemu/cpu-exec.c:307
> 307                 if (env->exception_index >= 0) {
> (gdb) info threads
> * 1 Thread 0xf7f7b550 (LWP 9363)  cpu_x86_exec (env1=0x2)
>      at /home/shaddy/qemu-cvs/qemu/cpu-exec.c:307
> (gdb)

My guess is that Linux glibc overwrites global registers at some
point, like in signal handling or setjmp. The generated code looks OK
and it shouldn't be different from what Solaris version would
generate. I've been thinking of different register design (using
locals or outs) but then the op helpers would need to use different
mechanism to access T0/T1/T2. Compiling Qemu against uClibc could also
show something.

> PS: couldn't this also be debugged from within qemu VM running Debian
> Sparc, for those that don't have access to a real machine? I got a start
> on this today as well (because I don't always have access to the Sun
> Ultra box). Seems stable, and I was able to get a start on a compile,
> that is currently still going.

Nice idea! Do you mean full system emulator or user mode?

  reply	other threads:[~2007-12-04 18:54 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-14  7:04 [Qemu-devel] Alpha build failure: dyngen picking out a nameless symbol Shaddy Baddah
2007-11-14  8:10 ` [Qemu-devel] now ppc build failure: dyngen: empty code for op_splatw_T1_64 Shaddy Baddah
2007-11-14 13:13   ` [Qemu-devel] and now bus error for i386 guest Shaddy Baddah
2007-11-14 20:42     ` Blue Swirl
2007-12-04  4:21       ` Shaddy Baddah
2007-12-04 13:23       ` Shaddy Baddah
2007-12-04 18:54         ` Blue Swirl [this message]
2007-12-05 14:33           ` Shaddy Baddah
2007-12-05 21:36             ` Blue Swirl
2007-12-06  0:17               ` Shaddy Baddah
2007-12-06  9:10                 ` Blue Swirl
2007-12-06 15:19                   ` Blue Swirl
2007-11-15 20:01 ` [Qemu-devel] Alpha build failure: dyngen picking out a nameless symbol Blue Swirl
2007-11-15 22:50   ` Paul Brook

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=f43fc5580712041054u117c5315t4112bc9f599a4202@mail.gmail.com \
    --to=blauwirbel@gmail.com \
    --cc=qemu-devel@nongnu.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).