Today I just happen to read May 2008 edition of Dr.Dobb’s Journal printed edition and the article “Kernel-mode Databases” written by Andrel and Alexander from McObject really excited me.
The basic principle of any database engine is its performance and scalability and success of any database in most part relays on these two concepts. To achieve this, operating system kernel plays a major role in the form of …
- resource allocation
- thread scheduling
- low-level hardware access
So, looks like eXtremeDB try to overcome from this by releasing kernel-mode database. The kernel mode package actually overrides most of the kernel access calls that database engine expects by replacing with optimized direct calls and exposing them to the top layer. And the run-time engine of eXtremeDB actually linked with the kernel mode to avoid any overhead from the RPC.
It will be really nice if McObject can release benchmark results between regular kernel threads and the optimized one, along with conducting some more tests to prove the benefit from their kernel mode. Even though they found a solution for part of the common problems (kernel overhead, security, thread scheduling) but still there is a overhead from regular IO and exclusive lock time when doing the updates. Looks like some of their locks are using “Compare-and-swap“; but could not find much reference to where they were actually used within the code base.