Monday, October 19, 2009
Domain Driven Design
Saturday, August 22, 2009
Enabling options based on filetype in vim. Picked from here
:au BufRead *.c so ~/.vim/c.vim
:au BufNewFile *.c so ~/.vim/c.vim
:au BufRead *.py so ~/.vim/py.vim
:au BufNewFile *.py so ~/.vim/py.vim
Then put this in ~/.vim/c.vim:
set shiftwidth=8
And this in ~/.vim/py.vim:
set shiftwidth=8
That'll cause vim to source the specified file when the corresponding file type is read (or when a new file of the corresponding type is created).
Sunday, July 26, 2009
Friday, July 24, 2009
Cilk++
With the advent of 16, 24 (and also 32?) cored machines, multi-core machines are foraying in a big way. Most applications programmed aren't multi-core aware and hence though multi-core hardware prices aren't daunting, the applications can't really scale to it. Redesigning the legacy apps for multi-core aware is not a small task. However suites like Cilk++ do make it so. Cilk++ comes with a complete suite of compiler, run time system et al, which enables legacy applications that have been designed with no scaling in sight to be multi-core aware with minimal changes. Believe it or not, your code requires as less change as using three keywords effectively to indicate parallelism and synchronization – cilk_for, clik_spawn (for areas which have recursive calls or the types to make use of the multi-cores), cilk_sync (gather results from all the calls). Cilk provides race detector and reducers (race free global variables) as well. To know more, read this: http://www.cilk.com/multicore-products/cilk-solution-overview/ On using the three keywords to indicate parallelism, the Cilk++ compiler compiles the serial code into multi-core enabled parallel application. N-Queens Problem A good starting point to understand how this can be used is the N-Queens problem: http://www.cilk.com/multicore-blog/bid/6381/Multicore-enabling-the-N-Queens-Problem-Using-Cilk. There are other problems discussed as well. You could track the cilk blog to know more. And to know more about the Cilk language itself: http://supertech.csail.mit.edu/papers/cilk5.pdf
Tuesday, October 28, 2008
Python & Scalability
Found some good links
http://highscalability.com/youtube-architecture
http://highscalability.com/tags/python
http://www.python.org/about/success/strakt/ (This one uses Twisted as well)
Generally you can check here: http://www.python.org/about/success/
Couldn't resist this one: http://www.python.org/about/success/rackspace/
And yes, python is not only a scripting language, it is an object oriented programming language too!
A pat for Twisted is here as well:
http://news.zdnet.co.uk/software/0,1000000121,39246546,00.htm
Sunday, September 14, 2008
In search for an ORM
A few that I found, though we yet to evaluate are:
http://soci.sourceforge.net/
http://sourceforge.net/projects/open-orm/
Database Template Library: http://dtemplatelib.sourceforge.net/
Found this one mentioned at a couple of places; but the page just refuses to open up
http://ceamus.com/objbuilder/
If anyone has any better suggestions, let me/sharan know.
Friday, February 22, 2008
wake_me_up or wake_me_not
So was quite happy with this find, wherein a person has documented his learnings in one place.
http://groups.google.co.in/group/comp.os.linux.development.system/browse_
thread/thread/607517fcb4ecf29d/d752bf66a0a7bb48?lnk=st&q=wake_up_
interruptible+wake_up_interruptible_all#d752bf66a0a7bb48
And the equivalents of Mac can be found at
http://developer.apple.com/documentation/Darwin/Conceptual/KernelProgramming
/services/chapter_16_section_5.html#//apple_ref/doc/uid/TP30000905-CH219-CHDIDIDF
Hope this will help others in pursuit of wake_up problems!