Previous | Next --- Slide 61 of 88
Back to Lecture Thumbnails
suninhouse

Perhaps a basic question but what are the exact/precise difference between 'simultaneous' and 'concurrent' when used to describe instruction streams?

itoen

Simultaneous means the instructions are being run at the same time. Each core can run one instruction stream at once, so with 16 cores we have 16 simultaneous instruction streams.

Concurrent means there are different sets of instruction streams (one for each thread on the core) and the core is cycling through them and interweaving the instructions from different streams. For example, with four threads A, B, C, D, the core might execute 10 instructions from A, then 8 instructions from D, and so forth.

If you took a snapshot in time, you would see instructions from 16 streams that are being executed at that moment in time. However, over a short period of time, there could be instructions from up to 64 different streams, as each of the 16 cores cycles through their 4 threads.

ajayram

I'm trying to understand how they arrived at 512 independent pieces of work.

16 cores * 4 threads per core = 64 concurrent instruction streams. 64 * 8 SIMD ALUs per core (8 adds/muls/etc can happen at once) = 512 independent pieces of work ?

Thanks for any clarification!

lfu

@ajayram

Yes, I think that's the correct calculation.

Maybe one example could be the SIMD parallelized sinx from lecture. Recall that there was a vector of N elements, and we were calculating sin(x) on each element. Calculating each element is independent. The code used 8 SIMD ALUs to process 8 elements at once. Let's change the problem a bit and say you also spawned 64 threads, where each thread processes N/64 elements, so data is split evenly across the 64 threads. Each thread does exactly what the SIMD parallelized sinx does from lecture, but on a smaller subset of examples. Now you are parallelized to 512 independent pieces of work at a time.

Does this make sense? This was my understanding but I could be wrong.

Please log in to leave a comment.