Saturday 11 April 2009

concurrency

Just read an interesting post about processors, which ones are better. The scary thing is someone had written "if you have a task to run on a single core, when you run it on a dual core it will complete twice as fast, FACT" well despite the fact this person has written FACT at the end it is totally untrue. Not only can the task not finish twice as fast, it may not complete any faster than a single core machine. This got me thinking, if this is a common misconception even in well regarded tech circles then maybe this explains why very little progress ( at least from what I've seen ) has been made into purposely writing programs to run on multiple cores. Presumably threads of operation are assigned to a particular processor already, this would help to load balance a system and yes vastly improve multithreading i.e. when we use several applications at the same time, however the programs themselves are not written for multiple cores, as far as I am aware. I might write an article about this at some point in the future, just as soon as I have more than a simple netbook to write with. Having said that, this netbook is fantastic, it still manages over 6 hours ( did 7.5 when it was new and running windows not linux ) of continuous use, building apps in netbeans whilst listening to music online e.t.c. very impressive. It's the Samsung NC10 if anyone is interested. Having said that I am seriously looking forward to what netbook offerings come off the back of nVidias ION, now that is a serious pico-ITX board. Whilst researching this I read an article stating that pico-ITX is currently the smallest ITX form factor after the nanao and micro, but I could have sworn the clever guys at VIA had announced a mobile-ITX form factor which was as small as a motorola V3 phone, could be wrong though so I'll have another look. Whilst on the subject of concurrency, does anyone have any metrics for using activeMQ topics as the broadcast bus in a distributed node concurrent system, the system I am looking into doesn't require so much speed to use a shared access memory model type design so I was curious about anyone elses finidings doing things this way.

1 comment:

  1. Twice as fast?

    If the task being referred to is a single task, i.e. a single thread of execution. Rubbish.

    If it's a process that may well be running many threads then it will run faster on two or more processors.

    Twice as fast? Maybe... but not if the threads need to interact and not if there is any kind of bottleneck somewhere else like disk or network IO.

    Overall - Aye, misleading enough to be considered bunk! :)

    The thread allocation per processor is down to the OS. Applications don't get a say (at least on Windows - not 100% sure on *NIX but even then it's not commonly done I'm sure!).


    activeMQ - sorry can't help there :)

    ReplyDelete

 
Stack Overflow profile for Richard Johnson at Stack Overflow, Q&A for professional and enthusiast programmers