Stop tracking if instruction formats have multiple results.

All instruction formats can represent multiple results now, so a few
redundant formats can be removed: UnarySplit and BinaryOverflow.
This commit is contained in:
Jakob Stoklund Olesen
2017-04-13 12:24:20 -07:00
parent e5115d7793
commit b151e942d9
7 changed files with 10 additions and 65 deletions

View File

@@ -105,14 +105,12 @@ pub enum InstructionData {
UnaryImm { opcode: Opcode, imm: Imm64 },
UnaryIeee32 { opcode: Opcode, imm: Ieee32 },
UnaryIeee64 { opcode: Opcode, imm: Ieee64 },
UnarySplit { opcode: Opcode, arg: Value },
Binary { opcode: Opcode, args: [Value; 2] },
BinaryImm {
opcode: Opcode,
arg: Value,
imm: Imm64,
},
BinaryOverflow { opcode: Opcode, args: [Value; 2] },
Ternary { opcode: Opcode, args: [Value; 3] },
MultiAry { opcode: Opcode, args: ValueList },
InsertLane {

View File

@@ -255,10 +255,8 @@ impl<'a> Verifier<'a> {
&UnaryImm { .. } |
&UnaryIeee32 { .. } |
&UnaryIeee64 { .. } |
&UnarySplit { .. } |
&Binary { .. } |
&BinaryImm { .. } |
&BinaryOverflow { .. } |
&Ternary { .. } |
&InsertLane { .. } |
&ExtractLane { .. } |

View File

@@ -245,10 +245,8 @@ pub fn write_operands(w: &mut Write, dfg: &DataFlowGraph, inst: Inst) -> Result
UnaryImm { imm, .. } => write!(w, " {}", imm),
UnaryIeee32 { imm, .. } => write!(w, " {}", imm),
UnaryIeee64 { imm, .. } => write!(w, " {}", imm),
UnarySplit { arg, .. } => write!(w, " {}", arg),
Binary { args, .. } => write!(w, " {}, {}", args[0], args[1]),
BinaryImm { arg, imm, .. } => write!(w, " {}, {}", arg, imm),
BinaryOverflow { args, .. } => write!(w, " {}, {}", args[0], args[1]),
Ternary { args, .. } => write!(w, " {}, {}, {}", args[0], args[1], args[2]),
MultiAry { ref args, .. } => {
if args.is_empty() {