Evan Martin (evan) wrote in evan_tech,
Evan Martin
evan
evan_tech

events and threads

LtU: Why Events Are a Bad Idea

As primarily an application programmer, it always seemed to me the problem with threads has been preemption. My tasks are always IO-bound and so any time I'm preempted while not blocked is a wasted context switch. By cooperatively multitasking it would seem I could significantly reduce the trouble of using threads (for example, I'd no longer need to worry about synchronization) and get most of the benefits.

It seems this reasoning would similarly apply to any low-CPU/IO-bound server, such as the web server they talked about in their paper or even memcached. (But what's with benchmarking your C app against a Java one? That's hardly fair.)
Tags: go read
Subscribe

  • megaupload captcha

    Someone make a Javascript-based captcha cracker for megaupload. It's strange to see those captchas again because I idly myself wrote a…

  • zombie ghosd

    I was tickled to discover another IBM developerworks article on one of my abandoned hacks and that both it and its predecessor have been translated…

  • gat, a git clone in haskell

    I've been pretty busy with work lately, so I may as well dump this on the internet before it gets too dusty. Though I think I understand Git decently…

  • Post a new comment

    Error

    default userpic
    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 6 comments