 
   if ((mode == 2) || 
       (mode == 3) || 
-      (mode == 5)) { ///////////////// Non-streaming examples //////////////////
+      (mode == 4)) { ///////////////// Non-streaming examples //////////////////
 
     // Copy input image to GPU:
     checkCudaErrors(  cudaMemcpy( old_image_G,


  ///////////////////////////// Clean up and exit: /////////////////////////////

  if (mode != 4) {
    free(new_image);
  }
  else if (mode == 4) {
    checkCudaErrors( cudaFreeHost(new_image) );
  }
  if (mode > 1) {

    printf("       mode 1 = CPU, 4 threads\n");
    printf("       mode 2 = GPU, global memory, 1d grid\n");
    printf("       mode 3 = GPU, global memory, 2d grid\n");
    printf("       mode 4 = GPU, shared memory, 2d grid\n");
    printf("       mode 5 = GPU, global memory, 1d grid, 4 streams\n");
    exit(EXIT_FAILURE);
  }

