Problem with memory allocation on Device

Hello, Im new to CUDA and I have quite serious problem.
I can’t get access to my device memory. Every time I try, cudaMalloc return value “cudaErrorStartupFailure”.
Can it be caused by software?
I work at Microsoft Visual Studio 2008 and CUDA 6.0.

Could You provide Your full code?

#include "cuda_runtime.h"
#include "device_launch_parameters.h"

#include <stdio.h>
#define N 1024

__global__ void addKernel(int *c, int *a)
    int i = 1;
    if (i<N)
		for (int j=1; j<=i; j++)
			c[i] = c[i]+a[j];

int main()

int *a1;
    int *c1;
	int i1=0;
	int *d_a;
	int *d_c;

	a1 = (int *)calloc(N, sizeof(int));
	c1 = (int *)calloc(N, sizeof(int));

	cudaMalloc(&d_a, N*sizeof(int)); 
	cudaMalloc(&d_c, N*sizeof(int)); 

	for (i1=0; i1<N; i1++)
	printf("%d %d %d %d %d %d %d %d %d %d %d\n", a1[0], a1[1], a1[3], a1[7], a1[15], a1[31], a1[63], a1[127], a1[255], a1[511], a1[1023]);
	cudaMemcpy(d_a, a1, N*sizeof(int), cudaMemcpyHostToDevice);
	cudaMemcpy(d_c, c1, N*sizeof(int), cudaMemcpyHostToDevice);
	addKernel <<< 1 , N >>> (d_c, d_a);

	cudaMemcpy(c1, d_c, N*sizeof(int), cudaMemcpyDeviceToHost);
	cudaMemcpy(a1, d_a, N*sizeof(int), cudaMemcpyDeviceToHost);

	printf("%d %d %d %d %d %d %d %d %d %d %d\n", c1[0], c1[1], c1[3], c1[7], c1[15], c1[31], c1[63], c1[127], c1[255], c1[511], c1[1023]);

	free (a1);
	free (c1);

    return 0;