Performance polish.
Merge pull request #6 from ivanzhaowy/master

Performance polish.