[MN-dev] [mndiff]: r193 - trunk/noe/galois.c

michael subversion at mplayerhq.hu
Tue Jul 13 11:31:45 CEST 2010


Author: michael
Date: Tue Jul 13 11:31:44 2010
New Revision: 193

Log:
Get rid of VLAs in galois.c

Modified:
   trunk/noe/galois.c

Modified: trunk/noe/galois.c
==============================================================================
--- trunk/noe/galois.c	Tue Jul 13 10:46:33 2010	(r192)
+++ trunk/noe/galois.c	Tue Jul 13 11:31:44 2010	(r193)
@@ -100,7 +100,7 @@ void EXT(prodPoly)(GFF4Element *dst, GFF
     }else{
         const int logSize= noe_log2(NOE_MIN(order-1, 1<<(SHIFT-1)))+1;
         const int size= 1<<logSize;
-        GFF4Element temp[2][size]; //FIXME is this fast?
+        GFF4Element temp[2][SIZE];
         const GFF4Element scale= inv(size);
 
         //FIXME avoid mem* (but note the memcpy/set only takes 2% of the prodPoly time)
@@ -225,7 +225,7 @@ void EXT(partialProdPoly)(GFF4Element *d
     }else{
         const int logSize= noe_log2(NOE_MIN(order2 + order1, 1<<(SHIFT-1)))+1;
         const int size= 1<<logSize;
-        GFF4Element temp[size]; //FIXME is this fast?
+        GFF4Element temp[SIZE];
         const GFF4Element scale= inv(size);
 
         //FIXME avoid mem* (but note the memcpy/set only takes 2% of the prodPoly time)
@@ -298,7 +298,7 @@ void EXT(getDerivative)(GFF4Element *dst
  */
 void EXT(synthPoly)(GFF4Element *dst, int *src, int count){
         int pass, i;
-        GFF4Element temp[2][4*count];
+        GFF4Element temp[2][4*SIZE];
         GFF4Element *temp1= count<=2 ? dst : temp[0];
 
         for(i=0; i+1<count; i+=2){


More information about the Mndiff-dev mailing list