0
$\begingroup$

I want to calculate the total time taken for a fixed code run using an NVIDIA GPU (for instance, Tesla K40). The code has to run 1 million single-bit comparisons. All the comparisons are independent of each other. There is no memory access involved during the execution of the code since the complete data (2 bits per core) are stored in the local registers of the cores at the time of execution. So effectively, the code can run x number of comparison operations in parallel in a single instruction cycle (where x is the maximum number of parallel comparisons that can be executed on the mentioned GPU, I am not sure this will be the number of cores or the number of threads). I want to understand the process of calculating the following in this problem, using the datasheet of NVIDA Tesla K40:

  1. x
  2. time taken for each instruction cycle (for a single-bit comparison)
  3. Total time taken for 1 million single-bit comparisons
$\endgroup$
2
  • 1
    $\begingroup$ You haven't linked any documentation that you looked at for NVIDIA Tesla K40 GPU Accelerator before posting. How fast single bit comparisons can be done "in parallel" ought to depend both on the nature of the instructions used and on the speed at which data can be supplied. $\endgroup$
    – hardmath
    Nov 4, 2022 at 16:13
  • $\begingroup$ In addition to clarifying what "using the datasheet of NVIDA Tesla K40" references, you should be more explicit about the algorithm (including input and output specifications). For example your one million one-bit comparisons might mean that you input two one-million bit arrays and output the xor of them (possibly overwriting one of the inputs). Alternatively you might mean that you perform the bit comparisons until you find the first disagreement between inputs and return its location (within the bit arrays). $\endgroup$
    – hardmath
    Nov 5, 2022 at 14:15

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.