  We consider a switch operating under the MaxWeight scheduling algorithm,
under any traffic pattern such that all the ports are loaded. This system is
interesting to study since the queue lengths exhibit a multi-dimensional
state-space collapse in the heavy-traffic regime. We use a Lyapunov-type drift
technique to characterize the heavy-traffic behavior of the expectation of the
sum queue lengths in steady-state, under the assumption that all ports are
saturated and all queues receive non-zero traffic. Under these conditions, we
show that the heavy-traffic scaled queue length is given by
$\left(1-\frac{1}{2n}\right)||\sigma||^2$, where $\sigma$ is the vector of the
standard deviations of arrivals to each port in the heavy-traffic limit. In the
special case of uniform Bernoulli arrivals, the corresponding formula is given
by $\left(n-\frac{3}{2}+\frac{1}{2n}\right)$. The result shows that the
heavy-traffic scaled queue length has optimal scaling with respect to $n,$ thus
settling one version of an open conjecture; in fact, it is shown that the
heavy-traffic queue length is at most within a factor of two from the optimal.
We then consider certain asymptotic regimes where the load of the system scales
simultaneously with the number of ports. We show that the MaxWeight algorithm
has optimal queue length scaling behavior provided that the arrival rate
approaches capacity sufficiently fast.
