Home ⌂Doc Index ◂Up ▴
Intel(R) Threading Building Blocks Doxygen Documentation  version 4.2.3
msvc_ia32_common.h File Reference
#include <intrin.h>
Include dependency graph for msvc_ia32_common.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  tbb::internal::cpu_ctl_env
 

Namespaces

 tbb
 The graph class.
 
 tbb::internal
 Identifiers declared inside namespace internal should never be used directly by client code.
 
 tbb::internal::msvc_intrinsics
 
 tbb::internal::msvc_inline_asm
 

Macros

#define __TBB_X86_MSVC_INLINE_ASM_AVAILABLE   1
 
#define __TBB_r(reg_name)   e##reg_name
 
#define __TBB_W(name)   name
 
#define __TBB_compiler_fence()   __asm { __asm nop }
 
#define __TBB_full_memory_fence()   __asm { __asm mfence }
 
#define __TBB_control_consistency_helper()   __TBB_compiler_fence()
 
#define __TBB_acquire_consistency_helper()   __TBB_compiler_fence()
 
#define __TBB_release_consistency_helper()   __TBB_compiler_fence()
 
#define __TBB_Pause(V)   tbb::internal::msvc_inline_asm::pause(V)
 
#define __TBB_SINGLE_PAUSE   __asm pause
 
#define __TBB_Log2(V)   tbb::internal::msvc_inline_asm::lg_bsr(V)
 
#define __TBB_AtomicOR(P, V)   tbb::internal::msvc_inline_asm::lock_or(P,V)
 
#define __TBB_AtomicAND(P, V)   tbb::internal::msvc_inline_asm::lock_and(P,V)
 
#define __TBB_time_stamp()   __TBB_machine_time_stamp()
 
#define __TBB_CPU_CTL_ENV_PRESENT   1
 
#define __TBB_Yield()   SwitchToThread()
 

Typedefs

typedef long tbb::internal::msvc_intrinsics::word
 

Functions

namespace msvc_inline_asm static inline void tbb::internal::pause (uintptr_t delay)
 
static uintptr_t tbb::internal::msvc_inline_asm::lg_bsr (uintptr_t i)
 
static void tbb::internal::msvc_inline_asm::lock_or (volatile void *operand, __int32 addend)
 
static void tbb::internal::msvc_inline_asm::lock_and (volatile void *operand, __int32 addend)
 
static tbb::internal::machine_tsc_t __TBB_machine_time_stamp ()
 
void __TBB_get_cpu_ctl_env (tbb::internal::cpu_ctl_env *ctl)
 
void __TBB_set_cpu_ctl_env (const tbb::internal::cpu_ctl_env *ctl)
 
 __declspec (dllimport) int __stdcall SwitchToThread(void)
 
__int8 __TBB_EXPORTED_FUNC __TBB_machine_try_lock_elided (volatile void *ptr)
 
void __TBB_EXPORTED_FUNC __TBB_machine_unlock_elided (volatile void *ptr)
 
static void __TBB_machine_try_lock_elided_cancel ()
 
__int8 __TBB_EXPORTED_FUNC __TBB_machine_is_in_transaction ()
 
unsigned __int32 __TBB_EXPORTED_FUNC __TBB_machine_begin_transaction ()
 
void __TBB_EXPORTED_FUNC __TBB_machine_end_transaction ()
 
void __TBB_EXPORTED_FUNC __TBB_machine_transaction_conflict_abort ()
 

Macro Definition Documentation

◆ __TBB_acquire_consistency_helper

#define __TBB_acquire_consistency_helper ( )    __TBB_compiler_fence()

Definition at line 89 of file msvc_ia32_common.h.

◆ __TBB_AtomicAND

#define __TBB_AtomicAND (   P,
 
)    tbb::internal::msvc_inline_asm::lock_and(P,V)

Definition at line 189 of file msvc_ia32_common.h.

◆ __TBB_AtomicOR

#define __TBB_AtomicOR (   P,
 
)    tbb::internal::msvc_inline_asm::lock_or(P,V)

Definition at line 188 of file msvc_ia32_common.h.

◆ __TBB_compiler_fence

#define __TBB_compiler_fence ( )    __asm { __asm nop }

Definition at line 82 of file msvc_ia32_common.h.

◆ __TBB_control_consistency_helper

#define __TBB_control_consistency_helper ( )    __TBB_compiler_fence()

Definition at line 88 of file msvc_ia32_common.h.

◆ __TBB_CPU_CTL_ENV_PRESENT

#define __TBB_CPU_CTL_ENV_PRESENT   1

Definition at line 200 of file msvc_ia32_common.h.

◆ __TBB_full_memory_fence

#define __TBB_full_memory_fence ( )    __asm { __asm mfence }

Definition at line 83 of file msvc_ia32_common.h.

◆ __TBB_Log2

#define __TBB_Log2 (   V)    tbb::internal::msvc_inline_asm::lg_bsr(V)

Definition at line 150 of file msvc_ia32_common.h.

◆ __TBB_Pause

#define __TBB_Pause (   V)    tbb::internal::msvc_inline_asm::pause(V)

Definition at line 119 of file msvc_ia32_common.h.

◆ __TBB_r

#define __TBB_r (   reg_name)    e##reg_name

Definition at line 41 of file msvc_ia32_common.h.

◆ __TBB_release_consistency_helper

#define __TBB_release_consistency_helper ( )    __TBB_compiler_fence()

Definition at line 90 of file msvc_ia32_common.h.

◆ __TBB_SINGLE_PAUSE

#define __TBB_SINGLE_PAUSE   __asm pause

Definition at line 120 of file msvc_ia32_common.h.

◆ __TBB_time_stamp

#define __TBB_time_stamp ( )    __TBB_machine_time_stamp()

Definition at line 197 of file msvc_ia32_common.h.

◆ __TBB_W

#define __TBB_W (   name)    name

Definition at line 42 of file msvc_ia32_common.h.

◆ __TBB_X86_MSVC_INLINE_ASM_AVAILABLE

#define __TBB_X86_MSVC_INLINE_ASM_AVAILABLE   1

Definition at line 27 of file msvc_ia32_common.h.

◆ __TBB_Yield

#define __TBB_Yield ( )    SwitchToThread()

Definition at line 245 of file msvc_ia32_common.h.

Function Documentation

◆ __declspec()

__declspec ( dllimport  )

◆ __TBB_get_cpu_ctl_env()

void __TBB_get_cpu_ctl_env ( tbb::internal::cpu_ctl_env ctl)
inline

Definition at line 204 of file msvc_ia32_common.h.

204  {
205  __asm {
206  __asm mov __TBB_r(ax), ctl
207  __asm stmxcsr [__TBB_r(ax)]
208  __asm fstcw [__TBB_r(ax)+4]
209  }
210  }
#define __TBB_r(reg_name)

References __TBB_r.

Referenced by tbb::internal::cpu_ctl_env::get_env().

Here is the caller graph for this function:

◆ __TBB_machine_begin_transaction()

unsigned __int32 __TBB_EXPORTED_FUNC __TBB_machine_begin_transaction ( )

◆ __TBB_machine_end_transaction()

void __TBB_EXPORTED_FUNC __TBB_machine_end_transaction ( )

◆ __TBB_machine_is_in_transaction()

__int8 __TBB_EXPORTED_FUNC __TBB_machine_is_in_transaction ( )

◆ __TBB_machine_time_stamp()

static tbb::internal::machine_tsc_t __TBB_machine_time_stamp ( )
inlinestatic

Definition at line 194 of file msvc_ia32_common.h.

194  {
195  return __rdtsc();
196 }

◆ __TBB_machine_transaction_conflict_abort()

void __TBB_EXPORTED_FUNC __TBB_machine_transaction_conflict_abort ( )

◆ __TBB_machine_try_lock_elided()

__int8 __TBB_EXPORTED_FUNC __TBB_machine_try_lock_elided ( volatile void ptr)

◆ __TBB_machine_try_lock_elided_cancel()

static void __TBB_machine_try_lock_elided_cancel ( )
inlinestatic

Definition at line 260 of file msvc_ia32_common.h.

#define __TBB_SINGLE_PAUSE

References __TBB_SINGLE_PAUSE.

◆ __TBB_machine_unlock_elided()

void __TBB_EXPORTED_FUNC __TBB_machine_unlock_elided ( volatile void ptr)

◆ __TBB_set_cpu_ctl_env()

void __TBB_set_cpu_ctl_env ( const tbb::internal::cpu_ctl_env ctl)
inline

Definition at line 211 of file msvc_ia32_common.h.

211  {
212  __asm {
213  __asm mov __TBB_r(ax), ctl
214  __asm ldmxcsr [__TBB_r(ax)]
215  __asm fldcw [__TBB_r(ax)+4]
216  }
217  }
#define __TBB_r(reg_name)

References __TBB_r.

Referenced by tbb::internal::cpu_ctl_env::set_env().

Here is the caller graph for this function:

Copyright © 2005-2020 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.