Merge "Cleanup tokenize_b and hoist some invarients out of the loop."