workgroupSizeOf
On this page

workgroupSizeOf()

Function in IR

The x workgroup size of a compute entry: the structured workgroupSize field first, then the @workgroup_size(n) attribute string; undefined when neither is present.

import { workgroupSizeOf } from 'typeshade'

The signature, the description and the examples come from the compiler's own source at commit 26de7be8.

Syntax

const workgroupSizeOf: (
f: Pick<FuncDecl, "workgroupSize" | "attrs">,
) => number | undefined

Parameters

f Pick<FuncDecl, 'workgroupSize' | 'attrs'>

Return value

number | undefined

Description

A two- or three-dimensional workgroup has more invocations than this; read workgroupShapeOf for the grid.

See also

Source

src/core/ir/nodes.ts, line 909, at commit 26de7be8

Edit this page Report a problem