embedded3 PERF-3 P1-2: the flag test's centreline polyline cached per thread and time (the 41-point rebuild with four transcendental evaluations each ran per surface-velocity call, ~10^6 calls per step): table faces 1,620 -> 54 ms, impose 622 -> 12 ms, build_mask 898 -> 404 ms, rebuild block 6.9 -> 4.3 s per step at 11.6 M cells; slab CSV byte-identical; table sub-laps
CI / Build (macos-latest) (push) Waiting to run
CI / Test (macos-latest) (push) Blocked by required conditions
CI / Test (ubuntu-latest) (push) Blocked by required conditions
CI / Python Bindings (maturin) (macos-latest) (push) Blocked by required conditions
CI / Python Bindings (maturin) (ubuntu-latest) (push) Blocked by required conditions
CI / WASM Build + Size Check (push) Blocked by required conditions
CI / Distributed Training Tests (push) Blocked by required conditions
CI / CI Success (push) Blocked by required conditions
CI / Clippy Check (push) Failing after 4s
Performance Benchmarks / Run Benchmarks (push) Failing after 4s
CI / Build (ubuntu-latest) (push) Failing after 3s
CI / Format Check (push) Failing after 4s
Documentation / Build User Guide (push) Successful in 5s
CI / Build CPU-Only (Explicit) (push) Failing after 1m33s
Documentation / Build API Documentation (push) Failing after 1m37s

Co-Authored-By: Claude Fable 5.1 <[email protected]>
This commit is contained in:
Omar Sobh
2026-09-19 18:42:55 -05:00
co-authored by Claude Fable 5.1
parent d9a2752cb9
commit 845e0ae01a
2 changed files with 41 additions and 10 deletions
@@ -82,7 +82,7 @@ pub(super) struct DeviceCut {
/// Which phase the tables serve: the predictor reads the instantaneous
/// apertures and kinds of the mask at its time; the projection reads the
/// step-averaged apertures and the space-time classification.
#[derive(Clone, Copy, PartialEq, Eq)]
#[derive(Clone, Copy, PartialEq, Eq, Debug)]
pub(super) enum Phase {
Predictor,
Projection,
@@ -125,6 +125,8 @@ impl DeviceCut {
};
// Surface velocity at the foot per face within the imposition band
// (zero beyond it: never read), and the open flags.
let lap = Instant::now();
let profile = std::env::var("RTX_E3_MOVING_PROFILE").is_ok();
let band = mask.impose_band().unwrap_or(f64::INFINITY);
let dists: [&[f64]; 3] = [&cut.d_u, &cut.d_v, &cut.d_w];
let mut ub: [Vec<f64>; 3] = [Vec::new(), Vec::new(), Vec::new()];
@@ -176,6 +178,7 @@ impl DeviceCut {
ub[c] = ubc;
open[c] = opc;
}
let l_faces = lap.elapsed();
// The solver's current table (the GCL table on a moving body) when
// it has one, else the static porous table.
let wall_flux: Vec<f64> = if solver.wall_fluxes().len() == g.cells() {
@@ -227,9 +230,10 @@ impl DeviceCut {
cursor[m] += 1;
}
}
let l_cells = lap.elapsed();
let ub_host = ub;
let ub_dev = [up_f(&ub_host[0]), up_f(&ub_host[1]), up_f(&ub_host[2])];
Some(Self {
let built = Self {
ub_host,
a: [up_f(ap_u), up_f(ap_v), up_f(ap_w)],
d: [up_f(&cut.d_u), up_f(&cut.d_v), up_f(&cut.d_w)],
@@ -246,7 +250,18 @@ impl DeviceCut {
None => [up_f(&[0.0]), up_f(&[0.0]), up_f(&[0.0])],
},
merged,
})
};
if profile {
let ms = |d: std::time::Duration| d.as_secs_f64() * 1e3;
eprintln!(
" table laps ({:?}): faces {:.0} ms, cells {:.0} ms, uploads {:.0} ms",
phase,
ms(l_faces),
ms(l_cells - l_faces),
ms(lap.elapsed() - l_cells)
);
}
Some(built)
}
/// The PREDICTOR tables from the PROJECTION tables of the same mask and