Shadowrun: Awakened 29 September 2011 - Build 871
Defines | Functions
linux_intel64.h File Reference
#include "linux_common.h"
Include dependency graph for Third Party Tech/TBB/tbb30_20100406oss_win/tbb30_20100406oss/include/tbb/machine/linux_intel64.h:

Go to the source code of this file.

Defines

#define __MACHINE_DECL_ATOMICS(S, T, X)
#define __TBB_AtomicAND(P, V)   __TBB_machine_and(P,V)
#define __TBB_AtomicOR(P, V)   __TBB_machine_or(P,V)
#define __TBB_BIG_ENDIAN   0
#define __TBB_CompareAndSwap1(P, V, C)   __TBB_machine_cmpswp1(P,V,C)
#define __TBB_CompareAndSwap2(P, V, C)   __TBB_machine_cmpswp2(P,V,C)
#define __TBB_CompareAndSwap4(P, V, C)   __TBB_machine_cmpswp4(P,V,C)
#define __TBB_CompareAndSwap8(P, V, C)   __TBB_machine_cmpswp8(P,V,C)
#define __TBB_CompareAndSwapW(P, V, C)   __TBB_machine_cmpswp8(P,V,C)
#define __TBB_FetchAndAdd1(P, V)   __TBB_machine_fetchadd1(P,V)
#define __TBB_FetchAndAdd2(P, V)   __TBB_machine_fetchadd2(P,V)
#define __TBB_FetchAndAdd4(P, V)   __TBB_machine_fetchadd4(P,V)
#define __TBB_FetchAndAdd8(P, V)   __TBB_machine_fetchadd8(P,V)
#define __TBB_FetchAndAddW(P, V)   __TBB_machine_fetchadd8(P,V)
#define __TBB_FetchAndAddWrelease(P, V)   __TBB_FetchAndAddW(P,V)
#define __TBB_FetchAndDecrementWrelease(P)   __TBB_FetchAndAddW(P,-1)
#define __TBB_FetchAndIncrementWacquire(P)   __TBB_FetchAndAddW(P,1)
#define __TBB_FetchAndStore1(P, V)   __TBB_machine_fetchstore1(P,V)
#define __TBB_FetchAndStore2(P, V)   __TBB_machine_fetchstore2(P,V)
#define __TBB_FetchAndStore4(P, V)   __TBB_machine_fetchstore4(P,V)
#define __TBB_FetchAndStore8(P, V)   __TBB_machine_fetchstore8(P,V)
#define __TBB_FetchAndStoreW(P, V)   __TBB_machine_fetchstore8(P,V)
#define __TBB_Load8(P)   (*P)
#define __TBB_Log2(V)   __TBB_machine_lg(V)
#define __TBB_Pause(V)   __TBB_machine_pause(V)
#define __TBB_release_consistency_helper()   __asm__ __volatile__("": : :"memory")
#define __TBB_Store8(P, V)   (*P = V)
#define __TBB_WORDSIZE   8

Functions

static void __TBB_machine_and (volatile void *ptr, uint64_t addend)
static int8_t __TBB_machine_cmpswp1 (volatile void *ptr, int8_t value, int8_t comparand)
static int16_t __TBB_machine_cmpswp2 (volatile void *ptr, int16_t value, int16_t comparand)
static int32_t __TBB_machine_cmpswp4 (volatile void *ptr, int32_t value, int32_t comparand)
static int64_t __TBB_machine_cmpswp8 (volatile void *ptr, int64_t value, int64_t comparand)
static int8_t __TBB_machine_fetchadd1 (volatile void *ptr, int8_t addend)
static int16_t __TBB_machine_fetchadd2 (volatile void *ptr, int16_t addend)
static int32_t __TBB_machine_fetchadd4 (volatile void *ptr, int32_t addend)
static int64_t __TBB_machine_fetchadd8 (volatile void *ptr, int64_t addend)
static int8_t __TBB_machine_fetchstore1 (volatile void *ptr, int8_t value)
static int16_t __TBB_machine_fetchstore2 (volatile void *ptr, int16_t value)
static int32_t __TBB_machine_fetchstore4 (volatile void *ptr, int32_t value)
static int64_t __TBB_machine_fetchstore8 (volatile void *ptr, int64_t value)
static int64_t __TBB_machine_lg (uint64_t x)
static void __TBB_machine_or (volatile void *ptr, uint64_t addend)
static void __TBB_machine_pause (int32_t delay)
void __TBB_rel_acq_fence ()

Define Documentation

#define __MACHINE_DECL_ATOMICS (   S,
  T,
 
)
Value:
static inline T __TBB_machine_cmpswp##S (volatile void *ptr, T value, T comparand )  \
{                                                                                    \
    T result;                                                                        \
                                                                                     \
    __asm__ __volatile__("lock\ncmpxchg" X " %2,%1"                                  \
                          : "=a"(result), "=m"(*(volatile T*)ptr)                    \
                          : "q"(value), "0"(comparand), "m"(*(volatile T*)ptr)       \
                          : "memory");                                               \
    return result;                                                                   \
}                                                                                    \
                                                                                     \
static inline T __TBB_machine_fetchadd##S(volatile void *ptr, T addend)              \
{                                                                                    \
    T result;                                                                        \
    __asm__ __volatile__("lock\nxadd" X " %0,%1"                                     \
                          : "=r"(result),"=m"(*(volatile T*)ptr)                     \
                          : "0"(addend), "m"(*(volatile T*)ptr)                      \
                          : "memory");                                               \
    return result;                                                                   \
}                                                                                    \
                                                                                     \
static inline  T __TBB_machine_fetchstore##S(volatile void *ptr, T value)            \
{                                                                                    \
    T result;                                                                        \
    __asm__ __volatile__("lock\nxchg" X " %0,%1"                                     \
                          : "=r"(result),"=m"(*(volatile T*)ptr)                     \
                          : "0"(value), "m"(*(volatile T*)ptr)                       \
                          : "memory");                                               \
    return result;                                                                   \
}                                                                                    \

Definition at line 44 of file Third Party Tech/TBB/tbb30_20100406oss_win/tbb30_20100406oss/include/tbb/machine/linux_intel64.h.

#define __TBB_AtomicAND (   P,
  V 
)    __TBB_machine_and(P,V)
#define __TBB_AtomicOR (   P,
  V 
)    __TBB_machine_or(P,V)
#define __TBB_BIG_ENDIAN   0
#define __TBB_CompareAndSwap1 (   P,
  V,
 
)    __TBB_machine_cmpswp1(P,V,C)
#define __TBB_CompareAndSwap2 (   P,
  V,
 
)    __TBB_machine_cmpswp2(P,V,C)
#define __TBB_CompareAndSwap4 (   P,
  V,
 
)    __TBB_machine_cmpswp4(P,V,C)
#define __TBB_CompareAndSwap8 (   P,
  V,
 
)    __TBB_machine_cmpswp8(P,V,C)
#define __TBB_CompareAndSwapW (   P,
  V,
 
)    __TBB_machine_cmpswp8(P,V,C)
#define __TBB_FetchAndAdd1 (   P,
  V 
)    __TBB_machine_fetchadd1(P,V)
#define __TBB_FetchAndAdd2 (   P,
  V 
)    __TBB_machine_fetchadd2(P,V)
#define __TBB_FetchAndAdd4 (   P,
  V 
)    __TBB_machine_fetchadd4(P,V)
#define __TBB_FetchAndAdd8 (   P,
  V 
)    __TBB_machine_fetchadd8(P,V)
#define __TBB_FetchAndAddW (   P,
  V 
)    __TBB_machine_fetchadd8(P,V)
#define __TBB_FetchAndAddWrelease (   P,
  V 
)    __TBB_FetchAndAddW(P,V)
#define __TBB_FetchAndDecrementWrelease (   P)    __TBB_FetchAndAddW(P,-1)
#define __TBB_FetchAndIncrementWacquire (   P)    __TBB_FetchAndAddW(P,1)
#define __TBB_FetchAndStore1 (   P,
  V 
)    __TBB_machine_fetchstore1(P,V)
#define __TBB_FetchAndStore2 (   P,
  V 
)    __TBB_machine_fetchstore2(P,V)
#define __TBB_FetchAndStore4 (   P,
  V 
)    __TBB_machine_fetchstore4(P,V)
#define __TBB_FetchAndStore8 (   P,
  V 
)    __TBB_machine_fetchstore8(P,V)
#define __TBB_FetchAndStoreW (   P,
  V 
)    __TBB_machine_fetchstore8(P,V)
#define __TBB_Load8 (   P)    (*P)
#define __TBB_Log2 (   V)    __TBB_machine_lg(V)
#define __TBB_Pause (   V)    __TBB_machine_pause(V)
#define __TBB_release_consistency_helper ( )    __asm__ __volatile__("": : :"memory")
#define __TBB_Store8 (   P,
  V 
)    (*P = V)
#define __TBB_WORDSIZE   8

Function Documentation

static void __TBB_machine_and ( volatile void *  ptr,
uint64_t  addend 
) [inline, static]

Definition at line 91 of file Third Party Tech/TBB/tbb30_20100406oss_win/tbb30_20100406oss/include/tbb/machine/linux_intel64.h.

                                                                            {
    __asm__ __volatile__("lock\nandq %1,%0" : "=m"(*(volatile uint64_t*)ptr) : "r"(addend), "m"(*(volatile uint64_t*)ptr) : "memory");
}
static int8_t __TBB_machine_cmpswp1 ( volatile void *  ptr,
int8_t  value,
int8_t  comparand 
) [inline, static]
static int16_t __TBB_machine_cmpswp2 ( volatile void *  ptr,
int16_t  value,
int16_t  comparand 
) [inline, static]
static int32_t __TBB_machine_cmpswp4 ( volatile void *  ptr,
int32_t  value,
int32_t  comparand 
) [inline, static]
static int64_t __TBB_machine_cmpswp8 ( volatile void *  ptr,
int64_t  value,
int64_t  comparand 
) [inline, static]
static int8_t __TBB_machine_fetchadd1 ( volatile void *  ptr,
int8_t  addend 
) [inline, static]
static int16_t __TBB_machine_fetchadd2 ( volatile void *  ptr,
int16_t  addend 
) [inline, static]
static int32_t __TBB_machine_fetchadd4 ( volatile void *  ptr,
int32_t  addend 
) [inline, static]
static int64_t __TBB_machine_fetchadd8 ( volatile void *  ptr,
int64_t  addend 
) [inline, static]
static int8_t __TBB_machine_fetchstore1 ( volatile void *  ptr,
int8_t  value 
) [inline, static]
static int16_t __TBB_machine_fetchstore2 ( volatile void *  ptr,
int16_t  value 
) [inline, static]
static int32_t __TBB_machine_fetchstore4 ( volatile void *  ptr,
int32_t  value 
) [inline, static]
static int64_t __TBB_machine_fetchstore8 ( volatile void *  ptr,
int64_t  value 
) [inline, static]
static int64_t __TBB_machine_lg ( uint64_t  x) [inline, static]

Definition at line 81 of file Third Party Tech/TBB/tbb30_20100406oss_win/tbb30_20100406oss/include/tbb/machine/linux_intel64.h.

                                                     {
    int64_t j;
    __asm__ ("bsr %1,%0" : "=r"(j) : "r"(x));
    return j;
}
static void __TBB_machine_or ( volatile void *  ptr,
uint64_t  addend 
) [inline, static]

Definition at line 87 of file Third Party Tech/TBB/tbb30_20100406oss_win/tbb30_20100406oss/include/tbb/machine/linux_intel64.h.

                                                                           {
    __asm__ __volatile__("lock\norq %1,%0" : "=m"(*(volatile uint64_t*)ptr) : "r"(addend), "m"(*(volatile uint64_t*)ptr) : "memory");
}
static void __TBB_machine_pause ( int32_t  delay) [inline, static]

Definition at line 95 of file Third Party Tech/TBB/tbb30_20100406oss_win/tbb30_20100406oss/include/tbb/machine/linux_intel64.h.

                                                        {
    for (int32_t i = 0; i < delay; i++) {
       __asm__ __volatile__("pause;");
    }
    return;
}
void __TBB_rel_acq_fence ( ) [inline]

Definition at line 41 of file Third Party Tech/TBB/tbb30_20100406oss_win/tbb30_20100406oss/include/tbb/machine/linux_intel64.h.

{ __asm__ __volatile__("mfence": : :"memory"); }

Copyright © 2007-2010 by The Shadowrun: Awakened Team. This work is licensed under the GNU Lesser General Public License 3.

GNU Lesser General Public License 3 Sourceforge.net