Improved port implementation and beautified some comments.