Skip to content

Commit

Permalink
rustfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
eupn committed Jan 9, 2024
1 parent ee470cd commit ba24a47
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions crates/core_arch/src/arm_shared/crc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,10 @@ pub unsafe fn __crc32d(crc: u32, data: u64) -> u32 {
pub unsafe fn __crc32d(crc: u32, data: u64) -> u32 {
// On 32-bit ARM this intrinsic emits a chain of two `crc32_w` instructions
// and truncates the data to 32 bits in both clang and gcc
crc32w_(crc32w_(crc, (data & 0xffffffff) as u32), (data >> 32) as u32)
crc32w_(
crc32w_(crc, (data & 0xffffffff) as u32),
(data >> 32) as u32,
)
}

/// CRC32 single round checksum for quad words (64 bits).
Expand All @@ -148,7 +151,10 @@ pub unsafe fn __crc32cd(crc: u32, data: u64) -> u32 {
pub unsafe fn __crc32cd(crc: u32, data: u64) -> u32 {
// On 32-bit ARM this intrinsic emits a chain of two `crc32_cw` instructions
// and truncates the data to 32 bits in both clang and gcc
crc32cw_(crc32cw_(crc, (data & 0xffffffff) as u32), (data >> 32) as u32)
crc32cw_(
crc32cw_(crc, (data & 0xffffffff) as u32),
(data >> 32) as u32,
)
}

#[cfg(test)]
Expand Down

0 comments on commit ba24a47

Please sign in to comment.