Fix inconsistencies
Addendum to truncation rename Rename constants for consistency
This commit is contained in:
parent
bdfede0b93
commit
efec6203b0
@ -11,10 +11,10 @@ local math_ceil = math.ceil
|
|||||||
local math_floor = math.floor
|
local math_floor = math.floor
|
||||||
local to_number = tonumber
|
local to_number = tonumber
|
||||||
|
|
||||||
local ID_ZERO = i64(0)
|
local NUM_ZERO = i64(0)
|
||||||
local ID_ONE = i64(1)
|
local NUM_ONE = i64(1)
|
||||||
|
|
||||||
local function truncate(num)
|
local function truncate_f64(num)
|
||||||
if num >= 0 then
|
if num >= 0 then
|
||||||
return (math_floor(num))
|
return (math_floor(num))
|
||||||
else
|
else
|
||||||
@ -62,13 +62,13 @@ do
|
|||||||
end
|
end
|
||||||
|
|
||||||
function mul.i32(lhs, rhs)
|
function mul.i32(lhs, rhs)
|
||||||
return (to_signed(ID_ONE * lhs * rhs))
|
return (to_signed(NUM_ONE * lhs * rhs))
|
||||||
end
|
end
|
||||||
|
|
||||||
function div.i32(lhs, rhs)
|
function div.i32(lhs, rhs)
|
||||||
assert(rhs ~= 0, "division by zero")
|
assert(rhs ~= 0, "division by zero")
|
||||||
|
|
||||||
return (truncate(lhs / rhs))
|
return (truncate_f64(lhs / rhs))
|
||||||
end
|
end
|
||||||
|
|
||||||
function div.u32(lhs, rhs)
|
function div.u32(lhs, rhs)
|
||||||
@ -257,38 +257,38 @@ do
|
|||||||
|
|
||||||
function clz.i64(num)
|
function clz.i64(num)
|
||||||
if num == 0 then
|
if num == 0 then
|
||||||
return 64 * ID_ONE
|
return 64 * NUM_ONE
|
||||||
end
|
end
|
||||||
|
|
||||||
local count = ID_ZERO
|
local count = NUM_ZERO
|
||||||
|
|
||||||
if bit_rshift(num, 32) == ID_ZERO then
|
if bit_rshift(num, 32) == NUM_ZERO then
|
||||||
num = bit_lshift(num, 32)
|
num = bit_lshift(num, 32)
|
||||||
count = count + 32
|
count = count + 32
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_rshift(num, 48) == ID_ZERO then
|
if bit_rshift(num, 48) == NUM_ZERO then
|
||||||
num = bit_lshift(num, 16)
|
num = bit_lshift(num, 16)
|
||||||
count = count + 16
|
count = count + 16
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_rshift(num, 56) == ID_ZERO then
|
if bit_rshift(num, 56) == NUM_ZERO then
|
||||||
num = bit_lshift(num, 8)
|
num = bit_lshift(num, 8)
|
||||||
count = count + 8
|
count = count + 8
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_rshift(num, 60) == ID_ZERO then
|
if bit_rshift(num, 60) == NUM_ZERO then
|
||||||
num = bit_lshift(num, 4)
|
num = bit_lshift(num, 4)
|
||||||
count = count + 4
|
count = count + 4
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_rshift(num, 62) == ID_ZERO then
|
if bit_rshift(num, 62) == NUM_ZERO then
|
||||||
num = bit_lshift(num, 2)
|
num = bit_lshift(num, 2)
|
||||||
count = count + 2
|
count = count + 2
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_rshift(num, 63) == ID_ZERO then
|
if bit_rshift(num, 63) == NUM_ZERO then
|
||||||
count = count + ID_ONE
|
count = count + NUM_ONE
|
||||||
end
|
end
|
||||||
|
|
||||||
return count
|
return count
|
||||||
@ -296,49 +296,49 @@ do
|
|||||||
|
|
||||||
function ctz.i64(num)
|
function ctz.i64(num)
|
||||||
if num == 0 then
|
if num == 0 then
|
||||||
return 64 * ID_ONE
|
return 64 * NUM_ONE
|
||||||
end
|
end
|
||||||
|
|
||||||
local count = ID_ZERO
|
local count = NUM_ZERO
|
||||||
|
|
||||||
if bit_lshift(num, 32) == ID_ZERO then
|
if bit_lshift(num, 32) == NUM_ZERO then
|
||||||
num = bit_rshift(num, 32)
|
num = bit_rshift(num, 32)
|
||||||
count = count + 32
|
count = count + 32
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_lshift(num, 48) == ID_ZERO then
|
if bit_lshift(num, 48) == NUM_ZERO then
|
||||||
num = bit_rshift(num, 16)
|
num = bit_rshift(num, 16)
|
||||||
count = count + 16
|
count = count + 16
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_lshift(num, 56) == ID_ZERO then
|
if bit_lshift(num, 56) == NUM_ZERO then
|
||||||
num = bit_rshift(num, 8)
|
num = bit_rshift(num, 8)
|
||||||
count = count + 8
|
count = count + 8
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_lshift(num, 60) == ID_ZERO then
|
if bit_lshift(num, 60) == NUM_ZERO then
|
||||||
num = bit_rshift(num, 4)
|
num = bit_rshift(num, 4)
|
||||||
count = count + 4
|
count = count + 4
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_lshift(num, 62) == ID_ZERO then
|
if bit_lshift(num, 62) == NUM_ZERO then
|
||||||
num = bit_rshift(num, 2)
|
num = bit_rshift(num, 2)
|
||||||
count = count + 2
|
count = count + 2
|
||||||
end
|
end
|
||||||
|
|
||||||
if bit_lshift(num, 63) == ID_ZERO then
|
if bit_lshift(num, 63) == NUM_ZERO then
|
||||||
count = count + ID_ONE
|
count = count + NUM_ONE
|
||||||
end
|
end
|
||||||
|
|
||||||
return count
|
return count
|
||||||
end
|
end
|
||||||
|
|
||||||
function popcnt.i64(num)
|
function popcnt.i64(num)
|
||||||
local count = ID_ZERO
|
local count = NUM_ZERO
|
||||||
|
|
||||||
while num ~= ID_ZERO do
|
while num ~= NUM_ZERO do
|
||||||
num = bit_and(num, num - ID_ONE)
|
num = bit_and(num, num - NUM_ONE)
|
||||||
count = count + ID_ONE
|
count = count + NUM_ONE
|
||||||
end
|
end
|
||||||
|
|
||||||
return count
|
return count
|
||||||
@ -395,7 +395,7 @@ end
|
|||||||
|
|
||||||
do
|
do
|
||||||
local wrap = {}
|
local wrap = {}
|
||||||
local trunc = {}
|
local truncate = {}
|
||||||
local extend = {}
|
local extend = {}
|
||||||
local convert = {}
|
local convert = {}
|
||||||
local promote = {}
|
local promote = {}
|
||||||
@ -419,14 +419,14 @@ do
|
|||||||
return RE_INSTANCE.i32
|
return RE_INSTANCE.i32
|
||||||
end
|
end
|
||||||
|
|
||||||
trunc.i32_f32 = truncate
|
truncate.i32_f32 = truncate_f64
|
||||||
trunc.i32_f64 = truncate
|
truncate.i32_f64 = truncate_f64
|
||||||
trunc.i64_f32 = i64
|
truncate.i64_f32 = i64
|
||||||
trunc.i64_f64 = i64
|
truncate.i64_f64 = i64
|
||||||
trunc.u64_f32 = i64
|
truncate.u64_f32 = i64
|
||||||
trunc.u64_f64 = i64
|
truncate.u64_f64 = i64
|
||||||
trunc.f32 = truncate
|
truncate.f32 = truncate_f64
|
||||||
trunc.f64 = truncate
|
truncate.f64 = truncate_f64
|
||||||
|
|
||||||
function extend.i32_n8(num)
|
function extend.i32_n8(num)
|
||||||
num = bit_and(num, 0xFF)
|
num = bit_and(num, 0xFF)
|
||||||
@ -481,7 +481,7 @@ do
|
|||||||
extend.i64_i32 = i64
|
extend.i64_i32 = i64
|
||||||
|
|
||||||
function extend.i64_u32(num)
|
function extend.i64_u32(num)
|
||||||
RE_INSTANCE.i64 = ID_ZERO
|
RE_INSTANCE.i64 = NUM_ZERO
|
||||||
RE_INSTANCE.i32 = num
|
RE_INSTANCE.i32 = num
|
||||||
|
|
||||||
return RE_INSTANCE.i64
|
return RE_INSTANCE.i64
|
||||||
@ -544,7 +544,7 @@ do
|
|||||||
end
|
end
|
||||||
|
|
||||||
module.wrap = wrap
|
module.wrap = wrap
|
||||||
module.trunc = trunc
|
module.truncate = truncate
|
||||||
module.extend = extend
|
module.extend = extend
|
||||||
module.convert = convert
|
module.convert = convert
|
||||||
module.demote = demote
|
module.demote = demote
|
||||||
|
@ -227,7 +227,6 @@ fn write_local_operation(head: &str, tail: &str, w: &mut dyn Write) -> Result<()
|
|||||||
("shr", "u32" | "u64") => write!(w, "bit.rshift "),
|
("shr", "u32" | "u64") => write!(w, "bit.rshift "),
|
||||||
("rotl", _) => write!(w, "bit.rol "),
|
("rotl", _) => write!(w, "bit.rol "),
|
||||||
("rotr", _) => write!(w, "bit.ror "),
|
("rotr", _) => write!(w, "bit.ror "),
|
||||||
("trunc", "u32_f32" | "u32_f64") => write!(w, "math.floor "),
|
|
||||||
("convert", "f32_i64" | "f64_i64") => write!(w, "tonumber "),
|
("convert", "f32_i64" | "f64_i64") => write!(w, "tonumber "),
|
||||||
_ => write!(w, "rt.{head}.{tail} "),
|
_ => write!(w, "rt.{head}.{tail} "),
|
||||||
}
|
}
|
||||||
|
@ -363,7 +363,7 @@ end
|
|||||||
|
|
||||||
do
|
do
|
||||||
local wrap = {}
|
local wrap = {}
|
||||||
local trunc = {}
|
local truncate = {}
|
||||||
local extend = {}
|
local extend = {}
|
||||||
local convert = {}
|
local convert = {}
|
||||||
local demote = {}
|
local demote = {}
|
||||||
@ -388,12 +388,12 @@ do
|
|||||||
return data_1
|
return data_1
|
||||||
end
|
end
|
||||||
|
|
||||||
trunc.i32_f32 = to_u32
|
truncate.i32_f32 = to_u32
|
||||||
trunc.i32_f64 = to_u32
|
truncate.i32_f64 = to_u32
|
||||||
trunc.u32_f32 = no_op
|
truncate.u32_f32 = no_op
|
||||||
trunc.u32_f64 = no_op
|
truncate.u32_f64 = no_op
|
||||||
|
|
||||||
function trunc.i64_f32(num)
|
function truncate.i64_f32(num)
|
||||||
if num < 0 then
|
if num < 0 then
|
||||||
local temp = num_from_u64(-math_ceil(num))
|
local temp = num_from_u64(-math_ceil(num))
|
||||||
|
|
||||||
@ -405,7 +405,7 @@ do
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function trunc.i64_f64(num)
|
function truncate.i64_f64(num)
|
||||||
if num < 0 then
|
if num < 0 then
|
||||||
local temp = num_from_u64(-math_ceil(num))
|
local temp = num_from_u64(-math_ceil(num))
|
||||||
|
|
||||||
@ -417,10 +417,10 @@ do
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
trunc.u64_f32 = num_from_u64
|
truncate.u64_f32 = num_from_u64
|
||||||
trunc.u64_f64 = num_from_u64
|
truncate.u64_f64 = num_from_u64
|
||||||
|
|
||||||
function trunc.f32(num)
|
function truncate.f32(num)
|
||||||
if num >= 0 then
|
if num >= 0 then
|
||||||
return math_floor(num)
|
return math_floor(num)
|
||||||
else
|
else
|
||||||
@ -428,7 +428,7 @@ do
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
trunc.f64 = trunc.f32
|
truncate.f64 = truncate.f32
|
||||||
|
|
||||||
function extend.i32_n8(num)
|
function extend.i32_n8(num)
|
||||||
num = bit_and(num, 0xFF)
|
num = bit_and(num, 0xFF)
|
||||||
@ -564,7 +564,7 @@ do
|
|||||||
end
|
end
|
||||||
|
|
||||||
module.wrap = wrap
|
module.wrap = wrap
|
||||||
module.trunc = trunc
|
module.truncate = truncate
|
||||||
module.extend = extend
|
module.extend = extend
|
||||||
module.convert = convert
|
module.convert = convert
|
||||||
module.demote = demote
|
module.demote = demote
|
||||||
@ -856,7 +856,7 @@ do
|
|||||||
store_i64(memory, addr, reinterpret_i64_f64(value))
|
store_i64(memory, addr, reinterpret_i64_f64(value))
|
||||||
end
|
end
|
||||||
|
|
||||||
function store.string(memory, offset, data, len)
|
function store.string(memory, addr, data, len)
|
||||||
len = len or #data
|
len = len or #data
|
||||||
|
|
||||||
local rem = len % 4
|
local rem = len % 4
|
||||||
@ -864,13 +864,13 @@ do
|
|||||||
for i = 1, len - rem, 4 do
|
for i = 1, len - rem, 4 do
|
||||||
local v = string_unpack("<I4", data, i)
|
local v = string_unpack("<I4", data, i)
|
||||||
|
|
||||||
store_i32(memory, offset + i - 1, v)
|
store_i32(memory, addr + i - 1, v)
|
||||||
end
|
end
|
||||||
|
|
||||||
for i = len - rem + 1, len do
|
for i = len - rem + 1, len do
|
||||||
local v = string_byte(data, i)
|
local v = string_byte(data, i)
|
||||||
|
|
||||||
store_i8(memory, offset + i - 1, v)
|
store_i8(memory, addr + i - 1, v)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -136,21 +136,25 @@ pub enum UnOpType {
|
|||||||
Neg_F32,
|
Neg_F32,
|
||||||
Ceil_F32,
|
Ceil_F32,
|
||||||
Floor_F32,
|
Floor_F32,
|
||||||
Trunc_F32,
|
Truncate_F32,
|
||||||
Nearest_F32,
|
Nearest_F32,
|
||||||
Sqrt_F32,
|
Sqrt_F32,
|
||||||
Abs_F64,
|
Abs_F64,
|
||||||
Neg_F64,
|
Neg_F64,
|
||||||
Ceil_F64,
|
Ceil_F64,
|
||||||
Floor_F64,
|
Floor_F64,
|
||||||
Trunc_F64,
|
Truncate_F64,
|
||||||
Nearest_F64,
|
Nearest_F64,
|
||||||
Sqrt_F64,
|
Sqrt_F64,
|
||||||
Wrap_I32_I64,
|
Wrap_I32_I64,
|
||||||
Trunc_I32_F32,
|
Truncate_I32_F32,
|
||||||
Trunc_U32_F32,
|
Truncate_I32_F64,
|
||||||
Trunc_I32_F64,
|
Truncate_U32_F32,
|
||||||
Trunc_U32_F64,
|
Truncate_U32_F64,
|
||||||
|
Truncate_I64_F32,
|
||||||
|
Truncate_I64_F64,
|
||||||
|
Truncate_U64_F32,
|
||||||
|
Truncate_U64_F64,
|
||||||
Extend_I32_N8,
|
Extend_I32_N8,
|
||||||
Extend_I32_N16,
|
Extend_I32_N16,
|
||||||
Extend_I64_N8,
|
Extend_I64_N8,
|
||||||
@ -158,10 +162,6 @@ pub enum UnOpType {
|
|||||||
Extend_I64_N32,
|
Extend_I64_N32,
|
||||||
Extend_I64_I32,
|
Extend_I64_I32,
|
||||||
Extend_I64_U32,
|
Extend_I64_U32,
|
||||||
Trunc_I64_F32,
|
|
||||||
Trunc_U64_F32,
|
|
||||||
Trunc_I64_F64,
|
|
||||||
Trunc_U64_F64,
|
|
||||||
Convert_F32_I32,
|
Convert_F32_I32,
|
||||||
Convert_F32_U32,
|
Convert_F32_U32,
|
||||||
Convert_F32_I64,
|
Convert_F32_I64,
|
||||||
@ -192,21 +192,25 @@ impl UnOpType {
|
|||||||
Self::Neg_F32 => ("neg", "f32"),
|
Self::Neg_F32 => ("neg", "f32"),
|
||||||
Self::Ceil_F32 => ("ceil", "f32"),
|
Self::Ceil_F32 => ("ceil", "f32"),
|
||||||
Self::Floor_F32 => ("floor", "f32"),
|
Self::Floor_F32 => ("floor", "f32"),
|
||||||
Self::Trunc_F32 => ("trunc", "f32"),
|
Self::Truncate_F32 => ("truncate", "f32"),
|
||||||
Self::Nearest_F32 => ("nearest", "f32"),
|
Self::Nearest_F32 => ("nearest", "f32"),
|
||||||
Self::Sqrt_F32 => ("sqrt", "f32"),
|
Self::Sqrt_F32 => ("sqrt", "f32"),
|
||||||
Self::Abs_F64 => ("abs", "f64"),
|
Self::Abs_F64 => ("abs", "f64"),
|
||||||
Self::Neg_F64 => ("neg", "f64"),
|
Self::Neg_F64 => ("neg", "f64"),
|
||||||
Self::Ceil_F64 => ("ceil", "f64"),
|
Self::Ceil_F64 => ("ceil", "f64"),
|
||||||
Self::Floor_F64 => ("floor", "f64"),
|
Self::Floor_F64 => ("floor", "f64"),
|
||||||
Self::Trunc_F64 => ("trunc", "f64"),
|
Self::Truncate_F64 => ("truncate", "f64"),
|
||||||
Self::Nearest_F64 => ("nearest", "f64"),
|
Self::Nearest_F64 => ("nearest", "f64"),
|
||||||
Self::Sqrt_F64 => ("sqrt", "f64"),
|
Self::Sqrt_F64 => ("sqrt", "f64"),
|
||||||
Self::Wrap_I32_I64 => ("wrap", "i32_i64"),
|
Self::Wrap_I32_I64 => ("wrap", "i32_i64"),
|
||||||
Self::Trunc_I32_F32 => ("trunc", "i32_f32"),
|
Self::Truncate_I32_F32 => ("truncate", "i32_f32"),
|
||||||
Self::Trunc_U32_F32 => ("trunc", "u32_f32"),
|
Self::Truncate_I32_F64 => ("truncate", "i32_f64"),
|
||||||
Self::Trunc_I32_F64 => ("trunc", "i32_f64"),
|
Self::Truncate_U32_F32 => ("truncate", "u32_f32"),
|
||||||
Self::Trunc_U32_F64 => ("trunc", "u32_f64"),
|
Self::Truncate_U32_F64 => ("truncate", "u32_f64"),
|
||||||
|
Self::Truncate_I64_F32 => ("truncate", "i64_f32"),
|
||||||
|
Self::Truncate_I64_F64 => ("truncate", "i64_f64"),
|
||||||
|
Self::Truncate_U64_F32 => ("truncate", "u64_f32"),
|
||||||
|
Self::Truncate_U64_F64 => ("truncate", "u64_f64"),
|
||||||
Self::Extend_I32_N8 => ("extend", "i32_n8"),
|
Self::Extend_I32_N8 => ("extend", "i32_n8"),
|
||||||
Self::Extend_I32_N16 => ("extend", "i32_n16"),
|
Self::Extend_I32_N16 => ("extend", "i32_n16"),
|
||||||
Self::Extend_I64_N8 => ("extend", "i64_n8"),
|
Self::Extend_I64_N8 => ("extend", "i64_n8"),
|
||||||
@ -214,10 +218,6 @@ impl UnOpType {
|
|||||||
Self::Extend_I64_N32 => ("extend", "i64_n32"),
|
Self::Extend_I64_N32 => ("extend", "i64_n32"),
|
||||||
Self::Extend_I64_I32 => ("extend", "i64_i32"),
|
Self::Extend_I64_I32 => ("extend", "i64_i32"),
|
||||||
Self::Extend_I64_U32 => ("extend", "i64_u32"),
|
Self::Extend_I64_U32 => ("extend", "i64_u32"),
|
||||||
Self::Trunc_I64_F32 => ("trunc", "i64_f32"),
|
|
||||||
Self::Trunc_U64_F32 => ("trunc", "u64_f32"),
|
|
||||||
Self::Trunc_I64_F64 => ("trunc", "i64_f64"),
|
|
||||||
Self::Trunc_U64_F64 => ("trunc", "u64_f64"),
|
|
||||||
Self::Convert_F32_I32 => ("convert", "f32_i32"),
|
Self::Convert_F32_I32 => ("convert", "f32_i32"),
|
||||||
Self::Convert_F32_U32 => ("convert", "f32_u32"),
|
Self::Convert_F32_U32 => ("convert", "f32_u32"),
|
||||||
Self::Convert_F32_I64 => ("convert", "f32_i64"),
|
Self::Convert_F32_I64 => ("convert", "f32_i64"),
|
||||||
@ -251,21 +251,25 @@ impl TryFrom<&Operator<'_>> for UnOpType {
|
|||||||
Operator::F32Neg => Self::Neg_F32,
|
Operator::F32Neg => Self::Neg_F32,
|
||||||
Operator::F32Ceil => Self::Ceil_F32,
|
Operator::F32Ceil => Self::Ceil_F32,
|
||||||
Operator::F32Floor => Self::Floor_F32,
|
Operator::F32Floor => Self::Floor_F32,
|
||||||
Operator::F32Trunc => Self::Trunc_F32,
|
Operator::F32Trunc => Self::Truncate_F32,
|
||||||
Operator::F32Nearest => Self::Nearest_F32,
|
Operator::F32Nearest => Self::Nearest_F32,
|
||||||
Operator::F32Sqrt => Self::Sqrt_F32,
|
Operator::F32Sqrt => Self::Sqrt_F32,
|
||||||
Operator::F64Abs => Self::Abs_F64,
|
Operator::F64Abs => Self::Abs_F64,
|
||||||
Operator::F64Neg => Self::Neg_F64,
|
Operator::F64Neg => Self::Neg_F64,
|
||||||
Operator::F64Ceil => Self::Ceil_F64,
|
Operator::F64Ceil => Self::Ceil_F64,
|
||||||
Operator::F64Floor => Self::Floor_F64,
|
Operator::F64Floor => Self::Floor_F64,
|
||||||
Operator::F64Trunc => Self::Trunc_F64,
|
Operator::F64Trunc => Self::Truncate_F64,
|
||||||
Operator::F64Nearest => Self::Nearest_F64,
|
Operator::F64Nearest => Self::Nearest_F64,
|
||||||
Operator::F64Sqrt => Self::Sqrt_F64,
|
Operator::F64Sqrt => Self::Sqrt_F64,
|
||||||
Operator::I32WrapI64 => Self::Wrap_I32_I64,
|
Operator::I32WrapI64 => Self::Wrap_I32_I64,
|
||||||
Operator::I32TruncF32S => Self::Trunc_I32_F32,
|
Operator::I32TruncF32S => Self::Truncate_I32_F32,
|
||||||
Operator::I32TruncF32U => Self::Trunc_U32_F32,
|
Operator::I32TruncF64S => Self::Truncate_I32_F64,
|
||||||
Operator::I32TruncF64S => Self::Trunc_I32_F64,
|
Operator::I32TruncF32U => Self::Truncate_U32_F32,
|
||||||
Operator::I32TruncF64U => Self::Trunc_U32_F64,
|
Operator::I32TruncF64U => Self::Truncate_U32_F64,
|
||||||
|
Operator::I64TruncF32S => Self::Truncate_I64_F32,
|
||||||
|
Operator::I64TruncF64S => Self::Truncate_I64_F64,
|
||||||
|
Operator::I64TruncF32U => Self::Truncate_U64_F32,
|
||||||
|
Operator::I64TruncF64U => Self::Truncate_U64_F64,
|
||||||
Operator::I32Extend8S => Self::Extend_I32_N8,
|
Operator::I32Extend8S => Self::Extend_I32_N8,
|
||||||
Operator::I32Extend16S => Self::Extend_I32_N16,
|
Operator::I32Extend16S => Self::Extend_I32_N16,
|
||||||
Operator::I64Extend8S => Self::Extend_I64_N8,
|
Operator::I64Extend8S => Self::Extend_I64_N8,
|
||||||
@ -273,10 +277,6 @@ impl TryFrom<&Operator<'_>> for UnOpType {
|
|||||||
Operator::I64Extend32S => Self::Extend_I64_N32,
|
Operator::I64Extend32S => Self::Extend_I64_N32,
|
||||||
Operator::I64ExtendI32S => Self::Extend_I64_I32,
|
Operator::I64ExtendI32S => Self::Extend_I64_I32,
|
||||||
Operator::I64ExtendI32U => Self::Extend_I64_U32,
|
Operator::I64ExtendI32U => Self::Extend_I64_U32,
|
||||||
Operator::I64TruncF32S => Self::Trunc_I64_F32,
|
|
||||||
Operator::I64TruncF32U => Self::Trunc_U64_F32,
|
|
||||||
Operator::I64TruncF64S => Self::Trunc_I64_F64,
|
|
||||||
Operator::I64TruncF64U => Self::Trunc_U64_F64,
|
|
||||||
Operator::F32ConvertI32S => Self::Convert_F32_I32,
|
Operator::F32ConvertI32S => Self::Convert_F32_I32,
|
||||||
Operator::F32ConvertI32U => Self::Convert_F32_U32,
|
Operator::F32ConvertI32U => Self::Convert_F32_U32,
|
||||||
Operator::F32ConvertI64S => Self::Convert_F32_I64,
|
Operator::F32ConvertI64S => Self::Convert_F32_I64,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user