Let $\mu$ be a general measure, suppose $f,g$ has compact support on $\mathbb{R}$, when does the integration by parts formula hold $$\int f'g d\mu = - \int g'fd\mu?$$ I know in general this is false, we can take $\mu$ to be supported on a point, say $0$, then it is not necessarily true that $$f'(0)g(0) = -g'(0)f(0).$$
If $\mu$ is absolute continuous w.r.t. Lebesgue measure, we have $\frac{d\mu}{dx} = h$ $$\int f'gd\mu = \int f'gh dx = -\int f(gh)'dx$$ where $(gh)'dx$ might be a measure. but we can not recover the form $\int g'fh dx$.
Thank you very much!