Question: a. Provide the appropriate pseudo code for exploiting the data level (CUDA) parallelism in a matrix vector multiplication b=Ax. The CUDA code is required to

a. Provide the appropriate pseudo code for exploiting the data level (CUDA) parallelism in a matrix vector multiplication b=Ax. The CUDA code is required to be executed using multiple blocks. Invoke the CUDA kernel with N/256 blocks per grid in y axis and 256 threads per block in y axis. [7] aji 012 21121 +21202 + ... + Qin In (121 (122 22111 + 02222 + ... + 02nIn Ax= : : : ml Am2 an In Amli + m2.02 + ... + Amnan ain Il 2n Ja b. Compute the value of total number of iterations in the loop (refer the C code), total number of blocks, and number of threads in each block, if the kernel is executed with 128 threads, grid dimension = (1, 4), and block dimension = (1, 32). [3] c. Construct a 16x16 omega network. Set the switches of 16x16 omega network to see if it supports the permutations P=(0,14,5,13,6,8,7,12). If not chalk the connections that can be made and identify the blocked connections. [5] a. Provide the appropriate pseudo code for exploiting the data level (CUDA) parallelism in a matrix vector multiplication b=Ax. The CUDA code is required to be executed using multiple blocks. Invoke the CUDA kernel with N/256 blocks per grid in y axis and 256 threads per block in y axis. [7] aji 012 21121 +21202 + ... + Qin In (121 (122 22111 + 02222 + ... + 02nIn Ax= : : : ml Am2 an In Amli + m2.02 + ... + Amnan ain Il 2n Ja b. Compute the value of total number of iterations in the loop (refer the C code), total number of blocks, and number of threads in each block, if the kernel is executed with 128 threads, grid dimension = (1, 4), and block dimension = (1, 32). [3] c. Construct a 16x16 omega network. Set the switches of 16x16 omega network to see if it supports the permutations P=(0,14,5,13,6,8,7,12). If not chalk the connections that can be made and identify the blocked connections. [5]
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
