Intel® C++ Compiler 19.0 Developer Guide and Reference
Intel® Cilk™ Plus is a deprecated feature. Use OpenMP* or Intel® Threading Building Blocks instead. For more information see Migrate Your Application to use OpenMP* or Intel® TBB Instead of Intel® Cilk™ Plus.
int __cilkrts_get_nworkers(void);
This function returns the number of worker threads assigned to handle Intel® Cilk™ Plus tasks. If called in serialized code, it will return 1.
The range of valid worker IDs is 0 to __cilkrts_get_nworkers()-1.