add BaseConvolutionLayer

This provides a common place for code used by ConvolutionLayer and
DeconvolutionLayer, simplifying the implementations of both.
add CPU_ONLY ifdef guards to BaseConvolutionLayer
rewrite ConvolutionLayer to use BaseConvolutionLayer helpers
add DeconvolutionLayer, using BaseConvolutionLayer