Ignore:
Timestamp:
Nov 12, 2008, 4:48:23 PM (17 years ago)
Author:
[email protected]
Message:

2008-11-12 Geoffrey Garen <[email protected]>

Reviewed by Sam Weinig.


Fixed https://bugs.webkit.org/show_bug.cgi?id=22192
+37 failures in fast/profiler


along with Darin's review comments in
https://bugs.webkit.org/show_bug.cgi?id=22174
Simplified op_call by nixing its responsibility for moving the value of
"this" into the first argument slot

  • VM/Machine.cpp: (JSC::returnToThrowTrampoline): (JSC::throwStackOverflowError): (JSC::Machine::cti_register_file_check): (JSC::Machine::cti_op_call_arityCheck): (JSC::Machine::cti_vm_throw): Moved the throw logic into a function, since functions are better than macros.
  • bytecompiler/CodeGenerator.cpp: (JSC::CodeGenerator::emitCall): (JSC::CodeGenerator::emitConstruct): Ensure that the function register is preserved if profiling is enabled, since the profiler uses that register.
  • runtime/JSGlobalData.h: Renamed throwReturnAddress to exceptionLocation, because I had a hard time understanding what "throwReturnAddress" meant.
File:
1 edited

Legend:

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

    r38330 r38349  
    813813        }
    814814        case op_call: {
    815             int r0 = (++it)->u.operand;
    816             int r1 = (++it)->u.operand;
    817             int r2 = (++it)->u.operand;
    818             int tempCount = (++it)->u.operand;
     815            int dst = (++it)->u.operand;
     816            int func = (++it)->u.operand;
    819817            int argCount = (++it)->u.operand;
    820818            int registerOffset = (++it)->u.operand;
    821             printf("[%4d] call\t\t %s, %s, %s, %d, %d, %d\n", location, registerName(r0).c_str(), registerName(r1).c_str(), registerName(r2).c_str(), tempCount, argCount, registerOffset);
     819            printf("[%4d] call\t\t %s, %s, %d, %d\n", location, registerName(dst).c_str(), registerName(func).c_str(), argCount, registerOffset);
    822820            break;
    823821        }
    824822        case op_call_eval: {
    825             int r0 = (++it)->u.operand;
    826             int r1 = (++it)->u.operand;
    827             int r2 = (++it)->u.operand;
    828             int tempCount = (++it)->u.operand;
     823            int dst = (++it)->u.operand;
     824            int func = (++it)->u.operand;
    829825            int argCount = (++it)->u.operand;
    830826            int registerOffset = (++it)->u.operand;
    831             printf("[%4d] call_eval\t\t %s, %s, %s, %d, %d, %d\n", location, registerName(r0).c_str(), registerName(r1).c_str(), registerName(r2).c_str(), tempCount, argCount, registerOffset);
     827            printf("[%4d] call_eval\t %s, %s, %d, %d\n", location, registerName(dst).c_str(), registerName(func).c_str(), argCount, registerOffset);
    832828            break;
    833829        }
     
    847843        }
    848844        case op_construct: {
    849             int r0 = (++it)->u.operand;
    850             int r1 = (++it)->u.operand;
    851             int r2 = (++it)->u.operand;
    852             int tempCount = (++it)->u.operand;
     845            int dst = (++it)->u.operand;
     846            int func = (++it)->u.operand;
    853847            int argCount = (++it)->u.operand;
    854848            int registerOffset = (++it)->u.operand;
    855             printf("[%4d] construct\t %s, %s, %s, %d, %d, %d\n", location, registerName(r0).c_str(), registerName(r1).c_str(), registerName(r2).c_str(), tempCount, argCount, registerOffset);
     849            int proto = (++it)->u.operand;
     850            int thisRegister = (++it)->u.operand;
     851            printf("[%4d] construct\t %s, %s, %d, %d, %s, %s\n", location, registerName(dst).c_str(), registerName(func).c_str(), argCount, registerOffset, registerName(proto).c_str(), registerName(thisRegister).c_str());
    856852            break;
    857853        }
Note: See TracChangeset for help on using the changeset viewer.