cranelift: Implement overflow flags for icmp in interpreter

This commit is contained in:
Afonso Bordado
2021-07-05 09:34:48 +01:00
committed by Andrew Brown
parent c42b725ce9
commit 04033fe645
3 changed files with 230 additions and 2 deletions

View File

@@ -720,8 +720,8 @@ where
&left.clone().convert(ValueConversionKind::ToUnsigned)?,
&right.clone().convert(ValueConversionKind::ToUnsigned)?,
)?,
IntCC::Overflow => unimplemented!("IntCC::Overflow"),
IntCC::NotOverflow => unimplemented!("IntCC::NotOverflow"),
IntCC::Overflow => Value::of(left, right)?,
IntCC::NotOverflow => !Value::of(left, right)?,
})
}