mirror of
https://github.com/Cuprate/cuprate.git
synced 2024-12-22 19:49:28 +00:00
fix builds on certain archs
This commit is contained in:
parent
a30f418247
commit
1afe3e4dc8
2 changed files with 6 additions and 4 deletions
|
@ -36,7 +36,7 @@ use monero_consensus::{blocks::randomx_seed_height, HardFork};
|
|||
|
||||
mod tx_pool;
|
||||
|
||||
const MAX_BLOCKS_IN_RANGE: u64 = 1000;
|
||||
const MAX_BLOCKS_IN_RANGE: u64 = 500;
|
||||
const BATCHES_IN_REQUEST: u64 = 3;
|
||||
const MAX_BLOCKS_HEADERS_IN_RANGE: u64 = 1000;
|
||||
|
||||
|
@ -226,7 +226,8 @@ where
|
|||
|
||||
tokio::spawn(async move {
|
||||
while let Some(blocks) = incoming_blocks.next().await {
|
||||
if blocks.last().unwrap().header.major_version >= 12 {
|
||||
// RX technically starts at hf 12 but we do 11 so the seed hash is in the cache.
|
||||
if blocks.last().unwrap().header.major_version >= 11 {
|
||||
let unwrapped_rx_vms = randomx_vms.as_mut().unwrap();
|
||||
|
||||
let blocks = rayon_spawn_async(move || {
|
||||
|
|
|
@ -21,13 +21,14 @@ fn main() {
|
|||
.file("c/skein.c")
|
||||
.file("c/slow-hash.c")
|
||||
.file("c/CryptonightR_JIT.c")
|
||||
.file("c/CryptonightR_template.S")
|
||||
.flag("-O3")
|
||||
.flag("-fexceptions");
|
||||
|
||||
let target = env::var("TARGET").unwrap();
|
||||
if target.contains("x86_64") {
|
||||
cfg.flag("-maes").flag("-msse2");
|
||||
cfg.file("c/CryptonightR_template.S")
|
||||
.flag("-maes")
|
||||
.flag("-msse2");
|
||||
}
|
||||
|
||||
cfg.compile("cryptonight")
|
||||
|
|
Loading…
Reference in a new issue