To find the amount of spending on marketing that will achieve the maximum profit for the company given the profit function \( P = -5x^2 + 1000x + 5000 \), we need to determine the vertex of the quadratic function. The vertex form of a parabola represented by \( y = ax^2 + bx + c \) occurs at \( x = -\frac{b}{2a} \).
In this case:
- \( a = -5 \)
- \( b = 1000 \)
Using the vertex formula:
\[ x = -\frac{b}{2a} = -\frac{1000}{2(-5)} = -\frac{1000}{-10} = 100 \]
Thus, the amount of spending in thousands that will be directed towards marketing to achieve the maximum profit is \( \boxed{100} \).