Dynamic pipeline architecture for adaptive binary arithmetic codes