Cuda Unknown Error
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies
Cudamalloc Unknown Error
of this site About Us Learn more about Stack Overflow the company cudamemcpy unknown error Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges
Cuda Toolkit
Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up CUDA “Unknown error” for unknown reasons [duplicate] up vote 2 down vote favorite This question already has an answer here: Copy an object to device? 1 answer In my current project, a call to cudaGetLastError() is returning unknown error and I don't know why. The code compiles just fine, but it is not behaving how I would like it to. Below is a brief, not compilable example of what the relevant code consists of: CU_Main.cu Below is the CUDA kernel: //My CUDA kernel __global__ void CU_KernelTest(Kernel* matrix){ int idx = blockIdx.x * blockDim.x + threadIdx.x; int idy = blockIdx.y * blockDim.y + threadIdx.y; if(idx == 0 && idy == 0){ printf("ID is: %d\n", idx); matrix->set(1,1, 16.0f); } } Here is the host code: //A host function which is called when a button is clicked int HOST_OnbuttonClick(){ Kernel* matrix = new Kernel(3,3,2); Kernel* device_matrix; cudaMalloc(&device_matrix, sizeof(Kernel)); cudaMemcpy(device_matrix, matrix, sizeof(Kernel), cudaMemcpyHostToDevice); CU_KernelTest<<<256, 256>>>(device_matrix); cudaDeviceSynchronize(); cudaError_t err = cudaGetLastError(); if (err != cudaSuccess) { printf("Error: %s\n", cudaGetErrorString(err)); } cudaFree(device_matrix); return 0.0f; } When matrix->set(1,1, 16.0f); is included in the cuda kernel, (err != cudaSuccess) returns true and prints out UNKNOWN ERROR, whereas if I comment set out, i get no error. The other struct relevant to this is my own helper for a convolution kernel design I'm going for, naturally called Kernel. Kernel.cuh struct Kernel { private : float* kernel; int rows; int columns; public : __device__ __host__ Kernel(int _rows, int _columns, float _default) { rows = _ro
to BlenderSite HelpForum RulesFAQContact Site SupportWebsite Support Forum BA Facebook Advanced Search Today's Posts FAQ Calendar Mark Forums Read Community Groups Forum Actions Mark Forums Read Quick Links View Forum Leaders If this https://blenderartists.org/forum/showthread.php?252018-CUDA-error-Unknown-error is your first visit, be sure to check out the FAQ by clicking https://www.capturingreality.com/forum/viewtopic.php?f=3&t=116 the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. [ - ] Hide Feature Row Forum Support Technical Support [SOLVED] CUDA error: Unknown error Results unknown error 1 to 3 of 3 Thread: CUDA error: Unknown error Thread Tools Show Printable Version Email this Page… Search Thread Advanced Search 14-Apr-12,06:11 #1 Daemonicus View Profile View Forum Posts Private Message Member Join Date Aug 2006 Posts 31 CUDA error: Unknown error Hi, I have the following CUDA error whenever I try and switch to viewport rendering (It renders fine with cuda unknown error F12) CUDA error: Unknown error CUDA error: Invalid context in cuMemAlloc(&device_pointer, mem.memory_size()) CUDA error: Invalid context in cuMemsetD8(cuda_device_ptr(mem.device_pointer), 0, mem.memory_size()) CUDA error: Invalid context in cuMemAlloc(&device_pointer, mem.memory_size()) CUDA error: Invalid context in cuMemcpyHtoD(cuda_device_ptr(mem.device_pointer), (void*)mem.data_pointer, mem.memory_size()) CUDA error: Invalid context in cuGraphicsGLRegisterBuffer(&pmem.cuPBOresource, pmem.cuPBO, CU_GRAPHICS_MAP_RESOURCE_FLAGS_NONE) System Spec: Lenovo Z570 - M556CUK Intel Core i7-2670QM 6GB Ram HD Graphics 3000 GeForce GT 540M Windows 7 64 Bit Have installed latest blender version and latest graphics drivers. Not really sure where to go now. Any help would be much appreciated. TIA Dave. PS. Could someone tell me how to copy and paste from the Blender System Console Window as I had to type that error code in manually :-) Last edited by Daemonicus; 16-Apr-12 at 12:20. Reason: Problem solved. 15-Apr-12,13:19 #2 Jan_Sandahl View Profile View Forum Posts Private Message Visit Homepage Member Join Date Sep 2010 Posts 25 Edit: I found this possible solution: http://blenderartists.org/forum/show...own-CUDA-error I get the same CUDA error in viewport here. After that when trying to change to solid for example, Blender crashes every time. Tried the 2.63 testbuild too. Same thing. Win 7 Pro 64 6Gb ram Intel Co
strictly for the product notification purposes. It will not be shared with any third parties for any reason. © 2015 CapturingReality s.r.o. Terms of Use Terms of Service Privacy Policy