MCPcopy Index your code
hub / github.com/apache/tvm / constructor

Method constructor

web/src/memory.ts:298–314  ·  view source on GitHub ↗
(
    memory: Memory,
    allocSpace: ctypes.FTVMWasmAllocSpace,
    freeSpace: ctypes.FTVMWasmFreeSpace
  )

Source from the content-addressed store, hash-verified

296 private addressToSetTargetValue: Array<[PtrOffset, PtrOffset]> = [];
297
298 constructor(
299 memory: Memory,
300 allocSpace: ctypes.FTVMWasmAllocSpace,
301 freeSpace: ctypes.FTVMWasmFreeSpace
302 ) {
303 const initCallStackSize = 128;
304 this.memory = memory;
305 this.cAllocSpace = allocSpace;
306 this.cFreeSpace = freeSpace;
307 this.buffer = new ArrayBuffer(initCallStackSize);
308 this.basePtr = this.cAllocSpace(initCallStackSize);
309 this.viewU8 = new Uint8Array(this.buffer);
310 this.viewI32 = new Int32Array(this.buffer);
311 this.viewU32 = new Uint32Array(this.buffer);
312 this.viewF64 = new Float64Array(this.buffer);
313 this.updateViews();
314 }
315
316 dispose(): void {
317 if (this.basePtr != 0) {

Callers

nothing calls this directly

Calls 1

updateViewsMethod · 0.95

Tested by

no test coverage detected