* [Qemu-devel] HELP PLEASE! Consecutive runs of qemu-user
@ 2011-01-01 21:31 Stefano Bonifazi
2011-01-04 10:56 ` Stefan Weil
0 siblings, 1 reply; 2+ messages in thread
From: Stefano Bonifazi @ 2011-01-01 21:31 UTC (permalink / raw)
To: QEMU Developers
Hi!
First of all Happy new year to everybody! :) Wish you all to realize
all your dreams! :)
I edited QEMU user, more exactly qemu-ppc launching the main function
(inside main.c) from another c function I created, passing it the
appropriate parameters.
I also caught the syscall 1 preventing it to abort the process, and
simply returning from cpu_loop function, so that this function is not
more endless, and main returns to my user defined function.
The problem is that launching a second time main with other parameters
fails: leaving the code like it was, the previous translated binary was
kept "in memory" and run again, no matter what binary parameter I passed
to main.
I added then tb_flush(env); after cpu_loop inside main..
But with this edit launching main with other parameters blocks the
execution at tcg_qemu_tb_exec(tc_ptr); ..It sounds like QEMU stores the
state of the translation even after main function is over :(
Is it possible to reset completely the state, allowing consecutive runs
of different binaries?
What are the state variables I should "clean" between different runs?
Thank you very much for your help!
Best regards!
Stefano B.
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] HELP PLEASE! Consecutive runs of qemu-user
2011-01-01 21:31 [Qemu-devel] HELP PLEASE! Consecutive runs of qemu-user Stefano Bonifazi
@ 2011-01-04 10:56 ` Stefan Weil
0 siblings, 0 replies; 2+ messages in thread
From: Stefan Weil @ 2011-01-04 10:56 UTC (permalink / raw)
To: Stefano Bonifazi; +Cc: QEMU Developers
Am 01.01.2011 22:31, schrieb Stefano Bonifazi:
> Hi!
> First of all Happy new year to everybody! :) Wish you all to realize
> all your dreams! :)
> I edited QEMU user, more exactly qemu-ppc launching the main function
> (inside main.c) from another c function I created, passing it the
> appropriate parameters.
> I also caught the syscall 1 preventing it to abort the process, and
> simply returning from cpu_loop function, so that this function is not
> more endless, and main returns to my user defined function.
> The problem is that launching a second time main with other parameters
> fails: leaving the code like it was, the previous translated binary
> was kept "in memory" and run again, no matter what binary parameter I
> passed to main.
> I added then tb_flush(env); after cpu_loop inside main..
> But with this edit launching main with other parameters blocks the
> execution at tcg_qemu_tb_exec(tc_ptr); ..It sounds like QEMU stores
> the state of the translation even after main function is over :(
> Is it possible to reset completely the state, allowing consecutive
> runs of different binaries?
> What are the state variables I should "clean" between different runs?
> Thank you very much for your help!
> Best regards!
> Stefano B.
Hi Stefano,
maybe 'qemu -singlestep' helps.
Regards,
Stefan W.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-01-04 10:56 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-01 21:31 [Qemu-devel] HELP PLEASE! Consecutive runs of qemu-user Stefano Bonifazi
2011-01-04 10:56 ` Stefan Weil
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).