From: Joe Perches <joe@perches.com>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Stratos Karafotis <stratosk@semaphore.gr>,
Dirk Brandewie <dirk.brandewie@gmail.com>,
dirk.j.brandewie@intel.com,
Viresh Kumar <viresh.kumar@linaro.org>,
"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 6/7] cpufreq: intel_pstate: Trivial code cleanup
Date: Tue, 10 Jun 2014 14:26:45 -0700 [thread overview]
Message-ID: <1402435605.4082.3.camel@joe-AO725> (raw)
In-Reply-To: <1894836.tjrHdJ7Duz@vostro.rjw.lan>
On Tue, 2014-06-10 at 23:38 +0200, Rafael J. Wysocki wrote:
> > > is. And the result of (a * 100) / b may generally be different from
> > > a * 100 / b for integers (if the division is carried out first).
> >
> > I thought that (a * 100) / b is always equivalent to a * 100 / b.
>
> I'm not actually sure if that's guaranteed by C standards.
It is. left to right, same precedence.
> It surely
> wasn't some time ago (when there was no formal C standard).
c89 is 25 years ago now.
> Either way, in my opinion it's better to put the parens into the expression
> in this particular case to clearly state the intention.
I don't think so.
next prev parent reply other threads:[~2014-06-10 21:26 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-09 21:01 [PATCH 6/7] cpufreq: intel_pstate: Trivial code cleanup Stratos Karafotis
2014-06-09 21:22 ` Joe Perches
2014-06-10 14:43 ` Stratos Karafotis
2014-06-10 15:12 ` Dirk Brandewie
2014-06-10 15:31 ` Rafael J. Wysocki
2014-06-10 17:26 ` Dirk Brandewie
2014-06-10 20:17 ` Rafael J. Wysocki
2014-06-10 20:14 ` Stratos Karafotis
2014-06-10 20:43 ` Rafael J. Wysocki
2014-06-10 21:02 ` Stratos Karafotis
2014-06-10 21:38 ` Rafael J. Wysocki
2014-06-10 21:26 ` Joe Perches [this message]
2014-06-11 0:23 ` Rafael J. Wysocki
2014-06-11 1:41 ` Joe Perches
2014-06-10 21:35 ` Stratos Karafotis
2014-06-11 0:24 ` Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1402435605.4082.3.camel@joe-AO725 \
--to=joe@perches.com \
--cc=dirk.brandewie@gmail.com \
--cc=dirk.j.brandewie@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=rjw@rjwysocki.net \
--cc=stratosk@semaphore.gr \
--cc=viresh.kumar@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox