Switched to actual byte arrays for about 50x speedup