Cranelift: Rewrite or(and(x, y), not(y)) => or(x, not(y)) (#5676)

Co-authored-by: Rainy Sinclair <844493+itsrainy@users.noreply.github.com>
This commit is contained in:
Nick Fitzgerald
2023-01-31 14:44:45 -08:00
committed by GitHub
parent e82995f03c
commit 8c9eb9939b
5 changed files with 112 additions and 1 deletions

View File

@@ -109,6 +109,11 @@ macro_rules! isle_common_prelude_methods {
!x
}
#[inline]
fn u64_eq(&mut self, x: u64, y: u64) -> u64 {
u64::from(x == y)
}
#[inline]
fn u64_is_zero(&mut self, value: u64) -> bool {
0 == value