codec: calculate theoretical minimal overhead