9. Let the real number $a<-1$, and the variable $x$ satisfies $x^{2}+a x \leqslant-x$, and the minimum value of $x^{2}+a x$ is $-\frac{1}{2}$. Then $a=$ $\qquad$ .
9. $-\frac{3}{2}$.

Given $a<-1$ and $x^{2}+a x \leqslant-x$, we get $0 \leqslant x \leqslant-(a+1)$.
Let $f(x)=x^{2}+a x=\left(x+\frac{a}{2}\right)^{2}-\frac{a^{2}}{4}$.
If $-(a+1)<-\frac{a}{2}$, i.e., $-2<a<-1$, then the minimum value of $f(x)$ is
$$
f(-a-1)=a+1=-\frac{1}{2} .
$$

Thus, $a=-\frac{3}{2}$, which satisfies the condition.
If $-(a+1) \geqslant-\frac{a}{2}$, i.e., $a \leqslant-2$, then the minimum value of $f(x)$ is $-\frac{a^{2}}{4}=-\frac{1}{2}$.
Thus, $a= \pm \sqrt{2}$ (discard).