Skip to content

Commit 54bcb31

Browse files
authored
Roll types 0.1.52 -> 0.1.59 (#4302)
1 parent 4e4a992 commit 54bcb31

File tree

9 files changed

+130
-135
lines changed

9 files changed

+130
-135
lines changed

package-lock.json

+7-7
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"@types/w3c-image-capture": "^1.0.10",
5151
"@typescript-eslint/eslint-plugin": "^6.9.1",
5252
"@typescript-eslint/parser": "^6.9.1",
53-
"@webgpu/types": "^0.1.52",
53+
"@webgpu/types": "^0.1.59",
5454
"ansi-colors": "4.1.3",
5555
"babel-plugin-add-header-comment": "^1.0.3",
5656
"babel-plugin-const-enum": "^1.2.0",

src/common/util/data_tables.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { ResolveType, ZipKeysWithValues } from './types.js';
22

33
export type valueof<K> = K[keyof K];
44

5-
export function keysOf<T extends string>(obj: { [k in T]: unknown }): readonly T[] {
5+
export function keysOf<T extends string>(obj: { [k in T]?: unknown }): readonly T[] {
66
return Object.keys(obj) as unknown[] as T[];
77
}
88

src/resources/cache/hashes.json

+110-110
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/webgpu/api/operation/adapter/info.spec.ts

+1-8
Original file line numberDiff line numberDiff line change
@@ -138,13 +138,6 @@ different orders to make sure that they are consistent regardless of the access
138138
}
139139
});
140140

141-
// This can be removed once 'subgroups' lands.
142-
// See https://github.com/gpuweb/gpuweb/pull/4963
143-
interface SubgroupProperties extends GPUAdapterInfo {
144-
subgroupMinSize?: number;
145-
subgroupMaxSize?: number;
146-
}
147-
148141
const kSubgroupMinSizeBound = 4;
149142
const kSubgroupMaxSizeBound = 128;
150143

@@ -161,7 +154,7 @@ If they exist, they must both exist and be powers of two, and
161154
const gpu = getGPU(t.rec);
162155
const adapter = await gpu.requestAdapter();
163156
assert(adapter !== null);
164-
const { subgroupMinSize, subgroupMaxSize } = adapter.info as SubgroupProperties;
157+
const { subgroupMinSize, subgroupMaxSize } = adapter.info;
165158
// Once 'subgroups' lands, the properties should be defined with default values 4 and 128
166159
// when adapter does not support the feature.
167160
// https://github.com/gpuweb/gpuweb/pull/4963

src/webgpu/capability_info.ts

+2
Original file line numberDiff line numberDiff line change
@@ -905,6 +905,8 @@ export const kFeatureNameInfo: {
905905
'float32-blendable': {},
906906
'clip-distances': {},
907907
'dual-source-blending': {},
908+
'subgroups': {},
909+
'core-features-and-limits': {},
908910
};
909911
/** List of all GPUFeatureName values. */
910912
export const kFeatureNames = keysOf(kFeatureNameInfo);

src/webgpu/idl/idl_test.ts

+5-3
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,11 @@ export class IDLTest extends Fixture {
1919
/**
2020
* Asserts that a member of an IDL interface has the expected value.
2121
*/
22-
assertMember(act: UnknownObject, exp: UnknownObject, key: string) {
22+
assertMember(act: object, exp: object, key: string) {
2323
assert(key in act, () => `Expected key ${key} missing`);
24-
assert(act[key] === exp[key], () => `Value of [${key}] was ${act[key]}, expected ${exp[key]}`);
24+
const actValue = (act as UnknownObject)[key];
25+
const expValue = (exp as UnknownObject)[key];
26+
assert(actValue === expValue, () => `Value of [${key}] was ${actValue}, expected ${expValue}`);
2527
}
2628

2729
/**
@@ -30,7 +32,7 @@ export class IDLTest extends Fixture {
3032
* MAINTENANCE_TODO: add a way to check for the types of keys with unknown values, like methods and attributes
3133
* MAINTENANCE_TODO: handle extensions
3234
*/
33-
assertMemberCount(act: UnknownObject, exp: UnknownObject) {
35+
assertMemberCount(act: object, exp: object) {
3436
const expKeys = Object.keys(exp);
3537
const actKeys = Object.keys(act);
3638
assert(

src/webgpu/shader/execution/expression/call/builtin/texture_utils.ts

+1-4
Original file line numberDiff line numberDiff line change
@@ -2895,12 +2895,9 @@ function getEffectiveViewDimension(
28952895
t: GPUTest,
28962896
descriptor: Omit<GPUTextureDescriptor, 'format' | 'usage'>
28972897
): GPUTextureViewDimension {
2898-
const { textureBindingViewDimension } = descriptor as unknown as {
2899-
textureBindingViewDimension?: GPUTextureViewDimension;
2900-
};
29012898
const size = reifyExtent3D(descriptor.size);
29022899
return effectiveViewDimensionForDimension(
2903-
textureBindingViewDimension,
2900+
descriptor.textureBindingViewDimension,
29042901
descriptor.dimension,
29052902
size.depthOrArrayLayers
29062903
);

src/webgpu/util/texture/base.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,8 @@ export function defaultViewDimensionsForTexture(textureDescriptor: Readonly<GPUT
207207
*/
208208
export function reifyTextureDescriptor(
209209
desc: Readonly<GPUTextureDescriptor>
210-
): Required<Omit<GPUTextureDescriptor, 'label' | 'viewFormats'>> {
210+
): GPUTextureDescriptor &
211+
Required<Omit<GPUTextureDescriptor, 'label' | 'viewFormats' | 'textureBindingViewDimension'>> {
211212
return { dimension: '2d' as const, mipLevelCount: 1, sampleCount: 1, ...desc };
212213
}
213214

0 commit comments

Comments
 (0)