Re: submitting code

new topic     » goto parent     » topic index » view thread      » older message » newer message
jeremy said...
useless said...
Jeremy said...

Date sent: Tue, 01 Sep 2009 08:37:00 -0400 From: Jeremy Cowgar <jeremy@cowgar.com> To: OpenEuphoria Developer Discussion <rapideuphoria-develop@lists.sourceforge.net> Subject: [Rapideuphoria-develop] task_yield and shared libraries

Instead of making task_yield a noop in shared libraries, would it be possible to make it call the main processes task_yield() function?


In the main process, the main process can call it's task_yield. No other task should be able to call the main process's task_yield.

Jeremy didn't say "call task_yield of the main process's task manager".

No, he said "call the main processes task_yield() function".

Which is exactly what it should do. Then you went into the idea of yielding to a parent task. That's what no one could understand. How do you go from the main processes task_yield() to the parent task?

Jeremy


Main process has a task_yield, by which it yields.

Task1 has a task_yield, by which it yields.

Task1 should not be able to call the main process's task_yield, it should be able to call only it's own task_yield. By calling it's own task_yield, it is yielding the cpu TO the task manager to assign to other tasks, such as the main task, since it's the only other task mentioned here.

If task1 calls the main process's task_yield, then task manager is told the main task has yielded.

In this example, the main process is the only executing code other than task1, therefor the main process is task1's parent.

useless

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu