 
 
 void updateXWithCGHost(float * A, float * x, float * b, const int batchSize, const int f, const float cgIter){
-	updateXWithCGKernel<<<batchSize, f>>>
+	updateXWithCGKernel<<<batchSize, f, (4*f+4)*sizeof(float)>>>
 		(A, x, b, batchSize, f, cgIter);
 	cudaDeviceSynchronize();
 	cudaCheckError();

		printf("***rsold:\n");
		printf("rsold = %f \n", rsold[0]);
		printf("***shared memory content after 1st blockReduceSum:\n");
		for(int i = 0; i < 100; i++)
			printf("%f ", sharedp[i]);
		printf("\n");
		for(int i = 0; i < 100; i++)
			printf("%f ", sharedr[i]);
		printf("\n");
		for(int i = 0; i < 100; i++)
			printf("%f ", sharedap[i]);
		printf("\n");
	}

		__syncthreads();
		if(threadIdx.x==0){
			printf("***shared memory content before 3rd blockReduceSum:\n");
			for(int i = 0; i < f; i++)
				printf("%f ", sharedp[i]);
			printf("\n");
			for(int i = 0; i < f; i++)
				printf("%f ", sharedr[i]);
			printf("\n");
			for(int i = 0; i < f; i++)
				printf("%f ", sharedap[i]);
			printf("\n");
		}
