puzzling code in pcpu stuff
dalroi at solfertje.student.utwente.nl
Sun Aug 2 17:20:37 UTC 2009
On 2 Aug 2009, at 18:55, Julian Elischer wrote:
> Alban Hertroys wrote:
>> On 2 Aug 2009, at 12:34, Christoph Mallon wrote:
>>> Julian Elischer schrieb:
>>>> I simplified the output of the preprocessor for a PCPU_SET(xx,
>>>> (to look at it).
>> Speaking as an outsider I'd better be careful with any criticism,
>> but the first thing I noticed here was the lack of comments. From
>> Julian's question it seems obvious that this function could do with
>> some. I wonder what people would make of this in a couple of years
>> when none of the (then) active developers has any intimate
>> knowledge of the workings of functions like this one?
> there are no comments in this cut-n-paste because it is the output
> of the C preprocessor.. of course the source doesn't have many
> comments either.. (in i386/include/pcpu.h)
Ah, I missed the first line of your message!
Yes, looking at the macro definitions that's a lot more like I
expected. It's just an assignment to *__PCPU_PTR(name), which is quite
A bit of a relief I must say :)
If you can't see the forest for the trees,
cut the trees and you'll see there is no forest.
More information about the freebsd-current