Questions: GPU Architecture and SIMT Execution

4 questions to test your understanding

Score: 0 / 4
Question 1 Multiple Choice

In a GPU kernel, the 32 threads of one warp reach `if (x[i] > 0) { A } else { B }`. Half the threads have x[i] > 0 and half do not. What typically happens?

AThe two halves run A and B at the same time on separate hardware
BThe warp runs A with the else-threads masked off, then runs B with the if-threads masked off
CThe threads that disagree with the first thread are cancelled
DThe compiler rejects the kernel, because warps cannot branch
Question 2 Multiple Choice

How does a GPU mainly keep its arithmetic units busy while some threads wait hundreds of cycles for data from memory?

AIt uses caches large enough to hold all data
BIt switches each cycle to other warps that are ready to execute
CIt predicts the data values and checks them later
DIt raises its clock rate while waiting
Question 3 True / False

Moving any program to a GPU will make it run faster than on a modern CPU.

TTrue
FFalse
Question 4 Short Answer

A student moves the addition of two 10-element arrays to a discrete GPU and finds it is slower than a simple CPU loop. Give the main reason.

Think about your answer, then reveal below.