Page 4 of 10
Re: Co_Routines Support for Oberon
Posted: Tue Apr 04, 2017 5:57 pm
by Dmitry Dagaev
If RETURN is for termination only, it can be accepted. If for intermediate transfer to parent - not.
Co_ package will remain the same, as new kernel version is not applicable for me. In any case, I'll finish my own Kernel with MarkRegion support.
Re: Co_Routines Support for Oberon
Posted: Wed Apr 05, 2017 8:54 am
by Ivan Denisov
Dmitry Dagaev wrote:If RETURN is for termination only, it can be accepted. If for intermediate transfer to parent - not.
Co_ package will remain the same, as new kernel version is not applicable for me. In any case, I'll finish my own Kernel with MarkRegion support.
Dmitry, you have said that initial Josef's version of Kernel is ok for your aims. Did you change your opinion?
http://blackboxframework.org/unstable/i ... a1.816.zip
Re: Co_Routines Support for Oberon
Posted: Wed Apr 05, 2017 12:59 pm
by Dmitry Dagaev
No, he has changed his version
Re: Co_Routines Support for Oberon
Posted: Wed Apr 05, 2017 3:32 pm
by Ivan Denisov
Dmitry Dagaev wrote:No, he has changed his version
We still in the discussion how to make this. So we are hearing all the arguments for and against various versions. I am also think that initial version of the Kernel was better. However also we should move WinApi from basic interface modules of the System folder to Host subsystem.
Re: Co_Routines Support for Oberon
Posted: Wed Apr 05, 2017 5:26 pm
by Dmitry Dagaev
Josef,
Performance benefits can be reached for background tasks. Co_ObxActions in background gains 400000 times per BlackBox ObxActions example in execution time. Why? Scheduler uses Services.Action time effectively. See ObxActions above.
Re: Co_Routines Support for Oberon
Posted: Wed Apr 05, 2017 8:28 pm
by Robert
I am not in a position to add anything of technical significance to this discussion, but just wanted to say I have been reading it with great interest.
I particularly liked the hungry philosophers example; so much so I described it to the (non computer) people I was staying with as a guest last weekend. Their reaction was that the philosophers were not doing any thinking, or they would have thought to buy more forks, or eat with their fingers. I have been teased about forks and thinking every mealtime since.
Re: Co_Routines Support for Oberon
Posted: Thu Apr 06, 2017 2:51 am
by Dmitry Dagaev
The alternative way of problem solving means that starvation encourages people to use their brains effectively. At least to scale on more resources.
Re: Co_Routines Support for Oberon
Posted: Thu Apr 06, 2017 7:37 am
by luowy
Dmitry
Do you have updated your Co_ package?
the module Co_Api is WinApi interface, the calling convention should be stdcall,
your [ccall] flag confusing me.
Re: Co_Routines Support for Oberon
Posted: Thu Apr 06, 2017 6:14 pm
by Dmitry Dagaev
Dmitry Dagaev wrote:The only reason to use ConvertThreadToFiberEx is to use FIBER_FLAG_FLOAT_SWITCH... So I met the portability problem and decided to use default behaviour.
The latest version uses ConvertThreadToFiber
Re: Co_Routines Support for Oberon
Posted: Fri Apr 07, 2017 7:32 am
by Josef Templ
Dmitry Dagaev wrote:Josef,
Performance benefits can be reached for background tasks. Co_ObxActions in background gains 400000 times per BlackBox ObxActions example in execution time. Why? Scheduler uses Services.Action time effectively. See ObxActions above.
If it is considered important it should be possible to optimize special Task use cases
by executing several rounds at once, I think.
I havn't looked into this yet because i tried to keep the base module simple.
But it may be a good idea indeed. Don't know yet how complicated it would be.
- Josef