cranelift: Remove brz and brnz (#5630)
Remove the brz and brnz instructions, as their behavior is now redundant with brif.
This commit is contained in:
@@ -118,7 +118,6 @@ impl Into<AMode> for StackAMode {
|
||||
}
|
||||
|
||||
/// risc-v always take two register to compare
|
||||
/// brz can be compare with zero register which has the value 0
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
pub struct IntegerCompare {
|
||||
pub(crate) kind: IntCC,
|
||||
|
||||
@@ -159,8 +159,7 @@ mod tests {
|
||||
|
||||
let mut pos = FuncCursor::new(&mut func);
|
||||
pos.insert_block(block0);
|
||||
pos.ins().brnz(v0, block2, &[]);
|
||||
pos.ins().jump(block1, &[]);
|
||||
pos.ins().brif(v0, block2, &[], block1, &[]);
|
||||
|
||||
pos.insert_block(block1);
|
||||
pos.ins().return_(&[]);
|
||||
|
||||
Reference in New Issue
Block a user