It depends when you arrive. Early mornings are the worst times (particularly for non-EU passengers).
The T5 immigration hall is more than sufficient in terms of design capacity, but UKBA are so inefficient (and understaffed) that the queues are sadly unavoidable at present.