sdk/linux_kernel_drivers/xocl/xocl_exec.c
/**
 * cu_idx_to_bitmask() - Compute the cu bitmask for cu_idx
 *
 * Subtract 32 * lower bitmasks prior to bitmask repsenting
 * this index.  For example, f.x cu_idx=67
 *  1 << (67 - (67>>5)<<5) = 
 *  1 << (67 - (2<<5)) = 
 *  1 << (67 - 64) =
 *  1 << 3 =
 *  0b1000 for position 4 in third bitmask
 *
 * @xdev: Device handle
 * @cu_idx: Global index [0..127] of CU
 *
 * This function computes the bitmask for cu_idx in the mask that stores cu_idx
 *
 * Return: Bitmask with bit set for corresponding CU
 */
Compute the cu bitmask for cu_idx
Subtract 32 * lower bitmasks prior to bitmask repsenting
this index.

@xdev: Device handle
@cu_idx: Global index [0..127] of CU

This function computes the bitmask for cu_idx in the mask that stores cu_idx

Bitmask with bit set for corresponding CU
Compute the cu bitmask for cu_idx Subtract 32 * lower bitmasks prior to bitmask repsenting this index . @xdev : Device handle @cu_idx : Global index [ 0 .. 127 ] of CU This function computes the bitmask for cu_idx in the mask that stores cu_idx Bitmask with bit set for corresponding CU
inline u32
cu_idx_to_bitmask(struct drm_xocl_dev *xdev, u32 cu_idx)
{
	return 1 << (cu_idx - (cu_mask_idx(cu_idx)<<5));
}
inline u32 cu_idx_to_bitmask ( struct drm_xocl_dev * xdev , u32 cu_idx ) { return 1 << ( cu_idx - ( cu_mask_idx ( cu_idx ) << 5 ) ) ; }
cu_idx_to_bitmask() - Compute the cu bitmask for cu_idx
 Subtract 32 * lower bitmasks prior to bitmask repsenting
 this index.
cu_idx_to_bitmask () - Compute the cu bitmask for cu_idx Subtract 32 * lower bitmasks prior to bitmask repsenting this index .