Skip to content

Commit 412fd75

Browse files
authored
WebGPU: update to dawn@acd91e (#19659)
* WebGPU: update to dawn@acd91e * gen_struct_info * device lost callback fix * fix deprecated, chain struct * rebaseline * add new functions and gen_sig_info * fix wgpuBufferGetMapState bufferId param
1 parent 9f9abed commit 412fd75

File tree

10 files changed

+1043
-779
lines changed

10 files changed

+1043
-779
lines changed

src/generated_struct_info32.json

Lines changed: 41 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -782,10 +782,11 @@
782782
"patch": 2
783783
},
784784
"WGPUAdapterProperties": {
785-
"__size__": 36,
785+
"__size__": 40,
786786
"adapterType": 28,
787787
"architecture": 12,
788788
"backendType": 32,
789+
"compatibilityMode": 36,
789790
"deviceID": 16,
790791
"driverDescription": 24,
791792
"name": 20,
@@ -890,14 +891,17 @@
890891
"nextInChain": 0
891892
},
892893
"WGPUCompilationMessage": {
893-
"__size__": 48,
894+
"__size__": 72,
894895
"length": 40,
895896
"lineNum": 16,
896897
"linePos": 24,
897898
"message": 4,
898899
"nextInChain": 0,
899900
"offset": 32,
900-
"type": 8
901+
"type": 8,
902+
"utf16Length": 64,
903+
"utf16LinePos": 48,
904+
"utf16Offset": 56
901905
},
902906
"WGPUComputePassDescriptor": {
903907
"__size__": 16,
@@ -940,8 +944,10 @@
940944
"stencilWriteMask": 52
941945
},
942946
"WGPUDeviceDescriptor": {
943-
"__size__": 28,
947+
"__size__": 36,
944948
"defaultQueue": 20,
949+
"deviceLostCallback": 28,
950+
"deviceLostUserdata": 32,
945951
"label": 4,
946952
"nextInChain": 0,
947953
"requiredFeatures": 12,
@@ -983,35 +989,38 @@
983989
"nextInChain": 0
984990
},
985991
"WGPULimits": {
986-
"__size__": 120,
992+
"__size__": 144,
987993
"maxBindGroups": 16,
988-
"maxColorAttachments": 92,
989-
"maxComputeInvocationsPerWorkgroup": 100,
990-
"maxComputeWorkgroupSizeX": 104,
991-
"maxComputeWorkgroupSizeY": 108,
992-
"maxComputeWorkgroupSizeZ": 112,
993-
"maxComputeWorkgroupStorageSize": 96,
994-
"maxComputeWorkgroupsPerDimension": 116,
995-
"maxDynamicStorageBuffersPerPipelineLayout": 24,
996-
"maxDynamicUniformBuffersPerPipelineLayout": 20,
997-
"maxInterStageShaderComponents": 84,
998-
"maxInterStageShaderVariables": 88,
999-
"maxSampledTexturesPerShaderStage": 28,
1000-
"maxSamplersPerShaderStage": 32,
1001-
"maxStorageBufferBindingSize": 56,
1002-
"maxStorageBuffersPerShaderStage": 36,
1003-
"maxStorageTexturesPerShaderStage": 40,
994+
"maxBindingsPerBindGroup": 20,
995+
"maxBufferSize": 88,
996+
"maxColorAttachmentBytesPerSample": 116,
997+
"maxColorAttachments": 112,
998+
"maxComputeInvocationsPerWorkgroup": 124,
999+
"maxComputeWorkgroupSizeX": 128,
1000+
"maxComputeWorkgroupSizeY": 132,
1001+
"maxComputeWorkgroupSizeZ": 136,
1002+
"maxComputeWorkgroupStorageSize": 120,
1003+
"maxComputeWorkgroupsPerDimension": 140,
1004+
"maxDynamicStorageBuffersPerPipelineLayout": 28,
1005+
"maxDynamicUniformBuffersPerPipelineLayout": 24,
1006+
"maxInterStageShaderComponents": 104,
1007+
"maxInterStageShaderVariables": 108,
1008+
"maxSampledTexturesPerShaderStage": 32,
1009+
"maxSamplersPerShaderStage": 36,
1010+
"maxStorageBufferBindingSize": 64,
1011+
"maxStorageBuffersPerShaderStage": 40,
1012+
"maxStorageTexturesPerShaderStage": 44,
10041013
"maxTextureArrayLayers": 12,
10051014
"maxTextureDimension1D": 0,
10061015
"maxTextureDimension2D": 4,
10071016
"maxTextureDimension3D": 8,
1008-
"maxUniformBufferBindingSize": 48,
1009-
"maxUniformBuffersPerShaderStage": 44,
1010-
"maxVertexAttributes": 76,
1011-
"maxVertexBufferArrayStride": 80,
1012-
"maxVertexBuffers": 72,
1013-
"minStorageBufferOffsetAlignment": 68,
1014-
"minUniformBufferOffsetAlignment": 64
1017+
"maxUniformBufferBindingSize": 56,
1018+
"maxUniformBuffersPerShaderStage": 48,
1019+
"maxVertexAttributes": 96,
1020+
"maxVertexBufferArrayStride": 100,
1021+
"maxVertexBuffers": 80,
1022+
"minStorageBufferOffsetAlignment": 76,
1023+
"minUniformBufferOffsetAlignment": 72
10151024
},
10161025
"WGPUMultisampleState": {
10171026
"__size__": 16,
@@ -1139,13 +1148,14 @@
11391148
},
11401149
"WGPURequestAdapterOptions": {
11411150
"__size__": 16,
1151+
"compatibilityMode": 13,
11421152
"compatibleSurface": 4,
11431153
"forceFallbackAdapter": 12,
11441154
"nextInChain": 0,
11451155
"powerPreference": 8
11461156
},
11471157
"WGPURequiredLimits": {
1148-
"__size__": 128,
1158+
"__size__": 152,
11491159
"limits": 8,
11501160
"nextInChain": 0
11511161
},
@@ -1183,7 +1193,7 @@
11831193
"WGPUShaderModuleWGSLDescriptor": {
11841194
"__size__": 12,
11851195
"chain": 0,
1186-
"source": 8
1196+
"code": 8
11871197
},
11881198
"WGPUStencilFaceState": {
11891199
"__size__": 16,
@@ -1200,7 +1210,7 @@
12001210
"viewDimension": 12
12011211
},
12021212
"WGPUSupportedLimits": {
1203-
"__size__": 128,
1213+
"__size__": 152,
12041214
"limits": 8,
12051215
"nextInChain": 0
12061216
},

src/generated_struct_info64.json

Lines changed: 44 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -782,10 +782,11 @@
782782
"patch": 2
783783
},
784784
"WGPUAdapterProperties": {
785-
"__size__": 64,
785+
"__size__": 72,
786786
"adapterType": 56,
787787
"architecture": 24,
788788
"backendType": 60,
789+
"compatibilityMode": 64,
789790
"deviceID": 32,
790791
"driverDescription": 48,
791792
"name": 40,
@@ -890,14 +891,17 @@
890891
"nextInChain": 0
891892
},
892893
"WGPUCompilationMessage": {
893-
"__size__": 56,
894+
"__size__": 80,
894895
"length": 48,
895896
"lineNum": 24,
896897
"linePos": 32,
897898
"message": 8,
898899
"nextInChain": 0,
899900
"offset": 40,
900-
"type": 16
901+
"type": 16,
902+
"utf16Length": 72,
903+
"utf16LinePos": 56,
904+
"utf16Offset": 64
901905
},
902906
"WGPUComputePassDescriptor": {
903907
"__size__": 32,
@@ -940,8 +944,10 @@
940944
"stencilWriteMask": 56
941945
},
942946
"WGPUDeviceDescriptor": {
943-
"__size__": 56,
947+
"__size__": 72,
944948
"defaultQueue": 40,
949+
"deviceLostCallback": 56,
950+
"deviceLostUserdata": 64,
945951
"label": 8,
946952
"nextInChain": 0,
947953
"requiredFeatures": 24,
@@ -983,35 +989,38 @@
983989
"nextInChain": 0
984990
},
985991
"WGPULimits": {
986-
"__size__": 120,
992+
"__size__": 144,
987993
"maxBindGroups": 16,
988-
"maxColorAttachments": 92,
989-
"maxComputeInvocationsPerWorkgroup": 100,
990-
"maxComputeWorkgroupSizeX": 104,
991-
"maxComputeWorkgroupSizeY": 108,
992-
"maxComputeWorkgroupSizeZ": 112,
993-
"maxComputeWorkgroupStorageSize": 96,
994-
"maxComputeWorkgroupsPerDimension": 116,
995-
"maxDynamicStorageBuffersPerPipelineLayout": 24,
996-
"maxDynamicUniformBuffersPerPipelineLayout": 20,
997-
"maxInterStageShaderComponents": 84,
998-
"maxInterStageShaderVariables": 88,
999-
"maxSampledTexturesPerShaderStage": 28,
1000-
"maxSamplersPerShaderStage": 32,
1001-
"maxStorageBufferBindingSize": 56,
1002-
"maxStorageBuffersPerShaderStage": 36,
1003-
"maxStorageTexturesPerShaderStage": 40,
994+
"maxBindingsPerBindGroup": 20,
995+
"maxBufferSize": 88,
996+
"maxColorAttachmentBytesPerSample": 116,
997+
"maxColorAttachments": 112,
998+
"maxComputeInvocationsPerWorkgroup": 124,
999+
"maxComputeWorkgroupSizeX": 128,
1000+
"maxComputeWorkgroupSizeY": 132,
1001+
"maxComputeWorkgroupSizeZ": 136,
1002+
"maxComputeWorkgroupStorageSize": 120,
1003+
"maxComputeWorkgroupsPerDimension": 140,
1004+
"maxDynamicStorageBuffersPerPipelineLayout": 28,
1005+
"maxDynamicUniformBuffersPerPipelineLayout": 24,
1006+
"maxInterStageShaderComponents": 104,
1007+
"maxInterStageShaderVariables": 108,
1008+
"maxSampledTexturesPerShaderStage": 32,
1009+
"maxSamplersPerShaderStage": 36,
1010+
"maxStorageBufferBindingSize": 64,
1011+
"maxStorageBuffersPerShaderStage": 40,
1012+
"maxStorageTexturesPerShaderStage": 44,
10041013
"maxTextureArrayLayers": 12,
10051014
"maxTextureDimension1D": 0,
10061015
"maxTextureDimension2D": 4,
10071016
"maxTextureDimension3D": 8,
1008-
"maxUniformBufferBindingSize": 48,
1009-
"maxUniformBuffersPerShaderStage": 44,
1010-
"maxVertexAttributes": 76,
1011-
"maxVertexBufferArrayStride": 80,
1012-
"maxVertexBuffers": 72,
1013-
"minStorageBufferOffsetAlignment": 68,
1014-
"minUniformBufferOffsetAlignment": 64
1017+
"maxUniformBufferBindingSize": 56,
1018+
"maxUniformBuffersPerShaderStage": 48,
1019+
"maxVertexAttributes": 96,
1020+
"maxVertexBufferArrayStride": 100,
1021+
"maxVertexBuffers": 80,
1022+
"minStorageBufferOffsetAlignment": 76,
1023+
"minUniformBufferOffsetAlignment": 72
10151024
},
10161025
"WGPUMultisampleState": {
10171026
"__size__": 24,
@@ -1139,13 +1148,14 @@
11391148
},
11401149
"WGPURequestAdapterOptions": {
11411150
"__size__": 24,
1151+
"compatibilityMode": 21,
11421152
"compatibleSurface": 8,
11431153
"forceFallbackAdapter": 20,
11441154
"nextInChain": 0,
11451155
"powerPreference": 16
11461156
},
11471157
"WGPURequiredLimits": {
1148-
"__size__": 128,
1158+
"__size__": 152,
11491159
"limits": 8,
11501160
"nextInChain": 0
11511161
},
@@ -1183,7 +1193,7 @@
11831193
"WGPUShaderModuleWGSLDescriptor": {
11841194
"__size__": 24,
11851195
"chain": 0,
1186-
"source": 16
1196+
"code": 16
11871197
},
11881198
"WGPUStencilFaceState": {
11891199
"__size__": 16,
@@ -1200,7 +1210,7 @@
12001210
"viewDimension": 16
12011211
},
12021212
"WGPUSupportedLimits": {
1203-
"__size__": 128,
1213+
"__size__": 152,
12041214
"limits": 8,
12051215
"nextInChain": 0
12061216
},
@@ -1270,10 +1280,10 @@
12701280
"shaderLocation": 16
12711281
},
12721282
"WGPUVertexBufferLayout": {
1273-
"__size__": 24,
1283+
"__size__": 32,
12741284
"arrayStride": 0,
1275-
"attributeCount": 12,
1276-
"attributes": 16,
1285+
"attributeCount": 16,
1286+
"attributes": 24,
12771287
"stepMode": 8
12781288
},
12791289
"WGPUVertexState": {

src/library_sigs.js

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1541,6 +1541,7 @@ sigs = {
15411541
wgpuBindGroupSetLabel__sig: 'vpp',
15421542
wgpuBufferDestroy__sig: 'vp',
15431543
wgpuBufferGetConstMappedRange__sig: 'pppp',
1544+
wgpuBufferGetMapState__sig: 'ip',
15441545
wgpuBufferGetMappedRange__sig: 'pppp',
15451546
wgpuBufferGetSize__sig: 'jp',
15461547
wgpuBufferGetUsage__sig: 'ip',
@@ -1578,7 +1579,7 @@ sigs = {
15781579
wgpuComputePassEncoderPushDebugGroup__sig: 'vpp',
15791580
wgpuComputePassEncoderReference__sig: 'vp',
15801581
wgpuComputePassEncoderRelease__sig: 'vp',
1581-
wgpuComputePassEncoderSetBindGroup__sig: 'vpipip',
1582+
wgpuComputePassEncoderSetBindGroup__sig: 'vpippp',
15821583
wgpuComputePassEncoderSetLabel__sig: 'vpp',
15831584
wgpuComputePassEncoderSetPipeline__sig: 'vpp',
15841585
wgpuComputePassEncoderWriteTimestamp__sig: 'vppi',
@@ -1607,11 +1608,10 @@ sigs = {
16071608
wgpuDeviceGetLimits__sig: 'ipp',
16081609
wgpuDeviceGetQueue__sig: 'pp',
16091610
wgpuDeviceHasFeature__sig: 'ipi',
1610-
wgpuDevicePopErrorScope__sig: 'ippp',
1611+
wgpuDevicePopErrorScope__sig: 'vppp',
16111612
wgpuDevicePushErrorScope__sig: 'vpi',
16121613
wgpuDeviceReference__sig: 'vp',
16131614
wgpuDeviceRelease__sig: 'vp',
1614-
wgpuDeviceSetDeviceLostCallback__sig: 'vppp',
16151615
wgpuDeviceSetLabel__sig: 'vpp',
16161616
wgpuDeviceSetUncapturedErrorCallback__sig: 'vppp',
16171617
wgpuGetProcAddress__sig: 'ppp',
@@ -1633,7 +1633,7 @@ sigs = {
16331633
wgpuQueueReference__sig: 'vp',
16341634
wgpuQueueRelease__sig: 'vp',
16351635
wgpuQueueSetLabel__sig: 'vpp',
1636-
wgpuQueueSubmit__sig: 'vpip',
1636+
wgpuQueueSubmit__sig: 'vppp',
16371637
wgpuQueueWriteBuffer__sig: 'vppjpp',
16381638
wgpuQueueWriteTexture__sig: 'vpppppp',
16391639
wgpuRenderBundleEncoderDraw__sig: 'vpiiii',
@@ -1646,13 +1646,14 @@ sigs = {
16461646
wgpuRenderBundleEncoderPushDebugGroup__sig: 'vpp',
16471647
wgpuRenderBundleEncoderReference__sig: 'vp',
16481648
wgpuRenderBundleEncoderRelease__sig: 'vp',
1649-
wgpuRenderBundleEncoderSetBindGroup__sig: 'vpipip',
1649+
wgpuRenderBundleEncoderSetBindGroup__sig: 'vpippp',
16501650
wgpuRenderBundleEncoderSetIndexBuffer__sig: 'vppijj',
16511651
wgpuRenderBundleEncoderSetLabel__sig: 'vpp',
16521652
wgpuRenderBundleEncoderSetPipeline__sig: 'vpp',
16531653
wgpuRenderBundleEncoderSetVertexBuffer__sig: 'vpipjj',
16541654
wgpuRenderBundleReference__sig: 'vp',
16551655
wgpuRenderBundleRelease__sig: 'vp',
1656+
wgpuRenderBundleSetLabel__sig: 'vpp',
16561657
wgpuRenderPassEncoderBeginOcclusionQuery__sig: 'vpi',
16571658
wgpuRenderPassEncoderBeginPipelineStatisticsQuery__sig: 'vppi',
16581659
wgpuRenderPassEncoderDraw__sig: 'vpiiii',
@@ -1662,13 +1663,13 @@ sigs = {
16621663
wgpuRenderPassEncoderEnd__sig: 'vp',
16631664
wgpuRenderPassEncoderEndOcclusionQuery__sig: 'vp',
16641665
wgpuRenderPassEncoderEndPipelineStatisticsQuery__sig: 'vp',
1665-
wgpuRenderPassEncoderExecuteBundles__sig: 'vpip',
1666+
wgpuRenderPassEncoderExecuteBundles__sig: 'vppp',
16661667
wgpuRenderPassEncoderInsertDebugMarker__sig: 'vpp',
16671668
wgpuRenderPassEncoderPopDebugGroup__sig: 'vp',
16681669
wgpuRenderPassEncoderPushDebugGroup__sig: 'vpp',
16691670
wgpuRenderPassEncoderReference__sig: 'vp',
16701671
wgpuRenderPassEncoderRelease__sig: 'vp',
1671-
wgpuRenderPassEncoderSetBindGroup__sig: 'vpipip',
1672+
wgpuRenderPassEncoderSetBindGroup__sig: 'vpippp',
16721673
wgpuRenderPassEncoderSetBlendConstant__sig: 'vpp',
16731674
wgpuRenderPassEncoderSetIndexBuffer__sig: 'vppijj',
16741675
wgpuRenderPassEncoderSetLabel__sig: 'vpp',

0 commit comments

Comments
 (0)