On Mon, Jun 27, 2011 at 14:56, Lawrence Crowl <cr...@google.com> wrote:
> On 6/27/11, Diego Novillo <dnovi...@google.com> wrote:
>> On Jun 27, 2011 Gabriel Charette <gch...@google.com> wrote:
>> > Just wondering why you're naming x finishing by an underscore
>> > "x_", this is a valid name, but just thinking it's tricky syntax,
>> > does this test anything more? or is it just a preference for
>> > private members?
>>
>> No real reason.  Just a quick hack I was trying to compile with
>> pph enabled.
>
> There is a convention in Google (and elsewhere) to mark data member
> fields with a trailing underscore in their name.  This convention
> makes it easy to identify field accesses, which helps avoid
> performance problems (unnecessary reloads) and correctness problems
> (missing reloads in the presence of aliasing).

That's probably where I picked it from.  I wasn't really thinking
about the code itself.  Just wanted to get some simple C++ executable
test.


Diego.

Reply via email to