forked from len0rd/rockbox
Macros should be ALL CAPS, so rename (un)likely() to (UN)LIKELY()
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19181 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
5dfde5c80b
commit
95cf600b6c
4 changed files with 35 additions and 27 deletions
|
|
@ -154,9 +154,9 @@ STIN long decode_packed_entry_number(codebook *book,
|
|||
long lo,hi;
|
||||
long lok = oggpack_look(b,book->dec_firsttablen);
|
||||
|
||||
if (likely(lok >= 0)) {
|
||||
if (LIKELY(lok >= 0)) {
|
||||
long entry = book->dec_firsttable[lok];
|
||||
if(unlikely(entry&0x80000000UL)){
|
||||
if(UNLIKELY(entry&0x80000000UL)){
|
||||
lo=(entry>>15)&0x7fff;
|
||||
hi=book->used_entries-(entry&0x7fff);
|
||||
}else{
|
||||
|
|
@ -218,7 +218,7 @@ static long decode_packed_block(codebook *book, oggpack_buffer *b,
|
|||
bitend = ((adr&3)+b->headend)*8;
|
||||
while (bufptr<bufend){
|
||||
long entry, lo, hi;
|
||||
if (unlikely(cachesize<book->dec_maxlength)) {
|
||||
if (UNLIKELY(cachesize<book->dec_maxlength)) {
|
||||
if (bit-cachesize+32>=bitend)
|
||||
break;
|
||||
bit-=cachesize;
|
||||
|
|
@ -230,13 +230,13 @@ static long decode_packed_block(codebook *book, oggpack_buffer *b,
|
|||
}
|
||||
|
||||
entry=book->dec_firsttable[cache&((1<<book->dec_firsttablen)-1)];
|
||||
if(unlikely(entry&0x80000000UL)){
|
||||
if(UNLIKELY(entry&0x80000000UL)){
|
||||
lo=(entry>>15)&0x7fff;
|
||||
hi=book->used_entries-(entry&0x7fff);
|
||||
{
|
||||
ogg_uint32_t testword=bitreverse((ogg_uint32_t)cache);
|
||||
|
||||
while(likely(hi-lo>1)){
|
||||
while(LIKELY(hi-lo>1)){
|
||||
long p=(hi-lo)>>1;
|
||||
if (book->codelist[lo+p]>testword)
|
||||
hi-=p;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue