Make sure that you fulfill the special requirements imposed by the functions you want to use, for instance, GPU or OpenCL (install a graphics adapter). If this solution didn’t help, you can check out other possible reasons that can cause Photoshop lagging.