annotate src/fftw-3.3.8/api/api.h @ 169:223a55898ab9 tip default

Add null config files
author Chris Cannam <cannam@all-day-breakfast.com>
date Mon, 02 Mar 2020 14:03:47 +0000
parents bd3cc4d1df30
children
rev   line source
cannam@167 1 /*
cannam@167 2 * Copyright (c) 2003, 2007-14 Matteo Frigo
cannam@167 3 * Copyright (c) 2003, 2007-14 Massachusetts Institute of Technology
cannam@167 4 *
cannam@167 5 * This program is free software; you can redistribute it and/or modify
cannam@167 6 * it under the terms of the GNU General Public License as published by
cannam@167 7 * the Free Software Foundation; either version 2 of the License, or
cannam@167 8 * (at your option) any later version.
cannam@167 9 *
cannam@167 10 * This program is distributed in the hope that it will be useful,
cannam@167 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
cannam@167 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
cannam@167 13 * GNU General Public License for more details.
cannam@167 14 *
cannam@167 15 * You should have received a copy of the GNU General Public License
cannam@167 16 * along with this program; if not, write to the Free Software
cannam@167 17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
cannam@167 18 *
cannam@167 19 */
cannam@167 20
cannam@167 21 /* internal API definitions */
cannam@167 22 #ifndef __API_H__
cannam@167 23 #define __API_H__
cannam@167 24
cannam@167 25 #ifndef CALLING_FFTW /* defined in hook.c, when calling internal functions */
cannam@167 26 # define COMPILING_FFTW /* used for DLL symbol exporting in fftw3.h */
cannam@167 27 #endif
cannam@167 28
cannam@167 29 /* When compiling with GNU libtool on Windows, DLL_EXPORT is #defined
cannam@167 30 for compiling the shared-library code. In this case, we'll #define
cannam@167 31 FFTW_DLL to add dllexport attributes to the specified functions in
cannam@167 32 fftw3.h.
cannam@167 33
cannam@167 34 If we don't specify dllexport explicitly, then libtool
cannam@167 35 automatically exports all symbols. However, if we specify
cannam@167 36 dllexport explicitly for any functions, then libtool apparently
cannam@167 37 doesn't do any automatic exporting. (Not documented, grrr, but
cannam@167 38 this is the observed behavior with libtool 1.5.8.) Thus, using
cannam@167 39 this forces us to correctly dllexport every exported symbol, or
cannam@167 40 linking bench.exe will fail. This has the advantage of forcing
cannam@167 41 us to mark things correctly, which is necessary for other compilers
cannam@167 42 (such as MS VC++). */
cannam@167 43 #ifdef DLL_EXPORT
cannam@167 44 # define FFTW_DLL
cannam@167 45 #endif
cannam@167 46
cannam@167 47 /* just in case: force <fftw3.h> not to use C99 complex numbers
cannam@167 48 (we need this for IBM xlc because _Complex_I is treated specially
cannam@167 49 and is defined even if <complex.h> is not included) */
cannam@167 50 #define FFTW_NO_Complex
cannam@167 51
cannam@167 52 #include "api/fftw3.h"
cannam@167 53 #include "kernel/ifftw.h"
cannam@167 54 #include "rdft/rdft.h"
cannam@167 55
cannam@167 56 #ifdef __cplusplus
cannam@167 57 extern "C"
cannam@167 58 {
cannam@167 59 #endif /* __cplusplus */
cannam@167 60
cannam@167 61 /* the API ``plan'' contains both the kernel plan and problem */
cannam@167 62 struct X(plan_s) {
cannam@167 63 plan *pln;
cannam@167 64 problem *prb;
cannam@167 65 int sign;
cannam@167 66 };
cannam@167 67
cannam@167 68 /* shorthand */
cannam@167 69 typedef struct X(plan_s) apiplan;
cannam@167 70
cannam@167 71 /* complex type for internal use */
cannam@167 72 typedef R C[2];
cannam@167 73
cannam@167 74 #define EXTRACT_REIM(sign, c, r, i) X(extract_reim)(sign, (c)[0], r, i)
cannam@167 75
cannam@167 76 #define TAINT_UNALIGNED(p, flg) TAINT(p, ((flg) & FFTW_UNALIGNED) != 0)
cannam@167 77
cannam@167 78 tensor *X(mktensor_rowmajor)(int rnk, const int *n,
cannam@167 79 const int *niphys, const int *nophys,
cannam@167 80 int is, int os);
cannam@167 81
cannam@167 82 tensor *X(mktensor_iodims)(int rank, const X(iodim) *dims, int is, int os);
cannam@167 83 tensor *X(mktensor_iodims64)(int rank, const X(iodim64) *dims, int is, int os);
cannam@167 84 const int *X(rdft2_pad)(int rnk, const int *n, const int *nembed,
cannam@167 85 int inplace, int cmplx, int **nfree);
cannam@167 86
cannam@167 87 int X(many_kosherp)(int rnk, const int *n, int howmany);
cannam@167 88 int X(guru_kosherp)(int rank, const X(iodim) *dims,
cannam@167 89 int howmany_rank, const X(iodim) *howmany_dims);
cannam@167 90 int X(guru64_kosherp)(int rank, const X(iodim64) *dims,
cannam@167 91 int howmany_rank, const X(iodim64) *howmany_dims);
cannam@167 92
cannam@167 93 /* Note: FFTW_EXTERN is used for "internal" functions used in tests/hook.c */
cannam@167 94
cannam@167 95 FFTW_EXTERN printer *X(mkprinter_file)(FILE *f);
cannam@167 96
cannam@167 97 printer *X(mkprinter_cnt)(size_t *cnt);
cannam@167 98 printer *X(mkprinter_str)(char *s);
cannam@167 99
cannam@167 100 FFTW_EXTERN planner *X(the_planner)(void);
cannam@167 101 void X(configure_planner)(planner *plnr);
cannam@167 102
cannam@167 103 void X(mapflags)(planner *, unsigned);
cannam@167 104
cannam@167 105 apiplan *X(mkapiplan)(int sign, unsigned flags, problem *prb);
cannam@167 106
cannam@167 107 rdft_kind *X(map_r2r_kind)(int rank, const X(r2r_kind) * kind);
cannam@167 108
cannam@167 109 typedef void (*planner_hook_t)(void);
cannam@167 110
cannam@167 111 void X(set_planner_hooks)(planner_hook_t before, planner_hook_t after);
cannam@167 112
cannam@167 113 #ifdef __cplusplus
cannam@167 114 } /* extern "C" */
cannam@167 115 #endif /* __cplusplus */
cannam@167 116
cannam@167 117 #endif /* __API_H__ */