Re: [PATCH] trace2: log progress time and throughput

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

 



On Tue, Jun 22, 2021 at 08:29:35PM -0700, Chris Torek wrote:
> On Tue, Jun 22, 2021 at 7:56 PM Taylor Blau <me@xxxxxxxxxxxx> wrote:
> >... I was going to comment on the fact that "(*p_progress)->total" could
> > be written simply as "*p_progress->total", but I'm (a) not sure that I
> > actually prefer the latter to the former, and (b) I find that kind of
> > style comment generally useless.
>
> Also, it can't. :-) The binding order is wrong; *p_progress->total binds as
> *(p_progress->total), and `p_progress` has to be followed first, so this
> just doesn't work.

Ack, serves me right for starting a discussion based on operator
precedence. Yes, you're right, I was mistaken and forgot that -> binds
with highest precedence in C (above *, which is why this doesn't work).

In any case, my confusion is probably a good reason to avoid this
entirely by manipulating a variable which stores *p_progress.

Thanks,
Taylor



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux