space-data-module-sdk 0.11.0 → 0.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,394 @@
1
+ // Host-owned shared GPU compute context and opaque buffer-handle registry (SDK GPU Module ABI v2).
2
+ //
3
+ // Enables independent modules (for example propagator/sdn-ap and analysis/conjunction-assessment)
4
+ // to share one host-owned GPUDevice and exchange GPU buffers via opaque numeric handle ids with
5
+ // zero CPU round-trip, while cleanly detecting GPU availability and falling back to CPU when
6
+ // WebGPU/Dawn is absent.
7
+
8
+ export const SDN_GPU_ABI_VERSION = 2;
9
+ export const SDN_GPU_CAPABILITY_ID = "gpu_compute";
10
+ export const SDN_GPU_CAPABILITY_SCOPE_V1 = "webgpu.v1";
11
+ export const SDN_GPU_CAPABILITY_SCOPE_V2 = "webgpu.v2";
12
+
13
+ export const SDN_GPU_STATUS = Object.freeze({
14
+ OK: 0,
15
+ UNAVAILABLE: 1,
16
+ UNSUPPORTED_ABI: 2,
17
+ INVALID_DESCRIPTOR: 3,
18
+ LIMIT_EXCEEDED: 4,
19
+ DISPATCH_FAILED: 5,
20
+ OUTPUT_OVERFLOW: 6,
21
+ UNKNOWN_HANDLE: 7,
22
+ DEVICE_MISMATCH: 8,
23
+ });
24
+
25
+ export const SDN_GPU_BACKEND = Object.freeze({
26
+ UNKNOWN: 0,
27
+ BROWSER_WEBGPU: 1,
28
+ DAWN_NATIVE: 2,
29
+ CPU_FALLBACK: 3,
30
+ });
31
+
32
+ export const SDN_GPU_BUFFER_ROLE = Object.freeze({
33
+ STORAGE_READ: 1 << 0,
34
+ STORAGE_WRITE: 1 << 1,
35
+ UNIFORM: 1 << 2,
36
+ INDIRECT: 1 << 3,
37
+ SHARED_EXCHANGE: 1 << 4,
38
+ });
39
+
40
+ export const SDN_GPU_SCALAR_FORMAT = Object.freeze({
41
+ U8: 1,
42
+ U32: 2,
43
+ I32: 3,
44
+ F32: 4,
45
+ SPLIT_F64: 5,
46
+ IEEE754_F64_U32X2: 6,
47
+ });
48
+
49
+ const _f64Scratch = new ArrayBuffer(8);
50
+ const _f64View = new Float64Array(_f64Scratch);
51
+ const _u32View = new Uint32Array(_f64Scratch);
52
+
53
+ /** Pack an IEEE-754 binary64 number into little-endian { lo, hi } u32 pair (0 ULP loss). */
54
+ export function packF64Bits(value) {
55
+ _f64View[0] = value;
56
+ return { lo: _u32View[0], hi: _u32View[1] };
57
+ }
58
+
59
+ /** Unpack little-endian (lo, hi) u32 pair into an exact IEEE-754 binary64 number. */
60
+ export function unpackF64Bits(lo, hi) {
61
+ _u32View[0] = lo >>> 0;
62
+ _u32View[1] = hi >>> 0;
63
+ return _f64View[0];
64
+ }
65
+
66
+ /** Reinterpret a Float64Array as little-endian Uint32Array (pairs of [lo, hi]) without copying. */
67
+ export function f64ArrayToU32Pairs(f64) {
68
+ return new Uint32Array(f64.buffer, f64.byteOffset, f64.length * 2);
69
+ }
70
+
71
+ /** Reinterpret little-endian Uint32Array pairs [lo, hi] as Float64Array without copying. */
72
+ export function u32PairsToF64Array(u32) {
73
+ if ((u32.byteLength & 7) !== 0) {
74
+ throw new RangeError("u32 byteLength must be a multiple of 8 for IEEE-754 f64 pairs.");
75
+ }
76
+ return new Float64Array(u32.buffer, u32.byteOffset, u32.byteLength / 8);
77
+ }
78
+
79
+ let nextDeviceId = 1;
80
+
81
+ /**
82
+ * Probes whether WebGPU is available in the current host without throwing.
83
+ * Returns { available: false, backendKind: 'cpu-fallback', reason, context: null }
84
+ * when unavailable, or { available: true, backendKind: 'browser-webgpu', adapter, device, context }.
85
+ */
86
+ export async function detectWebGpu(options = {}) {
87
+ const gpu = options.gpu ?? globalThis?.navigator?.gpu ?? null;
88
+ if (!gpu || typeof gpu.requestAdapter !== "function") {
89
+ return {
90
+ available: false,
91
+ abiVersion: SDN_GPU_ABI_VERSION,
92
+ backendKind: "cpu-fallback",
93
+ backendCode: SDN_GPU_BACKEND.CPU_FALLBACK,
94
+ reason: "navigator.gpu is unavailable in this runtime.",
95
+ adapter: null,
96
+ device: null,
97
+ context: null,
98
+ };
99
+ }
100
+ try {
101
+ const adapter = await gpu.requestAdapter({
102
+ powerPreference: options.powerPreference ?? "high-performance",
103
+ forceFallbackAdapter: Boolean(options.forceFallbackAdapter),
104
+ });
105
+ if (!adapter) {
106
+ return {
107
+ available: false,
108
+ abiVersion: SDN_GPU_ABI_VERSION,
109
+ backendKind: "cpu-fallback",
110
+ backendCode: SDN_GPU_BACKEND.CPU_FALLBACK,
111
+ reason: "No WebGPU adapter returned by navigator.gpu.requestAdapter().",
112
+ adapter: null,
113
+ device: null,
114
+ context: null,
115
+ };
116
+ }
117
+ const requiredLimits = options.requiredLimits ?? {};
118
+ const device = await adapter.requestDevice(
119
+ Object.keys(requiredLimits).length > 0 ? { requiredLimits } : undefined,
120
+ );
121
+ const info = adapter.info ?? (typeof adapter.requestAdapterInfo === "function" ? await adapter.requestAdapterInfo() : null);
122
+ const adapterLabel = info
123
+ ? [info.vendor, info.architecture, info.device, info.description].filter(Boolean).join(" ") || "WebGPU"
124
+ : "WebGPU";
125
+ const context = createSharedGpuContext({
126
+ device,
127
+ adapter,
128
+ adapterLabel,
129
+ backendKind: "browser-webgpu",
130
+ backendCode: SDN_GPU_BACKEND.BROWSER_WEBGPU,
131
+ });
132
+ return {
133
+ available: true,
134
+ abiVersion: SDN_GPU_ABI_VERSION,
135
+ backendKind: "browser-webgpu",
136
+ backendCode: SDN_GPU_BACKEND.BROWSER_WEBGPU,
137
+ adapterLabel,
138
+ adapter,
139
+ device,
140
+ context,
141
+ };
142
+ } catch (error) {
143
+ return {
144
+ available: false,
145
+ abiVersion: SDN_GPU_ABI_VERSION,
146
+ backendKind: "cpu-fallback",
147
+ backendCode: SDN_GPU_BACKEND.CPU_FALLBACK,
148
+ reason: error?.message ?? String(error),
149
+ adapter: null,
150
+ device: null,
151
+ context: null,
152
+ };
153
+ }
154
+ }
155
+
156
+ /**
157
+ * Host-owned shared GPU context: holds one GPUDevice and an opaque handle table so
158
+ * independent modules (e.g. AP and CA) exchange GPU buffers without CPU round-trips.
159
+ */
160
+ export function createSharedGpuContext(options = {}) {
161
+ const device = options.device ?? null;
162
+ if (!device || typeof device.createBuffer !== "function") {
163
+ throw new TypeError("createSharedGpuContext requires a valid GPUDevice (device.createBuffer).");
164
+ }
165
+ const deviceId = options.deviceId ?? nextDeviceId++;
166
+ const backendKind = options.backendKind ?? "browser-webgpu";
167
+ const backendCode = options.backendCode ?? SDN_GPU_BACKEND.BROWSER_WEBGPU;
168
+ const adapterLabel = options.adapterLabel ?? "WebGPU";
169
+ const handles = new Map();
170
+ let nextHandleId = 1;
171
+ let destroyed = false;
172
+
173
+ const assertAlive = () => {
174
+ if (destroyed) throw new Error("SharedGpuContext has been destroyed.");
175
+ };
176
+
177
+ function buildDescriptor(entry) {
178
+ return Object.freeze({
179
+ abiVersion: SDN_GPU_ABI_VERSION,
180
+ handleId: entry.handleId,
181
+ deviceId,
182
+ byteLength: entry.byteLength,
183
+ role: entry.role,
184
+ scalarFormat: entry.scalarFormat,
185
+ recordStride: entry.recordStride,
186
+ layout: entry.layout,
187
+ owner: entry.owner,
188
+ metadata: entry.metadata ? { ...entry.metadata } : {},
189
+ });
190
+ }
191
+
192
+ /** Register an existing GPUBuffer owned by this context's device and return its opaque handle descriptor. */
193
+ function registerBuffer(buffer, spec = {}) {
194
+ assertAlive();
195
+ if (!buffer || typeof buffer.destroy !== "function") {
196
+ throw new TypeError("registerBuffer requires a GPUBuffer.");
197
+ }
198
+ const handleId = nextHandleId++;
199
+ const entry = {
200
+ handleId,
201
+ buffer,
202
+ byteLength: Number(spec.byteLength ?? buffer.size ?? 0),
203
+ role: Number(spec.role ?? (SDN_GPU_BUFFER_ROLE.STORAGE_READ | SDN_GPU_BUFFER_ROLE.STORAGE_WRITE | SDN_GPU_BUFFER_ROLE.SHARED_EXCHANGE)),
204
+ scalarFormat: Number(spec.scalarFormat ?? SDN_GPU_SCALAR_FORMAT.U8),
205
+ recordStride: Number(spec.recordStride ?? 0),
206
+ layout: spec.layout ?? null,
207
+ owner: spec.owner ?? null,
208
+ ownedByContext: spec.ownedByContext !== false,
209
+ metadata: spec.metadata ? { ...spec.metadata } : {},
210
+ };
211
+ handles.set(handleId, entry);
212
+ return buildDescriptor(entry);
213
+ }
214
+
215
+ /** Allocate a GPUBuffer on the shared device and register an opaque handle for cross-module handoff. */
216
+ function createBuffer(spec = {}) {
217
+ assertAlive();
218
+ const byteLength = Number(spec.byteLength ?? spec.size ?? 0);
219
+ if (!(byteLength > 0)) {
220
+ throw new RangeError("createBuffer requires byteLength > 0.");
221
+ }
222
+ const alignedSize = Math.ceil(byteLength / 4) * 4;
223
+ const usage = spec.usage ?? (
224
+ globalThis.GPUBufferUsage
225
+ ? (globalThis.GPUBufferUsage.STORAGE | globalThis.GPUBufferUsage.COPY_SRC | globalThis.GPUBufferUsage.COPY_DST)
226
+ : 0x8c
227
+ );
228
+ const buffer = device.createBuffer({
229
+ size: alignedSize,
230
+ usage,
231
+ ...(spec.label ? { label: spec.label } : {}),
232
+ });
233
+ if (spec.initialData) {
234
+ const view = ArrayBuffer.isView(spec.initialData)
235
+ ? new Uint8Array(spec.initialData.buffer, spec.initialData.byteOffset, spec.initialData.byteLength)
236
+ : new Uint8Array(spec.initialData);
237
+ device.queue.writeBuffer(buffer, 0, view);
238
+ }
239
+ return registerBuffer(buffer, { ...spec, byteLength: alignedSize, ownedByContext: true });
240
+ }
241
+
242
+ function resolveEntry(handleOrId) {
243
+ assertAlive();
244
+ const id = typeof handleOrId === "object" && handleOrId !== null ? handleOrId.handleId : Number(handleOrId);
245
+ if (typeof handleOrId === "object" && handleOrId !== null && handleOrId.deviceId != null && handleOrId.deviceId !== deviceId) {
246
+ const err = new Error(`GPU buffer handle ${id} belongs to device ${handleOrId.deviceId}, not ${deviceId}.`);
247
+ err.gpuStatus = SDN_GPU_STATUS.DEVICE_MISMATCH;
248
+ throw err;
249
+ }
250
+ const entry = handles.get(id);
251
+ if (!entry) {
252
+ const err = new Error(`Unknown GPU buffer handle ${id}.`);
253
+ err.gpuStatus = SDN_GPU_STATUS.UNKNOWN_HANDLE;
254
+ throw err;
255
+ }
256
+ return entry;
257
+ }
258
+
259
+ function getBuffer(handleOrId) {
260
+ return resolveEntry(handleOrId).buffer;
261
+ }
262
+
263
+ function describeBuffer(handleOrId) {
264
+ return buildDescriptor(resolveEntry(handleOrId));
265
+ }
266
+
267
+ /** Read bytes from a registered shared buffer back to CPU (used only for CPU-consumer fallback or verification). */
268
+ async function readBuffer(handleOrId, byteOffset = 0, byteLength = null) {
269
+ const entry = resolveEntry(handleOrId);
270
+ const length = byteLength == null ? entry.byteLength - byteOffset : Number(byteLength);
271
+ if (length <= 0) return new Uint8Array(0);
272
+ const aligned = Math.ceil(length / 4) * 4;
273
+ const U = globalThis.GPUBufferUsage ?? { MAP_READ: 0x0001, COPY_DST: 0x0008 };
274
+ const M = globalThis.GPUMapMode ?? { READ: 0x0001 };
275
+ const staging = device.createBuffer({ size: aligned, usage: U.MAP_READ | U.COPY_DST });
276
+ try {
277
+ const enc = device.createCommandEncoder();
278
+ enc.copyBufferToBuffer(entry.buffer, byteOffset, staging, 0, aligned);
279
+ device.queue.submit([enc.finish()]);
280
+ await staging.mapAsync(M.READ, 0, aligned);
281
+ const copy = new Uint8Array(staging.getMappedRange(0, aligned).slice(0, length));
282
+ staging.unmap();
283
+ return copy;
284
+ } finally {
285
+ staging.destroy();
286
+ }
287
+ }
288
+
289
+ function releaseBuffer(handleOrId) {
290
+ const id = typeof handleOrId === "object" && handleOrId !== null ? handleOrId.handleId : Number(handleOrId);
291
+ const entry = handles.get(id);
292
+ if (!entry) return false;
293
+ handles.delete(id);
294
+ if (entry.ownedByContext) {
295
+ entry.buffer.destroy();
296
+ }
297
+ return true;
298
+ }
299
+
300
+ function listBuffers() {
301
+ return Array.from(handles.values(), buildDescriptor);
302
+ }
303
+
304
+ function getDeviceInfo() {
305
+ const lim = device.limits ?? {};
306
+ return Object.freeze({
307
+ abiVersion: SDN_GPU_ABI_VERSION,
308
+ available: !destroyed,
309
+ backendKind,
310
+ backendCode,
311
+ deviceId,
312
+ adapterLabel,
313
+ maxStorageBufferBindingSize: Number(lim.maxStorageBufferBindingSize ?? 0),
314
+ maxBufferSize: Number(lim.maxBufferSize ?? 0),
315
+ maxComputeWorkgroupSizeX: Number(lim.maxComputeWorkgroupSizeX ?? 256),
316
+ maxComputeInvocationsPerWorkgroup: Number(lim.maxComputeInvocationsPerWorkgroup ?? 256),
317
+ });
318
+ }
319
+
320
+ function destroy() {
321
+ if (destroyed) return;
322
+ destroyed = true;
323
+ for (const entry of handles.values()) {
324
+ if (entry.ownedByContext) entry.buffer.destroy();
325
+ }
326
+ handles.clear();
327
+ }
328
+
329
+ const context = {
330
+ abiVersion: SDN_GPU_ABI_VERSION,
331
+ deviceId,
332
+ device,
333
+ adapter: options.adapter ?? null,
334
+ adapterLabel,
335
+ backendKind,
336
+ backendCode,
337
+ getDeviceInfo,
338
+ createBuffer,
339
+ registerBuffer,
340
+ getBuffer,
341
+ describeBuffer,
342
+ readBuffer,
343
+ releaseBuffer,
344
+ listBuffers,
345
+ destroy,
346
+ };
347
+ return context;
348
+ }
349
+
350
+ /** Creates a runtime-host capability adapter for `gpu_compute` implementing v2 device/buffer operations. */
351
+ export function createGpuCapabilityAdapter(contextOrNull = null) {
352
+ return {
353
+ "device.info.v1"() {
354
+ if (!contextOrNull) {
355
+ return {
356
+ abiVersion: SDN_GPU_ABI_VERSION,
357
+ available: false,
358
+ backendKind: "cpu-fallback",
359
+ backendCode: SDN_GPU_BACKEND.CPU_FALLBACK,
360
+ deviceId: 0,
361
+ };
362
+ }
363
+ return contextOrNull.getDeviceInfo();
364
+ },
365
+ "buffer.create.v1"(params = {}) {
366
+ if (!contextOrNull) {
367
+ const err = new Error("GPU compute context unavailable.");
368
+ err.gpuStatus = SDN_GPU_STATUS.UNAVAILABLE;
369
+ throw err;
370
+ }
371
+ return contextOrNull.createBuffer(params);
372
+ },
373
+ "buffer.describe.v1"(params = {}) {
374
+ if (!contextOrNull) {
375
+ const err = new Error("GPU compute context unavailable.");
376
+ err.gpuStatus = SDN_GPU_STATUS.UNAVAILABLE;
377
+ throw err;
378
+ }
379
+ return contextOrNull.describeBuffer(params.handle ?? params.handleId);
380
+ },
381
+ "buffer.read.v1"(params = {}) {
382
+ if (!contextOrNull) {
383
+ const err = new Error("GPU compute context unavailable.");
384
+ err.gpuStatus = SDN_GPU_STATUS.UNAVAILABLE;
385
+ throw err;
386
+ }
387
+ return contextOrNull.readBuffer(params.handle ?? params.handleId, params.byteOffset ?? 0, params.byteLength ?? null);
388
+ },
389
+ "buffer.release.v1"(params = {}) {
390
+ if (!contextOrNull) return { released: false };
391
+ return { released: contextOrNull.releaseBuffer(params.handle ?? params.handleId) };
392
+ },
393
+ };
394
+ }
@@ -1,7 +1,50 @@
1
1
  import { createFlatSqlRuntimeStore } from "./flatsqlRuntimeStore.js";
2
2
  import { createFlatBufferStreamIngestor } from "./flatbufferStreamIngestor.js";
3
- import { createRuntimeRegionStore } from "./runtimeRegionStore.js";
3
+ import {
4
+ createArenaBuffer,
5
+ createRuntimeRegionStore,
6
+ isSharedBuffer,
7
+ } from "./runtimeRegionStore.js";
4
8
  import { createModuleRegistry } from "./moduleRegistry.js";
9
+ import {
10
+ SDN_GPU_ABI_VERSION,
11
+ SDN_GPU_CAPABILITY_ID,
12
+ SDN_GPU_CAPABILITY_SCOPE_V1,
13
+ SDN_GPU_CAPABILITY_SCOPE_V2,
14
+ SDN_GPU_STATUS,
15
+ SDN_GPU_BACKEND,
16
+ SDN_GPU_BUFFER_ROLE,
17
+ SDN_GPU_SCALAR_FORMAT,
18
+ packF64Bits,
19
+ unpackF64Bits,
20
+ f64ArrayToU32Pairs,
21
+ u32PairsToF64Array,
22
+ detectWebGpu,
23
+ createSharedGpuContext,
24
+ createGpuCapabilityAdapter,
25
+ } from "./gpuComputeContext.js";
26
+ import {
27
+ SCR_GRID_STATE_FLOATS,
28
+ SCR_GRID_STATE_BYTES,
29
+ SCR_RADIUS_BAND_FLOATS,
30
+ SCR_RADIUS_BAND_BYTES,
31
+ SCR_ROLE,
32
+ SCR_ROLE_MASK_ALL,
33
+ SCR_GRID_LAYOUT_ID,
34
+ DEFAULT_PROPAGATOR_ID,
35
+ SUPPORTED_PROPAGATOR_IDS,
36
+ DECLARED_ORBIT_THEORIES,
37
+ TheoryMismatchError,
38
+ StaleGridLeaseError,
39
+ resolvePropagatorId,
40
+ normalizeDeclaredTheory,
41
+ createPropagatorRegistry,
42
+ routeCatalogRecordsByTheory,
43
+ gridCacheKey,
44
+ encodeScrGridFlatBuffer,
45
+ decodeScrGridFlatBuffer,
46
+ createSharedEphemerisGridManager,
47
+ } from "./ephemerisGridStore.js";
5
48
 
6
49
  function normalizeCapabilityId(capability) {
7
50
  const normalized = String(capability ?? "").trim();
@@ -49,12 +92,46 @@ export function createRuntimeHost(options = {}) {
49
92
  const rows = options.rows ?? createFlatSqlRuntimeStore(options.rowStore);
50
93
  const regions = options.regions ?? createRuntimeRegionStore();
51
94
  const moduleRegistry = options.moduleRegistry ?? createModuleRegistry();
95
+ const propagators =
96
+ options.propagators ?? createPropagatorRegistry(options.propagatorAdapters);
97
+ const ephemerisGrids =
98
+ options.ephemerisGrids ??
99
+ createSharedEphemerisGridManager({ regions, propagators });
52
100
  const capabilities = createCapabilityRegistry(options.capabilities);
53
101
 
54
102
  return {
55
103
  rows,
56
104
  regions,
57
105
  moduleRegistry,
106
+ propagators,
107
+ ephemerisGrids,
108
+ registerPropagator(id, adapter) {
109
+ return propagators.registerPropagator(id, adapter);
110
+ },
111
+ listPropagators() {
112
+ return propagators.listPropagators();
113
+ },
114
+ populateEphemerisGrid(spec) {
115
+ return ephemerisGrids.populateGrid(spec);
116
+ },
117
+ getEphemerisGrid(regionId) {
118
+ return ephemerisGrids.getGrid(regionId);
119
+ },
120
+ attachEphemerisGrid(regionId, opts) {
121
+ return ephemerisGrids.attachGridModule(regionId, opts);
122
+ },
123
+ detachEphemerisGrid(lease) {
124
+ if (!lease || typeof lease.detach !== "function") {
125
+ return false;
126
+ }
127
+ return lease.detach();
128
+ },
129
+ spliceEphemerisGrid(spec) {
130
+ return ephemerisGrids.spliceGridObjects(spec);
131
+ },
132
+ invalidateEphemerisGrid(filter) {
133
+ return ephemerisGrids.invalidateGrid(filter);
134
+ },
58
135
  listCapabilities() {
59
136
  return Array.from(capabilities.keys()).sort();
60
137
  },
@@ -106,10 +183,47 @@ export function createRuntimeHost(options = {}) {
106
183
  }
107
184
 
108
185
  export {
186
+ createArenaBuffer,
109
187
  createFlatBufferStreamIngestor,
110
188
  createFlatSqlRuntimeStore,
111
189
  createModuleRegistry,
112
190
  createRuntimeRegionStore,
191
+ isSharedBuffer,
192
+ SCR_GRID_STATE_FLOATS,
193
+ SCR_GRID_STATE_BYTES,
194
+ SCR_RADIUS_BAND_FLOATS,
195
+ SCR_RADIUS_BAND_BYTES,
196
+ SCR_ROLE,
197
+ SCR_ROLE_MASK_ALL,
198
+ SCR_GRID_LAYOUT_ID,
199
+ DEFAULT_PROPAGATOR_ID,
200
+ SUPPORTED_PROPAGATOR_IDS,
201
+ DECLARED_ORBIT_THEORIES,
202
+ TheoryMismatchError,
203
+ StaleGridLeaseError,
204
+ resolvePropagatorId,
205
+ normalizeDeclaredTheory,
206
+ createPropagatorRegistry,
207
+ routeCatalogRecordsByTheory,
208
+ gridCacheKey,
209
+ encodeScrGridFlatBuffer,
210
+ decodeScrGridFlatBuffer,
211
+ createSharedEphemerisGridManager,
212
+ SDN_GPU_ABI_VERSION,
213
+ SDN_GPU_CAPABILITY_ID,
214
+ SDN_GPU_CAPABILITY_SCOPE_V1,
215
+ SDN_GPU_CAPABILITY_SCOPE_V2,
216
+ SDN_GPU_STATUS,
217
+ SDN_GPU_BACKEND,
218
+ SDN_GPU_BUFFER_ROLE,
219
+ SDN_GPU_SCALAR_FORMAT,
220
+ packF64Bits,
221
+ unpackF64Bits,
222
+ f64ArrayToU32Pairs,
223
+ u32PairsToF64Array,
224
+ detectWebGpu,
225
+ createSharedGpuContext,
226
+ createGpuCapabilityAdapter,
113
227
  };
114
228
  // Flow-tier validating method registry (vendored sdn-flow semantics; distinct
115
229
  // from createModuleRegistry's module-lifecycle registry).