Ignore:
Timestamp:
Sep 21, 2010, 11:43:09 AM (15 years ago)
Author:
[email protected]
Message:

2010-09-21 Geoffrey Garen <[email protected]>

Reviewed by Oliver Hunt.

<rdar://problem/8363003> REGRESSION: ~1.4% sunspider regression in
interpreter due to 54724 and 54596


Fixed a typo (using "UNLIKELY" instead of "LIKELY").


  • wtf/PassRefPtr.h: (WTF::refIfNotNull): (WTF::derefIfNotNull): It is likely that m_ptr != 0 because most RefPtrs hold real data. Also, in cases where they do not hold real data, the compiler usually sees a call to release() right before the call to the destructor, so it can probably optimize out the test completely.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/wtf/PassRefPtr.h

    r65130 r67972  
    4949    template<typename T> REF_DEREF_INLINE void refIfNotNull(T* ptr)
    5050    {
    51         if (UNLIKELY(ptr != 0))
     51        if (LIKELY(ptr != 0))
    5252            ptr->ref();
    5353    }
     
    5555    template<typename T> REF_DEREF_INLINE void derefIfNotNull(T* ptr)
    5656    {
    57         if (UNLIKELY(ptr != 0))
     57        if (LIKELY(ptr != 0))
    5858            ptr->deref();
    5959    }
Note: See TracChangeset for help on using the changeset viewer.