[threads-standard-discuss] MP standardization proposal

Nikodemus Siivola tsiivola at cc.hut.fi
Tue Dec 7 14:45:13 UTC 2004


I found this during my postponed-folder cleanup. It's ages past this
was last talked about... but what the more general point remains valid:

--snip--
On Fri, 9 Jul 2004, Daniel Barlow wrote:

> atomic-incf reference [Function]
> atomic-decf reference [Function]
>
> Increments (or decrements) the fixnum value referred to by reference
> as a single, atomic operation.  If the operation would take the value
> out of fixnum range, behaviour is undefined.

I'd propose "unspecified behaviour" instead, the essential difference
being that heap corruption, crashes, etc aren't allowed. Implementations 
would still be allowed to wrap, zero the reference, signal an error, etc.
--snap--

The "general point" being that "unspecified" and "undefined" have a nice 
distinction, and specifying something as unspecified behaviour instead of 
defining as undefined (sorry, couldn't resist) gives a useful promise of
"not destrying the world" to the user.

Whether that promise is something that can be given in this case, I do not 
know.

Cheers,

  -- Nikodemus                   "Not as clumsy or random as a C++ or Java.
                              An elegant weapon for a more civilized time."



More information about the Threads-standard-discuss mailing list