Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Processes and threads are both schedulable entities in linux, which is a bit muddled, but when we talk about processes, it still implies a separate address space. That's the whole point of distinguishing them.

Of course the more sane model is for a process to be an address space container, and threads to be associated with a particular process, but when discussing them, that particular implementation detail is moot.



Right, I know what processes and threads are under Linux; instance of task_struct. But I'm asking because if we're going to understand why he's seeing the performance he presented, we need to know the kind of system he's running on. And how Linux treats threads and processes is one major difference between it and Windows.


No, my argument is that the point is moot. If a task_struct on linux does not trigger an address space switch it is a thread. While to the kernel they are (regrettably) the same entity, they still have relevant performance characteristics of windows {process, thread}; the difference in cost is the cost of switching address spaces. That cost appears in either operating system. If there is any difference from the way Windows handles threads it is simply negligible in terms of this benchmark.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: