 			//index
 			SMem[indexBase+j] = j+num;
 			__syncthreads();
-/*
-			if(tid < count)
-			{
-				if(out[i*k+tid]-num>0 && out[i*k+tid]-num < indexBase)
-				{
-					SMem[ out[i*k+tid]-num ] = INIT_MAX;
-				}
-			}
-			__syncthreads();
-*/
-		}
-//		__syncthreads();
-/*
-//		for(int j=0; j<count; j++)
-		//coalesce
-		for(int j=tid; j<count; j+=blockDim.x)
-		{
-			if(out[i*k+j]-num>=0 && out[i*k+j]-num<indexBase)
-			{
-				SMem[ out[i*k+j]-num ] = INIT_MAX;
-			}
-			__syncthreads();
-		}
-		__syncthreads();
-*/
+		}
 		if(tid < count)
 		{
 			if(out[i*k+tid]-num>=0 && out[i*k+tid]-num<indexBase)

	}
}

void showD(int m, int *D)
{
	int i,j;
	printf("D:\n");
	for(i=0; i<m; i++)
	{
		for(j=0; j<m; j++)
		{
			printf("%d ", D[i*m+j]);
			if(j == m-1)
			{
				printf("\n");
			}	
		}    	
	}        	
	printf("D:\n");
}            	

void showResult(int m, int k, int *out)
{
	int i,j;

		}    	
	}        	
}            	

int main(int argc, char *argv[]) 
{ 
	int m,n,k;
