mirror of
https://github.com/fluencelabs/assemblyscript
synced 2025-04-25 23:12:19 +00:00
Support indirect calls with omitted arguments
This commit is contained in:
parent
664f2a1c0d
commit
19a616dd96
2
dist/assemblyscript.js
vendored
2
dist/assemblyscript.js
vendored
File diff suppressed because one or more lines are too long
2
dist/assemblyscript.js.map
vendored
2
dist/assemblyscript.js.map
vendored
File diff suppressed because one or more lines are too long
149
src/compiler.ts
149
src/compiler.ts
@ -23,7 +23,8 @@ import {
|
||||
NativeType,
|
||||
FunctionRef,
|
||||
ExpressionId,
|
||||
FunctionTypeRef
|
||||
FunctionTypeRef,
|
||||
GlobalRef
|
||||
} from "./module";
|
||||
|
||||
import {
|
||||
@ -194,29 +195,26 @@ export class Compiler extends DiagnosticEmitter {
|
||||
options: Options;
|
||||
/** Module instance being compiled. */
|
||||
module: Module;
|
||||
|
||||
/** Start function being compiled. */
|
||||
startFunction: Function;
|
||||
/** Start function statements. */
|
||||
startFunctionBody: ExpressionRef[] = [];
|
||||
|
||||
/** Current function in compilation. */
|
||||
currentFunction: Function;
|
||||
/** Current enum in compilation. */
|
||||
currentEnum: Enum | null = null;
|
||||
/** Current type in compilation. */
|
||||
currentType: Type = Type.void;
|
||||
|
||||
/** Start function being compiled. */
|
||||
startFunction: Function;
|
||||
/** Start function statements. */
|
||||
startFunctionBody: ExpressionRef[] = [];
|
||||
/** Counting memory offset. */
|
||||
memoryOffset: I64;
|
||||
/** Memory segments being compiled. */
|
||||
memorySegments: MemorySegment[] = new Array();
|
||||
/** Map of already compiled static string segments. */
|
||||
stringSegments: Map<string,MemorySegment> = new Map();
|
||||
|
||||
/** Function table being compiled. */
|
||||
functionTable: Function[] = new Array();
|
||||
|
||||
/** Argument count helper global. */
|
||||
argumentCountRef: GlobalRef = 0;
|
||||
/** Already processed file names. */
|
||||
files: Set<string> = new Set();
|
||||
|
||||
@ -1192,7 +1190,7 @@ export class Compiler extends DiagnosticEmitter {
|
||||
}
|
||||
var functionTable = this.functionTable;
|
||||
var index = functionTable.length;
|
||||
if (func.signature.requiredParameters < func.signature.parameterTypes.length) {
|
||||
if (!func.is(CommonFlags.TRAMPOLINE) && func.signature.requiredParameters < func.signature.parameterTypes.length) {
|
||||
// insert the trampoline if the function has optional parameters
|
||||
func = this.ensureTrampoline(func);
|
||||
}
|
||||
@ -4314,8 +4312,7 @@ export class Compiler extends DiagnosticEmitter {
|
||||
++minOperands;
|
||||
++maxOperands;
|
||||
}
|
||||
var numOptional = maxOperands - minOperands;
|
||||
assert(numOptional);
|
||||
var numOptional = assert(maxOperands - minOperands);
|
||||
|
||||
var forwardedOperands = new Array<ExpressionRef>(minOperands);
|
||||
var operandIndex = 0;
|
||||
@ -4333,21 +4330,13 @@ export class Compiler extends DiagnosticEmitter {
|
||||
}
|
||||
assert(operandIndex == minOperands);
|
||||
|
||||
// append an additional parameter taking the number of optional arguments provided
|
||||
var trampolineParameterTypes = new Array<Type>(maxArguments + 1);
|
||||
for (let i = 0; i < maxArguments; ++i) {
|
||||
trampolineParameterTypes[i] = originalParameterTypes[i];
|
||||
}
|
||||
trampolineParameterTypes[maxArguments] = Type.i32;
|
||||
|
||||
// create the trampoline element
|
||||
var trampolineSignature = new Signature(trampolineParameterTypes, commonReturnType, commonThisType);
|
||||
var trampolineSignature = new Signature(originalParameterTypes, commonReturnType, commonThisType);
|
||||
var trampolineName = originalName + "|trampoline";
|
||||
trampolineSignature.requiredParameters = maxArguments + 1;
|
||||
trampolineSignature.requiredParameters = maxArguments;
|
||||
trampoline = new Function(original.prototype, trampolineName, trampolineSignature, original.memberOf);
|
||||
trampoline.flags = original.flags;
|
||||
trampoline.set(original.flags | CommonFlags.TRAMPOLINE | CommonFlags.COMPILED);
|
||||
trampoline.contextualTypeArguments = original.contextualTypeArguments;
|
||||
trampoline.set(CommonFlags.COMPILED);
|
||||
original.trampoline = trampoline;
|
||||
|
||||
// compile initializers of omitted arguments in scope of the trampoline function
|
||||
@ -4356,23 +4345,24 @@ export class Compiler extends DiagnosticEmitter {
|
||||
this.currentFunction = trampoline;
|
||||
|
||||
// create a br_table switching over the number of optional parameters provided
|
||||
var numNames = numOptional + 1; // incl. 'with0'
|
||||
var numNames = numOptional + 1; // incl. outer block
|
||||
var names = new Array<string>(numNames);
|
||||
var ofN = "of" + numOptional.toString(10);
|
||||
for (let i = 0; i < numNames; ++i) {
|
||||
let label = "N=" + i.toString();
|
||||
let label = i.toString(10) + ofN;
|
||||
names[i] = label;
|
||||
}
|
||||
var body = module.createBlock(names[0], [
|
||||
module.createBlock("N=invalid", [
|
||||
module.createSwitch(names, "N=invalid",
|
||||
// condition is number of provided optional operands, so subtract required operands
|
||||
minOperands
|
||||
module.createBlock("oob", [
|
||||
module.createSwitch(names, "oob",
|
||||
// condition is number of provided optional arguments, so subtract required arguments
|
||||
minArguments
|
||||
? module.createBinary(
|
||||
BinaryOp.SubI32,
|
||||
module.createGetLocal(maxOperands, NativeType.I32),
|
||||
module.createI32(minOperands)
|
||||
module.createGetGlobal("argumentCount", NativeType.I32),
|
||||
module.createI32(minArguments)
|
||||
)
|
||||
: module.createGetLocal(maxOperands, NativeType.I32)
|
||||
: module.createGetGlobal("argumentCount", NativeType.I32)
|
||||
)
|
||||
]),
|
||||
module.createUnreachable()
|
||||
@ -4409,7 +4399,10 @@ export class Compiler extends DiagnosticEmitter {
|
||||
}
|
||||
|
||||
/** Creates a direct call to the specified function. */
|
||||
makeCallDirect(instance: Function, operands: ExpressionRef[] | null = null): ExpressionRef {
|
||||
makeCallDirect(
|
||||
instance: Function,
|
||||
operands: ExpressionRef[] | null = null
|
||||
): ExpressionRef {
|
||||
var numOperands = operands ? operands.length : 0;
|
||||
var numArguments = numOperands;
|
||||
var minArguments = instance.signature.requiredParameters;
|
||||
@ -4422,27 +4415,39 @@ export class Compiler extends DiagnosticEmitter {
|
||||
--numArguments;
|
||||
}
|
||||
assert(numOperands >= minOperands);
|
||||
|
||||
var module = this.module;
|
||||
if (!this.compileFunction(instance)) return module.createUnreachable();
|
||||
var returnType = instance.signature.returnType;
|
||||
var isCallImport = instance.is(CommonFlags.MODULE_IMPORT);
|
||||
|
||||
// fill up omitted arguments with zeroes
|
||||
if (numOperands < maxOperands) {
|
||||
instance = this.ensureTrampoline(instance);
|
||||
if (!this.compileFunction(instance)) return module.createUnreachable();
|
||||
if (!operands) {
|
||||
operands = new Array(maxOperands + 1);
|
||||
operands = new Array(maxOperands);
|
||||
operands.length = 0;
|
||||
}
|
||||
let parameterTypes = instance.signature.parameterTypes;
|
||||
for (let i = numArguments; i < maxArguments; ++i) {
|
||||
operands.push(instance.signature.parameterTypes[i].toNativeZero(module));
|
||||
operands.push(parameterTypes[i].toNativeZero(module));
|
||||
}
|
||||
if (!isCallImport) { // call the trampoline
|
||||
instance = this.ensureTrampoline(instance);
|
||||
if (!this.compileFunction(instance)) return module.createUnreachable();
|
||||
let nativeReturnType = returnType.toNativeType();
|
||||
this.currentType = returnType;
|
||||
return module.createBlock(null, [
|
||||
this.ensureArgumentCount(numArguments),
|
||||
module.createCall(instance.internalName, operands, nativeReturnType)
|
||||
], nativeReturnType);
|
||||
}
|
||||
operands.push(module.createI32(numOperands)); // actual number of provided operands
|
||||
}
|
||||
var returnType = instance.signature.returnType;
|
||||
|
||||
// otherwise just call through
|
||||
this.currentType = returnType;
|
||||
if (instance.is(CommonFlags.MODULE_IMPORT)) {
|
||||
return module.createCallImport(instance.internalName, operands, returnType.toNativeType());
|
||||
} else {
|
||||
return module.createCall(instance.internalName, operands, returnType.toNativeType());
|
||||
}
|
||||
return isCallImport
|
||||
? module.createCallImport(instance.internalName, operands, returnType.toNativeType())
|
||||
: module.createCall(instance.internalName, operands, returnType.toNativeType());
|
||||
}
|
||||
|
||||
/** Compiles an indirect call using an index argument and a signature. */
|
||||
@ -4483,11 +4488,59 @@ export class Compiler extends DiagnosticEmitter {
|
||||
}
|
||||
|
||||
/** Creates an indirect call to the function at `indexArg` in the function table. */
|
||||
makeCallIndirect(signature: Signature, indexArg: ExpressionRef, operands: ExpressionRef[]): ExpressionRef {
|
||||
makeCallIndirect(
|
||||
signature: Signature,
|
||||
indexArg: ExpressionRef,
|
||||
operands: ExpressionRef[] | null = null
|
||||
): ExpressionRef {
|
||||
var numOperands = operands ? operands.length : 0;
|
||||
var numArguments = numOperands;
|
||||
var minArguments = signature.requiredParameters;
|
||||
var minOperands = minArguments;
|
||||
var maxArguments = signature.parameterTypes.length;
|
||||
var maxOperands = maxArguments;
|
||||
if (signature.thisType) {
|
||||
++minOperands;
|
||||
++maxOperands;
|
||||
--numArguments;
|
||||
}
|
||||
assert(numOperands >= minOperands);
|
||||
|
||||
this.ensureFunctionType(signature);
|
||||
var module = this.module;
|
||||
|
||||
// fill up omitted arguments with zeroes
|
||||
if (numOperands < maxOperands) {
|
||||
if (!operands) {
|
||||
operands = new Array(maxOperands);
|
||||
operands.length = 0;
|
||||
}
|
||||
let parameterTypes = signature.parameterTypes;
|
||||
for (let i = numArguments; i < maxArguments; ++i) {
|
||||
operands.push(parameterTypes[i].toNativeZero(module));
|
||||
}
|
||||
}
|
||||
|
||||
var returnType = signature.returnType;
|
||||
this.currentType = returnType;
|
||||
this.ensureFunctionType(signature);
|
||||
return this.module.createCallIndirect(indexArg, operands, signature.toSignatureString());
|
||||
return module.createBlock(null, [
|
||||
this.ensureArgumentCount(numArguments), // might still be calling a trampoline
|
||||
module.createCallIndirect(indexArg, operands, signature.toSignatureString())
|
||||
], returnType.toNativeType());
|
||||
}
|
||||
|
||||
/** Makes sure that the `argumentCount` helper global is present and returns an expression that sets it. */
|
||||
private ensureArgumentCount(argumentCount: i32): ExpressionRef {
|
||||
var module = this.module;
|
||||
if (!this.argumentCountRef) {
|
||||
this.argumentCountRef = module.addGlobal(
|
||||
"argumentCount",
|
||||
NativeType.I32,
|
||||
true,
|
||||
module.createI32(0)
|
||||
);
|
||||
}
|
||||
return module.createSetGlobal("argumentCount", module.createI32(argumentCount));
|
||||
}
|
||||
|
||||
compileCommaExpression(expression: CommaExpression, contextualType: Type): ExpressionRef {
|
||||
|
@ -2070,7 +2070,9 @@ export enum CommonFlags {
|
||||
/** Has a constant value and is therefore inlined. */
|
||||
INLINED = 1 << 26,
|
||||
/** Is scoped. */
|
||||
SCOPED = 1 << 27
|
||||
SCOPED = 1 << 27,
|
||||
/** Is a trampoline. */
|
||||
TRAMPOLINE = 1 << 28
|
||||
}
|
||||
|
||||
/** Base class of all program elements. */
|
||||
|
@ -1,12 +1,16 @@
|
||||
(module
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $iiiiv (func (param i32 i32 i32 i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $call-optional/optIndirect (mut i32) (i32.const 0))
|
||||
(table 1 1 anyfunc)
|
||||
(elem (i32.const 0) $call-optional/opt|trampoline)
|
||||
(memory $0 1)
|
||||
(data (i32.const 4) "\10\00\00\00c\00a\00l\00l\00-\00o\00p\00t\00i\00o\00n\00a\00l\00.\00t\00s")
|
||||
(export "memory" (memory $0))
|
||||
(export "table" (table $0))
|
||||
(start $start)
|
||||
(func $call-optional/opt (; 1 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(i32.add
|
||||
@ -17,14 +21,14 @@
|
||||
(get_local $2)
|
||||
)
|
||||
)
|
||||
(func $call-optional/opt|trampoline (; 2 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=2
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=2 $N=invalid
|
||||
(func $call-optional/opt|trampoline (; 2 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $2of2
|
||||
(block $1of2
|
||||
(block $0of2
|
||||
(block $oob
|
||||
(br_table $0of2 $1of2 $2of2 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
@ -47,11 +51,15 @@
|
||||
)
|
||||
(func $start (; 3 ;) (type $v)
|
||||
(if
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -64,14 +72,18 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(i32.const 5)
|
||||
(i32.ne
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 0)
|
||||
)
|
||||
(i32.const 5)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -102,5 +114,77 @@
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call_indirect (type $iiii)
|
||||
(i32.const 3)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
(get_global $call-optional/optIndirect)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 9)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(i32.ne
|
||||
(call_indirect (type $iiii)
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 0)
|
||||
(get_global $call-optional/optIndirect)
|
||||
)
|
||||
(i32.const 5)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 10)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 3)
|
||||
)
|
||||
(i32.ne
|
||||
(call_indirect (type $iiii)
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 5)
|
||||
(get_global $call-optional/optIndirect)
|
||||
)
|
||||
(i32.const 12)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 11)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
@ -1,6 +1,11 @@
|
||||
function opt(a: i32, b: i32 = -1, c: i32 = -2): i32 {
|
||||
return a + b + c;
|
||||
}
|
||||
assert(opt(3) == 0); // calls the trampoline with N=0
|
||||
assert(opt(3, 4) == 5); // calls the trampoline with N=1
|
||||
assert(opt(3) == 0); // calls the trampoline with 0of2
|
||||
assert(opt(3, 4) == 5); // calls the trampoline with 1of2
|
||||
assert(opt(3, 4, 5) == 12); // calls the function directly
|
||||
|
||||
var optIndirect = opt;
|
||||
assert(optIndirect(3) == 0); // calls the trampoline indirectly with 0of2
|
||||
assert(optIndirect(3, 4) == 5); // calls the trampoline indirectly with 1of2
|
||||
assert(optIndirect(3, 4, 5) == 12); // calls the trampoline indirectly with 2of2
|
||||
|
@ -1,13 +1,17 @@
|
||||
(module
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $iiiiv (func (param i32 i32 i32 i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $call-optional/optIndirect (mut i32) (i32.const 0))
|
||||
(global $HEAP_BASE i32 (i32.const 40))
|
||||
(table 1 1 anyfunc)
|
||||
(elem (i32.const 0) $call-optional/opt|trampoline)
|
||||
(memory $0 1)
|
||||
(data (i32.const 4) "\10\00\00\00c\00a\00l\00l\00-\00o\00p\00t\00i\00o\00n\00a\00l\00.\00t\00s\00")
|
||||
(export "memory" (memory $0))
|
||||
(export "table" (table $0))
|
||||
(start $start)
|
||||
(func $call-optional/opt (; 1 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(return
|
||||
@ -20,14 +24,14 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func $call-optional/opt|trampoline (; 2 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=2
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=2 $N=invalid
|
||||
(func $call-optional/opt|trampoline (; 2 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $2of2
|
||||
(block $1of2
|
||||
(block $0of2
|
||||
(block $oob
|
||||
(br_table $0of2 $1of2 $2of2 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
@ -52,11 +56,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(i32.const 0)
|
||||
)
|
||||
@ -74,11 +82,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call $call-optional/opt|trampoline
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(i32.const 5)
|
||||
)
|
||||
@ -114,5 +126,86 @@
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call_indirect (type $iiii)
|
||||
(i32.const 3)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
(get_global $call-optional/optIndirect)
|
||||
)
|
||||
)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 9)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $iiii)
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 0)
|
||||
(get_global $call-optional/optIndirect)
|
||||
)
|
||||
)
|
||||
(i32.const 5)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 10)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 3)
|
||||
)
|
||||
(call_indirect (type $iiii)
|
||||
(i32.const 3)
|
||||
(i32.const 4)
|
||||
(i32.const 5)
|
||||
(get_global $call-optional/optIndirect)
|
||||
)
|
||||
)
|
||||
(i32.const 12)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 11)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
@ -5,6 +5,7 @@
|
||||
(type $i (func (result i32)))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global $function-expression/f1 (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $function-expression/f2 (mut i32) (i32.const 1))
|
||||
(global $function-expression/f3 (mut i32) (i32.const 2))
|
||||
(global $function-expression/f4 (mut i32) (i32.const 3))
|
||||
@ -26,12 +27,17 @@
|
||||
)
|
||||
(func $start (; 4 ;) (type $v)
|
||||
(if
|
||||
(i32.ne
|
||||
(call_indirect (type $ii)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.ne
|
||||
(call_indirect (type $ii)
|
||||
(i32.const 1)
|
||||
(get_global $function-expression/f1)
|
||||
)
|
||||
(i32.const 1)
|
||||
(get_global $function-expression/f1)
|
||||
)
|
||||
(i32.const 1)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -44,12 +50,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call_indirect (type $ii)
|
||||
(i32.const 2)
|
||||
(get_global $function-expression/f2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.ne
|
||||
(call_indirect (type $ii)
|
||||
(i32.const 2)
|
||||
(get_global $function-expression/f2)
|
||||
)
|
||||
(i32.const 2)
|
||||
)
|
||||
(i32.const 2)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -61,15 +72,23 @@
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(set_global $argumentCount
|
||||
(i32.const 0)
|
||||
)
|
||||
(call_indirect (type $v)
|
||||
(get_global $function-expression/f3)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call_indirect (type $i)
|
||||
(get_global $function-expression/f4)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 0)
|
||||
)
|
||||
(i32.ne
|
||||
(call_indirect (type $i)
|
||||
(get_global $function-expression/f4)
|
||||
)
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.const 1)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
|
@ -5,6 +5,7 @@
|
||||
(type $i (func (result i32)))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global $function-expression/f1 (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $function-expression/f2 (mut i32) (i32.const 1))
|
||||
(global $function-expression/f3 (mut i32) (i32.const 2))
|
||||
(global $function-expression/f4 (mut i32) (i32.const 3))
|
||||
@ -35,9 +36,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call_indirect (type $ii)
|
||||
(i32.const 1)
|
||||
(get_global $function-expression/f1)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call_indirect (type $ii)
|
||||
(i32.const 1)
|
||||
(get_global $function-expression/f1)
|
||||
)
|
||||
)
|
||||
(i32.const 1)
|
||||
)
|
||||
@ -55,9 +61,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call_indirect (type $ii)
|
||||
(i32.const 2)
|
||||
(get_global $function-expression/f2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call_indirect (type $ii)
|
||||
(i32.const 2)
|
||||
(get_global $function-expression/f2)
|
||||
)
|
||||
)
|
||||
(i32.const 2)
|
||||
)
|
||||
@ -72,14 +83,24 @@
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(call_indirect (type $v)
|
||||
(get_global $function-expression/f3)
|
||||
(block
|
||||
(set_global $argumentCount
|
||||
(i32.const 0)
|
||||
)
|
||||
(call_indirect (type $v)
|
||||
(get_global $function-expression/f3)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call_indirect (type $i)
|
||||
(get_global $function-expression/f4)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 0)
|
||||
)
|
||||
(call_indirect (type $i)
|
||||
(get_global $function-expression/f4)
|
||||
)
|
||||
)
|
||||
(i32.const 1)
|
||||
)
|
||||
|
@ -5,10 +5,10 @@
|
||||
(type $III (func (param i64 i64) (result i64)))
|
||||
(type $FFF (func (param f64 f64) (result f64)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global $function-types/i32Adder (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $function-types/i64Adder (mut i32) (i32.const 0))
|
||||
(table 4 4 anyfunc)
|
||||
(elem (i32.const 0) $function-types/makeAdder<i32>~anonymous|0 $function-types/makeAdder<i64>~anonymous|1 $function-types/makeAdder<f64>~anonymous|2 $function-types/makeAdder<i32>~anonymous|0)
|
||||
@ -45,6 +45,9 @@
|
||||
(i32.const 2)
|
||||
)
|
||||
(func $function-types/doAddWithFn<i32> (; 7 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
@ -52,19 +55,22 @@
|
||||
)
|
||||
)
|
||||
(func $function-types/doAdd<i32> (; 8 ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
(call $function-types/makeAdder<i32>)
|
||||
)
|
||||
)
|
||||
(func $function-types/makeAndAdd<i32>|trampoline (; 9 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func $function-types/makeAndAdd<i32>|trampoline (; 9 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 2)
|
||||
)
|
||||
)
|
||||
@ -86,13 +92,18 @@
|
||||
(call $function-types/makeAdder<i32>)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call_indirect (type $iii)
|
||||
(i32.const 1)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
(get_global $function-types/i32Adder)
|
||||
)
|
||||
(i32.const 3)
|
||||
(i32.ne
|
||||
(call_indirect (type $iii)
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(get_global $function-types/i32Adder)
|
||||
)
|
||||
(i32.const 3)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -108,13 +119,18 @@
|
||||
(call $function-types/makeAdder<i64>)
|
||||
)
|
||||
(if
|
||||
(i64.ne
|
||||
(call_indirect (type $III)
|
||||
(i64.const 10)
|
||||
(i64.const 20)
|
||||
(get_global $function-types/i64Adder)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(i64.ne
|
||||
(call_indirect (type $III)
|
||||
(i64.const 10)
|
||||
(i64.const 20)
|
||||
(get_global $function-types/i64Adder)
|
||||
)
|
||||
(i64.const 30)
|
||||
)
|
||||
(i64.const 30)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -127,13 +143,18 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call_indirect (type $FFF)
|
||||
(f64.const 1.5)
|
||||
(f64.const 2.5)
|
||||
(call $function-types/makeAdder<f64>)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(f64.ne
|
||||
(call_indirect (type $FFF)
|
||||
(f64.const 1.5)
|
||||
(f64.const 2.5)
|
||||
(call $function-types/makeAdder<f64>)
|
||||
)
|
||||
(f64.const 4)
|
||||
)
|
||||
(f64.const 4)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -202,14 +223,18 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call $function-types/makeAndAdd<i32>|trampoline
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(i32.const 3)
|
||||
(i32.ne
|
||||
(call $function-types/makeAndAdd<i32>|trampoline
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(i32.const 0)
|
||||
)
|
||||
(i32.const 3)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -221,5 +246,24 @@
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call $function-types/doAddWithFn<i32>
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(call $function-types/makeAdder<i32>)
|
||||
)
|
||||
(i32.const 3)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
@ -39,3 +39,4 @@ function makeAndAdd<T>(a: T, b: T, adder: Adder<T> = makeAdder<T>()): T {
|
||||
}
|
||||
|
||||
assert(makeAndAdd<i32>(1, 2) == 3);
|
||||
assert(makeAndAdd<i32>(1, 2, makeAdder<i32>()) == 3);
|
||||
|
@ -5,10 +5,10 @@
|
||||
(type $III (func (param i64 i64) (result i64)))
|
||||
(type $FFF (func (param f64 f64) (result f64)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global $function-types/i32Adder (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $function-types/i64Adder (mut i32) (i32.const 0))
|
||||
(global $HEAP_BASE i32 (i32.const 44))
|
||||
(table 4 4 anyfunc)
|
||||
@ -59,19 +59,29 @@
|
||||
)
|
||||
(func $function-types/doAddWithFn<i32> (; 7 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(return
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
(get_local $2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
(get_local $2)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(func $function-types/doAdd<i32> (; 8 ;) (type $iii) (param $0 i32) (param $1 i32) (result i32)
|
||||
(return
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
(call $function-types/makeAdder<i32>)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
(call $function-types/makeAdder<i32>)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -85,20 +95,25 @@
|
||||
)
|
||||
(func $function-types/makeAndAdd<i32> (; 10 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(return
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
(get_local $2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $iii)
|
||||
(get_local $0)
|
||||
(get_local $1)
|
||||
(get_local $2)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
(func $function-types/makeAndAdd<i32>|trampoline (; 11 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func $function-types/makeAndAdd<i32>|trampoline (; 11 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 2)
|
||||
)
|
||||
)
|
||||
@ -123,10 +138,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call_indirect (type $iii)
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(get_global $function-types/i32Adder)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $iii)
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(get_global $function-types/i32Adder)
|
||||
)
|
||||
)
|
||||
(i32.const 3)
|
||||
)
|
||||
@ -147,10 +167,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i64.eq
|
||||
(call_indirect (type $III)
|
||||
(i64.const 10)
|
||||
(i64.const 20)
|
||||
(get_global $function-types/i64Adder)
|
||||
(block (result i64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $III)
|
||||
(i64.const 10)
|
||||
(i64.const 20)
|
||||
(get_global $function-types/i64Adder)
|
||||
)
|
||||
)
|
||||
(i64.const 30)
|
||||
)
|
||||
@ -168,10 +193,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call_indirect (type $FFF)
|
||||
(f64.const 1.5)
|
||||
(f64.const 2.5)
|
||||
(call $function-types/makeAdder<f64>)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call_indirect (type $FFF)
|
||||
(f64.const 1.5)
|
||||
(f64.const 2.5)
|
||||
(call $function-types/makeAdder<f64>)
|
||||
)
|
||||
)
|
||||
(f64.const 4)
|
||||
)
|
||||
@ -251,11 +281,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call $function-types/makeAndAdd<i32>|trampoline
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 2)
|
||||
)
|
||||
(call $function-types/makeAndAdd<i32>|trampoline
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(i32.const 3)
|
||||
)
|
||||
@ -270,5 +304,26 @@
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call $function-types/makeAndAdd<i32>
|
||||
(i32.const 1)
|
||||
(i32.const 2)
|
||||
(call $function-types/makeAdder<i32>)
|
||||
)
|
||||
(i32.const 3)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
(i32.const 0)
|
||||
(i32.const 4)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
(unreachable)
|
||||
)
|
||||
)
|
||||
)
|
||||
)
|
||||
|
@ -6,13 +6,13 @@
|
||||
(type $iiiv (func (param i32 i32 i32)))
|
||||
(type $iv (func (param i32)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global "$(lib)/allocator/arena/startOffset" (mut i32) (i32.const 0))
|
||||
(global "$(lib)/allocator/arena/offset" (mut i32) (i32.const 0))
|
||||
(global $std/array/arr (mut i32) (i32.const 0))
|
||||
(global $std/array/i (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $std/array/includes (mut i32) (i32.const 0))
|
||||
(global $HEAP_BASE i32 (i32.const 64))
|
||||
(memory $0 1)
|
||||
@ -2839,14 +2839,14 @@
|
||||
)
|
||||
(i32.const -1)
|
||||
)
|
||||
(func "$(lib)/array/Array<i32>#indexOf|trampoline" (; 15 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/array/Array<i32>#indexOf|trampoline" (; 15 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -2950,14 +2950,14 @@
|
||||
)
|
||||
(i32.const 0)
|
||||
)
|
||||
(func "$(lib)/array/Array<i32>#includes|trampoline" (; 17 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/array/Array<i32>#includes|trampoline" (; 17 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -4039,11 +4039,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/i
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4059,11 +4063,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/i
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4082,11 +4090,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/i
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4259,11 +4271,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/includes
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4282,11 +4298,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/includes
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4305,11 +4325,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/includes
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
|
@ -7,7 +7,6 @@
|
||||
(type $iiiv (func (param i32 i32 i32)))
|
||||
(type $iv (func (param i32)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global "$(lib)/allocator/common/alignment/BITS" i32 (i32.const 3))
|
||||
@ -17,6 +16,7 @@
|
||||
(global "$(lib)/allocator/arena/offset" (mut i32) (i32.const 0))
|
||||
(global $std/array/arr (mut i32) (i32.const 0))
|
||||
(global $std/array/i (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $std/array/includes (mut i32) (i32.const 0))
|
||||
(global $HEAP_BASE i32 (i32.const 64))
|
||||
(memory $0 1)
|
||||
@ -3187,14 +3187,14 @@
|
||||
(i32.const -1)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/array/Array<i32>#indexOf|trampoline" (; 15 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/array/Array<i32>#indexOf|trampoline" (; 15 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -3308,14 +3308,14 @@
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/array/Array<i32>#includes|trampoline" (; 17 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/array/Array<i32>#includes|trampoline" (; 17 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -4525,11 +4525,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/i
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4550,11 +4554,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/i
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4575,11 +4583,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/i
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#indexOf|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4768,11 +4780,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/includes
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 44)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4793,11 +4809,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/includes
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -4818,11 +4838,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/array/includes
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/array/Array<i32>#includes|trampoline"
|
||||
(get_global $std/array/arr)
|
||||
(i32.const 45)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
|
@ -4,13 +4,13 @@
|
||||
(type $iiiiv (func (param i32 i32 i32 i32)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiv (func (param i32 i32 i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global "$(lib)/allocator/arena/startOffset" (mut i32) (i32.const 0))
|
||||
(global "$(lib)/allocator/arena/offset" (mut i32) (i32.const 0))
|
||||
(global $std/arraybuffer/buffer (mut i32) (i32.const 0))
|
||||
(global "$(lib)/arraybuffer/ArrayBuffer.EMPTY" (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $std/arraybuffer/sliced (mut i32) (i32.const 0))
|
||||
(global $HEAP_BASE i32 (i32.const 44))
|
||||
(memory $0 1)
|
||||
@ -2129,16 +2129,13 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline" (; 6 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=2
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=2 $N=invalid
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 1)
|
||||
)
|
||||
(func "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline" (; 6 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $2of2
|
||||
(block $1of2
|
||||
(block $0of2
|
||||
(block $oob
|
||||
(br_table $0of2 $1of2 $2of2 $oob
|
||||
(get_global $argumentCount)
|
||||
)
|
||||
)
|
||||
(unreachable)
|
||||
@ -2194,11 +2191,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 0)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -2234,11 +2235,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 1)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 1)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -2259,11 +2264,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const -1)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const -1)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -2380,11 +2389,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
|
@ -5,7 +5,6 @@
|
||||
(type $iiiiv (func (param i32 i32 i32 i32)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiv (func (param i32 i32 i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $v (func))
|
||||
(import "env" "abort" (func $abort (param i32 i32 i32 i32)))
|
||||
(global "$(lib)/allocator/common/alignment/BITS" i32 (i32.const 3))
|
||||
@ -16,6 +15,7 @@
|
||||
(global "$(lib)/arraybuffer/HEADER_SIZE" i32 (i32.const 4))
|
||||
(global $std/arraybuffer/buffer (mut i32) (i32.const 0))
|
||||
(global "$(lib)/arraybuffer/ArrayBuffer.EMPTY" (mut i32) (i32.const 0))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $std/arraybuffer/sliced (mut i32) (i32.const 0))
|
||||
(global $HEAP_BASE i32 (i32.const 44))
|
||||
(memory $0 1)
|
||||
@ -2435,16 +2435,13 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline" (; 6 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=2
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=2 $N=invalid
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 1)
|
||||
)
|
||||
(func "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline" (; 6 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $2of2
|
||||
(block $1of2
|
||||
(block $0of2
|
||||
(block $oob
|
||||
(br_table $0of2 $1of2 $2of2 $oob
|
||||
(get_global $argumentCount)
|
||||
)
|
||||
)
|
||||
(unreachable)
|
||||
@ -2505,11 +2502,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 0)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 0)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -2549,11 +2550,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 1)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 1)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -2576,11 +2581,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const -1)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const -1)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
@ -2707,11 +2716,15 @@
|
||||
)
|
||||
)
|
||||
(set_global $std/arraybuffer/sliced
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/arraybuffer/ArrayBuffer#slice|trampoline"
|
||||
(get_global $std/arraybuffer/buffer)
|
||||
(i32.const 42)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(if
|
||||
|
@ -3,9 +3,7 @@
|
||||
(type $iiiiv (func (param i32 i32 i32 i32)))
|
||||
(type $iii (func (param i32 i32) (result i32)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $iiF (func (param i32 i32) (result f64)))
|
||||
(type $iiiF (func (param i32 i32 i32) (result f64)))
|
||||
(type $iF (func (param i32) (result f64)))
|
||||
(type $ii (func (param i32) (result i32)))
|
||||
(type $iiiv (func (param i32 i32 i32)))
|
||||
@ -14,6 +12,7 @@
|
||||
(global "$(lib)/allocator/arena/startOffset" (mut i32) (i32.const 0))
|
||||
(global "$(lib)/allocator/arena/offset" (mut i32) (i32.const 0))
|
||||
(global $std/string/str (mut i32) (i32.const 4))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global $std/string/c (mut i32) (i32.const 0))
|
||||
(global $HEAP_BASE i32 (i32.const 348))
|
||||
(memory $0 1)
|
||||
@ -279,14 +278,14 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#startsWith|trampoline" (; 5 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#startsWith|trampoline" (; 5 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -388,14 +387,14 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#endsWith|trampoline" (; 7 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#endsWith|trampoline" (; 7 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -527,14 +526,14 @@
|
||||
(i32.const -1)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#includes|trampoline" (; 10 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#includes|trampoline" (; 10 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -550,14 +549,14 @@
|
||||
(get_local $2)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#indexOf|trampoline" (; 11 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#indexOf|trampoline" (; 11 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -947,13 +946,13 @@
|
||||
(get_local $1)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/parseInt|trampoline" (; 15 ;) (type $iiiF) (param $0 i32) (param $1 i32) (param $2 i32) (result f64)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/parseInt|trampoline" (; 15 ;) (type $iiF) (param $0 i32) (param $1 i32) (result f64)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
@ -3368,12 +3367,16 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#startsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 108)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#startsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 108)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(block
|
||||
@ -3387,12 +3390,16 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#endsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 128)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#endsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 128)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(block
|
||||
@ -3406,12 +3413,16 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#includes|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 144)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#includes|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 144)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(block
|
||||
@ -3425,14 +3436,18 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 156)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.ne
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 156)
|
||||
(i32.const 0)
|
||||
)
|
||||
(i32.const 2)
|
||||
)
|
||||
(i32.const 2)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3445,14 +3460,18 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(i32.ne
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 164)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(i32.ne
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 164)
|
||||
(i32.const 0)
|
||||
)
|
||||
(i32.const -1)
|
||||
)
|
||||
(i32.const -1)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3465,13 +3484,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 172)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 0)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 172)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 0)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3484,13 +3507,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 180)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 1)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 180)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 1)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3503,13 +3530,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 188)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 5)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 188)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 5)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3522,13 +3553,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 204)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 455)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 204)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 455)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3541,13 +3576,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 220)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 3855)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 220)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 3855)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3560,13 +3599,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 236)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 3855)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 236)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 3855)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3579,13 +3622,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 252)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 11)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 252)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 11)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
@ -3598,13 +3645,17 @@
|
||||
)
|
||||
)
|
||||
(if
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 264)
|
||||
(i32.const 0)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(f64.const 1)
|
||||
(f64.ne
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 264)
|
||||
(i32.const 0)
|
||||
)
|
||||
(f64.const 1)
|
||||
)
|
||||
)
|
||||
(block
|
||||
(call $abort
|
||||
|
@ -3,9 +3,7 @@
|
||||
(type $iiiiv (func (param i32 i32 i32 i32)))
|
||||
(type $iii (func (param i32 i32) (result i32)))
|
||||
(type $iiii (func (param i32 i32 i32) (result i32)))
|
||||
(type $iiiii (func (param i32 i32 i32 i32) (result i32)))
|
||||
(type $iiF (func (param i32 i32) (result f64)))
|
||||
(type $iiiF (func (param i32 i32 i32) (result f64)))
|
||||
(type $iF (func (param i32) (result f64)))
|
||||
(type $ii (func (param i32) (result i32)))
|
||||
(type $iiiv (func (param i32 i32 i32)))
|
||||
@ -18,6 +16,7 @@
|
||||
(global "$(lib)/allocator/arena/offset" (mut i32) (i32.const 0))
|
||||
(global $std/string/str (mut i32) (i32.const 4))
|
||||
(global "$(lib)/string/HEADER_SIZE" i32 (i32.const 4))
|
||||
(global $argumentCount (mut i32) (i32.const 0))
|
||||
(global "$(lib)/string/CharCode.PLUS" i32 (i32.const 43))
|
||||
(global "$(lib)/string/CharCode.MINUS" i32 (i32.const 45))
|
||||
(global "$(lib)/string/CharCode.DOT" i32 (i32.const 46))
|
||||
@ -344,14 +343,14 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#startsWith|trampoline" (; 5 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#startsWith|trampoline" (; 5 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -471,14 +470,14 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#endsWith|trampoline" (; 7 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#endsWith|trampoline" (; 7 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -635,14 +634,14 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#includes|trampoline" (; 10 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#includes|trampoline" (; 10 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -658,14 +657,14 @@
|
||||
(get_local $2)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/String#indexOf|trampoline" (; 11 ;) (type $iiiii) (param $0 i32) (param $1 i32) (param $2 i32) (param $3 i32) (result i32)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/String#indexOf|trampoline" (; 11 ;) (type $iiii) (param $0 i32) (param $1 i32) (param $2 i32) (result i32)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $3)
|
||||
(i32.const 2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
)
|
||||
@ -1104,13 +1103,13 @@
|
||||
)
|
||||
)
|
||||
)
|
||||
(func "$(lib)/string/parseInt|trampoline" (; 15 ;) (type $iiiF) (param $0 i32) (param $1 i32) (param $2 i32) (result f64)
|
||||
(block $N=1
|
||||
(block $N=0
|
||||
(block $N=invalid
|
||||
(br_table $N=0 $N=1 $N=invalid
|
||||
(func "$(lib)/string/parseInt|trampoline" (; 15 ;) (type $iiF) (param $0 i32) (param $1 i32) (result f64)
|
||||
(block $1of1
|
||||
(block $0of1
|
||||
(block $oob
|
||||
(br_table $0of1 $1of1 $oob
|
||||
(i32.sub
|
||||
(get_local $2)
|
||||
(get_global $argumentCount)
|
||||
(i32.const 1)
|
||||
)
|
||||
)
|
||||
@ -3865,11 +3864,15 @@
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#startsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 108)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/String#startsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 108)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(block
|
||||
@ -3884,11 +3887,15 @@
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#endsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 128)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/String#endsWith|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 128)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(block
|
||||
@ -3903,11 +3910,15 @@
|
||||
)
|
||||
(if
|
||||
(i32.eqz
|
||||
(call "$(lib)/string/String#includes|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 144)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/String#includes|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 144)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
)
|
||||
(block
|
||||
@ -3923,11 +3934,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 156)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 156)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(i32.const 2)
|
||||
)
|
||||
@ -3945,11 +3960,15 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(i32.eq
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 164)
|
||||
(i32.const 0)
|
||||
(i32.const 2)
|
||||
(block (result i32)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/String#indexOf|trampoline"
|
||||
(get_global $std/string/str)
|
||||
(i32.const 164)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(i32.const -1)
|
||||
)
|
||||
@ -3967,10 +3986,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 172)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 172)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 0)
|
||||
)
|
||||
@ -3988,10 +4011,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 180)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 180)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 1)
|
||||
)
|
||||
@ -4009,10 +4036,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 188)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 188)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 5)
|
||||
)
|
||||
@ -4030,10 +4061,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 204)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 204)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 455)
|
||||
)
|
||||
@ -4051,10 +4086,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 220)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 220)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 3855)
|
||||
)
|
||||
@ -4072,10 +4111,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 236)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 236)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 3855)
|
||||
)
|
||||
@ -4093,10 +4136,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 252)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 252)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 11)
|
||||
)
|
||||
@ -4114,10 +4161,14 @@
|
||||
(if
|
||||
(i32.eqz
|
||||
(f64.eq
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 264)
|
||||
(i32.const 0)
|
||||
(i32.const 1)
|
||||
(block (result f64)
|
||||
(set_global $argumentCount
|
||||
(i32.const 1)
|
||||
)
|
||||
(call "$(lib)/string/parseInt|trampoline"
|
||||
(i32.const 264)
|
||||
(i32.const 0)
|
||||
)
|
||||
)
|
||||
(f64.const 1)
|
||||
)
|
||||
|
Loading…
x
Reference in New Issue
Block a user