in reply to Re^15: Should I use threads? Perl/DHCP/Radius
in thread Should I use threads? Perl/DHCP/Radius

. I'l bet ... So....eventloops rule the human mind

Ah. So now you're a expert research biologist. Though you know, you may well be right. It would explain why they suffer the same problems as event loops.

Which is why when a guy sees a girl in a short skirt, he fails to notice the oncoming truck. And why the women on the cell phone hearing about her girlfriend's latest conquest, fails to notice the brake lights on the car in front and tail-shunts it.

Ie. Processing the current event completely excludes a timely response to any other event; including the more urgent ones.

Threads don't suffer this problem. Which is why battleships and attack subs use threads. Multiple, dedicated, human brains, each to monitor and respond to their own critical events.


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
RIP an inspiration; A true Folk's Guy
  • Comment on Re^16: Should I use threads? Perl/DHCP/Radius

Replies are listed 'Best First'.
Re^17: Should I use threads? Perl/DHCP/Radius
by Anonymous Monk on Aug 25, 2010 at 16:38 UTC
    You sank his battleship :)

    BTW, video was a lie, there was no gorilla, just a girl in a suit

Re^17: Should I use threads? Perl/DHCP/Radius
by shmem (Chancellor) on Aug 25, 2010 at 22:42 UTC

    This is getting rather OT, so I might as well do some trolling ;-)

    Which is why when a guy sees a girl in a short skirt, he fails to notice the oncoming truck.

    Well, that's not becuse the poor guy is unable to multitask, but because at that very moment he stops multitasking - and focuses on that girl in a short skirt. And it could well be that his attention isn't even much on the girl but much more on the sensation this sight is causing to himself.

    I haven't read much into that "modern research", but if the result is

    And researchers at Stanford University found that regular multi-taskers are actually quite bad at it. In a series of tests that required switching attention from one task to another, heavy multi-task had slower response times than those who rarely multi tasked.

    What that suggests, the researchers say, is that multi-task are more easily distracted by irrelevant information. The more we multi-task, the less we are able to focus properly on just one thing.

    - well, then the researchers have found out one obvious thing: tasks which demand our full attention aren't very apt for being dealt with by multitasking. Oh, wait... that isn't even multitasking what they are talking about, it's about context switching!

    The other day I've been told that "on television" (whatever that is, I don't have one) amazing guys can be seen. In live shows, they chop onions, talk to the audience at the same time about what they are doing, keep an eye on the color of things frying and the bowl being filled with water from the tap, react to changes of the scent of something boiling over there, answer questions and process instructions from the filming stuff via an earphone, and more - and all that at the same time!

    I didn't do research, but found out by doing (and not being able to) that I am, whilst playing lute, unable to talk or answer a question or even utter a single word if it's not in the context of the music (i.e. text of song I am performing). Does that mean that I am unable to multitask? No - it rather means that I have only one "channel of expression". But I am able to chop onions or firewood or screwing up my motorbike whilst at the same time chewing on the universe like on a piece of sugar cane with a good friend, and! listening to music.

    But to meditatively explore a piece of musical art - which requires all of me being focused on it, I must refrain from doing anything else.

    This "event loop vs. thread" discussion between you and zentara doesn't make sense. Event loops can be implemented with threads, and event loops can be used - via time slicing - to simulate threads. Let the discussion be practical

    Ah, and the human mind? What event loop? Rather, the human mind is an event filter in a stream of events, driven by a singular conciousness, which condenses what is in his short time memory into what becomes it's own story. A phenomenon not very apt indeed to drive pro and cons of event loops or threads for a given computational problem.

      Well, that's not becuse the poor guy is unable to multitask, but because at that very moment he stops multitasking

      I never asserted that we don't multi-task; just that we are lousy at it.

      It's less than a month since I watched a Michelin-starred and frequent TV chef, slice his thumb whilst chopping onions. Some poor sous-chef elsewhere in the kitchen dropped a pan--loud noise--momentary distraction--blue plaster. (And possibly an ex-sous-chef, but they didn't show that bit! :)

      Like all analogies, it is flawed. And each of us chose to emphasise those bits which we thought best supported our point of view.


      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      "Science is about questioning the status quo. Questioning authority".
      In the absence of evidence, opinion is indistinguishable from prejudice.
Re^17: Should I use threads? Perl/DHCP/Radius
by zentara (Cardinal) on Aug 25, 2010 at 19:39 UTC
    So even though, your own brain and the brains of most humans, run time loops of sorts, to track the event-sequences of their lives, you assert that there is better logic to do it, and that we should model our machines to think differently from us?

    Yes, I feel that I am qualified to comment on how the inner logic of my mind works. ... even without some degree.... philosopher, know thyself

    In any event, at my level of programming, event loops are the cat's meow, and our numbers are growing everyday. Be afarid, very afraid . :-)


    I'm not really a human, but I play one on earth.
    Old Perl Programmer Haiku ................... flash japh
      So even though, your own brain and the brains of most humans, run time loops of sorts, to track the event-sequences of their lives, you assert that there is better logic to do it, and that we should model our machines to think differently from us?

      Besides that your gross oversimplification of the issues involved is naive, bordering on ...um...

      Insects and birds are very successful natural fliers, but we don't fly away on holiday in a Jumbo Ornithopters. And we never will.

      Nature is amazing, but it isn't always the best model for man made endeavours.

      and our numbers are growing everyday.

      I'd love to see the scientific basis for that assertion. But I guarantee you won't be able to find any research to back it up.


      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      "Science is about questioning the status quo. Questioning authority".
      In the absence of evidence, opinion is indistinguishable from prejudice.

        /me builds an auto threading event based looping thing-a-ma-jig, uses it to build an AI that then builds an Ornithopter and flies far away!!!


        ___________
        Eric Hodges
        My apologies, BrowserUk. You know I just like to get your dander up. I do respect, and am in awe of your code and knowledge.

        BTW, I fly an OMnithopter.


        I'm not really a human, but I play one on earth.
        Old Perl Programmer Haiku ................... flash japh