Logo Search packages:      
Sourcecode: blender version File versions

t1bv_15.c

/*
 * Copyright (c) 2003, 2006 Matteo Frigo
 * Copyright (c) 2003, 2006 Massachusetts Institute of Technology
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 */

/* This file was automatically generated --- DO NOT EDIT */
/* Generated on Sat Jul  1 14:59:42 EDT 2006 */

#include "codelet-dft.h"

#ifdef HAVE_FMA

/* Generated by: ../../../genfft/gen_twiddle_c -fma -reorder-insns -schedule-for-pipeline -simd -compact -variables 4 -pipeline-latency 8 -n 15 -name t1bv_15 -include t1b.h -sign 1 */

/*
 * This function contains 92 FP additions, 77 FP multiplications,
 * (or, 50 additions, 35 multiplications, 42 fused multiply/add),
 * 81 stack variables, and 30 memory accesses
 */
/*
 * Generator Id's : 
 * $Id: algsimp.ml,v 1.9 2006-02-12 23:34:12 athena Exp $
 * $Id: fft.ml,v 1.4 2006-01-05 03:04:27 stevenj Exp $
 * $Id: gen_twiddle_c.ml,v 1.14 2006-02-12 23:34:12 athena Exp $
 */

#include "t1b.h"

static const R *t1bv_15(R *ri, R *ii, const R *W, stride ios, INT m, INT dist)
{
     DVK(KP823639103, +0.823639103546331925877420039278190003029660514);
     DVK(KP910592997, +0.910592997310029334643087372129977886038870291);
     DVK(KP559016994, +0.559016994374947424102293417182819058860154590);
     DVK(KP951056516, +0.951056516295153572116439333379382143405698634);
     DVK(KP866025403, +0.866025403784438646763723170752936183471402627);
     DVK(KP250000000, +0.250000000000000000000000000000000000000000000);
     DVK(KP618033988, +0.618033988749894848204586834365638117720309180);
     DVK(KP500000000, +0.500000000000000000000000000000000000000000000);
     INT i;
     R *x;
     x = ii;
     for (i = m; i > 0; i = i - VL, x = x + (VL * dist), W = W + (TWVL * 28), MAKE_VOLATILE_STRIDE(ios)) {
        V Tq, Ty, Th, TV, TK, Ts, T1f, T7, Tu, TA, TC, Tj, Tk, T1g, Tf;
        {
             V T1, T4, T2, T9, Te;
             T1 = LD(&(x[0]), dist, &(x[0]));
             T4 = LD(&(x[WS(ios, 10)]), dist, &(x[0]));
             T2 = LD(&(x[WS(ios, 5)]), dist, &(x[WS(ios, 1)]));
             {
                V T8, Tp, Tx, Tg;
                T8 = LD(&(x[WS(ios, 3)]), dist, &(x[WS(ios, 1)]));
                Tp = LD(&(x[WS(ios, 6)]), dist, &(x[0]));
                Tx = LD(&(x[WS(ios, 9)]), dist, &(x[WS(ios, 1)]));
                Tg = LD(&(x[WS(ios, 12)]), dist, &(x[0]));
                {
                   V Tb, Td, Tr, T6, Tt, Tz, TB, Ti;
                   {
                        V T5, T3, Ta, Tc;
                        Ta = LD(&(x[WS(ios, 8)]), dist, &(x[0]));
                        Tc = LD(&(x[WS(ios, 13)]), dist, &(x[WS(ios, 1)]));
                        T5 = BYTW(&(W[TWVL * 18]), T4);
                        T3 = BYTW(&(W[TWVL * 8]), T2);
                        T9 = BYTW(&(W[TWVL * 4]), T8);
                        Tq = BYTW(&(W[TWVL * 10]), Tp);
                        Ty = BYTW(&(W[TWVL * 16]), Tx);
                        Th = BYTW(&(W[TWVL * 22]), Tg);
                        Tb = BYTW(&(W[TWVL * 14]), Ta);
                        Td = BYTW(&(W[TWVL * 24]), Tc);
                        Tr = LD(&(x[WS(ios, 11)]), dist, &(x[WS(ios, 1)]));
                        TV = VSUB(T3, T5);
                        T6 = VADD(T3, T5);
                        Tt = LD(&(x[WS(ios, 1)]), dist, &(x[WS(ios, 1)]));
                   }
                   Tz = LD(&(x[WS(ios, 14)]), dist, &(x[0]));
                   TB = LD(&(x[WS(ios, 4)]), dist, &(x[0]));
                   Ti = LD(&(x[WS(ios, 2)]), dist, &(x[0]));
                   Te = VADD(Tb, Td);
                   TK = VSUB(Tb, Td);
                   Ts = BYTW(&(W[TWVL * 20]), Tr);
                   T1f = VADD(T1, T6);
                   T7 = VFNMS(LDK(KP500000000), T6, T1);
                   Tu = BYTW(&(W[0]), Tt);
                   TA = BYTW(&(W[TWVL * 26]), Tz);
                   TC = BYTW(&(W[TWVL * 6]), TB);
                   Tj = BYTW(&(W[TWVL * 2]), Ti);
                   Tk = LD(&(x[WS(ios, 7)]), dist, &(x[WS(ios, 1)]));
                }
             }
             T1g = VADD(T9, Te);
             Tf = VFNMS(LDK(KP500000000), Te, T9);
        }
        {
             V Tv, TN, TD, TO, Tl;
             Tv = VADD(Ts, Tu);
             TN = VSUB(Ts, Tu);
             TD = VADD(TA, TC);
             TO = VSUB(TA, TC);
             Tl = BYTW(&(W[TWVL * 12]), Tk);
             {
                V Tw, T1j, TX, TP, TE, T1k, TL, Tm;
                Tw = VFNMS(LDK(KP500000000), Tv, Tq);
                T1j = VADD(Tq, Tv);
                TX = VADD(TN, TO);
                TP = VSUB(TN, TO);
                TE = VFNMS(LDK(KP500000000), TD, Ty);
                T1k = VADD(Ty, TD);
                TL = VSUB(Tj, Tl);
                Tm = VADD(Tj, Tl);
                {
                   V TT, TF, T1q, T1l, TW, TM, T1h, Tn;
                   TT = VSUB(Tw, TE);
                   TF = VADD(Tw, TE);
                   T1q = VSUB(T1j, T1k);
                   T1l = VADD(T1j, T1k);
                   TW = VADD(TK, TL);
                   TM = VSUB(TK, TL);
                   T1h = VADD(Th, Tm);
                   Tn = VFNMS(LDK(KP500000000), Tm, Th);
                   {
                        V T10, TY, T16, TQ, T1r, T1i, TS, To, TZ, T1e;
                        T10 = VSUB(TW, TX);
                        TY = VADD(TW, TX);
                        T16 = VFNMS(LDK(KP618033988), TM, TP);
                        TQ = VFMA(LDK(KP618033988), TP, TM);
                        T1r = VSUB(T1g, T1h);
                        T1i = VADD(T1g, T1h);
                        TS = VSUB(Tf, Tn);
                        To = VADD(Tf, Tn);
                        TZ = VFNMS(LDK(KP250000000), TY, TV);
                        T1e = VMUL(LDK(KP866025403), VADD(TV, TY));
                        {
                           V T1u, T1s, T1o, T18, TU, TG, TI, T19, T11, T1n, T1m;
                           T1u = VMUL(LDK(KP951056516), VFMA(LDK(KP618033988), T1q, T1r));
                           T1s = VMUL(LDK(KP951056516), VFNMS(LDK(KP618033988), T1r, T1q));
                           T1m = VADD(T1i, T1l);
                           T1o = VSUB(T1i, T1l);
                           T18 = VFNMS(LDK(KP618033988), TS, TT);
                           TU = VFMA(LDK(KP618033988), TT, TS);
                           TG = VADD(To, TF);
                           TI = VSUB(To, TF);
                           T19 = VFNMS(LDK(KP559016994), T10, TZ);
                           T11 = VFMA(LDK(KP559016994), T10, TZ);
                           ST(&(x[0]), VADD(T1f, T1m), dist, &(x[0]));
                           T1n = VFNMS(LDK(KP250000000), T1m, T1f);
                           {
                              V T1a, T1c, T14, T12, T1p, T1t, T15, TJ, T1d, TH;
                              T1d = VADD(T7, TG);
                              TH = VFNMS(LDK(KP250000000), TG, T7);
                              T1a = VMUL(LDK(KP951056516), VFMA(LDK(KP910592997), T19, T18));
                              T1c = VMUL(LDK(KP951056516), VFNMS(LDK(KP910592997), T19, T18));
                              T14 = VMUL(LDK(KP951056516), VFNMS(LDK(KP910592997), T11, TU));
                              T12 = VMUL(LDK(KP951056516), VFMA(LDK(KP910592997), T11, TU));
                              T1p = VFNMS(LDK(KP559016994), T1o, T1n);
                              T1t = VFMA(LDK(KP559016994), T1o, T1n);
                              ST(&(x[WS(ios, 10)]), VFMAI(T1e, T1d), dist, &(x[0]));
                              ST(&(x[WS(ios, 5)]), VFNMSI(T1e, T1d), dist, &(x[WS(ios, 1)]));
                              T15 = VFNMS(LDK(KP559016994), TI, TH);
                              TJ = VFMA(LDK(KP559016994), TI, TH);
                              {
                                   V T17, T1b, T13, TR;
                                   ST(&(x[WS(ios, 12)]), VFNMSI(T1s, T1p), dist, &(x[0]));
                                   ST(&(x[WS(ios, 3)]), VFMAI(T1s, T1p), dist, &(x[WS(ios, 1)]));
                                   ST(&(x[WS(ios, 9)]), VFNMSI(T1u, T1t), dist, &(x[WS(ios, 1)]));
                                   ST(&(x[WS(ios, 6)]), VFMAI(T1u, T1t), dist, &(x[0]));
                                   T17 = VFNMS(LDK(KP823639103), T16, T15);
                                   T1b = VFMA(LDK(KP823639103), T16, T15);
                                   T13 = VFMA(LDK(KP823639103), TQ, TJ);
                                   TR = VFNMS(LDK(KP823639103), TQ, TJ);
                                   ST(&(x[WS(ios, 13)]), VFMAI(T1a, T17), dist, &(x[WS(ios, 1)]));
                                   ST(&(x[WS(ios, 2)]), VFNMSI(T1a, T17), dist, &(x[0]));
                                   ST(&(x[WS(ios, 8)]), VFMAI(T1c, T1b), dist, &(x[0]));
                                   ST(&(x[WS(ios, 7)]), VFNMSI(T1c, T1b), dist, &(x[WS(ios, 1)]));
                                   ST(&(x[WS(ios, 11)]), VFMAI(T14, T13), dist, &(x[WS(ios, 1)]));
                                   ST(&(x[WS(ios, 4)]), VFNMSI(T14, T13), dist, &(x[0]));
                                   ST(&(x[WS(ios, 14)]), VFNMSI(T12, TR), dist, &(x[0]));
                                   ST(&(x[WS(ios, 1)]), VFMAI(T12, TR), dist, &(x[WS(ios, 1)]));
                              }
                           }
                        }
                   }
                }
             }
        }
     }
     return W;
}

static const tw_instr twinstr[] = {
     VTW(1),
     VTW(2),
     VTW(3),
     VTW(4),
     VTW(5),
     VTW(6),
     VTW(7),
     VTW(8),
     VTW(9),
     VTW(10),
     VTW(11),
     VTW(12),
     VTW(13),
     VTW(14),
     {TW_NEXT, VL, 0}
};

static const ct_desc desc = { 15, "t1bv_15", twinstr, &GENUS, {50, 35, 42, 0}, 0, 0, 0 };

void X(codelet_t1bv_15) (planner *p) {
     X(kdft_dit_register) (p, t1bv_15, &desc);
}
#else                   /* HAVE_FMA */

/* Generated by: ../../../genfft/gen_twiddle_c -simd -compact -variables 4 -pipeline-latency 8 -n 15 -name t1bv_15 -include t1b.h -sign 1 */

/*
 * This function contains 92 FP additions, 53 FP multiplications,
 * (or, 78 additions, 39 multiplications, 14 fused multiply/add),
 * 52 stack variables, and 30 memory accesses
 */
/*
 * Generator Id's : 
 * $Id: algsimp.ml,v 1.9 2006-02-12 23:34:12 athena Exp $
 * $Id: fft.ml,v 1.4 2006-01-05 03:04:27 stevenj Exp $
 * $Id: gen_twiddle_c.ml,v 1.14 2006-02-12 23:34:12 athena Exp $
 */

#include "t1b.h"

static const R *t1bv_15(R *ri, R *ii, const R *W, stride ios, INT m, INT dist)
{
     DVK(KP216506350, +0.216506350946109661690930792688234045867850657);
     DVK(KP484122918, +0.484122918275927110647408174972799951354115213);
     DVK(KP866025403, +0.866025403784438646763723170752936183471402627);
     DVK(KP509036960, +0.509036960455127183450980863393907648510733164);
     DVK(KP823639103, +0.823639103546331925877420039278190003029660514);
     DVK(KP951056516, +0.951056516295153572116439333379382143405698634);
     DVK(KP587785252, +0.587785252292473129168705954639072768597652438);
     DVK(KP250000000, +0.250000000000000000000000000000000000000000000);
     DVK(KP559016994, +0.559016994374947424102293417182819058860154590);
     DVK(KP500000000, +0.500000000000000000000000000000000000000000000);
     INT i;
     R *x;
     x = ii;
     for (i = m; i > 0; i = i - VL, x = x + (VL * dist), W = W + (TWVL * 28), MAKE_VOLATILE_STRIDE(ios)) {
        V Ts, TV, T1f, TZ, T10, Tb, Tm, Tt, T1j, T1k, T1l, TI, TM, TR, Tz;
        V TD, TQ, T1g, T1h, T1i;
        {
             V TT, Tr, Tp, Tq, To, TU;
             TT = LD(&(x[0]), dist, &(x[0]));
             Tq = LD(&(x[WS(ios, 10)]), dist, &(x[0]));
             Tr = BYTW(&(W[TWVL * 18]), Tq);
             To = LD(&(x[WS(ios, 5)]), dist, &(x[WS(ios, 1)]));
             Tp = BYTW(&(W[TWVL * 8]), To);
             Ts = VSUB(Tp, Tr);
             TU = VADD(Tp, Tr);
             TV = VFNMS(LDK(KP500000000), TU, TT);
             T1f = VADD(TT, TU);
        }
        {
             V Tx, TG, TK, TB, T5, Ty, Tg, TH, Tl, TL, Ta, TC;
             {
                V Tw, TF, TJ, TA;
                Tw = LD(&(x[WS(ios, 3)]), dist, &(x[WS(ios, 1)]));
                Tx = BYTW(&(W[TWVL * 4]), Tw);
                TF = LD(&(x[WS(ios, 6)]), dist, &(x[0]));
                TG = BYTW(&(W[TWVL * 10]), TF);
                TJ = LD(&(x[WS(ios, 9)]), dist, &(x[WS(ios, 1)]));
                TK = BYTW(&(W[TWVL * 16]), TJ);
                TA = LD(&(x[WS(ios, 12)]), dist, &(x[0]));
                TB = BYTW(&(W[TWVL * 22]), TA);
             }
             {
                V T2, T4, T1, T3;
                T1 = LD(&(x[WS(ios, 8)]), dist, &(x[0]));
                T2 = BYTW(&(W[TWVL * 14]), T1);
                T3 = LD(&(x[WS(ios, 13)]), dist, &(x[WS(ios, 1)]));
                T4 = BYTW(&(W[TWVL * 24]), T3);
                T5 = VSUB(T2, T4);
                Ty = VADD(T2, T4);
             }
             {
                V Td, Tf, Tc, Te;
                Tc = LD(&(x[WS(ios, 11)]), dist, &(x[WS(ios, 1)]));
                Td = BYTW(&(W[TWVL * 20]), Tc);
                Te = LD(&(x[WS(ios, 1)]), dist, &(x[WS(ios, 1)]));
                Tf = BYTW(&(W[0]), Te);
                Tg = VSUB(Td, Tf);
                TH = VADD(Td, Tf);
             }
             {
                V Ti, Tk, Th, Tj;
                Th = LD(&(x[WS(ios, 14)]), dist, &(x[0]));
                Ti = BYTW(&(W[TWVL * 26]), Th);
                Tj = LD(&(x[WS(ios, 4)]), dist, &(x[0]));
                Tk = BYTW(&(W[TWVL * 6]), Tj);
                Tl = VSUB(Ti, Tk);
                TL = VADD(Ti, Tk);
             }
             {
                V T7, T9, T6, T8;
                T6 = LD(&(x[WS(ios, 2)]), dist, &(x[0]));
                T7 = BYTW(&(W[TWVL * 2]), T6);
                T8 = LD(&(x[WS(ios, 7)]), dist, &(x[WS(ios, 1)]));
                T9 = BYTW(&(W[TWVL * 12]), T8);
                Ta = VSUB(T7, T9);
                TC = VADD(T7, T9);
             }
             TZ = VSUB(T5, Ta);
             T10 = VSUB(Tg, Tl);
             Tb = VADD(T5, Ta);
             Tm = VADD(Tg, Tl);
             Tt = VADD(Tb, Tm);
             T1j = VADD(TG, TH);
             T1k = VADD(TK, TL);
             T1l = VADD(T1j, T1k);
             TI = VFNMS(LDK(KP500000000), TH, TG);
             TM = VFNMS(LDK(KP500000000), TL, TK);
             TR = VADD(TI, TM);
             Tz = VFNMS(LDK(KP500000000), Ty, Tx);
             TD = VFNMS(LDK(KP500000000), TC, TB);
             TQ = VADD(Tz, TD);
             T1g = VADD(Tx, Ty);
             T1h = VADD(TB, TC);
             T1i = VADD(T1g, T1h);
        }
        {
             V T1o, T1m, T1n, T1s, T1t, T1q, T1r, T1u, T1p;
             T1o = VMUL(LDK(KP559016994), VSUB(T1i, T1l));
             T1m = VADD(T1i, T1l);
             T1n = VFNMS(LDK(KP250000000), T1m, T1f);
             T1q = VSUB(T1g, T1h);
             T1r = VSUB(T1j, T1k);
             T1s = VBYI(VFNMS(LDK(KP951056516), T1r, VMUL(LDK(KP587785252), T1q)));
             T1t = VBYI(VFMA(LDK(KP951056516), T1q, VMUL(LDK(KP587785252), T1r)));
             ST(&(x[0]), VADD(T1f, T1m), dist, &(x[0]));
             T1u = VADD(T1o, T1n);
             ST(&(x[WS(ios, 6)]), VADD(T1t, T1u), dist, &(x[0]));
             ST(&(x[WS(ios, 9)]), VSUB(T1u, T1t), dist, &(x[WS(ios, 1)]));
             T1p = VSUB(T1n, T1o);
             ST(&(x[WS(ios, 3)]), VSUB(T1p, T1s), dist, &(x[WS(ios, 1)]));
             ST(&(x[WS(ios, 12)]), VADD(T1s, T1p), dist, &(x[0]));
        }
        {
             V T11, T18, T1e, TO, T16, Tv, T15, TY, T1d, T19, TE, TN;
             T11 = VFMA(LDK(KP823639103), TZ, VMUL(LDK(KP509036960), T10));
             T18 = VFNMS(LDK(KP823639103), T10, VMUL(LDK(KP509036960), TZ));
             T1e = VBYI(VMUL(LDK(KP866025403), VADD(Ts, Tt)));
             TE = VSUB(Tz, TD);
             TN = VSUB(TI, TM);
             TO = VFMA(LDK(KP951056516), TE, VMUL(LDK(KP587785252), TN));
             T16 = VFNMS(LDK(KP951056516), TN, VMUL(LDK(KP587785252), TE));
             {
                V Tn, Tu, TS, TW, TX;
                Tn = VMUL(LDK(KP484122918), VSUB(Tb, Tm));
                Tu = VFNMS(LDK(KP216506350), Tt, VMUL(LDK(KP866025403), Ts));
                Tv = VADD(Tn, Tu);
                T15 = VSUB(Tn, Tu);
                TS = VMUL(LDK(KP559016994), VSUB(TQ, TR));
                TW = VADD(TQ, TR);
                TX = VFNMS(LDK(KP250000000), TW, TV);
                TY = VADD(TS, TX);
                T1d = VADD(TV, TW);
                T19 = VSUB(TX, TS);
             }
             {
                V TP, T12, T1b, T1c;
                ST(&(x[WS(ios, 5)]), VSUB(T1d, T1e), dist, &(x[WS(ios, 1)]));
                ST(&(x[WS(ios, 10)]), VADD(T1e, T1d), dist, &(x[0]));
                TP = VBYI(VADD(Tv, TO));
                T12 = VSUB(TY, T11);
                ST(&(x[WS(ios, 1)]), VADD(TP, T12), dist, &(x[WS(ios, 1)]));
                ST(&(x[WS(ios, 14)]), VSUB(T12, TP), dist, &(x[0]));
                T1b = VBYI(VSUB(T16, T15));
                T1c = VSUB(T19, T18);
                ST(&(x[WS(ios, 7)]), VADD(T1b, T1c), dist, &(x[WS(ios, 1)]));
                ST(&(x[WS(ios, 8)]), VSUB(T1c, T1b), dist, &(x[0]));
                {
                   V T17, T1a, T13, T14;
                   T17 = VBYI(VADD(T15, T16));
                   T1a = VADD(T18, T19);
                   ST(&(x[WS(ios, 2)]), VADD(T17, T1a), dist, &(x[0]));
                   ST(&(x[WS(ios, 13)]), VSUB(T1a, T17), dist, &(x[WS(ios, 1)]));
                   T13 = VBYI(VSUB(Tv, TO));
                   T14 = VADD(T11, TY);
                   ST(&(x[WS(ios, 4)]), VADD(T13, T14), dist, &(x[0]));
                   ST(&(x[WS(ios, 11)]), VSUB(T14, T13), dist, &(x[WS(ios, 1)]));
                }
             }
        }
     }
     return W;
}

static const tw_instr twinstr[] = {
     VTW(1),
     VTW(2),
     VTW(3),
     VTW(4),
     VTW(5),
     VTW(6),
     VTW(7),
     VTW(8),
     VTW(9),
     VTW(10),
     VTW(11),
     VTW(12),
     VTW(13),
     VTW(14),
     {TW_NEXT, VL, 0}
};

static const ct_desc desc = { 15, "t1bv_15", twinstr, &GENUS, {78, 39, 14, 0}, 0, 0, 0 };

void X(codelet_t1bv_15) (planner *p) {
     X(kdft_dit_register) (p, t1bv_15, &desc);
}
#endif                        /* HAVE_FMA */

Generated by  Doxygen 1.6.0   Back to index