Re: Important question to all Euphoria users

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

Hayden McKay wrote:
> 
> Eu's new multitasking is still a single core application. There is one main
> thread that switches control to another proccess (ie: task_yield). Eu can't
> run two seprate processes in parallel (one must be qued after another). The
> only advantage is that we have timed process mechanism.

If this is in response to Rob's last message, then I think the point was that
once you code your program in a threaded manner it might be possible in future
for Euphoria to parallelise those threads.

Besides which, I think even current multithreaded applications would have a
hard time running truly concurrently, which I think that article mentioned
also.

> Even though Eu can only utilize one proccessor, on a duel core system Eu
> can run on the main core while the OS will utilize the other core to run
> the background type stuff ie:  virus scanners and other desktop resident
> proccesses.

I agree with this.  I think it is mainly the domain of the operating system
to determine which CPUs will be used for what.  I as a programmer don't want
to be concerned with that detail, nor do I want other programmers able to do
"allocateCPUs(100)" or whatever.  It's the job of the operating system to 
balance resources fairly and efficiently.

A typical desktop operating system runs maybe 50-100 processes so even if they
are all single threaded, if they are compiled with the operating system's
compiler it is quite feasible for the OS to multi-thread each process according
to whatever resources are available.  That's what Linux's SMP does and 
that can utilise Hyperthreaded CPUs as well.

> Note: A program useing more than one core does not benifit in any extra
>       speed. The overhead of switching states and stacks etc, outwieghs
>       the performance of a single inline thread.

The article mentioned that as well.

> So in my opinion the only benifit of haveing duel cores is only of benifit
> to the OS in that a program won't have to be halted when the OS want's to
> update the clock or somethin' stupid like that.

The article talked about possible 100's of core CPUs and how programs can
utilise that most efficiently.

I think the best Euphoria programmers can do is look at ways to thread our 
applications (once this is in the binary distribution) and hope that at a
later stage Euphoria uses true OS threads to manage these 'abstract' threads.

Gary

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

Search



Quick Links

User menu

Not signed in.

Misc Menu