Skip to main content

cudarc/cufft/sys/
mod.rs

1#![cfg_attr(feature = "no-std", no_std)]
2#![allow(non_camel_case_types)]
3#![allow(non_snake_case)]
4#![allow(dead_code)]
5#[cfg(feature = "no-std")]
6extern crate alloc;
7#[cfg(feature = "no-std")]
8extern crate no_std_compat as std;
9pub use self::cufftCompatibility_t as cufftCompatibility;
10#[cfg(any(
11    feature = "cuda-12040",
12    feature = "cuda-12050",
13    feature = "cuda-12060",
14    feature = "cuda-12080",
15    feature = "cuda-12090",
16    feature = "cuda-13000",
17    feature = "cuda-13010",
18    feature = "cuda-13020"
19))]
20pub use self::cufftProperty_t as cufftProperty;
21pub use self::cufftResult_t as cufftResult;
22pub use self::cufftType_t as cufftType;
23pub use self::libraryPropertyType_t as libraryPropertyType;
24pub type cuComplex = cuFloatComplex;
25pub type cuDoubleComplex = double2;
26pub type cuFloatComplex = float2;
27pub type cudaStream_t = *mut CUstream_st;
28pub type cufftComplex = cuComplex;
29pub type cufftDoubleComplex = cuDoubleComplex;
30pub type cufftDoubleReal = f64;
31pub type cufftHandle = ::core::ffi::c_int;
32pub type cufftReal = f32;
33#[repr(u32)]
34#[derive(Debug, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
35pub enum cufftCompatibility_t {
36    CUFFT_COMPATIBILITY_FFTW_PADDING = 1,
37}
38#[cfg(any(feature = "cuda-12040"))]
39#[repr(u32)]
40#[derive(Debug, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
41pub enum cufftProperty_t {
42    NVFFT_PLAN_PROPERTY_INT64_PATIENT_JIT = 1,
43}
44#[cfg(any(
45    feature = "cuda-12050",
46    feature = "cuda-12060",
47    feature = "cuda-12080",
48    feature = "cuda-12090",
49    feature = "cuda-13000",
50    feature = "cuda-13010",
51    feature = "cuda-13020"
52))]
53#[repr(u32)]
54#[derive(Debug, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
55pub enum cufftProperty_t {
56    NVFFT_PLAN_PROPERTY_INT64_PATIENT_JIT = 1,
57    NVFFT_PLAN_PROPERTY_INT64_MAX_NUM_HOST_THREADS = 2,
58}
59#[cfg(any(
60    feature = "cuda-12000",
61    feature = "cuda-12010",
62    feature = "cuda-12020",
63    feature = "cuda-12030",
64    feature = "cuda-12040",
65    feature = "cuda-12050",
66    feature = "cuda-12060",
67    feature = "cuda-12080",
68    feature = "cuda-12090"
69))]
70#[repr(u32)]
71#[derive(Debug, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
72pub enum cufftResult_t {
73    CUFFT_SUCCESS = 0,
74    CUFFT_INVALID_PLAN = 1,
75    CUFFT_ALLOC_FAILED = 2,
76    CUFFT_INVALID_TYPE = 3,
77    CUFFT_INVALID_VALUE = 4,
78    CUFFT_INTERNAL_ERROR = 5,
79    CUFFT_EXEC_FAILED = 6,
80    CUFFT_SETUP_FAILED = 7,
81    CUFFT_INVALID_SIZE = 8,
82    CUFFT_UNALIGNED_DATA = 9,
83    CUFFT_INCOMPLETE_PARAMETER_LIST = 10,
84    CUFFT_INVALID_DEVICE = 11,
85    CUFFT_PARSE_ERROR = 12,
86    CUFFT_NO_WORKSPACE = 13,
87    CUFFT_NOT_IMPLEMENTED = 14,
88    CUFFT_LICENSE_ERROR = 15,
89    CUFFT_NOT_SUPPORTED = 16,
90}
91#[cfg(any(feature = "cuda-13000", feature = "cuda-13010", feature = "cuda-13020"))]
92#[repr(u32)]
93#[derive(Debug, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
94pub enum cufftResult_t {
95    CUFFT_SUCCESS = 0,
96    CUFFT_INVALID_PLAN = 1,
97    CUFFT_ALLOC_FAILED = 2,
98    CUFFT_INVALID_TYPE = 3,
99    CUFFT_INVALID_VALUE = 4,
100    CUFFT_INTERNAL_ERROR = 5,
101    CUFFT_EXEC_FAILED = 6,
102    CUFFT_SETUP_FAILED = 7,
103    CUFFT_INVALID_SIZE = 8,
104    CUFFT_UNALIGNED_DATA = 9,
105    CUFFT_INVALID_DEVICE = 11,
106    CUFFT_NO_WORKSPACE = 13,
107    CUFFT_NOT_IMPLEMENTED = 14,
108    CUFFT_NOT_SUPPORTED = 16,
109    CUFFT_MISSING_DEPENDENCY = 17,
110    CUFFT_NVRTC_FAILURE = 18,
111    CUFFT_NVJITLINK_FAILURE = 19,
112    CUFFT_NVSHMEM_FAILURE = 20,
113}
114#[repr(u32)]
115#[derive(Debug, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
116pub enum cufftType_t {
117    CUFFT_R2C = 42,
118    CUFFT_C2R = 44,
119    CUFFT_C2C = 41,
120    CUFFT_D2Z = 106,
121    CUFFT_Z2D = 108,
122    CUFFT_Z2Z = 105,
123}
124#[repr(u32)]
125#[derive(Debug, Copy, Clone, Hash, PartialOrd, Ord, PartialEq, Eq)]
126pub enum libraryPropertyType_t {
127    MAJOR_VERSION = 0,
128    MINOR_VERSION = 1,
129    PATCH_LEVEL = 2,
130}
131#[repr(C)]
132#[derive(Debug, Copy, Clone)]
133pub struct CUstream_st {
134    _unused: [u8; 0],
135}
136#[repr(C)]
137#[repr(align(16))]
138#[derive(Debug, Copy, Clone, PartialOrd, PartialEq)]
139pub struct double2 {
140    pub x: f64,
141    pub y: f64,
142}
143#[repr(C)]
144#[repr(align(8))]
145#[derive(Debug, Copy, Clone, PartialOrd, PartialEq)]
146pub struct float2 {
147    pub x: f32,
148    pub y: f32,
149}
150#[cfg(not(feature = "dynamic-loading"))]
151extern "C" {
152    pub fn cufftCreate(handle: *mut cufftHandle) -> cufftResult;
153    pub fn cufftDestroy(plan: cufftHandle) -> cufftResult;
154    pub fn cufftEstimate1d(
155        nx: ::core::ffi::c_int,
156        type_: cufftType,
157        batch: ::core::ffi::c_int,
158        workSize: *mut usize,
159    ) -> cufftResult;
160    pub fn cufftEstimate2d(
161        nx: ::core::ffi::c_int,
162        ny: ::core::ffi::c_int,
163        type_: cufftType,
164        workSize: *mut usize,
165    ) -> cufftResult;
166    pub fn cufftEstimate3d(
167        nx: ::core::ffi::c_int,
168        ny: ::core::ffi::c_int,
169        nz: ::core::ffi::c_int,
170        type_: cufftType,
171        workSize: *mut usize,
172    ) -> cufftResult;
173    pub fn cufftEstimateMany(
174        rank: ::core::ffi::c_int,
175        n: *mut ::core::ffi::c_int,
176        inembed: *mut ::core::ffi::c_int,
177        istride: ::core::ffi::c_int,
178        idist: ::core::ffi::c_int,
179        onembed: *mut ::core::ffi::c_int,
180        ostride: ::core::ffi::c_int,
181        odist: ::core::ffi::c_int,
182        type_: cufftType,
183        batch: ::core::ffi::c_int,
184        workSize: *mut usize,
185    ) -> cufftResult;
186    pub fn cufftExecC2C(
187        plan: cufftHandle,
188        idata: *mut cufftComplex,
189        odata: *mut cufftComplex,
190        direction: ::core::ffi::c_int,
191    ) -> cufftResult;
192    pub fn cufftExecC2R(
193        plan: cufftHandle,
194        idata: *mut cufftComplex,
195        odata: *mut cufftReal,
196    ) -> cufftResult;
197    pub fn cufftExecD2Z(
198        plan: cufftHandle,
199        idata: *mut cufftDoubleReal,
200        odata: *mut cufftDoubleComplex,
201    ) -> cufftResult;
202    pub fn cufftExecR2C(
203        plan: cufftHandle,
204        idata: *mut cufftReal,
205        odata: *mut cufftComplex,
206    ) -> cufftResult;
207    pub fn cufftExecZ2D(
208        plan: cufftHandle,
209        idata: *mut cufftDoubleComplex,
210        odata: *mut cufftDoubleReal,
211    ) -> cufftResult;
212    pub fn cufftExecZ2Z(
213        plan: cufftHandle,
214        idata: *mut cufftDoubleComplex,
215        odata: *mut cufftDoubleComplex,
216        direction: ::core::ffi::c_int,
217    ) -> cufftResult;
218    #[cfg(any(
219        feature = "cuda-12040",
220        feature = "cuda-12050",
221        feature = "cuda-12060",
222        feature = "cuda-12080",
223        feature = "cuda-12090",
224        feature = "cuda-13000",
225        feature = "cuda-13010",
226        feature = "cuda-13020"
227    ))]
228    pub fn cufftGetPlanPropertyInt64(
229        plan: cufftHandle,
230        property: cufftProperty,
231        returnPtrValue: *mut ::core::ffi::c_longlong,
232    ) -> cufftResult;
233    pub fn cufftGetProperty(
234        type_: libraryPropertyType,
235        value: *mut ::core::ffi::c_int,
236    ) -> cufftResult;
237    pub fn cufftGetSize(handle: cufftHandle, workSize: *mut usize) -> cufftResult;
238    pub fn cufftGetSize1d(
239        handle: cufftHandle,
240        nx: ::core::ffi::c_int,
241        type_: cufftType,
242        batch: ::core::ffi::c_int,
243        workSize: *mut usize,
244    ) -> cufftResult;
245    pub fn cufftGetSize2d(
246        handle: cufftHandle,
247        nx: ::core::ffi::c_int,
248        ny: ::core::ffi::c_int,
249        type_: cufftType,
250        workSize: *mut usize,
251    ) -> cufftResult;
252    pub fn cufftGetSize3d(
253        handle: cufftHandle,
254        nx: ::core::ffi::c_int,
255        ny: ::core::ffi::c_int,
256        nz: ::core::ffi::c_int,
257        type_: cufftType,
258        workSize: *mut usize,
259    ) -> cufftResult;
260    pub fn cufftGetSizeMany(
261        handle: cufftHandle,
262        rank: ::core::ffi::c_int,
263        n: *mut ::core::ffi::c_int,
264        inembed: *mut ::core::ffi::c_int,
265        istride: ::core::ffi::c_int,
266        idist: ::core::ffi::c_int,
267        onembed: *mut ::core::ffi::c_int,
268        ostride: ::core::ffi::c_int,
269        odist: ::core::ffi::c_int,
270        type_: cufftType,
271        batch: ::core::ffi::c_int,
272        workArea: *mut usize,
273    ) -> cufftResult;
274    pub fn cufftGetSizeMany64(
275        plan: cufftHandle,
276        rank: ::core::ffi::c_int,
277        n: *mut ::core::ffi::c_longlong,
278        inembed: *mut ::core::ffi::c_longlong,
279        istride: ::core::ffi::c_longlong,
280        idist: ::core::ffi::c_longlong,
281        onembed: *mut ::core::ffi::c_longlong,
282        ostride: ::core::ffi::c_longlong,
283        odist: ::core::ffi::c_longlong,
284        type_: cufftType,
285        batch: ::core::ffi::c_longlong,
286        workSize: *mut usize,
287    ) -> cufftResult;
288    pub fn cufftGetVersion(version: *mut ::core::ffi::c_int) -> cufftResult;
289    pub fn cufftMakePlan1d(
290        plan: cufftHandle,
291        nx: ::core::ffi::c_int,
292        type_: cufftType,
293        batch: ::core::ffi::c_int,
294        workSize: *mut usize,
295    ) -> cufftResult;
296    pub fn cufftMakePlan2d(
297        plan: cufftHandle,
298        nx: ::core::ffi::c_int,
299        ny: ::core::ffi::c_int,
300        type_: cufftType,
301        workSize: *mut usize,
302    ) -> cufftResult;
303    pub fn cufftMakePlan3d(
304        plan: cufftHandle,
305        nx: ::core::ffi::c_int,
306        ny: ::core::ffi::c_int,
307        nz: ::core::ffi::c_int,
308        type_: cufftType,
309        workSize: *mut usize,
310    ) -> cufftResult;
311    pub fn cufftMakePlanMany(
312        plan: cufftHandle,
313        rank: ::core::ffi::c_int,
314        n: *mut ::core::ffi::c_int,
315        inembed: *mut ::core::ffi::c_int,
316        istride: ::core::ffi::c_int,
317        idist: ::core::ffi::c_int,
318        onembed: *mut ::core::ffi::c_int,
319        ostride: ::core::ffi::c_int,
320        odist: ::core::ffi::c_int,
321        type_: cufftType,
322        batch: ::core::ffi::c_int,
323        workSize: *mut usize,
324    ) -> cufftResult;
325    pub fn cufftMakePlanMany64(
326        plan: cufftHandle,
327        rank: ::core::ffi::c_int,
328        n: *mut ::core::ffi::c_longlong,
329        inembed: *mut ::core::ffi::c_longlong,
330        istride: ::core::ffi::c_longlong,
331        idist: ::core::ffi::c_longlong,
332        onembed: *mut ::core::ffi::c_longlong,
333        ostride: ::core::ffi::c_longlong,
334        odist: ::core::ffi::c_longlong,
335        type_: cufftType,
336        batch: ::core::ffi::c_longlong,
337        workSize: *mut usize,
338    ) -> cufftResult;
339    pub fn cufftPlan1d(
340        plan: *mut cufftHandle,
341        nx: ::core::ffi::c_int,
342        type_: cufftType,
343        batch: ::core::ffi::c_int,
344    ) -> cufftResult;
345    pub fn cufftPlan2d(
346        plan: *mut cufftHandle,
347        nx: ::core::ffi::c_int,
348        ny: ::core::ffi::c_int,
349        type_: cufftType,
350    ) -> cufftResult;
351    pub fn cufftPlan3d(
352        plan: *mut cufftHandle,
353        nx: ::core::ffi::c_int,
354        ny: ::core::ffi::c_int,
355        nz: ::core::ffi::c_int,
356        type_: cufftType,
357    ) -> cufftResult;
358    pub fn cufftPlanMany(
359        plan: *mut cufftHandle,
360        rank: ::core::ffi::c_int,
361        n: *mut ::core::ffi::c_int,
362        inembed: *mut ::core::ffi::c_int,
363        istride: ::core::ffi::c_int,
364        idist: ::core::ffi::c_int,
365        onembed: *mut ::core::ffi::c_int,
366        ostride: ::core::ffi::c_int,
367        odist: ::core::ffi::c_int,
368        type_: cufftType,
369        batch: ::core::ffi::c_int,
370    ) -> cufftResult;
371    #[cfg(any(
372        feature = "cuda-12040",
373        feature = "cuda-12050",
374        feature = "cuda-12060",
375        feature = "cuda-12080",
376        feature = "cuda-12090",
377        feature = "cuda-13000",
378        feature = "cuda-13010",
379        feature = "cuda-13020"
380    ))]
381    pub fn cufftResetPlanProperty(plan: cufftHandle, property: cufftProperty) -> cufftResult;
382    pub fn cufftSetAutoAllocation(
383        plan: cufftHandle,
384        autoAllocate: ::core::ffi::c_int,
385    ) -> cufftResult;
386    #[cfg(any(
387        feature = "cuda-12040",
388        feature = "cuda-12050",
389        feature = "cuda-12060",
390        feature = "cuda-12080",
391        feature = "cuda-12090",
392        feature = "cuda-13000",
393        feature = "cuda-13010",
394        feature = "cuda-13020"
395    ))]
396    pub fn cufftSetPlanPropertyInt64(
397        plan: cufftHandle,
398        property: cufftProperty,
399        inputValueInt: ::core::ffi::c_longlong,
400    ) -> cufftResult;
401    pub fn cufftSetStream(plan: cufftHandle, stream: cudaStream_t) -> cufftResult;
402    pub fn cufftSetWorkArea(plan: cufftHandle, workArea: *mut ::core::ffi::c_void) -> cufftResult;
403}
404#[cfg(feature = "dynamic-loading")]
405mod loaded {
406    use super::*;
407    pub unsafe fn cufftCreate(handle: *mut cufftHandle) -> cufftResult {
408        (culib().cufftCreate)(handle)
409    }
410    pub unsafe fn cufftDestroy(plan: cufftHandle) -> cufftResult {
411        (culib().cufftDestroy)(plan)
412    }
413    pub unsafe fn cufftEstimate1d(
414        nx: ::core::ffi::c_int,
415        type_: cufftType,
416        batch: ::core::ffi::c_int,
417        workSize: *mut usize,
418    ) -> cufftResult {
419        (culib().cufftEstimate1d)(nx, type_, batch, workSize)
420    }
421    pub unsafe fn cufftEstimate2d(
422        nx: ::core::ffi::c_int,
423        ny: ::core::ffi::c_int,
424        type_: cufftType,
425        workSize: *mut usize,
426    ) -> cufftResult {
427        (culib().cufftEstimate2d)(nx, ny, type_, workSize)
428    }
429    pub unsafe fn cufftEstimate3d(
430        nx: ::core::ffi::c_int,
431        ny: ::core::ffi::c_int,
432        nz: ::core::ffi::c_int,
433        type_: cufftType,
434        workSize: *mut usize,
435    ) -> cufftResult {
436        (culib().cufftEstimate3d)(nx, ny, nz, type_, workSize)
437    }
438    pub unsafe fn cufftEstimateMany(
439        rank: ::core::ffi::c_int,
440        n: *mut ::core::ffi::c_int,
441        inembed: *mut ::core::ffi::c_int,
442        istride: ::core::ffi::c_int,
443        idist: ::core::ffi::c_int,
444        onembed: *mut ::core::ffi::c_int,
445        ostride: ::core::ffi::c_int,
446        odist: ::core::ffi::c_int,
447        type_: cufftType,
448        batch: ::core::ffi::c_int,
449        workSize: *mut usize,
450    ) -> cufftResult {
451        (culib().cufftEstimateMany)(
452            rank, n, inembed, istride, idist, onembed, ostride, odist, type_, batch, workSize,
453        )
454    }
455    pub unsafe fn cufftExecC2C(
456        plan: cufftHandle,
457        idata: *mut cufftComplex,
458        odata: *mut cufftComplex,
459        direction: ::core::ffi::c_int,
460    ) -> cufftResult {
461        (culib().cufftExecC2C)(plan, idata, odata, direction)
462    }
463    pub unsafe fn cufftExecC2R(
464        plan: cufftHandle,
465        idata: *mut cufftComplex,
466        odata: *mut cufftReal,
467    ) -> cufftResult {
468        (culib().cufftExecC2R)(plan, idata, odata)
469    }
470    pub unsafe fn cufftExecD2Z(
471        plan: cufftHandle,
472        idata: *mut cufftDoubleReal,
473        odata: *mut cufftDoubleComplex,
474    ) -> cufftResult {
475        (culib().cufftExecD2Z)(plan, idata, odata)
476    }
477    pub unsafe fn cufftExecR2C(
478        plan: cufftHandle,
479        idata: *mut cufftReal,
480        odata: *mut cufftComplex,
481    ) -> cufftResult {
482        (culib().cufftExecR2C)(plan, idata, odata)
483    }
484    pub unsafe fn cufftExecZ2D(
485        plan: cufftHandle,
486        idata: *mut cufftDoubleComplex,
487        odata: *mut cufftDoubleReal,
488    ) -> cufftResult {
489        (culib().cufftExecZ2D)(plan, idata, odata)
490    }
491    pub unsafe fn cufftExecZ2Z(
492        plan: cufftHandle,
493        idata: *mut cufftDoubleComplex,
494        odata: *mut cufftDoubleComplex,
495        direction: ::core::ffi::c_int,
496    ) -> cufftResult {
497        (culib().cufftExecZ2Z)(plan, idata, odata, direction)
498    }
499    #[cfg(any(
500        feature = "cuda-12040",
501        feature = "cuda-12050",
502        feature = "cuda-12060",
503        feature = "cuda-12080",
504        feature = "cuda-12090",
505        feature = "cuda-13000",
506        feature = "cuda-13010",
507        feature = "cuda-13020"
508    ))]
509    pub unsafe fn cufftGetPlanPropertyInt64(
510        plan: cufftHandle,
511        property: cufftProperty,
512        returnPtrValue: *mut ::core::ffi::c_longlong,
513    ) -> cufftResult {
514        (culib().cufftGetPlanPropertyInt64)(plan, property, returnPtrValue)
515    }
516    pub unsafe fn cufftGetProperty(
517        type_: libraryPropertyType,
518        value: *mut ::core::ffi::c_int,
519    ) -> cufftResult {
520        (culib().cufftGetProperty)(type_, value)
521    }
522    pub unsafe fn cufftGetSize(handle: cufftHandle, workSize: *mut usize) -> cufftResult {
523        (culib().cufftGetSize)(handle, workSize)
524    }
525    pub unsafe fn cufftGetSize1d(
526        handle: cufftHandle,
527        nx: ::core::ffi::c_int,
528        type_: cufftType,
529        batch: ::core::ffi::c_int,
530        workSize: *mut usize,
531    ) -> cufftResult {
532        (culib().cufftGetSize1d)(handle, nx, type_, batch, workSize)
533    }
534    pub unsafe fn cufftGetSize2d(
535        handle: cufftHandle,
536        nx: ::core::ffi::c_int,
537        ny: ::core::ffi::c_int,
538        type_: cufftType,
539        workSize: *mut usize,
540    ) -> cufftResult {
541        (culib().cufftGetSize2d)(handle, nx, ny, type_, workSize)
542    }
543    pub unsafe fn cufftGetSize3d(
544        handle: cufftHandle,
545        nx: ::core::ffi::c_int,
546        ny: ::core::ffi::c_int,
547        nz: ::core::ffi::c_int,
548        type_: cufftType,
549        workSize: *mut usize,
550    ) -> cufftResult {
551        (culib().cufftGetSize3d)(handle, nx, ny, nz, type_, workSize)
552    }
553    pub unsafe fn cufftGetSizeMany(
554        handle: cufftHandle,
555        rank: ::core::ffi::c_int,
556        n: *mut ::core::ffi::c_int,
557        inembed: *mut ::core::ffi::c_int,
558        istride: ::core::ffi::c_int,
559        idist: ::core::ffi::c_int,
560        onembed: *mut ::core::ffi::c_int,
561        ostride: ::core::ffi::c_int,
562        odist: ::core::ffi::c_int,
563        type_: cufftType,
564        batch: ::core::ffi::c_int,
565        workArea: *mut usize,
566    ) -> cufftResult {
567        (culib().cufftGetSizeMany)(
568            handle, rank, n, inembed, istride, idist, onembed, ostride, odist, type_, batch,
569            workArea,
570        )
571    }
572    pub unsafe fn cufftGetSizeMany64(
573        plan: cufftHandle,
574        rank: ::core::ffi::c_int,
575        n: *mut ::core::ffi::c_longlong,
576        inembed: *mut ::core::ffi::c_longlong,
577        istride: ::core::ffi::c_longlong,
578        idist: ::core::ffi::c_longlong,
579        onembed: *mut ::core::ffi::c_longlong,
580        ostride: ::core::ffi::c_longlong,
581        odist: ::core::ffi::c_longlong,
582        type_: cufftType,
583        batch: ::core::ffi::c_longlong,
584        workSize: *mut usize,
585    ) -> cufftResult {
586        (culib().cufftGetSizeMany64)(
587            plan, rank, n, inembed, istride, idist, onembed, ostride, odist, type_, batch, workSize,
588        )
589    }
590    pub unsafe fn cufftGetVersion(version: *mut ::core::ffi::c_int) -> cufftResult {
591        (culib().cufftGetVersion)(version)
592    }
593    pub unsafe fn cufftMakePlan1d(
594        plan: cufftHandle,
595        nx: ::core::ffi::c_int,
596        type_: cufftType,
597        batch: ::core::ffi::c_int,
598        workSize: *mut usize,
599    ) -> cufftResult {
600        (culib().cufftMakePlan1d)(plan, nx, type_, batch, workSize)
601    }
602    pub unsafe fn cufftMakePlan2d(
603        plan: cufftHandle,
604        nx: ::core::ffi::c_int,
605        ny: ::core::ffi::c_int,
606        type_: cufftType,
607        workSize: *mut usize,
608    ) -> cufftResult {
609        (culib().cufftMakePlan2d)(plan, nx, ny, type_, workSize)
610    }
611    pub unsafe fn cufftMakePlan3d(
612        plan: cufftHandle,
613        nx: ::core::ffi::c_int,
614        ny: ::core::ffi::c_int,
615        nz: ::core::ffi::c_int,
616        type_: cufftType,
617        workSize: *mut usize,
618    ) -> cufftResult {
619        (culib().cufftMakePlan3d)(plan, nx, ny, nz, type_, workSize)
620    }
621    pub unsafe fn cufftMakePlanMany(
622        plan: cufftHandle,
623        rank: ::core::ffi::c_int,
624        n: *mut ::core::ffi::c_int,
625        inembed: *mut ::core::ffi::c_int,
626        istride: ::core::ffi::c_int,
627        idist: ::core::ffi::c_int,
628        onembed: *mut ::core::ffi::c_int,
629        ostride: ::core::ffi::c_int,
630        odist: ::core::ffi::c_int,
631        type_: cufftType,
632        batch: ::core::ffi::c_int,
633        workSize: *mut usize,
634    ) -> cufftResult {
635        (culib().cufftMakePlanMany)(
636            plan, rank, n, inembed, istride, idist, onembed, ostride, odist, type_, batch, workSize,
637        )
638    }
639    pub unsafe fn cufftMakePlanMany64(
640        plan: cufftHandle,
641        rank: ::core::ffi::c_int,
642        n: *mut ::core::ffi::c_longlong,
643        inembed: *mut ::core::ffi::c_longlong,
644        istride: ::core::ffi::c_longlong,
645        idist: ::core::ffi::c_longlong,
646        onembed: *mut ::core::ffi::c_longlong,
647        ostride: ::core::ffi::c_longlong,
648        odist: ::core::ffi::c_longlong,
649        type_: cufftType,
650        batch: ::core::ffi::c_longlong,
651        workSize: *mut usize,
652    ) -> cufftResult {
653        (culib().cufftMakePlanMany64)(
654            plan, rank, n, inembed, istride, idist, onembed, ostride, odist, type_, batch, workSize,
655        )
656    }
657    pub unsafe fn cufftPlan1d(
658        plan: *mut cufftHandle,
659        nx: ::core::ffi::c_int,
660        type_: cufftType,
661        batch: ::core::ffi::c_int,
662    ) -> cufftResult {
663        (culib().cufftPlan1d)(plan, nx, type_, batch)
664    }
665    pub unsafe fn cufftPlan2d(
666        plan: *mut cufftHandle,
667        nx: ::core::ffi::c_int,
668        ny: ::core::ffi::c_int,
669        type_: cufftType,
670    ) -> cufftResult {
671        (culib().cufftPlan2d)(plan, nx, ny, type_)
672    }
673    pub unsafe fn cufftPlan3d(
674        plan: *mut cufftHandle,
675        nx: ::core::ffi::c_int,
676        ny: ::core::ffi::c_int,
677        nz: ::core::ffi::c_int,
678        type_: cufftType,
679    ) -> cufftResult {
680        (culib().cufftPlan3d)(plan, nx, ny, nz, type_)
681    }
682    pub unsafe fn cufftPlanMany(
683        plan: *mut cufftHandle,
684        rank: ::core::ffi::c_int,
685        n: *mut ::core::ffi::c_int,
686        inembed: *mut ::core::ffi::c_int,
687        istride: ::core::ffi::c_int,
688        idist: ::core::ffi::c_int,
689        onembed: *mut ::core::ffi::c_int,
690        ostride: ::core::ffi::c_int,
691        odist: ::core::ffi::c_int,
692        type_: cufftType,
693        batch: ::core::ffi::c_int,
694    ) -> cufftResult {
695        (culib().cufftPlanMany)(
696            plan, rank, n, inembed, istride, idist, onembed, ostride, odist, type_, batch,
697        )
698    }
699    #[cfg(any(
700        feature = "cuda-12040",
701        feature = "cuda-12050",
702        feature = "cuda-12060",
703        feature = "cuda-12080",
704        feature = "cuda-12090",
705        feature = "cuda-13000",
706        feature = "cuda-13010",
707        feature = "cuda-13020"
708    ))]
709    pub unsafe fn cufftResetPlanProperty(
710        plan: cufftHandle,
711        property: cufftProperty,
712    ) -> cufftResult {
713        (culib().cufftResetPlanProperty)(plan, property)
714    }
715    pub unsafe fn cufftSetAutoAllocation(
716        plan: cufftHandle,
717        autoAllocate: ::core::ffi::c_int,
718    ) -> cufftResult {
719        (culib().cufftSetAutoAllocation)(plan, autoAllocate)
720    }
721    #[cfg(any(
722        feature = "cuda-12040",
723        feature = "cuda-12050",
724        feature = "cuda-12060",
725        feature = "cuda-12080",
726        feature = "cuda-12090",
727        feature = "cuda-13000",
728        feature = "cuda-13010",
729        feature = "cuda-13020"
730    ))]
731    pub unsafe fn cufftSetPlanPropertyInt64(
732        plan: cufftHandle,
733        property: cufftProperty,
734        inputValueInt: ::core::ffi::c_longlong,
735    ) -> cufftResult {
736        (culib().cufftSetPlanPropertyInt64)(plan, property, inputValueInt)
737    }
738    pub unsafe fn cufftSetStream(plan: cufftHandle, stream: cudaStream_t) -> cufftResult {
739        (culib().cufftSetStream)(plan, stream)
740    }
741    pub unsafe fn cufftSetWorkArea(
742        plan: cufftHandle,
743        workArea: *mut ::core::ffi::c_void,
744    ) -> cufftResult {
745        (culib().cufftSetWorkArea)(plan, workArea)
746    }
747    pub struct Lib {
748        __library: ::libloading::Library,
749        pub cufftCreate: unsafe extern "C" fn(handle: *mut cufftHandle) -> cufftResult,
750        pub cufftDestroy: unsafe extern "C" fn(plan: cufftHandle) -> cufftResult,
751        pub cufftEstimate1d: unsafe extern "C" fn(
752            nx: ::core::ffi::c_int,
753            type_: cufftType,
754            batch: ::core::ffi::c_int,
755            workSize: *mut usize,
756        ) -> cufftResult,
757        pub cufftEstimate2d: unsafe extern "C" fn(
758            nx: ::core::ffi::c_int,
759            ny: ::core::ffi::c_int,
760            type_: cufftType,
761            workSize: *mut usize,
762        ) -> cufftResult,
763        pub cufftEstimate3d: unsafe extern "C" fn(
764            nx: ::core::ffi::c_int,
765            ny: ::core::ffi::c_int,
766            nz: ::core::ffi::c_int,
767            type_: cufftType,
768            workSize: *mut usize,
769        ) -> cufftResult,
770        pub cufftEstimateMany: unsafe extern "C" fn(
771            rank: ::core::ffi::c_int,
772            n: *mut ::core::ffi::c_int,
773            inembed: *mut ::core::ffi::c_int,
774            istride: ::core::ffi::c_int,
775            idist: ::core::ffi::c_int,
776            onembed: *mut ::core::ffi::c_int,
777            ostride: ::core::ffi::c_int,
778            odist: ::core::ffi::c_int,
779            type_: cufftType,
780            batch: ::core::ffi::c_int,
781            workSize: *mut usize,
782        ) -> cufftResult,
783        pub cufftExecC2C: unsafe extern "C" fn(
784            plan: cufftHandle,
785            idata: *mut cufftComplex,
786            odata: *mut cufftComplex,
787            direction: ::core::ffi::c_int,
788        ) -> cufftResult,
789        pub cufftExecC2R: unsafe extern "C" fn(
790            plan: cufftHandle,
791            idata: *mut cufftComplex,
792            odata: *mut cufftReal,
793        ) -> cufftResult,
794        pub cufftExecD2Z: unsafe extern "C" fn(
795            plan: cufftHandle,
796            idata: *mut cufftDoubleReal,
797            odata: *mut cufftDoubleComplex,
798        ) -> cufftResult,
799        pub cufftExecR2C: unsafe extern "C" fn(
800            plan: cufftHandle,
801            idata: *mut cufftReal,
802            odata: *mut cufftComplex,
803        ) -> cufftResult,
804        pub cufftExecZ2D: unsafe extern "C" fn(
805            plan: cufftHandle,
806            idata: *mut cufftDoubleComplex,
807            odata: *mut cufftDoubleReal,
808        ) -> cufftResult,
809        pub cufftExecZ2Z: unsafe extern "C" fn(
810            plan: cufftHandle,
811            idata: *mut cufftDoubleComplex,
812            odata: *mut cufftDoubleComplex,
813            direction: ::core::ffi::c_int,
814        ) -> cufftResult,
815        #[cfg(any(
816            feature = "cuda-12040",
817            feature = "cuda-12050",
818            feature = "cuda-12060",
819            feature = "cuda-12080",
820            feature = "cuda-12090",
821            feature = "cuda-13000",
822            feature = "cuda-13010",
823            feature = "cuda-13020"
824        ))]
825        pub cufftGetPlanPropertyInt64: unsafe extern "C" fn(
826            plan: cufftHandle,
827            property: cufftProperty,
828            returnPtrValue: *mut ::core::ffi::c_longlong,
829        ) -> cufftResult,
830        pub cufftGetProperty: unsafe extern "C" fn(
831            type_: libraryPropertyType,
832            value: *mut ::core::ffi::c_int,
833        ) -> cufftResult,
834        pub cufftGetSize:
835            unsafe extern "C" fn(handle: cufftHandle, workSize: *mut usize) -> cufftResult,
836        pub cufftGetSize1d: unsafe extern "C" fn(
837            handle: cufftHandle,
838            nx: ::core::ffi::c_int,
839            type_: cufftType,
840            batch: ::core::ffi::c_int,
841            workSize: *mut usize,
842        ) -> cufftResult,
843        pub cufftGetSize2d: unsafe extern "C" fn(
844            handle: cufftHandle,
845            nx: ::core::ffi::c_int,
846            ny: ::core::ffi::c_int,
847            type_: cufftType,
848            workSize: *mut usize,
849        ) -> cufftResult,
850        pub cufftGetSize3d: unsafe extern "C" fn(
851            handle: cufftHandle,
852            nx: ::core::ffi::c_int,
853            ny: ::core::ffi::c_int,
854            nz: ::core::ffi::c_int,
855            type_: cufftType,
856            workSize: *mut usize,
857        ) -> cufftResult,
858        pub cufftGetSizeMany: unsafe extern "C" fn(
859            handle: cufftHandle,
860            rank: ::core::ffi::c_int,
861            n: *mut ::core::ffi::c_int,
862            inembed: *mut ::core::ffi::c_int,
863            istride: ::core::ffi::c_int,
864            idist: ::core::ffi::c_int,
865            onembed: *mut ::core::ffi::c_int,
866            ostride: ::core::ffi::c_int,
867            odist: ::core::ffi::c_int,
868            type_: cufftType,
869            batch: ::core::ffi::c_int,
870            workArea: *mut usize,
871        ) -> cufftResult,
872        pub cufftGetSizeMany64: unsafe extern "C" fn(
873            plan: cufftHandle,
874            rank: ::core::ffi::c_int,
875            n: *mut ::core::ffi::c_longlong,
876            inembed: *mut ::core::ffi::c_longlong,
877            istride: ::core::ffi::c_longlong,
878            idist: ::core::ffi::c_longlong,
879            onembed: *mut ::core::ffi::c_longlong,
880            ostride: ::core::ffi::c_longlong,
881            odist: ::core::ffi::c_longlong,
882            type_: cufftType,
883            batch: ::core::ffi::c_longlong,
884            workSize: *mut usize,
885        ) -> cufftResult,
886        pub cufftGetVersion: unsafe extern "C" fn(version: *mut ::core::ffi::c_int) -> cufftResult,
887        pub cufftMakePlan1d: unsafe extern "C" fn(
888            plan: cufftHandle,
889            nx: ::core::ffi::c_int,
890            type_: cufftType,
891            batch: ::core::ffi::c_int,
892            workSize: *mut usize,
893        ) -> cufftResult,
894        pub cufftMakePlan2d: unsafe extern "C" fn(
895            plan: cufftHandle,
896            nx: ::core::ffi::c_int,
897            ny: ::core::ffi::c_int,
898            type_: cufftType,
899            workSize: *mut usize,
900        ) -> cufftResult,
901        pub cufftMakePlan3d: unsafe extern "C" fn(
902            plan: cufftHandle,
903            nx: ::core::ffi::c_int,
904            ny: ::core::ffi::c_int,
905            nz: ::core::ffi::c_int,
906            type_: cufftType,
907            workSize: *mut usize,
908        ) -> cufftResult,
909        pub cufftMakePlanMany: unsafe extern "C" fn(
910            plan: cufftHandle,
911            rank: ::core::ffi::c_int,
912            n: *mut ::core::ffi::c_int,
913            inembed: *mut ::core::ffi::c_int,
914            istride: ::core::ffi::c_int,
915            idist: ::core::ffi::c_int,
916            onembed: *mut ::core::ffi::c_int,
917            ostride: ::core::ffi::c_int,
918            odist: ::core::ffi::c_int,
919            type_: cufftType,
920            batch: ::core::ffi::c_int,
921            workSize: *mut usize,
922        ) -> cufftResult,
923        pub cufftMakePlanMany64: unsafe extern "C" fn(
924            plan: cufftHandle,
925            rank: ::core::ffi::c_int,
926            n: *mut ::core::ffi::c_longlong,
927            inembed: *mut ::core::ffi::c_longlong,
928            istride: ::core::ffi::c_longlong,
929            idist: ::core::ffi::c_longlong,
930            onembed: *mut ::core::ffi::c_longlong,
931            ostride: ::core::ffi::c_longlong,
932            odist: ::core::ffi::c_longlong,
933            type_: cufftType,
934            batch: ::core::ffi::c_longlong,
935            workSize: *mut usize,
936        ) -> cufftResult,
937        pub cufftPlan1d: unsafe extern "C" fn(
938            plan: *mut cufftHandle,
939            nx: ::core::ffi::c_int,
940            type_: cufftType,
941            batch: ::core::ffi::c_int,
942        ) -> cufftResult,
943        pub cufftPlan2d: unsafe extern "C" fn(
944            plan: *mut cufftHandle,
945            nx: ::core::ffi::c_int,
946            ny: ::core::ffi::c_int,
947            type_: cufftType,
948        ) -> cufftResult,
949        pub cufftPlan3d: unsafe extern "C" fn(
950            plan: *mut cufftHandle,
951            nx: ::core::ffi::c_int,
952            ny: ::core::ffi::c_int,
953            nz: ::core::ffi::c_int,
954            type_: cufftType,
955        ) -> cufftResult,
956        pub cufftPlanMany: unsafe extern "C" fn(
957            plan: *mut cufftHandle,
958            rank: ::core::ffi::c_int,
959            n: *mut ::core::ffi::c_int,
960            inembed: *mut ::core::ffi::c_int,
961            istride: ::core::ffi::c_int,
962            idist: ::core::ffi::c_int,
963            onembed: *mut ::core::ffi::c_int,
964            ostride: ::core::ffi::c_int,
965            odist: ::core::ffi::c_int,
966            type_: cufftType,
967            batch: ::core::ffi::c_int,
968        ) -> cufftResult,
969        #[cfg(any(
970            feature = "cuda-12040",
971            feature = "cuda-12050",
972            feature = "cuda-12060",
973            feature = "cuda-12080",
974            feature = "cuda-12090",
975            feature = "cuda-13000",
976            feature = "cuda-13010",
977            feature = "cuda-13020"
978        ))]
979        pub cufftResetPlanProperty:
980            unsafe extern "C" fn(plan: cufftHandle, property: cufftProperty) -> cufftResult,
981        pub cufftSetAutoAllocation: unsafe extern "C" fn(
982            plan: cufftHandle,
983            autoAllocate: ::core::ffi::c_int,
984        ) -> cufftResult,
985        #[cfg(any(
986            feature = "cuda-12040",
987            feature = "cuda-12050",
988            feature = "cuda-12060",
989            feature = "cuda-12080",
990            feature = "cuda-12090",
991            feature = "cuda-13000",
992            feature = "cuda-13010",
993            feature = "cuda-13020"
994        ))]
995        pub cufftSetPlanPropertyInt64: unsafe extern "C" fn(
996            plan: cufftHandle,
997            property: cufftProperty,
998            inputValueInt: ::core::ffi::c_longlong,
999        ) -> cufftResult,
1000        pub cufftSetStream:
1001            unsafe extern "C" fn(plan: cufftHandle, stream: cudaStream_t) -> cufftResult,
1002        pub cufftSetWorkArea: unsafe extern "C" fn(
1003            plan: cufftHandle,
1004            workArea: *mut ::core::ffi::c_void,
1005        ) -> cufftResult,
1006    }
1007    impl Lib {
1008        pub unsafe fn new<P>(path: P) -> Result<Self, ::libloading::Error>
1009        where
1010            P: AsRef<::std::ffi::OsStr>,
1011        {
1012            let library = ::libloading::Library::new(path.as_ref())?;
1013            Self::from_library(library)
1014        }
1015        pub unsafe fn from_library<L>(library: L) -> Result<Self, ::libloading::Error>
1016        where
1017            L: Into<::libloading::Library>,
1018        {
1019            let __library = library.into();
1020            let cufftCreate = __library
1021                .get(b"cufftCreate\0")
1022                .map(|sym| *sym)
1023                .expect("Expected symbol in library");
1024            let cufftDestroy = __library
1025                .get(b"cufftDestroy\0")
1026                .map(|sym| *sym)
1027                .expect("Expected symbol in library");
1028            let cufftEstimate1d = __library
1029                .get(b"cufftEstimate1d\0")
1030                .map(|sym| *sym)
1031                .expect("Expected symbol in library");
1032            let cufftEstimate2d = __library
1033                .get(b"cufftEstimate2d\0")
1034                .map(|sym| *sym)
1035                .expect("Expected symbol in library");
1036            let cufftEstimate3d = __library
1037                .get(b"cufftEstimate3d\0")
1038                .map(|sym| *sym)
1039                .expect("Expected symbol in library");
1040            let cufftEstimateMany = __library
1041                .get(b"cufftEstimateMany\0")
1042                .map(|sym| *sym)
1043                .expect("Expected symbol in library");
1044            let cufftExecC2C = __library
1045                .get(b"cufftExecC2C\0")
1046                .map(|sym| *sym)
1047                .expect("Expected symbol in library");
1048            let cufftExecC2R = __library
1049                .get(b"cufftExecC2R\0")
1050                .map(|sym| *sym)
1051                .expect("Expected symbol in library");
1052            let cufftExecD2Z = __library
1053                .get(b"cufftExecD2Z\0")
1054                .map(|sym| *sym)
1055                .expect("Expected symbol in library");
1056            let cufftExecR2C = __library
1057                .get(b"cufftExecR2C\0")
1058                .map(|sym| *sym)
1059                .expect("Expected symbol in library");
1060            let cufftExecZ2D = __library
1061                .get(b"cufftExecZ2D\0")
1062                .map(|sym| *sym)
1063                .expect("Expected symbol in library");
1064            let cufftExecZ2Z = __library
1065                .get(b"cufftExecZ2Z\0")
1066                .map(|sym| *sym)
1067                .expect("Expected symbol in library");
1068            #[cfg(any(
1069                feature = "cuda-12040",
1070                feature = "cuda-12050",
1071                feature = "cuda-12060",
1072                feature = "cuda-12080",
1073                feature = "cuda-12090",
1074                feature = "cuda-13000",
1075                feature = "cuda-13010",
1076                feature = "cuda-13020"
1077            ))]
1078            let cufftGetPlanPropertyInt64 = __library
1079                .get(b"cufftGetPlanPropertyInt64\0")
1080                .map(|sym| *sym)
1081                .expect("Expected symbol in library");
1082            let cufftGetProperty = __library
1083                .get(b"cufftGetProperty\0")
1084                .map(|sym| *sym)
1085                .expect("Expected symbol in library");
1086            let cufftGetSize = __library
1087                .get(b"cufftGetSize\0")
1088                .map(|sym| *sym)
1089                .expect("Expected symbol in library");
1090            let cufftGetSize1d = __library
1091                .get(b"cufftGetSize1d\0")
1092                .map(|sym| *sym)
1093                .expect("Expected symbol in library");
1094            let cufftGetSize2d = __library
1095                .get(b"cufftGetSize2d\0")
1096                .map(|sym| *sym)
1097                .expect("Expected symbol in library");
1098            let cufftGetSize3d = __library
1099                .get(b"cufftGetSize3d\0")
1100                .map(|sym| *sym)
1101                .expect("Expected symbol in library");
1102            let cufftGetSizeMany = __library
1103                .get(b"cufftGetSizeMany\0")
1104                .map(|sym| *sym)
1105                .expect("Expected symbol in library");
1106            let cufftGetSizeMany64 = __library
1107                .get(b"cufftGetSizeMany64\0")
1108                .map(|sym| *sym)
1109                .expect("Expected symbol in library");
1110            let cufftGetVersion = __library
1111                .get(b"cufftGetVersion\0")
1112                .map(|sym| *sym)
1113                .expect("Expected symbol in library");
1114            let cufftMakePlan1d = __library
1115                .get(b"cufftMakePlan1d\0")
1116                .map(|sym| *sym)
1117                .expect("Expected symbol in library");
1118            let cufftMakePlan2d = __library
1119                .get(b"cufftMakePlan2d\0")
1120                .map(|sym| *sym)
1121                .expect("Expected symbol in library");
1122            let cufftMakePlan3d = __library
1123                .get(b"cufftMakePlan3d\0")
1124                .map(|sym| *sym)
1125                .expect("Expected symbol in library");
1126            let cufftMakePlanMany = __library
1127                .get(b"cufftMakePlanMany\0")
1128                .map(|sym| *sym)
1129                .expect("Expected symbol in library");
1130            let cufftMakePlanMany64 = __library
1131                .get(b"cufftMakePlanMany64\0")
1132                .map(|sym| *sym)
1133                .expect("Expected symbol in library");
1134            let cufftPlan1d = __library
1135                .get(b"cufftPlan1d\0")
1136                .map(|sym| *sym)
1137                .expect("Expected symbol in library");
1138            let cufftPlan2d = __library
1139                .get(b"cufftPlan2d\0")
1140                .map(|sym| *sym)
1141                .expect("Expected symbol in library");
1142            let cufftPlan3d = __library
1143                .get(b"cufftPlan3d\0")
1144                .map(|sym| *sym)
1145                .expect("Expected symbol in library");
1146            let cufftPlanMany = __library
1147                .get(b"cufftPlanMany\0")
1148                .map(|sym| *sym)
1149                .expect("Expected symbol in library");
1150            #[cfg(any(
1151                feature = "cuda-12040",
1152                feature = "cuda-12050",
1153                feature = "cuda-12060",
1154                feature = "cuda-12080",
1155                feature = "cuda-12090",
1156                feature = "cuda-13000",
1157                feature = "cuda-13010",
1158                feature = "cuda-13020"
1159            ))]
1160            let cufftResetPlanProperty = __library
1161                .get(b"cufftResetPlanProperty\0")
1162                .map(|sym| *sym)
1163                .expect("Expected symbol in library");
1164            let cufftSetAutoAllocation = __library
1165                .get(b"cufftSetAutoAllocation\0")
1166                .map(|sym| *sym)
1167                .expect("Expected symbol in library");
1168            #[cfg(any(
1169                feature = "cuda-12040",
1170                feature = "cuda-12050",
1171                feature = "cuda-12060",
1172                feature = "cuda-12080",
1173                feature = "cuda-12090",
1174                feature = "cuda-13000",
1175                feature = "cuda-13010",
1176                feature = "cuda-13020"
1177            ))]
1178            let cufftSetPlanPropertyInt64 = __library
1179                .get(b"cufftSetPlanPropertyInt64\0")
1180                .map(|sym| *sym)
1181                .expect("Expected symbol in library");
1182            let cufftSetStream = __library
1183                .get(b"cufftSetStream\0")
1184                .map(|sym| *sym)
1185                .expect("Expected symbol in library");
1186            let cufftSetWorkArea = __library
1187                .get(b"cufftSetWorkArea\0")
1188                .map(|sym| *sym)
1189                .expect("Expected symbol in library");
1190            Ok(Self {
1191                __library,
1192                cufftCreate,
1193                cufftDestroy,
1194                cufftEstimate1d,
1195                cufftEstimate2d,
1196                cufftEstimate3d,
1197                cufftEstimateMany,
1198                cufftExecC2C,
1199                cufftExecC2R,
1200                cufftExecD2Z,
1201                cufftExecR2C,
1202                cufftExecZ2D,
1203                cufftExecZ2Z,
1204                #[cfg(any(
1205                    feature = "cuda-12040",
1206                    feature = "cuda-12050",
1207                    feature = "cuda-12060",
1208                    feature = "cuda-12080",
1209                    feature = "cuda-12090",
1210                    feature = "cuda-13000",
1211                    feature = "cuda-13010",
1212                    feature = "cuda-13020"
1213                ))]
1214                cufftGetPlanPropertyInt64,
1215                cufftGetProperty,
1216                cufftGetSize,
1217                cufftGetSize1d,
1218                cufftGetSize2d,
1219                cufftGetSize3d,
1220                cufftGetSizeMany,
1221                cufftGetSizeMany64,
1222                cufftGetVersion,
1223                cufftMakePlan1d,
1224                cufftMakePlan2d,
1225                cufftMakePlan3d,
1226                cufftMakePlanMany,
1227                cufftMakePlanMany64,
1228                cufftPlan1d,
1229                cufftPlan2d,
1230                cufftPlan3d,
1231                cufftPlanMany,
1232                #[cfg(any(
1233                    feature = "cuda-12040",
1234                    feature = "cuda-12050",
1235                    feature = "cuda-12060",
1236                    feature = "cuda-12080",
1237                    feature = "cuda-12090",
1238                    feature = "cuda-13000",
1239                    feature = "cuda-13010",
1240                    feature = "cuda-13020"
1241                ))]
1242                cufftResetPlanProperty,
1243                cufftSetAutoAllocation,
1244                #[cfg(any(
1245                    feature = "cuda-12040",
1246                    feature = "cuda-12050",
1247                    feature = "cuda-12060",
1248                    feature = "cuda-12080",
1249                    feature = "cuda-12090",
1250                    feature = "cuda-13000",
1251                    feature = "cuda-13010",
1252                    feature = "cuda-13020"
1253                ))]
1254                cufftSetPlanPropertyInt64,
1255                cufftSetStream,
1256                cufftSetWorkArea,
1257            })
1258        }
1259    }
1260    pub unsafe fn is_culib_present() -> bool {
1261        let lib_names = ["cufft"];
1262        let choices = lib_names
1263            .iter()
1264            .map(|l| crate::get_lib_name_candidates(l))
1265            .flatten();
1266        for choice in choices {
1267            if Lib::new(choice).is_ok() {
1268                return true;
1269            }
1270        }
1271        false
1272    }
1273    pub unsafe fn culib() -> &'static Lib {
1274        static LIB: std::sync::OnceLock<Lib> = std::sync::OnceLock::new();
1275        LIB.get_or_init(|| {
1276            let lib_names = std::vec!["cufft"];
1277            let choices: std::vec::Vec<_> = lib_names
1278                .iter()
1279                .map(|l| crate::get_lib_name_candidates(l))
1280                .flatten()
1281                .collect();
1282            for choice in choices.iter() {
1283                if let Ok(lib) = Lib::new(choice) {
1284                    return lib;
1285                }
1286            }
1287            crate::panic_no_lib_found(lib_names[0], &choices);
1288        })
1289    }
1290}
1291#[cfg(feature = "dynamic-loading")]
1292pub use loaded::*;