>From: "Bresticker, Shalom" <shalom.bresticker@intel.com> >Who is the parent thread in this case? Could I argue that the parent >disappears and thus never reaches a blocking statement? No. I don't believe that calling a function is considered by the 1800 LRM to create a thread. The thread executing in the function is the same thread that called the function and the same thread that continues after the return. Now it could have been defined differently. Calling a function could have been defined as the parent creating a child thread to execute the function and then suspending itself. The return would then cause the child to disappear and wake up its parent to continue. The text in 10.2 of the 1364 LRM on enabling tasks describes it much like this. The behavior of the two definitions would be equivalent in 1364. The second one seems strange, but might have been considered more natural from a hardware perspective. Or maybe that is how Verilog-XL actually implemented it; I don't know. But the two are not equivalent in 1800. Constructs like "wait fork" and "disable fork" wouldn't treat them the same. For example, if you do a "wait fork" in a task, it waits for all the children of this thread. With the first definition, that includes all the children it created before calling the task. With the second definition, those would not be children of this new task thread, so they would not be included. Steven Sharp sharp@cadence.comReceived on Mon Feb 20 12:19:08 2006
This archive was generated by hypermail 2.1.8 : Mon Feb 20 2006 - 12:19:27 PST