rtx-cfd legacy GPU modules: cudarc 0.18 API — unsafe launches, the stream accessor, memcpy_htod argument order; the renamed k-ε constants and ::standard(); get_module clones; CfdConfig test literals take ..Default
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 / Build (ubuntu-latest) (push) Failing after 5s
CI / Clippy Check (push) Failing after 5s
Documentation / Build User Guide (push) Successful in 6s
Documentation / Build API Documentation (push) Failing after 17s
CI / Build CPU-Only (Explicit) (push) Failing after 32s
CI / Format Check (push) Failing after 42s
Performance Benchmarks / Run Benchmarks (push) Successful in 1m59s

This commit is contained in:
Omar Sobh
2026-09-16 07:16:39 -05:00
parent de435eb91c
commit 5e402918bb
6 changed files with 432 additions and 378 deletions
@@ -377,21 +377,23 @@ impl PisoGpuSolver {
};
unsafe {
self.kernel_manager
.stream()
.launch_builder(&func)
.arg(&mut buffers.mass_source)
.arg(u)
.arg(v)
.arg(&(density / dt))
.arg(&dx)
.arg(&dy)
.arg(&(buffers.nx as i32))
.arg(&(buffers.ny as i32))
.launch(config)
.map_err(|e| {
CfdError::gpu_error(&format!("Divergence kernel launch failed: {}", e))
})?;
unsafe {
self.kernel_manager
.stream()
.launch_builder(&func)
.arg(&mut buffers.mass_source)
.arg(u)
.arg(v)
.arg(&(density / dt))
.arg(&dx)
.arg(&dy)
.arg(&(buffers.nx as i32))
.arg(&(buffers.ny as i32))
.launch(config)
.map_err(|e| {
CfdError::gpu_error(&format!("Divergence kernel launch failed: {}", e))
})?;
}
}
self.kernel_manager.synchronize()?;
@@ -460,21 +462,23 @@ impl PisoGpuSolver {
let correction_factor = -dt / density;
unsafe {
self.kernel_manager
.stream()
.launch_builder(&func)
.arg(&buffers.pressure_correction)
.arg(&mut buffers.u_correction.clone())
.arg(&mut buffers.v_correction.clone())
.arg(&correction_factor)
.arg(&dx)
.arg(&dy)
.arg(&(buffers.nx as i32))
.arg(&(buffers.ny as i32))
.launch(config)
.map_err(|e| {
CfdError::gpu_error(&format!("Gradient kernel launch failed: {}", e))
})?;
unsafe {
self.kernel_manager
.stream()
.launch_builder(&func)
.arg(&buffers.pressure_correction)
.arg(&mut buffers.u_correction.clone())
.arg(&mut buffers.v_correction.clone())
.arg(&correction_factor)
.arg(&dx)
.arg(&dy)
.arg(&(buffers.nx as i32))
.arg(&(buffers.ny as i32))
.launch(config)
.map_err(|e| {
CfdError::gpu_error(&format!("Gradient kernel launch failed: {}", e))
})?;
}
}
self.kernel_manager.synchronize()?;
@@ -644,6 +648,7 @@ mod tests {
viscosity: 0.01,
density: 1.0,
device_id: 0,
..CfdConfig::default()
};
let params = PisoParameters::default();
@@ -702,6 +707,7 @@ mod tests {
viscosity: 0.01,
density: 1.0,
device_id: 0,
..CfdConfig::default()
};
let params = PisoParameters::default();