The ATOMIC_INT structure stores an integer value
that can be atomically accessed from multiple engines.
Within a processor family,
the precision of the value stored
in the ATOMIC_INT is at least as great
as the data type int.
An ATOMIC_INT structure,
can be used by a driver to keep a consistent counter value
across multiple engines without the need to acquire locks.
Specifically, for any single ATOMIC_INT object,
the following operations on that object are serialized:
This means that the results of a set of these operations on multiple
engines will appear as though they had occurred in some specific order on a
The ATOMIC_INT objects must be allocated by the
function and initialized by the
function before they are used.
They may be freed with the
The atomicity properties of ATOMIC_INT objects
(as defined in the section above)
are strictly limited to a single object.
Drivers should be careful not to assume
any ordering of operations between two instances
of ATOMIC_INT objects,
or between these objects and objects
whose access patterns are serialized by means of locks,
unless such ordering is explicitly set up in the driver
through use of locks.
In particular, drivers should not assume that arbitrary writes
will be observed in any particular order by another engine.
The ATOMIC_INT structure contains no driver accessible fields.
6, 6mp, 7, 7mp, 7.1, 7.1mp, 8, 8mp
Difference between versions
19 June 2005
© 2005 The SCO Group, Inc. All rights reserved.
OpenServer 6 and UnixWare (SVR5) HDK - June 2005