Visible to Intel only — GUID: ekn1517935220930
Ixiasoft
Visible to Intel only — GUID: ekn1517935220930
Ixiasoft
3.9. Avoiding Work-Item ID-Dependent Backward Branching
The collapses conditional statements into single bits that indicate when a particular functional unit becomes active. The offline compiler completely eliminates simple control flows that do not involve looping structures, resulting in a flat control structure and more efficient hardware usage. The offline compiler compiles kernels that include forward branches, such as conditional statements, efficiently.
For example, the following code fragment illustrates branching that involves work-item ID such as get_global_id or get_local_id:
for (size_t i = 0; i < get_global_id(0); i++)
{
// statements
}