Define a "table" concept.

"Table" is to WebAssembly tables as "Heap" is to WebAssembly linear
memories.
This commit is contained in:
Dan Gohman
2018-05-20 07:48:46 -07:00
parent cd75176f10
commit 1b30265c5c
23 changed files with 500 additions and 16 deletions

View File

@@ -176,6 +176,12 @@ pub enum SerInstData {
heap: String,
imm: String,
},
TableAddr {
opcode: String,
arg: String,
table: String,
offset: String,
},
RegMove {
opcode: String,
arg: String,
@@ -572,6 +578,17 @@ pub fn get_inst_data(inst_index: Inst, func: &Function) -> SerInstData {
heap: heap.to_string(),
imm: imm.to_string(),
},
InstructionData::TableAddr {
opcode,
arg,
table,
offset,
} => SerInstData::TableAddr {
opcode: opcode.to_string(),
arg: arg.to_string(),
table: table.to_string(),
offset: offset.to_string(),
},
InstructionData::RegMove {
opcode,
arg,