Revert "Merge pull request #1170 from jmdavis/perf"

This reverts commit 684c43dfc52105b232641965702a10295d0ba7cb, reversing
changes made to 707a60101b41ac54af2f757beec89875fe51ac37.