qatomic_sh.h File Reference

Go to the source code of this file.

Defines

#define  Q_ATOMIC_INT_REFERENCE_COUNTING_IS_NOT_NATIVE
#define  Q_ATOMIC_INT_TEST_AND_SET_IS_NOT_NATIVE
#define  Q_ATOMIC_INT_FETCH_AND_STORE_IS_NOT_NATIVE
#define  Q_ATOMIC_INT_FETCH_AND_ADD_IS_NOT_NATIVE
#define  Q_ATOMIC_POINTER_TEST_AND_SET_IS_NOT_NATIVE
#define  Q_ATOMIC_POINTER_FETCH_AND_STORE_IS_NOT_NATIVE
#define  Q_ATOMIC_POINTER_FETCH_AND_ADD_IS_NOT_NATIVE

Functions

Q_CORE_EXPORT void  qt_atomic_yield (int *count)
int  qt_atomic_tasb (volatile char *ptr)

Variables

Q_CORE_EXPORT volatile char  qt_atomic_lock

Define Documentation

#define Q_ATOMIC_INT_REFERENCE_COUNTING_IS_NOT_NATIVE

Definition at line 49 of file qatomic_sh.h.

#define Q_ATOMIC_INT_TEST_AND_SET_IS_NOT_NATIVE

Definition at line 56 of file qatomic_sh.h.

#define Q_ATOMIC_INT_FETCH_AND_STORE_IS_NOT_NATIVE

Definition at line 63 of file qatomic_sh.h.

#define Q_ATOMIC_INT_FETCH_AND_ADD_IS_NOT_NATIVE

Definition at line 70 of file qatomic_sh.h.

#define Q_ATOMIC_POINTER_TEST_AND_SET_IS_NOT_NATIVE

Definition at line 77 of file qatomic_sh.h.

#define Q_ATOMIC_POINTER_FETCH_AND_STORE_IS_NOT_NATIVE

Definition at line 86 of file qatomic_sh.h.

#define Q_ATOMIC_POINTER_FETCH_AND_ADD_IS_NOT_NATIVE

Definition at line 95 of file qatomic_sh.h.


Function Documentation

Q_CORE_EXPORT void qt_atomic_yield ( int *  count )
int qt_atomic_tasb ( volatile char *  ptr ) [inline]

Definition at line 107 of file qatomic_sh.h.

{
    register int ret;
    asm volatile("tas.b @%2\n"
                 "movt  %0"
                 : "=&r"(ret), "=m"(*ptr)
                 : "r"(ptr)
                 : "cc", "memory");
    return ret;
}

Variable Documentation

Q_CORE_EXPORT volatile char qt_atomic_lock