Improve decoder speed, cleanup

Move decoder's function pointer registration from runtime to static this
improved its performance dramatically (depending on the input 10-30%).

- cleanup
- create realloc_or_raise() that is used in s_alloc() and
  alloc_or_raise()
- benchmark using benchmark/ips, which tries to compare
  iterations/second