19 |
* along with this program; if not, write to the Free Software |
* along with this program; if not, write to the Free Software |
20 |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
21 |
* |
* |
22 |
* $Id: xvid_bench.c,v 1.24 2005-09-20 11:51:40 suxen_drol Exp $ |
* $Id: xvid_bench.c,v 1.25 2005-09-23 12:53:35 suxen_drol Exp $ |
23 |
* |
* |
24 |
****************************************************************************/ |
****************************************************************************/ |
25 |
|
|
923 |
DECLARE_ALIGNED_MATRIX(Src2, 6, 64, int16_t, 16); |
DECLARE_ALIGNED_MATRIX(Src2, 6, 64, int16_t, 16); |
924 |
DECLARE_ALIGNED_MATRIX(Src3, 6, 64, int16_t, 16); |
DECLARE_ALIGNED_MATRIX(Src3, 6, 64, int16_t, 16); |
925 |
DECLARE_ALIGNED_MATRIX(Src4, 6, 64, int16_t, 16); |
DECLARE_ALIGNED_MATRIX(Src4, 6, 64, int16_t, 16); |
926 |
|
DECLARE_ALIGNED_MATRIX(Src5, 6, 64, int16_t, 16); |
927 |
|
|
928 |
printf( "\n ===== test cbp =====\n" ); |
printf( "\n ===== test cbp =====\n" ); |
929 |
|
|
932 |
Src2[i] = (i<3*64); /* half-full */ |
Src2[i] = (i<3*64); /* half-full */ |
933 |
Src3[i] = ((i+32)>3*64); |
Src3[i] = ((i+32)>3*64); |
934 |
Src4[i] = (i==(3*64+2) || i==(5*64+9)); |
Src4[i] = (i==(3*64+2) || i==(5*64+9)); |
935 |
|
Src5[i] = ieee_rand(0,1) ? -1 : 1; /* +/- test */ |
936 |
} |
} |
937 |
|
|
938 |
for(cpu = cpu_list; cpu->name!=0; ++cpu) |
for(cpu = cpu_list; cpu->name!=0; ++cpu) |
955 |
TEST_CBP(calc_cbp, Src4, nb_tests); |
TEST_CBP(calc_cbp, Src4, nb_tests); |
956 |
printf("%s - calc_cbp#4 %.3f usec cbp=0x%02x %s\n", |
printf("%s - calc_cbp#4 %.3f usec cbp=0x%02x %s\n", |
957 |
cpu->name, t, cbp, (cbp!=0x05)?"| ERROR": "" ); |
cpu->name, t, cbp, (cbp!=0x05)?"| ERROR": "" ); |
958 |
|
TEST_CBP(calc_cbp, Src5, nb_tests); |
959 |
|
printf("%s - calc_cbp#4 %.3f usec cbp=0x%02x %s\n", |
960 |
|
cpu->name, t, cbp, (cbp!=0x3f)?"| ERROR": "" ); |
961 |
printf( " --- \n" ); |
printf( " --- \n" ); |
962 |
} |
} |
963 |
|
|