sparse and constant convolution optimized