-
Notifications
You must be signed in to change notification settings - Fork 160
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
Unable to compile with ZFP_WITH_CUDA=TRUE on Windows #244
Comments
There's no reason I'm aware of why zfp cannot be built with CUDA support on Windows. We unfortunately do not have a CUDA-capable Windows machine that would allow us to reproduce the issue, but it seems unlikely that the issue is related to zfp. Perhaps you can include the full CMake output to see if it gives any other hints? Also, what version of CMake are you using? What host compiler and version? Is the compiler compatible with CUDA 12.5? See https://docs.nvidia.com/cuda/cuda-installation-guide-microsoft-windows/index.html for requirements. Can you successfully build any of the CUDA code samples? |
cmake out log is as follows:
cmake .. -DZFP_WITH_CUDA=TRUE --log-level=VERBOSE This warning is for project developers. Use -Wno-dev to suppress it. -- Found CUDA: C:/Program Files/NVIDIA GPU Computing Toolkit/CUDA/v12.5 (found version "12.5") |
So the CMake warning is related to #232, which we will fix in the next release. Still, CUDA is found, so presumably that's not the cause. From NVIDIA docs, your compiler should be compatible with CUDA 12.5. But please do attempt to build one or more of the CUDA code samples to verify that this is not a zfp specific issue. It would also be instructive to test if zfp builds with CUDA disabled ( |
Hi, sorry for late response. CUDA code samples can be compiled without any issue on my env. thank you for sharing #232, I will keep an eye on it. Thanks. |
I just noticed this CMake line: Lines 44 to 46 in a46fa8b
What happens if you comment this out? |
Not working, got linking error. e.g. error LNK2019: unresolved external symbol cudaGetLastError referenced in function "bool __cdecl cuZFP::is_gpu_ptr(void const *)" (?is_gpu_ptr@cuZFP@@YA_NPEBX@Z) Btw, I think you can check it on your windows system by just installing CUDA Toolkits. |
If that reveals nothing, perhaps we just need to wait for #232 to be merged and see if that resolves the issue. However, we're not at a very good point to merge that PR (see discussion there).
We don't have access to a Windows machine with an NVIDIA GPU, so that is unfortunately not an option. |
I mean just compiling without NVIDA GPU. Issue here is code generation. |
@kminemur Can you please check to see if the latest changes on the |
Hi, the staging branch raises the other error. nvcc fatal : A single input file is required for a non-link phase when an outputfile is specified C:\Program Files\Microsoft Visual Studio\2022\Professional\MSBuild\Microsoft\VC\v170\BuildCustomizations\CUDA 12.5.targets(799,9): error MSB3721: The command ""C:\Progra |
I wonder if the MSVC flags Lines 80 to 81 in 3d2d67a
|
Update: I can confirm that commenting out those two CMake lines fixes the above nvcc issue (on the The next issue has to do with Line 37 in 3d2d67a
There is at least one more issue with duplicate |
This last issue is fixed by substituting Line 18 in 3d2d67a
These changes allow me to build zfp on Windows with -DZFP_WITH_CUDA=ON , though without an NVIDIA GPU on a Windows machine, I cannot test for correctness.
We'll push some changes that address these build issues over the coming days. |
@kminemur I believe we've now addressed the CUDA build issues on Windows on the |
Great to hear. Since we don't have a Windows box with an NVIDIA GPU, would you mind running the tests also (by building with |
@kminemur Thanks for trying. I believe there are a few issues at hand. First, I saw similar google test linkage warnings on my machine, which from a cursory look may have something to do with including Second, CMocka seems to cause some symbolic link issues on Windows, which evidently thinks symlinks are harmful:
The "correct" solution cannot be to require admin privileges just to use CMocka--let me look further into this. Your build log suggests that most (all?) test executables are built, yet no tests are being run. Is this another Windows issue, where |
@kminemur Can you please confirm whether or not you ran |
42% tests passed, 129 tests failed out of 221 with "ctest -C Release" |
@kminemur Thanks for letting us know. The "failing" tests are the C tests that depend on CMocka and which are not being built, as that requires permission to make symlinks on Windows (see, e.g., https://stackoverflow.com/questions/61243174/replacement-of-create-symlink-in-windows). These tests pass on the |
Hi team,
I'm trying to compiler zfp with CUDA on Windows system, however I'm getting link error of "LINK : fatal error LNK1104: cannot open file 'stdc++.lib'". I could compiler it on Ubuntu22.04 environemt.
Does zfp with CUDA only support Linux environment?
Steps
install CUDA Toolkit 12.5
git clone zfp
cd zfp; mkdir zfp; cd zfp
cmake .. -DZFP_WITH_CUDA=TRUE
cmake --build .
The text was updated successfully, but these errors were encountered: