logoalt Hacker News

masklinnyesterday at 8:23 PM1 replyview on HN

Threads which can’t share state are called processes.


Replies

RealityVoidtoday at 6:03 AM

Fair-ish point, if a bit cheeky. But threads can be still threads, i.e. in the same address space, but without actually having shared state between them. And then they're still threads, not processes.

You could also have stuff like message ques going between them, the cost of passing data around is small then, you don't have do leave user space to put stuff in the mq's. But can you still call it "not having shared state"? I'd say yes, even though you do share memory and you do have the mutually accessible que. But I can see why you could argue otherwise.

show 1 reply