MCPcopy Create free account
hub / github.com/cameron314/concurrentqueue / MoveThreadIntoProcessorGroup

Function MoveThreadIntoProcessorGroup

benchmarks/tbb/tbb_misc_ex.cpp:353–359  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

351}
352
353void MoveThreadIntoProcessorGroup( void* hThread, int groupIndex ) {
354 __TBB_ASSERT( hardware_concurrency_info == initialization_complete, "MoveThreadIntoProcessorGroup is used before AvailableHwConcurrency" );
355 if ( !TBB_SetThreadGroupAffinity )
356 return;
357 TBB_GROUP_AFFINITY ga = { theProcessorGroups[groupIndex].mask, (WORD)groupIndex, {0,0,0} };
358 TBB_SetThreadGroupAffinity( hThread, &ga, NULL );
359}
360
361#else
362 #error AvailableHwConcurrency is not implemented in this OS

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected