DeviceInfo
Interface in Runtime
Frozen, JSON-serializable historical metadata of an opened device.
import type { DeviceInfo } from 'typeshade'import type { DeviceInfo } from 'typeshade/runtime'
The signature, the description and the examples come from the compiler's own source at commit af54ddad5.
Syntax
interface DeviceInfo { readonly build: TypeShadeBuildInfo; readonly tier: Tier; readonly webgpu: { readonly provenance: 'device' | 'adapter' | 'unavailable'; readonly vendor: string | null; readonly architecture: string | null; readonly device: string | null; readonly description: string | null; readonly fallback: boolean | null; readonly features: readonly string[]; readonly limits: Readonly<Record<string, number>>; } | null; readonly webgl: { readonly vendor: string | null; readonly renderer: string | null; readonly unmaskedVendor: string | null; readonly unmaskedRenderer: string | null; } | null; readonly subgroups: { readonly minSize: number | null; readonly maxSize: number | null; readonly size: number; readonly numSubgroups: number; readonly consecutive: boolean; } | null;}Description
Frozen, JSON-serializable historical metadata of an opened device. It remains readable after
loss or disposal and does not identify the effective tier of an individual call.
Exported from typeshade and typeshade/runtime (change 0083).
Instance properties
buildread onlyTypeShadeBuildInfotierread onlyTierwebgpuread only{ readonly provenance: 'device' | 'adapter' | 'unavailable'; readonly vendor: string | null; readonly architecture: string | null; readonly device: string | null; readonly description: string | null; readonly fallback: boolean | null; readonly features: readonly string[]; readonly limits: Readonly<Record<string, number>>; } | nullIdentity from the actual WebGPU device or its retained creation adapter. Features and limits describe the enabled device, never the adapter’s supported maxima.
nullon other tiers.webglread only{ readonly vendor: string | null; readonly renderer: string | null; readonly unmaskedVendor: string | null; readonly unmaskedRenderer: string | null; } | nullStrings from the actual WebGL2 context. Debug strings remain null when unavailable or redacted. This section never attributes a WebGL probe to a WebGPU device.
subgroupsread only{ readonly minSize: number | null; readonly maxSize: number | null; readonly size: number; readonly numSubgroups: number; readonly consecutive: boolean; } | nullWhat the subgroup probe saw when the device opened (change 0119): the adapter’s size range, the
subgroup_sizeandnum_subgroupsone workgroup of 256 lanes had, and whether a subgroup’s lanes were consecutive.nullon a tier without WebGPU, on a device without thesubgroupsfeature, wherecreateDevice({ subgroups: 'off' })kept the probe off, or where the probe failed; a kernel call of the device then runs the tree text.
Source
src/core/device-info.ts, line 11, at commit af54ddad5