|
From: Julian S. <js...@ac...> - 2010-01-28 09:40:48
|
> By the way, the "abstract_handle" is unnecessary in my opinion. Since > B_DEPART() will always be invoked from the same thread as the > corresponding B_ARRIVE() call, a threading tool can figure out which > B_DEPART() corresponds to B_ARRIVE() call by keeping a limited amount > of state information. Yes, I think you're right. The extra information is: for each thread, the current barrier we're associated with, and, for that barrier, the VTS we must update our state by, when leaving. I think that would make the implementation more complex, though. Using the abstract_handles, the checker only needs to keep track of data per-barrier. With your "completely automatic" proposal it would have to also have some per-thread data. J |