Changeset 36727 in webkit for trunk/JavaScriptCore/VM/Machine.cpp


Ignore:
Timestamp:
Sep 20, 2008, 10:54:23 PM (17 years ago)
Author:
[email protected]
Message:

2008-09-20 Maciej Stachowiak <[email protected]>

Reviewed by Darin.



2.5% speedup on earley-boyer test

  • VM/Machine.cpp: (JSC::Machine::cti_op_stricteq): Use inline version of strictEqualSlowCase; remove unneeded exception check. (JSC::Machine::cti_op_nstricteq): ditto
  • kjs/operations.cpp: (JSC::strictEqual): Use strictEqualSlowCaseInline (JSC::strictEqualSlowCase): ditto
  • kjs/operations.h: (JSC::strictEqualSlowCaseInline): Version of strictEqualSlowCase that can be inlined, since the extra function call indirection is a lose for CTI.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/VM/Machine.cpp

    r36726 r36727  
    53025302    if (JSImmediate::areBothImmediate(src1, src2))
    53035303        return jsBoolean(reinterpret_cast<intptr_t>(src1) == reinterpret_cast<intptr_t>(src2));
    5304     if (JSImmediate::isEitherImmediate(src1, src2) & (src1 != JSImmediate::from(0)) & (src2 != JSImmediate::from(0)))
     5304    if (JSImmediate::isEitherImmediate(src1, src2) & (src1 != JSImmediate::zeroImmediate()) & (src2 != JSImmediate::zeroImmediate()))
    53055305        return jsBoolean(false);
    53065306
    5307     ExecState* exec = ARG_exec;
    5308     JSValue* result = jsBoolean(strictEqualSlowCase(src1, src2));
    5309     VM_CHECK_EXCEPTION_AT_END();
    5310     return result;
     5307    return jsBoolean(strictEqualSlowCaseInline(src1, src2));
    53115308}
    53125309
     
    53185315    if (JSImmediate::areBothImmediate(src1, src2))
    53195316        return jsBoolean(reinterpret_cast<intptr_t>(src1) != reinterpret_cast<intptr_t>(src2));
    5320     if (JSImmediate::isEitherImmediate(src1, src2) & (src1 != JSImmediate::from(0)) & (src2 != JSImmediate::from(0)))
     5317    if (JSImmediate::isEitherImmediate(src1, src2) & (src1 != JSImmediate::zeroImmediate()) & (src2 != JSImmediate::zeroImmediate()))
    53215318        return jsBoolean(true);
    53225319   
    5323     ExecState* exec = ARG_exec;
    5324     JSValue* result = jsBoolean(!strictEqualSlowCase(src1, src2));
    5325     VM_CHECK_EXCEPTION_AT_END();
    5326     return result;
     5320    return jsBoolean(!strictEqualSlowCaseInline(src1, src2));
    53275321}
    53285322
Note: See TracChangeset for help on using the changeset viewer.