brotli: speed up processing of commands in a meta-block using goto
brotli: speed up processing of commands in a meta-block using goto

Since decompression can come to an arbitrary halt when the buffer is filled,
there must be some way for the work to be resumed at the points where the read
buffer is flushed. The previous way to accomplish this, encapsulated every unit
of work in a function, and simply registered which function to call when
resuming the work. This is functionally correct, but leads to long recursive
call chains. Since Go does not support tail-call optimizations, these call
chains cannot be optimized away.

The new approach uses goto statements to step through each unit of work. When
work needs to be halted, we also store which label we need to jump to in order
to resume this work. This does not add much complexity compared to the
recursion approach, but significantly speeds up processing.

benchmark                              old MB/s     new MB/s     speedup
BenchmarkDecodeDigitsSpeed1e4-4        43.69        43.76        1.00x
BenchmarkDecodeDigitsSpeed1e5-4        37.47        43.71        1.17x
BenchmarkDecodeDigitsSpeed1e6-4        35.41        44.27        1.25x
BenchmarkDecodeDigitsDefault1e4-4      30.74        33.99        1.11x
BenchmarkDecodeDigitsDefault1e5-4      31.76        39.54        1.24x
BenchmarkDecodeDigitsDefault1e6-4      32.11        41.75        1.30x
BenchmarkDecodeDigitsCompress1e4-4     30.19        34.11        1.13x
BenchmarkDecodeDigitsCompress1e5-4     31.46        38.80        1.23x
BenchmarkDecodeDigitsCompress1e6-4     31.58        41.48        1.31x
BenchmarkDecodeTwainSpeed1e4-4         37.02        39.86        1.08x
BenchmarkDecodeTwainSpeed1e5-4         39.83        47.94        1.20x
BenchmarkDecodeTwainSpeed1e6-4         42.15        52.04        1.23x
BenchmarkDecodeTwainDefault1e4-4       31.21        35.25        1.13x
BenchmarkDecodeTwainDefault1e5-4       39.78        49.46        1.24x
BenchmarkDecodeTwainDefault1e6-4       43.37        54.81        1.26x
BenchmarkDecodeTwainCompress1e4-4      31.21        35.78        1.15x
BenchmarkDecodeTwainCompress1e5-4      39.67        49.66        1.25x
BenchmarkDecodeTwainCompress1e6-4      45.05        55.18        1.22x

dsnet/compress,dsnet/compress