[Top][All Lists]

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

Re: [Qemu-devel] [PATCH 3/3] tcg: declare internal helpers as const and

From: Aurelien Jarno
Subject: Re: [Qemu-devel] [PATCH 3/3] tcg: declare internal helpers as const and pure
Date: Fri, 5 Mar 2010 21:07:31 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

On Fri, Mar 05, 2010 at 11:15:45AM +0000, Paul Brook wrote:
> > TCG internal helpers only access to the values passed in arguments, and
> > do not modify the CPU internal state. Thus they can be declared as
> > const and pure.
> I think this needs an explanatory comment. It's not immediately obvious that 
> tcg_gen_helperN and tcg_gen_helper{32,64} have significantly different 
> semantics.

What do you mean exactly? Mentioning explicitly tcg_gen_helper{32,64}
instead of "TCG internal helpers".

> tcg/README also needs updating, specifically:
> "* Helpers:
> Using the tcg_gen_helper_x_y it is possible to call any function
> taking i32, i64 or pointer types. Before calling an helper, all
> globals are stored at their canonical location and it is assumed that
> the function can modify them. In the future, function modifiers will
> be allowed to tell that the helper does not read or write some globals.
> "

Fully agreed, but it is not a change introduce by this patch series. 
I'll submit a patch later.

Aurelien Jarno                          GPG: 1024D/F1BCDB73
address@hidden                 http://www.aurel32.net

reply via email to

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