This is not a differential, but a derivative; they are different things. Since f' denotes the derivative of f, which is a function of its own, the best notation for the value at 1 is
f'(1)
If you want to use the heavier notation
f'(x)|x=1
then
$f'(x)|_{x=1}$
is perfectly good. You may want to define a command for this:
\newcommand{\at}[2][]{#1|_{#2}}
to be used as
$f'(x)\at{x=1}$
or, if you need a larger bar to cover a larger function symbol,
$f'(x)\at[\big]{x=1}$
The optional argument can be one of \big, \Big, \bigg or \Bigg. I wouldn't use an automatically growing bar, because it may give bad results.
f'(1)=5? – egreg Jul 21 '12 at 10:14