Re: [PATCH] cpumask 5/10 rewrite cpumask.h - single bitmap basedimplementation
From: Paul Jackson
Date: Fri Jun 04 2004 - 04:11:58 EST
William Lee Irwin III wrote:
On Thu, Jun 03, 2004 at 10:10:10AM -0700, Paul Jackson wrote:
> > +static inline void __cpu_set(int cpu, volatile cpumask_t *dstp)
> > ...
> Hungarian notation?
You mean the 'p' for pointer? Well, loosely speaking, I guess you could
call it that. Why do you ask?
Well ... I am not being straight forward. I likely know why you ask. I
find an occassional 'p' in a variable name to be helpful. For example,
in this case, I am flipping between referring to the same datum by
reference and by value - so it is useful to reflect that distinction in
the variable names - it's _the_ key distinction. If you wish to state a
case to the contrary, you're welcome to do so.
> #ifdef'ing it anyway?
In certain cases, yes. I had a version of these particular macros that
used inline logic instead, but this looked easier to read to my eye. If
I spoke out against ifdef's carte blanche at some point (which likely I
did) then I was being incautious in my speaking. The question is more
how best to make the code readable, maintainable, robust, fast and small.
> This is an improvement?
... see Keith's reply ...
Thank-you for your review comments.
--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@xxxxxxx> 1.650.933.1373
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/