Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GLM Support is broken on Windows? #1011

Closed
Robadob opened this issue Dec 12, 2022 · 2 comments · Fixed by #1012
Closed

GLM Support is broken on Windows? #1011

Robadob opened this issue Dec 12, 2022 · 2 comments · Fixed by #1012
Labels

Comments

@Robadob
Copy link
Member

Robadob commented Dec 12, 2022

Unable to build CUDAAgent.cu or DeviceAgentVector_impl.cu with FLAMEGPU_ENABLE_GLM set true (in example_shuffle branch, but this shouldn't affect it). There may be other failures, but by this point the error limit is reached. Both files include CUDAAgent.h

CUDAAgent.cu

1>c:\users\robadob\fgpu2\src\flamegpu\simulation\detail\cudaagent.cu(162): error : calling a __host__ function("_wassert") from a __global__ function("flamegpu::detail::generateCollisionFlags") is not allowed
1>
1>c:\users\robadob\fgpu2\src\flamegpu\simulation\detail\cudaagent.cu(162): error : identifier "_wassert" is undefined in device code

DeviceAgentVector_impl.cu

1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1080): error : identifier "CUjitInputType" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1082): error : identifier "CU_JIT_INPUT_PTX" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1084): error : identifier "CU_JIT_INPUT_CUBIN" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1086): error : identifier "CU_JIT_INPUT_FATBINARY" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1094): error : identifier "CU_JIT_INPUT_OBJECT" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1105): error : identifier "CU_JIT_INPUT_LIBRARY" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1112): error : identifier "CUlinkState" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1113): error : identifier "CUmodule" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1114): error : identifier "CUfunction" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1118): error : identifier "CUjit_option" is undefined
1>
1>C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.26.28801\include\vector(422): error : static assertion failed with "vector<T, Allocator> requires that Allocator's value_type match T (See N4659 26.2.1 [container.requirements.general]/16 allocator_type) Either fix the allocator value_type or define _ENFORCE_MATCHING_ALLOCATORS=0 to suppress this diagnostic."
1>          detected during instantiation of class "std::vector<_Ty, _Alloc> [with _Ty=<error-type>, _Alloc=std::allocator<<error-type>>]"
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1118): here
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1126): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1268): error : identifier "CUjit_option" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1286): error : identifier "CUjit_option" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1301): error : expected an operator
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1301): error : explicit type is missing ("int" assumed)
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1303): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1304): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1310): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1316): error : identifier "CUfunction_attribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1322): error : identifier "CUfunction_attribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1327): error : identifier "CUdeviceptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1341): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1342): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1356): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1357): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1127): error : identifier "CUDA_SUCCESS" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1129): error : identifier "cuGetErrorName" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1135): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1135): error : expected a ";"
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1140): error : identifier "result" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1141): error : identifier "cuModuleLoadDataEx" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1146): error : identifier "cuLinkCreate_v2" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1148): error : identifier "CU_JIT_INPUT_PTX" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1148): error : identifier "cuLinkAddData_v2" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1153): error : identifier "CUjitInputType" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1153): error : expected a ";"
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1157): error : identifier "jit_input_type" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1157): error : identifier "CU_JIT_INPUT_OBJECT" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1160): error : identifier "jit_input_type" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1162): error : identifier "result" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1162): error : identifier "jit_input_type" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1162): error : identifier "cuLinkAddFile_v2" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1165): error : identifier "CUDA_ERROR_FILE_NOT_FOUND" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1185): error : identifier "result" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1185): error : identifier "cuLinkComplete" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1186): error : identifier "CUDA_SUCCESS" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1187): error : identifier "cuModuleLoadData" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1201): error : identifier "result" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1206): error : identifier "cuModuleGetFunction" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1211): error : identifier "cuLinkDestroy" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1215): error : identifier "cuModuleUnload" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1276): error : no instance of constructor "std::vector<_Ty, _Alloc>::vector [with _Ty=<error-type>, _Alloc=std::allocator<<error-type>>]" matches the argument list
1>            argument types are: (<error-type> *, <error-type> *)
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1293): error : no instance of overloaded function "std::vector<_Ty, _Alloc>::assign [with _Ty=<error-type>, _Alloc=std::allocator<<error-type>>]" matches the argument list
1>            argument types are: (<error-type> *, <error-type> *)
1>            object type is: std::vector<<error-type>, std::allocator<<error-type>>>
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1305): error : identifier "cuLaunchKernel" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1311): error : identifier "cuLaunchKernel" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1318): error : identifier "cuFuncGetAttribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1324): error : identifier "cuFuncSetAttribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1329): error : identifier "CUdeviceptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1329): error : expected a ";"
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1332): error : identifier "global_ptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1332): error : identifier "cuModuleGetGlobal_v2" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(1337): error : identifier "global_ptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2316): error : incomplete type is not allowed
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2316): error : identifier "CUfunction" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2316): error : expected a ")"
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2319): warning #12-D: parsing restarts here after previous syntax error
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2319): error : expected a ";"
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2337): warning #12-D: parsing restarts here after previous syntax error
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2461): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2495): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2517): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2525): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2556): error : expected an operator
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2556): error : explicit type is missing ("int" assumed)
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2590): error : identifier "CUoccupancyB2DSize" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2603): error : identifier "CUfunction_attribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2610): error : identifier "CUfunction_attribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2618): error : identifier "CUdeviceptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2628): error : identifier "CUdeviceptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2638): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2639): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2648): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2649): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2658): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2659): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2668): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2669): error : identifier "CUstream" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2594): error : identifier "CUfunction" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2594): error : expected a ";"
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2595): error : identifier "func" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(2894): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3165): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3570): error : expected an operator
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3570): error : explicit type is missing ("int" assumed)
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3626): error : identifier "CUoccupancyB2DSize" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3632): error : identifier "CUfunction_attribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3639): error : identifier "CUfunction_attribute" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3647): error : identifier "CUdeviceptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3656): error : identifier "CUdeviceptr" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3665): error : identifier "CUresult" is undefined
1>
1>C:\Users\Robadob\fgpu2\build2\_deps\jitify-src\jitify/jitify.hpp(3666): error : identifier "CUstream" is undefined

In both cases it appears to be an issue with cuda headers not being included correctly.

@Robadob Robadob added the bug label Dec 12, 2022
@Robadob
Copy link
Member Author

Robadob commented Dec 12, 2022

Appears it was broken by #1007, as the previous commit to master works fine. Some includes may have been changed by mistake?

@Robadob
Copy link
Member Author

Robadob commented Dec 12, 2022

Solved. type_decode had been moved into a namespace, this was causing glm.hpp to be include inside flamegpu::detail namespace breaking stuff.

Fix inc soon.

Robadob added a commit that referenced this issue Dec 12, 2022
This was broken by #1007 earlier today

Also removed a leftover file from the same PR, and improved the syntax of a few includes.

Closes #1011
Robadob added a commit that referenced this issue Dec 12, 2022
This was broken by #1007 earlier today

Also removed a leftover file from the same PR, and improved the syntax of a few includes.

Closes #1011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant