Lines Matching refs:wasm

204   const wasm = Object.create(null);
392 else if(wasm.isPtr(v)) v = wasm.cstringToJs(v);
678 Object.assign(wasm, {
778 wasm.allocFromTypedArray = function(srcTypedArray){
780 const pRet = wasm.alloc(srcTypedArray.byteLength || 1);
781 wasm.heapForSize(srcTypedArray.constructor).set(
790 const f = wasm.exports[key];
794 wasm.alloc = function f(n){
799 wasm.alloc.impl = wasm.exports[keyAlloc];
800 wasm.dealloc = wasm.exports[keyDealloc];
831 wasm.compileOptionUsed = function f(optName){
882 wasm.bindingSignatures = [
987 if(false && wasm.compileOptionUsed('SQLITE_ENABLE_NORMALIZE')){
991 wasm.bindingSignatures.push(["sqlite3_normalized_sql", "string", "sqlite3_stmt*"]);
999 wasm.bindingSignatures.int64 = [
1017 wasm.bindingSignatures.wasm = [
1057 wasm.pstack = Object.assign(Object.create(null),{
1063 restore: wasm.exports.sqlite3_wasm_pstack_restore,
1077 return wasm.exports.sqlite3_wasm_pstack_alloc(n)
1095 const mem = wasm.pstack.alloc(n * sz);
1124 ? wasm.pstack.alloc(safePtrSize ? 8 : wasm.ptrSizeof)
1125 : wasm.pstack.allocChunks(n, safePtrSize ? 8 : wasm.ptrSizeof);
1128 Object.defineProperties(wasm.pstack, {
1138 get: wasm.exports.sqlite3_wasm_pstack_ptr
1150 get: wasm.exports.sqlite3_wasm_pstack_quota
1158 get: wasm.exports.sqlite3_wasm_pstack_remaining
1167 wasm.exports.sqlite3_randomness(0,0);
1170 const stack = wasm.pstack.pointer;
1173 const r = wasm.exports.sqlite3_randomness;
1174 const heap = wasm.heap8u();
1176 const ptr = wasm.pstack.alloc(nAlloc);
1188 wasm.pstack.restore(stack);
1192 wasm.exports.sqlite3_randomness(...args);
1221 if(pdir && 0===wasm.xCallWrapped(
1247 if(false && 0===wasm.exports.sqlite3_vfs_find(0)){
1250 wasm.exports.sqlite3_initialize();
1301 rc.push(wasm.cstringToJs(oVfs.$zName));
1315 if(!wasm.bigIntEnabled) toss3('BigInt64 support is not enabled.');
1316 const stack = wasm.pstack.pointer;
1319 const pSize = wasm.pstack.alloc(8/*i64*/ + wasm.ptrSizeof);
1328 let rc = wasm.exports.sqlite3_wasm_db_serialize(
1335 pOut = wasm.getPtrValue(ppOut);
1336 const nOut = wasm.getMemValue(pSize, 'i64');
1338 ? wasm.heap8u().slice(pOut, pOut + Number(nOut))
1342 if(pOut) wasm.exports.sqlite3_free(pOut);
1343 wasm.pstack.restore(stack);
1354 (dbPointer, dbName=0)=>wasm.sqlite3_wasm_db_vfs(dbPointer, dbName);
1457 wasm,