pub enum PtxParam {
Scalar {
name: String,
ptx_type: PtxType,
},
Pointer {
name: String,
elem_type: PtxType,
},
}Expand description
A parameter to a PTX kernel function.
In PTX, kernel parameters are declared in the .entry signature:
- Scalar:
.param .u32 n— a value passed by copy - Pointer:
.param .u64 a_ptr— a device memory address (always 64-bit)
For pointer params, elem_type records the type of data pointed to
(used by the code generator for load/store instruction types).
Variants§
Scalar
A scalar value (e.g. .param .u32 n).
Pointer
A pointer to device memory (declared as .param .u64 name).
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PtxParam
impl RefUnwindSafe for PtxParam
impl Send for PtxParam
impl Sync for PtxParam
impl Unpin for PtxParam
impl UnsafeUnpin for PtxParam
impl UnwindSafe for PtxParam
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more