Is $ \int \frac{f'(x)}{f(x)} \ dx = \log |f(x)| + C$ true for all differentiable functions $f$? Let $f$ be a differentiable function. Is the following identity true for all such $f$?
$$
\int \frac{f'(x)}{f(x)} \ dx = \log |f(x)| +  C
$$
I ask because there exist differentiable functions whose derivatives are not Riemann integrable (see here for instance). On the other hand, if we use the substitution $u = f(x)$ for $f$ on $[a,b]$,
$$
\int_a^b \frac{f'(x)}{f(x)} \ dx  = \int_{f(a)}^{f(b)} \frac{1}{u} \ du
$$
and the RHS appears to be integrable. How can we reconcile this?
Any comments, help and explanations are welcome.

Even if you take, say $f(x)=2+x^2\sin\frac{1}{x^2}, f(0)=2$ on $[-1,1]$ so that $f(x)\neq 0,$ you have $f’(x)$ is unbounded and $f$ is bounded away from $0$ on $[-1,1],$ so $\frac{f’(x)}{f(x)}$ is not bounded, and hence it isn’t Riemann integrable.
Indeed, if $f$ is never $0$ on $[a,b]$ then $f$ is bounded away from zero, so that $f’(x)$ is unbounded if and only if $f’(x)/f(x)$ is unbounded.
That doesn’t mean there isn’t a useful value for the integral, only that Riemann doesn’t get us to there immediately.
For the given $f,$ we’d have to do $$\int_{-1}^{-a}+\int_b^1$$ and then let $a,b\to0^+,$ to get a the value.
Or we can do a Lesbesgue integral.
Either way, we’ll get $\log |f(1)|-\log|f(-1)|.$
