Added comments.
Remove some dead code.