Separate immediate and value operands in the instruction format.
Instruction formats are now identified by a signature that doesn't include the ordering of value operands relative to immediate operands. This means that the BinaryRev instruction format becomes redundant, so delete it. The isub_imm instruction was the only one using that format. Rename it to irsub_imm to make it clear what it does now that it is printed as 'irsub_imm v2, 45'.
This commit is contained in:
@@ -177,7 +177,6 @@ impl<'a> Context<'a> {
|
||||
InstructionData::Unary { ref mut arg, .. } |
|
||||
InstructionData::UnarySplit { ref mut arg, .. } |
|
||||
InstructionData::BinaryImm { ref mut arg, .. } |
|
||||
InstructionData::BinaryImmRev { ref mut arg, .. } |
|
||||
InstructionData::ExtractLane { ref mut arg, .. } |
|
||||
InstructionData::BranchTable { ref mut arg, .. } => {
|
||||
self.map.rewrite_value(arg, loc)?;
|
||||
@@ -1368,17 +1367,6 @@ impl<'a> Parser<'a> {
|
||||
imm: rhs,
|
||||
}
|
||||
}
|
||||
InstructionFormat::BinaryImmRev => {
|
||||
let lhs = self.match_imm64("expected immediate integer first operand")?;
|
||||
self.match_token(Token::Comma, "expected ',' between operands")?;
|
||||
let rhs = self.match_value("expected SSA value second operand")?;
|
||||
InstructionData::BinaryImmRev {
|
||||
opcode: opcode,
|
||||
ty: VOID,
|
||||
imm: lhs,
|
||||
arg: rhs,
|
||||
}
|
||||
}
|
||||
InstructionFormat::BinaryOverflow => {
|
||||
let lhs = self.match_value("expected SSA value first operand")?;
|
||||
self.match_token(Token::Comma, "expected ',' between operands")?;
|
||||
|
||||
Reference in New Issue
Block a user