[−][src]Struct rustacuda::function::BlockSize
Dimensions of a thread block, or the number of threads in a block.
Each component of a BlockSize
must be at least 1. The maximum size depends on your device's
compute capability, but maximums of x = 1024, y = 1024, z = 64
are common. In addition, the
limit on total number of threads in a block (x * y * z
) is also defined by the compute
capability, typically 1024. Launching a kernel with a block size greater than these limits will
cause an error.
Fields
x: u32
X dimension of each thread block
y: u32
Y dimension of each thread block
z: u32
Z dimension of each thread block
Implementations
impl BlockSize
[src]
pub fn x(x: u32) -> BlockSize
[src]
Create a one-dimensional block of x
threads
pub fn xy(x: u32, y: u32) -> BlockSize
[src]
Create a two-dimensional block of x * y
threads
pub fn xyz(x: u32, y: u32, z: u32) -> BlockSize
[src]
Create a three-dimensional block of x * y * z
threads
Trait Implementations
impl Clone for BlockSize
[src]
impl Debug for BlockSize
[src]
impl Eq for BlockSize
[src]
impl<'a> From<&'a BlockSize> for BlockSize
[src]
impl From<(u32, u32, u32)> for BlockSize
[src]
impl From<(u32, u32)> for BlockSize
[src]
impl From<u32> for BlockSize
[src]
impl PartialEq<BlockSize> for BlockSize
[src]
impl StructuralEq for BlockSize
[src]
impl StructuralPartialEq for BlockSize
[src]
Auto Trait Implementations
impl RefUnwindSafe for BlockSize
impl Send for BlockSize
impl Sync for BlockSize
impl Unpin for BlockSize
impl UnwindSafe for BlockSize
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,