Skip to content

Commit 66b8bfb

Browse files
committed
fix: pre-commit error
1 parent 40abfea commit 66b8bfb

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

qdp/qdp-core/src/gpu/encodings/angle.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -402,6 +402,15 @@ impl QuantumEncoder for AngleEncoder {
402402

403403
impl AngleEncoder {
404404
#[cfg(target_os = "linux")]
405+
/// Encodes `input_len` angle values from a device-resident `f32` buffer into a GPU state
406+
/// vector, using the provided CUDA stream for all launched work.
407+
///
408+
/// # Safety
409+
/// The caller must ensure that `input_d` points to at least `input_len` contiguous `f32`
410+
/// values in GPU-accessible memory and remains valid for the duration of this call.
411+
/// The caller must also ensure that `stream` is either null or a valid CUDA stream handle
412+
/// associated with `device`, and that no concurrent use of these raw pointers violates Rust's
413+
/// aliasing or lifetime rules.
405414
pub unsafe fn encode_from_gpu_ptr_f32_with_stream(
406415
device: &Arc<CudaDevice>,
407416
input_d: *const f32,

0 commit comments

Comments
 (0)