5 ms·
Take a look at lthread: https://github.com/halayli/lthread https://github.com/halayli/lthread lthread supports concurrency and parallelism using pthreads. Eac
by halayli 14y ago
Take a look at lthread:
https://github.com/halayli/lthread https://github.com/halayli/lthread
lthread supports concurrency and parallelism using pthreads. Each lthread scheduler runs its own lthreads concurrently, or better said, one at a time. But from an observer's perspective they look like they are running in parallel.
Now if you create 2 pthreads on a 2 core machine and each runs an lthread scheduler then you have true parallelism because you can have 2 lthreads running in parallel at the same time. One by each scheduler.
I feel this is a closer context to what Rob is discussing than what I found in the comments here.