On 23 November 2011 23:00, Alexander Graf <ag...@suse.de> wrote:
>
> On 23.11.2011, at 23:34, Peter Maydell wrote:
>
>> On 23 November 2011 22:03, Alexander Graf <ag...@suse.de> wrote:
>>> Yes. Maybe we should add a check if input_state != output_state and
>>> only then do the conversion?
>>
>> I'm not sure this works (unless you go to the effort of implementing
>> target_to_host_waitstatus() which seems overkill to me) but I'm not
>> entirely sure what you're proposing to compare to what.
>
> It's an integer. If the number is the same before and after the wait
> syscall, we can safely assume that it's the same thing, so we don't
> have to convert it, no?

But you don't know whether it's the same before and after because
wait() didn't write to it [=> don't write to guest memory] or if
wait() did write to it but happened to write it as the same value
it had before [=> do write to guest memory].

-- PMM

Reply via email to