If I create two threads using pthread_create calls in linux does the kernel sees them as two schedulable entities ??>I can see two LWP with diff PIds.
This behaviour is correct.
The pids will differ, but the thread ids (tid) will be same for all the process in the same thread_group (of the parent thread). getpid() will return the tid instead of pid, so all processes will have the same value returned by getpid().
BTW, limit line length.
Regards, Om.
-- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/