Consider a $C^\infty$ smooth nonconvex function $f$, and ODE $$ \dot{x}=-x\circ\nabla f(x),\;x(0)\in\mathbb{R}^d_{++}. $$ Then, can you prove that the solution has finite length under mild condition, e.g. $f$ satisfies the Kurdyka-Łojasiewicz inequality. We shold be careful that $x(t)$ can approach the boundary of $\mathbb{R}^d_{++}$. I believe it should be correct, I have tried many numerical test and cannot find any counterexamples.