Improve decode speed by ~50%; nbd

https://gist.github.com/naomik/6473346
Merge pull request #1 from naomik/master

Improve decode speed by ~50%; nbd