Re: [patch] threading fix, tid-2.5.47-A3

From: Luca Barbieri (ldb@ldb.ods.org)
Date: Mon Nov 18 2002 - 03:27:29 EST


> > You could avoid the additional pointer by letting
> > child_tidptr = (!(flags & CLONE_VM) && current->user_tid) ?
> > current->user_tid : parent_tidptr;
>
> This doesn't work since it would overwrite the TID field in the calling
> thread's descriptor.
No: for the pthread_create case you would pass the pointer to new struct
pthread tid in parent_tidptr, while for fork you would pass the
parameter of cfork as parent_tidptr and child_tidptr would be inherited.

However I don't think that this is a good interface, just a bit better
than having two flags and a single pointer.



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Nov 23 2002 - 22:00:21 EST