 			//printf("%f ",h_odata[out_index+j]);
 			if (h_idata[in_index+j] != h_odata[out_index+j])
 			{
-				fprintf(stdout,"Experiment: %ld element bytes, %d elements, %ld source stride, %ld destination stride, %d DMA warps, %d alignment, %d offset, ",element_size*sizeof(float),element_count,src_stride*sizeof(float),dst_stride*sizeof(float),dma_warps,ALIGNMENT,ALIGN_OFFSET);
-				fprintf(stdout,"Index %d of element %d was expecting %f but received %f, ", j, i, h_idata[in_index+j], h_odata[out_index+j]);
+				fprintf(stderr,"Experiment: %ld element bytes, %d elements, %ld source stride, %ld destination stride, %d DMA warps, %d alignment, %d offset, ",element_size*sizeof(float),element_count,src_stride*sizeof(float),dst_stride*sizeof(float),dma_warps,ALIGNMENT,ALIGN_OFFSET);
+				fprintf(stderr,"Index %d of element %d was expecting %f but received %f\n", j, i, h_idata[in_index+j], h_odata[out_index+j]);
 				pass = false;
 				break;
 			}

	int num_compute_warps = 1;
	int total_threads = (num_compute_warps + dma_warps)*WARP_SIZE;

	dma_ld_test<ALIGNMENT,ALIGN_OFFSET>
		<<<1,total_threads,shared_buffer_size*sizeof(float),0>>>
		(d_idata, d_odata, element_size, element_count, src_stride,
		 dst_stride, shared_buffer_size, num_compute_warps*WARP_SIZE,
		 dma_warps*WARP_SIZE);
	CUDA_SAFE_CALL( cudaThreadSynchronize());

	CUDA_SAFE_CALL( cudaMemcpy (h_odata, d_odata, output_size*sizeof(float), cudaMemcpyDeviceToHost));

// I hate global variables, but whatever
long total_experiments = 0;

template<int ALIGNMENT, int ALIGN_OFFSET, int MAX_BYTES_PER_ELMT>
__global__ void __launch_bounds__(1024,1)
dma_ld_test ( float *idata, float *odata, int element_size /*in number of floats*/, int num_elements, int src_stride/*bytes*/, int dst_stride/*bytes*/, int buffer_size /*number of floats*/, int num_compute_threads, int num_dma_threads_per_ld)
{
	extern __shared__ float buffer[];	

	cudaDMAStrided<MAX_BYTES_PER_ELMT,ALIGNMENT>
	  dma0 (1, num_dma_threads_per_ld, num_compute_threads,
		num_compute_threads, element_size*sizeof(float),
		num_elements, src_stride*sizeof(float), dst_stride*sizeof(float));
