gcc isn't smart enough to factor out duplicate stores

Originally committed as revision 10611 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Loren Merritt 2007-09-29 01:54:25 +00:00
parent 551109d48a
commit f6215b1b06

View File

@ -499,10 +499,11 @@ static void calc_sums(int pmin, int pmax, uint32_t *data, int n, int pred_order,
res = &data[pred_order];
res_end = &data[n >> pmax];
for(i=0; i<parts; i++) {
sums[pmax][i] = 0;
uint32_t sum = 0;
while(res < res_end){
sums[pmax][i] += *(res++);
sum += *(res++);
}
sums[pmax][i] = sum;
res_end+= n >> pmax;
}
/* sums for lower levels */