git.delta.rocks / jrsonnet / refs/commits / 604f09da5796

difftreelog

fix only build benchmarker for x86_64-linux

oqtmzxprYaroslav Bolyukin2026-05-06parent: #3e1d397.patch.diff
in: master

3 files changed

modifiedxtask/Cargo.tomldiffbeforeafterboth
--- a/xtask/Cargo.toml
+++ b/xtask/Cargo.toml
@@ -18,5 +18,5 @@
 xshell.workspace = true
 clap = { workspace = true, features = ["derive"] }
 
-[target.'cfg(target_os = "linux")'.dependencies]
+[target.'cfg(all(target_arch = "x86_64", target_os = "linux"))'.dependencies]
 nix.workspace = true
modifiedxtask/src/bench.rsdiffbeforeafterboth
--- a/xtask/src/bench.rs
+++ b/xtask/src/bench.rs
@@ -1,3 +1,5 @@
+#![allow(clippy::cast_precision_loss)]
+
 use std::{
 	ffi::OsString,
 	mem,
modifiedxtask/src/main.rsdiffbeforeafterboth
1use anyhow::Result;1use anyhow::Result;
2#[cfg(not(target_os = "linux"))]
3use anyhow::bail;
4use clap::Parser;2use clap::Parser;
5use xshell::{Shell, cmd};3use xshell::{Shell, cmd};
64
7#[cfg(target_os = "linux")]5#[cfg(all(target_arch = "x86_64", target_os = "linux"))]
8mod bench;6mod bench;
9mod sourcegen;7mod sourcegen;
108
40 args: Vec<String>,38 args: Vec<String>,
41 },39 },
42 /// Benchmark a command: repeated runs, reports time + RSS stats (Linux only)40 /// Benchmark a command: repeated runs, reports time + RSS stats (Linux only)
41 #[cfg(all(target_arch = "x86_64", target_os = "linux"))]
43 Bench {42 Bench {
44 #[arg(long, default_value_t = 10)]43 #[arg(long, default_value_t = 10)]
45 runs: u32,44 runs: u32,
121120
122 Ok(())121 Ok(())
123 }122 }
124 #[cfg(target_os = "linux")]123 #[cfg(all(target_arch = "x86_64", target_os = "linux"))]
125 Opts::Bench {124 Opts::Bench {
126 runs,125 runs,
127 warmup,126 warmup,