diff --git a/storage-proofs/porep/src/lib.rs b/storage-proofs/porep/src/lib.rs index 7c4698b0c..e95bad2de 100644 --- a/storage-proofs/porep/src/lib.rs +++ b/storage-proofs/porep/src/lib.rs @@ -1,6 +1,8 @@ //requires nightly, or later stable version //#![warn(clippy::unwrap_used)] +#![cfg_attr(target_arch = "aarch64", feature(stdsimd))] + pub mod drg; pub mod stacked; diff --git a/storage-proofs/porep/src/stacked/vanilla/macros.rs b/storage-proofs/porep/src/stacked/vanilla/macros.rs index 97d8f26f6..2cb29d3bd 100644 --- a/storage-proofs/porep/src/stacked/vanilla/macros.rs +++ b/storage-proofs/porep/src/stacked/vanilla/macros.rs @@ -55,6 +55,11 @@ macro_rules! prefetch { _mm_prefetch($val, _MM_HINT_T0); } + #[cfg(all(target_arch = "aarch64"))] + unsafe { + use std::arch::aarch64::*; + _prefetch($val, _PREFETCH_READ, _PREFETCH_LOCALITY3); + } }; }