Subject: | |
From: | |
Reply To: | |
Date: | Tue, 30 Sep 1997 02:31:37 GMT |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
Gavin Scott ([log in to unmask]) wrote:
: Pete writes:
: > I have no idea why the choice was made to reverse the
: > fields when defining the POSIX PID, but that appears to be what was
: > done.
: If it's the reuse counter that's first, that would make some sense as
: it would result in PID numbers which are smaller than they would be
: otherwise, and (more or less) always increasing.
What's scary is that I helped to design the POSIX PID and I don't
remember why we reversed the fields, either. I seem to recall that it
had something to do with needing a signed number that still preserved
the PIN value.
[I'm going to check the data structure declaraion.]
After looking at the definition file, I see that I was correct. The
POSIX PID actually is three fields: a sign bit, a reuse counter, and
the PIN. Of course, the POSIX PID is supposed to be an opaque data
type. So, if you write code that decomposes this number, it's subject
to future breakage.
Mike P.
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Mike Paivinen
[log in to unmask]
Hewlett-Packard
CSY - Mailstop 47UA
19447 Pruneridge Avenue
Cupertino, CA 95014
|
|
|