Done inline-ing backprop functions.