I am not comfortable with differential forms and do not understand what $d (\log x)$ represents. My understanding is that since
$$ \frac{d}{dx} \log(x) = \frac{1}{x} $$
then we can write
$$ d \log x = \frac{dx}{x} $$
However, I have noticed that some authors make a distinction between these two quantities. For example, in Hull's notes on variance swaps, he writes
$$ \frac{\sigma^2}{2} dt = \frac{dS}{S} - d\log S $$
It's not clear to me why the right-hand side is not zero. What is the difference between the two terms? Clearly, I am missing something about the notation around differential form.
For an ordinary differential, the equality
$$\mathrm{d}(\log x)=\frac{\mathrm{d}x}{x}$$
is true by the chain rule. (This formula holds even when $x$ depends on multiple parameters, as long as $x$ is continuously differentiable in any reasonable sense.)
However, for a diffusion process $S$, the differential $\mathrm{d}S$ behaves differently from ordinary ones, and is subject to the "stochastic version of chain rule" called Itô's lemma (a.k.a. Itô's lemma). In OP's case, this lemma tells that
$$\mathrm{d}(\log S) = \frac{\mathrm{d}S}{S} - \frac{\mathrm{d}[S]}{2S^2}, $$
where $[S]=([S]_t)_{t\geq0}$ stands for the quadratic variation of $S$. The assumption in the note then tells that $\mathrm{d}[S] = S^2 \sigma^2 \, \mathrm{d}t$, hence
$$\mathrm{d}(\log S) = \frac{\mathrm{d}S}{S} - \frac{\sigma^2}{2} \, \mathrm{d}t, $$
which is equivalent to what OP asked.