Comment by dwattttt
1 day ago
I'm curious; using hardware threads is M logical threads preemptively scheduled on N physical cores. In what way does this not satisfy the original criteria?
1 day ago
I'm curious; using hardware threads is M logical threads preemptively scheduled on N physical cores. In what way does this not satisfy the original criteria?
They are still full OS threads: they have a full-size stack and have all the same overheads for context switching. Why would you think that a marketing term for a CPU feature is equivalent to an M:N scheduler?
A "hyperthread" can schedule work for two OS threads simultaneously on a single core. An M:N scheduler will schedule millions of green threads on as many cores/hardware threads as you give it (typically you'd give it all of them).
Yes. However the number of times I've scheduled millions of concurrent tasks is 0; hence my question about subjective experience.
I would guess that how well integrated OS threads or green threads are into a language has a much stronger impact on experience & quality.
EDIT: you're also comparing hyper threading itself to the green thread scheduler (M green threads vs 2 logical cores), that doesn't make any sense. You probably want to compare to the OS's scheduler. It will schedule those millions of threads over all the hardware concurrency available too.
That's just not what is referred to as green threads.
Yes, in implementation they are not. I'm curious what the difference in subjective experience is.
Green threads don’t allocate stack frames and do not require such a massive context switch, which in turn allows for many more threads.
4 replies →