User: Password:
|
|
Subscribe / Log in / New account

w00t for exception-throwing languages

w00t for exception-throwing languages

Posted Jul 5, 2008 23:39 UTC (Sat) by giraffedata (subscriber, #1954)
In reply to: w00t for exception-throwing languages by walles
Parent article: TASK_KILLABLE

Things are getting better though. So maybe 10 years from now the uninterruptible sleeps can be removed from the kernel.

There will have to be advances on other fronts for us to go that far. The article covers one of the major reasons for uninterruptible sleep today: that your client can't deal with a half-finished operation. But the other reason programs do uninterruptible sleep is that they themselves lack the intelligence to finish a partially done operation -- i.e. there's nowhere to get off the highway before the destination.

I have found it takes some very hard work to make it possible to get out of something in the middle. You have to carefully decide whether to spend time and bug tolerance for that or use it for something else.


(Log in to post comments)

Don't forget the ten commandments...

Posted Jul 7, 2008 5:14 UTC (Mon) by walles (guest, #954) [Link]

... for C programmers. Let me quote the sixth commandment for you:

"
If a function be advertised to return an error code in the event of difficulties, thou shalt check for that code, yea, even though the checks triple the size of thy code and produce aches in thy typing fingers, for if thou thinkest ``it cannot happen to me'', the gods shall surely punish thee for thy arrogance.
"

Writing broken code for yourself is OK. Writing broken code for others is not.


Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds