From: Stefan Weil <weil@mail.berlios.de>
To: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] Porting TCG to alpha platform
Date: Sat, 30 Jan 2010 00:04:29 +0100 [thread overview]
Message-ID: <4B63697D.4040507@mail.berlios.de> (raw)
In-Reply-To: <20100129213808.GA11999@laped.iglesias.mooo.com>
Edgar E. Iglesias schrieb:
> On Fri, Jan 29, 2010 at 09:04:58AM -0800, Richard Henderson wrote:
>> On 01/28/2010 05:55 PM, identifier scorpio wrote:
>>> Your code is more skilled and I learn a lot from it, but I haven't yet
>>> recognized the key difference between your version and mine. In last
>>> mail, you've said that "Mainly, tcg_target_long was used places that
>>> could be holding HOST values, which means that the host values would
>>> have been truncated to 32 bits.", and I can't fully understand it, may
>>> you put it more clearly.
>> It was a mis-statement made while tired. Of course tcg_target_long is
>> defined to int64_t when TCG_TARGET_REG_BITS == 64, so there was no
>> truncation to 32 bits.
>>
>> Have you tested of any of the other embedded targets? You may be able
>> to find the error with one of those easier than finding it emulating
>> full-scale Windows. See the images at the bottom of the QEMU download
>> page.
>
> Hi,
>
> Although I've never hacked on a TCG backend I'd still like to give some
> advice.
>
> >From experience when developing both the CRIS and the MicroBlaze ISA
> translators I very much suggest getting something very stable to work
> in linux-user before going further.
>
> I used GCC's C torture tests and OpenSSL's bignum tests to verify the
> ports. In particular, OpenSSL's bignum tests seem to excersice lot's of
> cornercases.
>
> If you pass those, you've come a long way. In general it's much easier
> to debug a guest testcase (bntest, etc) that fails compared to huge
> propretiary blob that fails (windows).
>
> Just a suggestion, hope it helps.
>
> Cheers,
> Edgar
Hi Edgar,
that was a good suggestion. bntest raises a segmentation fault
(NULL pointer, p == 0, see below) with qemu-x86_64 on a x86_64 host.
Regards,
Stefan
obase=16
ibase=16
test BN_add
print "test BN_add\n"
Program received signal SIGSEGV, Segmentation fault.
tb_alloc_page (tb=0x7ffff3423290, phys_pc=<value optimized out>,
phys_page2=18446744073709551615) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/exec.c:1124
1124 tb->page_next[n] = p->first_tb;
(gdb) i s
#0 tb_alloc_page (tb=0x7ffff3423290, phys_pc=<value optimized out>,
phys_page2=18446744073709551615) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/exec.c:1124
#1 tb_link_phys (tb=0x7ffff3423290, phys_pc=<value optimized out>,
phys_page2=18446744073709551615) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/exec.c:1214
#2 0x000000006001fd5c in tb_gen_code (env=0x7ffff7f97010,
pc=18446744073699066880, cs_base=<value optimized out>, flags=<value
optimized out>, cflags=<value optimized out>) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/exec.c:912
#3 0x000000006002241b in tb_find_slow (env1=<value optimized out>) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/cpu-exec.c:161
#4 tb_find_fast (env1=<value optimized out>) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/cpu-exec.c:182
#5 cpu_x86_exec (env1=<value optimized out>) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/cpu-exec.c:574
#6 0x00000000600064c0 in cpu_loop (env=0x7ffff7f97010) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/linux-user/main.c:309
#7 0x00000000600076d2 in main (argc=<value optimized out>, argv=<value
optimized out>, envp=<value optimized out>) at
/home/stefan/src/qemu/repo.or.cz/qemu/ar7/linux-user/main.c:3101
next prev parent reply other threads:[~2010-01-29 23:04 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-22 15:47 [Qemu-devel] [PATCH] Porting TCG to alpha platform identifier scorpio
2010-01-22 18:00 ` Richard Henderson
2010-01-26 1:19 ` Richard Henderson
2010-01-29 1:55 ` identifier scorpio
2010-01-29 17:04 ` Richard Henderson
2010-01-29 21:38 ` Edgar E. Iglesias
2010-01-29 23:04 ` Stefan Weil [this message]
2010-01-30 0:38 ` Edgar E. Iglesias
2010-01-30 1:14 ` Laurent Desnogues
2010-01-30 9:30 ` [Qemu-devel] [BUG] qemu-x86_64 crash when running bntest (was: [PATCH] Porting TCG to alpha platform) Stefan Weil
2010-01-30 9:59 ` Laurent Desnogues
2010-01-30 14:47 ` Laurent Desnogues
2010-01-29 17:37 ` [Qemu-devel] [PATCH] Porting TCG to alpha platform Richard Henderson
2010-01-29 19:19 ` Richard Henderson
2010-01-30 2:45 ` identifier scorpio
2010-01-31 23:09 ` Richard Henderson
-- strict thread matches above, loose matches on Subject: below --
2010-01-21 3:42 identifier scorpio
2010-01-21 18:18 ` Stefan Weil
2010-01-20 17:19 identifier scorpio
2010-01-20 21:26 ` Richard Henderson
2010-01-19 8:47 identifier scorpio
2010-01-19 20:18 ` Richard Henderson
2010-01-19 21:35 ` malc
2010-01-19 21:42 ` Stefan Weil
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=4B63697D.4040507@mail.berlios.de \
--to=weil@mail.berlios.de \
--cc=edgar.iglesias@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).