URL
https://opencores.org/ocsvn/openrisc_2011-10-31/openrisc_2011-10-31/trunk
Only display areas with differences |
Details |
Blame |
View Log
Rev 298 |
Rev 384 |
/* { dg-do compile } */
|
/* { dg-do compile } */
|
/* { dg-options "-O2 -ftree-loop-linear" } */
|
/* { dg-options "-O2 -ftree-loop-linear" } */
|
|
|
float weight[10];
|
float weight[10];
|
void lsp_weight_quant(float *x, char *cdbk)
|
void lsp_weight_quant(float *x, char *cdbk)
|
{
|
{
|
int i,j;
|
int i,j;
|
float dist;
|
float dist;
|
int best_id=0;
|
int best_id=0;
|
for (i=0;i<16;i++)
|
for (i=0;i<16;i++)
|
{
|
{
|
for (j=0;j<10;j++)
|
for (j=0;j<10;j++)
|
dist=dist+weight[j];
|
dist=dist+weight[j];
|
if (dist<0)
|
if (dist<0)
|
best_id=i;
|
best_id=i;
|
}
|
}
|
x[j] = cdbk[best_id*10+j];
|
x[j] = cdbk[best_id*10+j];
|
}
|
}
|
|
|
© copyright 1999-2024
OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.