# HG changeset patch # User michael # Date 1263857474 0 # Node ID bb774f0bc2b6a20ebd90ec1029a36459a3cb65d3 # Parent 42cff5346e53e70ee57f1a9ff410c3d66a72d5c4 Optimize top non_zero_count_cache init. diff -r 42cff5346e53 -r bb774f0bc2b6 h264.h --- a/h264.h Mon Jan 18 23:30:21 2010 +0000 +++ b/h264.h Mon Jan 18 23:31:14 2010 +0000 @@ -970,16 +970,13 @@ if(for_deblock){ *(uint32_t*)&h->non_zero_count_cache[4+8*0]= 0; }else{ - h->non_zero_count_cache[4+8*0]= - h->non_zero_count_cache[5+8*0]= - h->non_zero_count_cache[6+8*0]= - h->non_zero_count_cache[7+8*0]= h->non_zero_count_cache[1+8*0]= h->non_zero_count_cache[2+8*0]= h->non_zero_count_cache[1+8*3]= - h->non_zero_count_cache[2+8*3]= CABAC && !IS_INTRA(mb_type) ? 0 : 64; + h->non_zero_count_cache[2+8*3]= + *(uint32_t*)&h->non_zero_count_cache[4+8*0]= CABAC && !IS_INTRA(mb_type) ? 0 : 0x40404040; } }