mirror of
https://github.com/fluencelabs/assemblyscript
synced 2025-06-22 11:11:43 +00:00
more consistent naming, move libm
This commit is contained in:
@ -145,7 +145,7 @@
|
||||
if
|
||||
i32.const 0
|
||||
i32.const 256
|
||||
i32.const 171
|
||||
i32.const 172
|
||||
i32.const 4
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
|
@ -253,7 +253,6 @@
|
||||
(local $5 i32)
|
||||
(local $6 i32)
|
||||
(local $7 i32)
|
||||
(local $8 i32)
|
||||
local.get $1
|
||||
call $~lib/rt/stub/__retain
|
||||
drop
|
||||
@ -264,7 +263,7 @@
|
||||
if
|
||||
i32.const 0
|
||||
i32.const 256
|
||||
i32.const 171
|
||||
i32.const 172
|
||||
i32.const 4
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -290,12 +289,10 @@
|
||||
end
|
||||
local.set $1
|
||||
end
|
||||
local.get $2
|
||||
local.set $5
|
||||
local.get $0
|
||||
call $~lib/string/String#get:length
|
||||
local.set $6
|
||||
local.get $5
|
||||
local.set $5
|
||||
local.get $2
|
||||
local.tee $3
|
||||
i32.const 0
|
||||
local.tee $4
|
||||
@ -304,20 +301,20 @@
|
||||
i32.gt_s
|
||||
select
|
||||
local.tee $3
|
||||
local.get $6
|
||||
local.get $5
|
||||
local.tee $4
|
||||
local.get $3
|
||||
local.get $4
|
||||
i32.lt_s
|
||||
select
|
||||
local.set $7
|
||||
local.set $6
|
||||
local.get $1
|
||||
call $~lib/string/String#get:length
|
||||
local.set $8
|
||||
local.get $8
|
||||
local.set $7
|
||||
local.get $7
|
||||
i32.add
|
||||
local.get $6
|
||||
i32.add
|
||||
local.get $5
|
||||
i32.gt_s
|
||||
if
|
||||
i32.const 0
|
||||
@ -328,10 +325,10 @@
|
||||
return
|
||||
end
|
||||
local.get $0
|
||||
local.get $7
|
||||
local.get $6
|
||||
local.get $1
|
||||
i32.const 0
|
||||
local.get $8
|
||||
local.get $7
|
||||
call $~lib/util/string/compareImpl
|
||||
i32.eqz
|
||||
local.set $3
|
||||
|
@ -4417,7 +4417,7 @@
|
||||
if
|
||||
i32.const 0
|
||||
i32.const 3160
|
||||
i32.const 1021
|
||||
i32.const 1020
|
||||
i32.const 4
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -5970,7 +5970,7 @@
|
||||
if
|
||||
i32.const 3936
|
||||
i32.const 3160
|
||||
i32.const 1030
|
||||
i32.const 1029
|
||||
i32.const 24
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
|
@ -7105,7 +7105,7 @@
|
||||
if
|
||||
i32.const 0
|
||||
i32.const 3160
|
||||
i32.const 1021
|
||||
i32.const 1020
|
||||
i32.const 4
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -9460,7 +9460,7 @@
|
||||
if
|
||||
i32.const 3936
|
||||
i32.const 3160
|
||||
i32.const 1030
|
||||
i32.const 1029
|
||||
i32.const 24
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -11392,7 +11392,7 @@
|
||||
if
|
||||
i32.const 0
|
||||
i32.const 4360
|
||||
i32.const 40
|
||||
i32.const 46
|
||||
i32.const 4
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1,144 +1,3 @@
|
||||
export const E = Math.E;
|
||||
export const LN10 = Math.LN10;
|
||||
export const LN2 = Math.LN2;
|
||||
export const LOG10E = Math.LOG10E;
|
||||
export const LOG2E = Math.LOG2E;
|
||||
export const PI = Math.PI;
|
||||
export const SQRT1_2 = Math.SQRT1_2;
|
||||
export const SQRT2 = Math.SQRT2;
|
||||
|
||||
export function abs(x: f64): f64 {
|
||||
return Math.abs(x);
|
||||
}
|
||||
|
||||
export function acos(x: f64): f64 {
|
||||
return Math.acos(x);
|
||||
}
|
||||
|
||||
export function acosh(x: f64): f64 {
|
||||
return Math.acosh(x);
|
||||
}
|
||||
|
||||
export function asin(x: f64): f64 {
|
||||
return Math.asin(x);
|
||||
}
|
||||
|
||||
export function asinh(x: f64): f64 {
|
||||
return Math.asinh(x);
|
||||
}
|
||||
|
||||
export function atan(x: f64): f64 {
|
||||
return Math.atan(x);
|
||||
}
|
||||
|
||||
export function atanh(x: f64): f64 {
|
||||
return Math.atanh(x);
|
||||
}
|
||||
|
||||
export function atan2(y: f64, x: f64): f64 {
|
||||
return Math.atan2(y, x);
|
||||
}
|
||||
|
||||
export function cbrt(x: f64): f64 {
|
||||
return Math.cbrt(x);
|
||||
}
|
||||
|
||||
export function ceil(x: f64): f64 {
|
||||
return Math.ceil(x);
|
||||
}
|
||||
|
||||
export function clz32(x: f64): f64 {
|
||||
return Math.clz32(x);
|
||||
}
|
||||
|
||||
export function cos(x: f64): f64 {
|
||||
return Math.cos(x);
|
||||
}
|
||||
|
||||
export function cosh(x: f64): f64 {
|
||||
return Math.cosh(x);
|
||||
}
|
||||
|
||||
export function exp(x: f64): f64 {
|
||||
return Math.exp(x);
|
||||
}
|
||||
|
||||
export function expm1(x: f64): f64 {
|
||||
return Math.expm1(x);
|
||||
}
|
||||
|
||||
export function floor(x: f64): f64 {
|
||||
return Math.floor(x);
|
||||
}
|
||||
|
||||
export function fround(x: f64): f32 {
|
||||
return Math.fround(x);
|
||||
}
|
||||
|
||||
export function hypot(a: f64, b: f64): f64 {
|
||||
return Math.hypot(a, b);
|
||||
}
|
||||
|
||||
export function imul(a: f64, b: f64): f64 {
|
||||
return Math.imul(a, b);
|
||||
}
|
||||
|
||||
export function log(x: f64): f64 {
|
||||
return Math.log(x);
|
||||
}
|
||||
|
||||
export function log10(x: f64): f64 {
|
||||
return Math.log10(x);
|
||||
}
|
||||
|
||||
export function log1p(x: f64): f64 {
|
||||
return Math.log1p(x);
|
||||
}
|
||||
|
||||
export function log2(x: f64): f64 {
|
||||
return Math.log2(x);
|
||||
}
|
||||
|
||||
export function max(a: f64, b: f64): f64 {
|
||||
return Math.max(a, b);
|
||||
}
|
||||
|
||||
export function min(a: f64, b: f64): f64 {
|
||||
return Math.min(a, b);
|
||||
}
|
||||
|
||||
export function pow(x: f64, y: f64): f64 {
|
||||
return Math.pow(x, y);
|
||||
}
|
||||
|
||||
export function round(x: f64): f64 {
|
||||
return Math.round(x);
|
||||
}
|
||||
|
||||
export function sign(x: f64): f64 {
|
||||
return Math.sign(x);
|
||||
}
|
||||
|
||||
export function sin(x: f64): f64 {
|
||||
return Math.sin(x);
|
||||
}
|
||||
|
||||
export function sinh(x: f64): f64 {
|
||||
return Math.sinh(x);
|
||||
}
|
||||
|
||||
export function sqrt(x: f64): f64 {
|
||||
return Math.sqrt(x);
|
||||
}
|
||||
|
||||
export function tan(x: f64): f64 {
|
||||
return Math.tan(x);
|
||||
}
|
||||
|
||||
export function tanh(x: f64): f64 {
|
||||
return Math.tanh(x);
|
||||
}
|
||||
|
||||
export function trunc(x: f64): f64 {
|
||||
return Math.trunc(x);
|
||||
}
|
||||
import * as libm from "../../../lib/libm/assembly/libm";
|
||||
import * as libmf from "../../../lib/libm/assembly/libmf";
|
||||
export { libm, libmf };
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -8056,7 +8056,7 @@
|
||||
if
|
||||
i32.const 0
|
||||
i32.const 144
|
||||
i32.const 1021
|
||||
i32.const 1020
|
||||
i32.const 4
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -8087,7 +8087,7 @@
|
||||
if
|
||||
i32.const 184
|
||||
i32.const 144
|
||||
i32.const 1030
|
||||
i32.const 1029
|
||||
i32.const 24
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -8134,7 +8134,7 @@
|
||||
if
|
||||
i32.const 184
|
||||
i32.const 144
|
||||
i32.const 2312
|
||||
i32.const 2309
|
||||
i32.const 24
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
|
@ -10211,7 +10211,7 @@
|
||||
if
|
||||
i32.const 0
|
||||
i32.const 144
|
||||
i32.const 1021
|
||||
i32.const 1020
|
||||
i32.const 4
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -10243,7 +10243,7 @@
|
||||
if
|
||||
i32.const 184
|
||||
i32.const 144
|
||||
i32.const 1030
|
||||
i32.const 1029
|
||||
i32.const 24
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
@ -10300,7 +10300,7 @@
|
||||
if
|
||||
i32.const 184
|
||||
i32.const 144
|
||||
i32.const 2312
|
||||
i32.const 2309
|
||||
i32.const 24
|
||||
call $~lib/builtins/abort
|
||||
unreachable
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user