I am currently in the process of writing an IB Extended Essay on the efficacy of multithreading on increasing the performance of applications. So far, I have been able to deduce that there are three main multithreading techniques:
- Cooperative/Coarse-Grained/Block Multithreading
- Preemptive/Fine grained/Interleaved Multithreading
- Simultaneous Multithreading
My question: Under what circumstance is each method of multithreading considered to be the optimal one to use? I assume one or the other will perform better with a higher number of cores, repetitive instructions, low/high remote access latencies or low/high remote cache miss rates, etc.
This means that if I were to create a simple program in Java with two versions, one using multithreading and the other not, I want to be able to see the largest possible processing time difference between the two versions.
P.S Can they all even be implemented at the user level (i.e. coded into commercial software)?