pub fn max_potential_block_size(
func: &Function,
dynamic_smem_bytes: usize,
block_size_limit: i32,
) -> Result<(i32, i32)>Expand description
Block size that maximises occupancy for func, assuming the given
fixed dynamic_smem_bytes. Returns (min_grid_size, optimal_block_size):
launch min_grid_size blocks of optimal_block_size threads to cover
the device with peak SM-utilization.
block_size_limit clamps the returned block size; pass 0 for the
device’s documented maximum.