Replace ExtractLane format with BinaryImm8

Like https://github.com/bytecodealliance/wasmtime/pull/1762, this change the name of the `ExtractLane` format to the more-general `BinaryImm8` and renames its immediate argument from `lane` to `imm`.
This commit is contained in:
Andrew Brown
2020-05-27 09:24:46 -07:00
parent 7d6e94b952
commit a27a079d65
9 changed files with 36 additions and 39 deletions

View File

@@ -32,6 +32,11 @@ pub enum SerInstData {
opcode: String,
args: [String; 2],
},
BinaryImm8 {
opcode: String,
arg: String,
imm: String,
},
BinaryImm {
opcode: String,
arg: String,
@@ -53,11 +58,6 @@ pub enum SerInstData {
NullAry {
opcode: String,
},
ExtractLane {
opcode: String,
arg: String,
lane: String,
},
Shuffle {
opcode: String,
args: [String; 2],
@@ -292,6 +292,11 @@ pub fn get_inst_data(inst_index: Inst, func: &Function) -> SerInstData {
args: hold_args,
}
}
InstructionData::BinaryImm8 { opcode, arg, imm } => SerInstData::BinaryImm8 {
opcode: opcode.to_string(),
arg: arg.to_string(),
imm: imm.to_string(),
},
InstructionData::BinaryImm { opcode, arg, imm } => SerInstData::BinaryImm {
opcode: opcode.to_string(),
arg: arg.to_string(),
@@ -331,11 +336,6 @@ pub fn get_inst_data(inst_index: Inst, func: &Function) -> SerInstData {
imm: imm.to_string(),
}
}
InstructionData::ExtractLane { opcode, arg, lane } => SerInstData::ExtractLane {
opcode: opcode.to_string(),
arg: arg.to_string(),
lane: lane.to_string(),
},
InstructionData::UnaryConst {
opcode,
constant_handle,