annotate src/fftw-3.3.3/dft/simd/common/n1bv_3.c @ 138:eb184393b244

Rebuild with DW2 exception handling to match Qt
author Chris Cannam <cannam@all-day-breakfast.com>
date Thu, 27 Oct 2016 10:26:57 +0100
parents 89f5e221ed7b
children
rev   line source
cannam@95 1 /*
cannam@95 2 * Copyright (c) 2003, 2007-11 Matteo Frigo
cannam@95 3 * Copyright (c) 2003, 2007-11 Massachusetts Institute of Technology
cannam@95 4 *
cannam@95 5 * This program is free software; you can redistribute it and/or modify
cannam@95 6 * it under the terms of the GNU General Public License as published by
cannam@95 7 * the Free Software Foundation; either version 2 of the License, or
cannam@95 8 * (at your option) any later version.
cannam@95 9 *
cannam@95 10 * This program is distributed in the hope that it will be useful,
cannam@95 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
cannam@95 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
cannam@95 13 * GNU General Public License for more details.
cannam@95 14 *
cannam@95 15 * You should have received a copy of the GNU General Public License
cannam@95 16 * along with this program; if not, write to the Free Software
cannam@95 17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
cannam@95 18 *
cannam@95 19 */
cannam@95 20
cannam@95 21 /* This file was automatically generated --- DO NOT EDIT */
cannam@95 22 /* Generated on Sun Nov 25 07:36:58 EST 2012 */
cannam@95 23
cannam@95 24 #include "codelet-dft.h"
cannam@95 25
cannam@95 26 #ifdef HAVE_FMA
cannam@95 27
cannam@95 28 /* Generated by: ../../../genfft/gen_notw_c.native -fma -reorder-insns -schedule-for-pipeline -simd -compact -variables 4 -pipeline-latency 8 -sign 1 -n 3 -name n1bv_3 -include n1b.h */
cannam@95 29
cannam@95 30 /*
cannam@95 31 * This function contains 6 FP additions, 4 FP multiplications,
cannam@95 32 * (or, 3 additions, 1 multiplications, 3 fused multiply/add),
cannam@95 33 * 11 stack variables, 2 constants, and 6 memory accesses
cannam@95 34 */
cannam@95 35 #include "n1b.h"
cannam@95 36
cannam@95 37 static void n1bv_3(const R *ri, const R *ii, R *ro, R *io, stride is, stride os, INT v, INT ivs, INT ovs)
cannam@95 38 {
cannam@95 39 DVK(KP500000000, +0.500000000000000000000000000000000000000000000);
cannam@95 40 DVK(KP866025403, +0.866025403784438646763723170752936183471402627);
cannam@95 41 {
cannam@95 42 INT i;
cannam@95 43 const R *xi;
cannam@95 44 R *xo;
cannam@95 45 xi = ii;
cannam@95 46 xo = io;
cannam@95 47 for (i = v; i > 0; i = i - VL, xi = xi + (VL * ivs), xo = xo + (VL * ovs), MAKE_VOLATILE_STRIDE(6, is), MAKE_VOLATILE_STRIDE(6, os)) {
cannam@95 48 V T1, T2, T3, T6, T4, T5;
cannam@95 49 T1 = LD(&(xi[0]), ivs, &(xi[0]));
cannam@95 50 T2 = LD(&(xi[WS(is, 1)]), ivs, &(xi[WS(is, 1)]));
cannam@95 51 T3 = LD(&(xi[WS(is, 2)]), ivs, &(xi[0]));
cannam@95 52 T6 = VMUL(LDK(KP866025403), VSUB(T2, T3));
cannam@95 53 T4 = VADD(T2, T3);
cannam@95 54 T5 = VFNMS(LDK(KP500000000), T4, T1);
cannam@95 55 ST(&(xo[0]), VADD(T1, T4), ovs, &(xo[0]));
cannam@95 56 ST(&(xo[WS(os, 2)]), VFNMSI(T6, T5), ovs, &(xo[0]));
cannam@95 57 ST(&(xo[WS(os, 1)]), VFMAI(T6, T5), ovs, &(xo[WS(os, 1)]));
cannam@95 58 }
cannam@95 59 }
cannam@95 60 VLEAVE();
cannam@95 61 }
cannam@95 62
cannam@95 63 static const kdft_desc desc = { 3, XSIMD_STRING("n1bv_3"), {3, 1, 3, 0}, &GENUS, 0, 0, 0, 0 };
cannam@95 64
cannam@95 65 void XSIMD(codelet_n1bv_3) (planner *p) {
cannam@95 66 X(kdft_register) (p, n1bv_3, &desc);
cannam@95 67 }
cannam@95 68
cannam@95 69 #else /* HAVE_FMA */
cannam@95 70
cannam@95 71 /* Generated by: ../../../genfft/gen_notw_c.native -simd -compact -variables 4 -pipeline-latency 8 -sign 1 -n 3 -name n1bv_3 -include n1b.h */
cannam@95 72
cannam@95 73 /*
cannam@95 74 * This function contains 6 FP additions, 2 FP multiplications,
cannam@95 75 * (or, 5 additions, 1 multiplications, 1 fused multiply/add),
cannam@95 76 * 11 stack variables, 2 constants, and 6 memory accesses
cannam@95 77 */
cannam@95 78 #include "n1b.h"
cannam@95 79
cannam@95 80 static void n1bv_3(const R *ri, const R *ii, R *ro, R *io, stride is, stride os, INT v, INT ivs, INT ovs)
cannam@95 81 {
cannam@95 82 DVK(KP500000000, +0.500000000000000000000000000000000000000000000);
cannam@95 83 DVK(KP866025403, +0.866025403784438646763723170752936183471402627);
cannam@95 84 {
cannam@95 85 INT i;
cannam@95 86 const R *xi;
cannam@95 87 R *xo;
cannam@95 88 xi = ii;
cannam@95 89 xo = io;
cannam@95 90 for (i = v; i > 0; i = i - VL, xi = xi + (VL * ivs), xo = xo + (VL * ovs), MAKE_VOLATILE_STRIDE(6, is), MAKE_VOLATILE_STRIDE(6, os)) {
cannam@95 91 V T4, T3, T5, T1, T2, T6;
cannam@95 92 T4 = LD(&(xi[0]), ivs, &(xi[0]));
cannam@95 93 T1 = LD(&(xi[WS(is, 1)]), ivs, &(xi[WS(is, 1)]));
cannam@95 94 T2 = LD(&(xi[WS(is, 2)]), ivs, &(xi[0]));
cannam@95 95 T3 = VBYI(VMUL(LDK(KP866025403), VSUB(T1, T2)));
cannam@95 96 T5 = VADD(T1, T2);
cannam@95 97 ST(&(xo[0]), VADD(T4, T5), ovs, &(xo[0]));
cannam@95 98 T6 = VFNMS(LDK(KP500000000), T5, T4);
cannam@95 99 ST(&(xo[WS(os, 1)]), VADD(T3, T6), ovs, &(xo[WS(os, 1)]));
cannam@95 100 ST(&(xo[WS(os, 2)]), VSUB(T6, T3), ovs, &(xo[0]));
cannam@95 101 }
cannam@95 102 }
cannam@95 103 VLEAVE();
cannam@95 104 }
cannam@95 105
cannam@95 106 static const kdft_desc desc = { 3, XSIMD_STRING("n1bv_3"), {5, 1, 1, 0}, &GENUS, 0, 0, 0, 0 };
cannam@95 107
cannam@95 108 void XSIMD(codelet_n1bv_3) (planner *p) {
cannam@95 109 X(kdft_register) (p, n1bv_3, &desc);
cannam@95 110 }
cannam@95 111
cannam@95 112 #endif /* HAVE_FMA */