processes and threads
Posted: Wed Feb 27, 2013 3:40 pm
Dear fellow kernel programmers,
Currently there is no way in KolibriOS to tell which thread belongs to what process, because there is no real process identifier.
There is field called PID, but it practice, it seems to be the thread identifier.
Therefore, I propose to rename the field pid in struct TASKDATA to tid, and introduce a new field pid.
All current references to TASKDATA.pid shall be changed to TASKDATA.tid
The procedure new_sys_threads should then be updated to copy the PID of the process to the new thread.
(Single threaded processes will have PID == TID)
Am I forgetting something? Do you think it's a good idea?
Currently there is no way in KolibriOS to tell which thread belongs to what process, because there is no real process identifier.
There is field called PID, but it practice, it seems to be the thread identifier.
Therefore, I propose to rename the field pid in struct TASKDATA to tid, and introduce a new field pid.
All current references to TASKDATA.pid shall be changed to TASKDATA.tid
The procedure new_sys_threads should then be updated to copy the PID of the process to the new thread.
(Single threaded processes will have PID == TID)
Am I forgetting something? Do you think it's a good idea?