Code Cleanup

- Added comments
- Fixed a possible bug in create
Merge branch 'dheeraj' into nithin
Cache replacement bug fix

- No other known bugs currently