{"action":"created","issue":{"url":"https://api.github.com/repos/arrayfire/arrayfire/issues/2084","repository_url":"https://api.github.com/repos/arrayfire/arrayfire","labels_url":"https://api.github.com/repos/arrayfire/arrayfire/issues/2084/labels{/name}","comments_url":"https://api.github.com/repos/arrayfire/arrayfire/issues/2084/comments","events_url":"https://api.github.com/repos/arrayfire/arrayfire/issues/2084/events","html_url":"https://github.com/arrayfire/arrayfire/issues/2084","id":304835941,"number":2084,"title":"cuda::compileToPTX()  NVRTC_ERROR_COMPILATION","user":{"login":"WilliamTambellini","id":109458,"avatar_url":"https://avatars3.githubusercontent.com/u/109458?v=4","gravatar_id":"","url":"https://api.github.com/users/WilliamTambellini","html_url":"https://github.com/WilliamTambellini","followers_url":"https://api.github.com/users/WilliamTambellini/followers","following_url":"https://api.github.com/users/WilliamTambellini/following{/other_user}","gists_url":"https://api.github.com/users/WilliamTambellini/gists{/gist_id}","starred_url":"https://api.github.com/users/WilliamTambellini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WilliamTambellini/subscriptions","organizations_url":"https://api.github.com/users/WilliamTambellini/orgs","repos_url":"https://api.github.com/users/WilliamTambellini/repos","events_url":"https://api.github.com/users/WilliamTambellini/events{/privacy}","received_events_url":"https://api.github.com/users/WilliamTambellini/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-03-13T16:20:11Z","updated_at":"2018-03-13T19:20:54Z","closed_at":null,"author_association":"NONE","body":"Hi\r\ncuda::compileToPTX fails with my program using the current AF master at least the one from yesterday:\r\n8c34aa999b4b092e51c603360b7ed203d2453955\r\n \r\nIn function std::vector<char> cuda::compileToPTX(const char*, std::string)\r\nIn file src/backend/cuda/jit.cpp:291\r\nNVRTC Error(6): NVRTC_ERROR_COMPILATION\r\nIn function af::array af::moddims(const af::array&, unsigned int, const dim_t*)\r\nIn file src/api/cpp/data.cpp:192\r\n\r\nArrayFire v3.6.0 (CUDA, 64-bit Linux, build b7bd543)\r\nPlatform: CUDA Toolkit 8, Driver: 375.74\r\n[0] GeForce GTX 1060, 6073 MB, CUDA Compute 6.1\r\nNVIDIA-SMI 375.74                 Driver Version: 375.74  \r\n\r\nAF_PRINT_ERRORS=1\r\ndoes not seem to output more details.\r\n\r\nI can hardly atm send any source code to reproduce, as it happens when running our production software. \r\n\r\nIs there any way at least for AF to print the faulty buggy kernel source failing to compile ?\r\nKind\r\n"},"comment":{"url":"https://api.github.com/repos/arrayfire/arrayfire/issues/comments/372787375","html_url":"https://github.com/arrayfire/arrayfire/issues/2084#issuecomment-372787375","issue_url":"https://api.github.com/repos/arrayfire/arrayfire/issues/2084","id":372787375,"user":{"login":"WilliamTambellini","id":109458,"avatar_url":"https://avatars3.githubusercontent.com/u/109458?v=4","gravatar_id":"","url":"https://api.github.com/users/WilliamTambellini","html_url":"https://github.com/WilliamTambellini","followers_url":"https://api.github.com/users/WilliamTambellini/followers","following_url":"https://api.github.com/users/WilliamTambellini/following{/other_user}","gists_url":"https://api.github.com/users/WilliamTambellini/gists{/gist_id}","starred_url":"https://api.github.com/users/WilliamTambellini/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/WilliamTambellini/subscriptions","organizations_url":"https://api.github.com/users/WilliamTambellini/orgs","repos_url":"https://api.github.com/users/WilliamTambellini/repos","events_url":"https://api.github.com/users/WilliamTambellini/events{/privacy}","received_events_url":"https://api.github.com/users/WilliamTambellini/received_events","type":"User","site_admin":false},"created_at":"2018-03-13T19:20:54Z","updated_at":"2018-03-13T19:20:54Z","author_association":"NONE","body":"Ok so we debugged with @umar456  and looks like AF is generating a too long kernel : \r\nKER17250219459061981991(228): Error: Formal parameter space overflowed (4096 bytes max) in function KER17250219459061981991\r\nLowering AF_CUDA_MAX_JIT_LEN is of course preventing that to happen but that s just a workaround.\r\nThe best would be for AF to detect this 4KB limit and only generating kernels within that limit.\r\n\r\nStrangely table 14 on this page\r\nhttp://docs.nvidia.com/cuda/cuda-c-programming-guide/index.html#compute-capabilities\r\nis reporting a  \"Cache working set per multiprocessor for constant memory\" of 4KB for Cuda Compute 6 but my setup is 6.1 so the limit should be 8KB...\r\n\r\nTo be continued."}}
{"actor":{"display_login":"WilliamTambellini"}}