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

Thrust max_element header change #155

Open
garrettwrong opened this issue Oct 27, 2023 · 1 comment
Open

Thrust max_element header change #155

garrettwrong opened this issue Oct 27, 2023 · 1 comment
Labels
wontfix This will not be worked on

Comments

@garrettwrong
Copy link
Collaborator

Building the latest master with the compilers below gave an error regarding a missing header.

Reporting this for posterity; already worked around. One line fix is below.

nvcc -DSINGLE --device-c -c -std=c++14 -ccbin=g++ -O3 -arch=sm_80 -gencode=arch=compute_80,code=sm_80 -Wno-deprecated-gpu-targets --default-stream per-thread -Xcompiler "-fPIC -O3 -funroll-loops -march=native -std=c++14" -I/usr/local/cuda/include -Icontrib/cuda_samples -I include test/fseries_kernel_test.cu -o test/fseries_kernel_test_32.o
src/precision_independent.cu(92): error: namespace "thrust" has no member "max_element"
   int *maxptsinbin = thrust::max_element(thrust::seq,
                              ^

1 error detected in the compilation of "src/precision_independent.cu".
make: *** [Makefile:112: src/precision_independent.o] Error 2
make: *** Waiting for unfinished jobs....
(/u/gbwright/.conda-envs/test_pacm3) ➜  cufinufft git:(master) ✗ gcc --version 
gcc (GCC) 11.3.1 20221121 (Red Hat 11.3.1-4)
Copyright (C) 2021 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

(/u/gbwright/.conda-envs/test_pacm3) ➜  cufinufft git:(master) ✗ nvcc --version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2023 NVIDIA Corporation
Built on Tue_Aug_15_22:02:13_PDT_2023
Cuda compilation tools, release 12.2, V12.2.140
Build cuda_12.2.r12.2/compiler.33191640_0
(/u/gbwright/.conda-envs/test_pacm3) ➜  cufinufft git:(master) ✗ git diff | cat
diff --git a/src/precision_independent.cu b/src/precision_independent.cu
index 5351362..fa05303 100644
--- a/src/precision_independent.cu
+++ b/src/precision_independent.cu
@@ -5,6 +5,7 @@
 
 #include <thrust/device_ptr.h>
 #include <thrust/scan.h>
+#include <thrust/extrema.h>
 #include <cuComplex.h>
 
 #include "precision_independent.h"
@garrettwrong garrettwrong added the wontfix This will not be worked on label Oct 27, 2023
@janden
Copy link
Collaborator

janden commented Oct 30, 2023

Thanks! Will see if this pops up in the merged codebase as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants