_iprt_atomic.h revision c7814cf6e1240a519cbec0441e033d0e2470ed00
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * IPRT Atomic Operation, for including into a system config header.
c7814cf6e1240a519cbec0441e033d0e2470ed00vboxsync * Copyright (C) 2009-2010 Oracle Corporation
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * This file is part of VirtualBox Open Source Edition (OSE), as
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * available from http://www.virtualbox.org. This file is free software;
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * you can redistribute it and/or modify it under the terms of the GNU
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * General Public License (GPL) as published by the Free Software
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * Foundation, in version 2 as it comes in the "COPYING" file of the
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync/* Note! Do not copy this around, put it in a header of its own if reused anywhere! */
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync#define _MD_INIT_ATOMIC() do {} while (0)
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsyncDECLINLINE(PRInt32) _PR_IPRT_AtomicIncrement(PRInt32 *pVal)
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync#define _MD_ATOMIC_INCREMENT(pVal) _PR_IPRT_AtomicIncrement(pVal)
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsyncDECLINLINE(PRInt32) _PR_IPRT_AtomicDecrement(PRInt32 *pVal)
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync#define _MD_ATOMIC_DECREMENT(pVal) _PR_IPRT_AtomicDecrement(pVal)
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsyncDECLINLINE(PRInt32) _PR_IPRT_AtomicSet(PRInt32 *pVal, PRInt32 NewVal)
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsync#define _MD_ATOMIC_SET(pVal, NewVal) _PR_IPRT_AtomicSet(pVal, NewVal)
49aaec872ad8c04d8b2cd5abb6b1f7f582c4e9b4vboxsyncDECLINLINE(PRInt32) _PR_IPRT_AtomicAdd(PRInt32 *pVal, PRInt32 ToAdd)