Skip to content

Commit

Permalink
fixes for current nightly
Browse files Browse the repository at this point in the history
  • Loading branch information
hkratz committed Oct 24, 2024
1 parent d3399cd commit 82c5fee
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
1 change: 1 addition & 0 deletions src/implementation/aarch64/neon.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ use core::arch::aarch64::{
};

use crate::implementation::helpers::Utf8CheckAlgorithm;
use core::arch::asm;

// aarch64 SIMD primitives

Expand Down
3 changes: 0 additions & 3 deletions src/implementation/algorithm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,6 @@ macro_rules! algorithm_simd {
#[cfg_attr(not(target_arch="aarch64"), target_feature(enable = $feat))]
#[inline]
#[allow(unconditional_panic)] // does not panic because len is checked
#[allow(const_err)] // the same, but for Rust 1.38.0
unsafe fn check_block(&mut self, input: SimdInput) {
// WORKAROUND
// necessary because the for loop is not unrolled on ARM64
Expand All @@ -208,7 +207,6 @@ macro_rules! algorithm_simd {
#[cfg_attr(not(target_arch="aarch64"), target_feature(enable = $feat))]
#[inline]
#[allow(unconditional_panic)] // does not panic because len is checked
#[allow(const_err)] // the same, but for Rust 1.38.0
unsafe fn check_remainder(&mut self, mut input: *const u8, len: usize) {
const SIMD_SIZE: usize = core::mem::size_of::<SimdU8Value>();
let orig_len = len;
Expand Down Expand Up @@ -245,7 +243,6 @@ macro_rules! algorithm_simd {
#[cfg_attr(not(target_arch="aarch64"), target_feature(enable = $feat))]
#[inline]
#[allow(unconditional_panic)] // does not panic because len is checked
#[allow(const_err)] // the same, but for Rust 1.38.0
unsafe fn check_remainder_ascii(&mut self, mut input: *const u8, mut len: usize) {
const SIMD_SIZE: usize = core::mem::size_of::<SimdU8Value>();

Expand Down
7 changes: 3 additions & 4 deletions src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#![deny(warnings)]
#![warn(warnings)]
#![warn(unused_extern_crates)]
#![deny(
#![warn(
clippy::all,
clippy::unwrap_used,
clippy::unnecessary_unwrap,
Expand All @@ -15,8 +15,7 @@
#![cfg_attr(docsrs, feature(doc_cfg))]
#![cfg_attr(
all(feature = "aarch64_neon", target_arch = "aarch64"),
feature(stdsimd),
feature(asm)
feature(stdarch_aarch64_prefetch)
)]

//! Blazingly fast API-compatible UTF-8 validation for Rust using SIMD extensions, based on the implementation from
Expand Down

0 comments on commit 82c5fee

Please sign in to comment.