qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] How to get gpr register contents in translate.c


From: Andreas Färber
Subject: Re: [Qemu-devel] How to get gpr register contents in translate.c
Date: Thu, 08 Mar 2012 23:28:30 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.2) Gecko/20120215 Thunderbird/10.0.2

Hello,

Am 07.03.2012 16:24, schrieb Elta:
> Now I get trouble in translate.c. I really want to get gpr value in 
> translate.c, but cpu_gpr[rs]'s type is TCGv, can not get the real value of 
> rs. Is the have any method or macro can made it?

You forgot to mention which target you are talking about. ;)

Translation happens ahead of time. You do have access to CPUState but
its fields likely do not have the value you are interested in.
You'll have to read up on TCG and how to emit code that does what you
want to do with the register value at runtime rather than at translation
time.

Andreas

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg



reply via email to

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