Changeset 171614 in webkit


Ignore:
Timestamp:
Jul 25, 2014, 2:26:20 PM (11 years ago)
Author:
[email protected]
Message:

Remove JSPropertyNameIterator
https://bugs.webkit.org/show_bug.cgi?id=135066

Reviewed by Geoffrey Garen.

It has been replaced by JSPropertyNameEnumerator.

(JSC::isBranch):

  • bytecode/BytecodeList.json:
  • bytecode/BytecodeUseDef.h:

(JSC::computeUsesForBytecodeOffset):
(JSC::computeDefsForBytecodeOffset):

  • bytecode/CodeBlock.cpp:

(JSC::CodeBlock::dumpBytecode):

  • bytecode/PreciseJumpTargets.cpp:

(JSC::getJumpTargetsForBytecodeOffset):

  • bytecompiler/BytecodeGenerator.cpp:

(JSC::BytecodeGenerator::emitGetPropertyNames): Deleted.
(JSC::BytecodeGenerator::emitNextPropertyName): Deleted.

  • bytecompiler/BytecodeGenerator.h:
  • interpreter/Interpreter.cpp:
  • interpreter/Register.h:
  • jit/JIT.cpp:

(JSC::JIT::privateCompileMainPass):
(JSC::JIT::privateCompileSlowCases):

  • jit/JIT.h:
  • jit/JITOpcodes.cpp:

(JSC::JIT::emit_op_get_pnames): Deleted.
(JSC::JIT::emit_op_next_pname): Deleted.

  • jit/JITOpcodes32_64.cpp:

(JSC::JIT::emit_op_get_pnames): Deleted.
(JSC::JIT::emit_op_next_pname): Deleted.

  • jit/JITOperations.cpp:
  • jit/JITPropertyAccess.cpp:

(JSC::JIT::emit_op_get_by_pname): Deleted.
(JSC::JIT::emitSlow_op_get_by_pname): Deleted.

  • jit/JITPropertyAccess32_64.cpp:

(JSC::JIT::emit_op_get_by_pname): Deleted.
(JSC::JIT::emitSlow_op_get_by_pname): Deleted.

  • llint/LLIntOffsetsExtractor.cpp:
  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::LLINT_SLOW_PATH_DECL): Deleted.

  • llint/LLIntSlowPaths.h:
  • llint/LowLevelInterpreter.asm:
  • llint/LowLevelInterpreter32_64.asm:
  • llint/LowLevelInterpreter64.asm:
  • runtime/CommonSlowPaths.cpp:
  • runtime/JSPropertyNameIterator.cpp:

(JSC::JSPropertyNameIterator::JSPropertyNameIterator): Deleted.
(JSC::JSPropertyNameIterator::create): Deleted.
(JSC::JSPropertyNameIterator::destroy): Deleted.
(JSC::JSPropertyNameIterator::get): Deleted.
(JSC::JSPropertyNameIterator::visitChildren): Deleted.

  • runtime/JSPropertyNameIterator.h:

(JSC::JSPropertyNameIterator::createStructure): Deleted.
(JSC::JSPropertyNameIterator::size): Deleted.
(JSC::JSPropertyNameIterator::setCachedStructure): Deleted.
(JSC::JSPropertyNameIterator::cachedStructure): Deleted.
(JSC::JSPropertyNameIterator::setCachedPrototypeChain): Deleted.
(JSC::JSPropertyNameIterator::cachedPrototypeChain): Deleted.
(JSC::JSPropertyNameIterator::finishCreation): Deleted.
(JSC::Register::propertyNameIterator): Deleted.
(JSC::StructureRareData::enumerationCache): Deleted.
(JSC::StructureRareData::setEnumerationCache): Deleted.

  • runtime/Structure.cpp:

(JSC::Structure::addPropertyWithoutTransition):
(JSC::Structure::removePropertyWithoutTransition):

  • runtime/Structure.h:
  • runtime/StructureInlines.h:

(JSC::Structure::setEnumerationCache): Deleted.
(JSC::Structure::enumerationCache): Deleted.

  • runtime/StructureRareData.cpp:

(JSC::StructureRareData::visitChildren):

  • runtime/StructureRareData.h:
  • runtime/VM.cpp:

(JSC::VM::VM):

Location:
branches/ftlopt/Source/JavaScriptCore
Files:
2 deleted
35 edited

Legend:

Unmodified
Added
Removed
  • branches/ftlopt/Source/JavaScriptCore/CMakeLists.txt

    r171495 r171614  
    435435    runtime/JSPromiseReaction.cpp
    436436    runtime/JSPromisePrototype.cpp
    437     runtime/JSPropertyNameIterator.cpp
    438437    runtime/JSProxy.cpp
    439438    runtime/JSScope.cpp
  • branches/ftlopt/Source/JavaScriptCore/ChangeLog

    r171611 r171614  
     12014-07-25  Mark Hahnenberg  <[email protected]>
     2
     3        Remove JSPropertyNameIterator
     4        https://bugs.webkit.org/show_bug.cgi?id=135066
     5
     6        Reviewed by Geoffrey Garen.
     7
     8        It has been replaced by JSPropertyNameEnumerator.
     9
     10        * JavaScriptCore.order:
     11        * bytecode/BytecodeBasicBlock.cpp:
     12        (JSC::isBranch):
     13        * bytecode/BytecodeList.json:
     14        * bytecode/BytecodeUseDef.h:
     15        (JSC::computeUsesForBytecodeOffset):
     16        (JSC::computeDefsForBytecodeOffset):
     17        * bytecode/CodeBlock.cpp:
     18        (JSC::CodeBlock::dumpBytecode):
     19        * bytecode/PreciseJumpTargets.cpp:
     20        (JSC::getJumpTargetsForBytecodeOffset):
     21        * bytecompiler/BytecodeGenerator.cpp:
     22        (JSC::BytecodeGenerator::emitGetPropertyNames): Deleted.
     23        (JSC::BytecodeGenerator::emitNextPropertyName): Deleted.
     24        * bytecompiler/BytecodeGenerator.h:
     25        * interpreter/Interpreter.cpp:
     26        * interpreter/Register.h:
     27        * jit/JIT.cpp:
     28        (JSC::JIT::privateCompileMainPass):
     29        (JSC::JIT::privateCompileSlowCases):
     30        * jit/JIT.h:
     31        * jit/JITOpcodes.cpp:
     32        (JSC::JIT::emit_op_get_pnames): Deleted.
     33        (JSC::JIT::emit_op_next_pname): Deleted.
     34        * jit/JITOpcodes32_64.cpp:
     35        (JSC::JIT::emit_op_get_pnames): Deleted.
     36        (JSC::JIT::emit_op_next_pname): Deleted.
     37        * jit/JITOperations.cpp:
     38        * jit/JITPropertyAccess.cpp:
     39        (JSC::JIT::emit_op_get_by_pname): Deleted.
     40        (JSC::JIT::emitSlow_op_get_by_pname): Deleted.
     41        * jit/JITPropertyAccess32_64.cpp:
     42        (JSC::JIT::emit_op_get_by_pname): Deleted.
     43        (JSC::JIT::emitSlow_op_get_by_pname): Deleted.
     44        * llint/LLIntOffsetsExtractor.cpp:
     45        * llint/LLIntSlowPaths.cpp:
     46        (JSC::LLInt::LLINT_SLOW_PATH_DECL): Deleted.
     47        * llint/LLIntSlowPaths.h:
     48        * llint/LowLevelInterpreter.asm:
     49        * llint/LowLevelInterpreter32_64.asm:
     50        * llint/LowLevelInterpreter64.asm:
     51        * runtime/CommonSlowPaths.cpp:
     52        * runtime/JSPropertyNameIterator.cpp:
     53        (JSC::JSPropertyNameIterator::JSPropertyNameIterator): Deleted.
     54        (JSC::JSPropertyNameIterator::create): Deleted.
     55        (JSC::JSPropertyNameIterator::destroy): Deleted.
     56        (JSC::JSPropertyNameIterator::get): Deleted.
     57        (JSC::JSPropertyNameIterator::visitChildren): Deleted.
     58        * runtime/JSPropertyNameIterator.h:
     59        (JSC::JSPropertyNameIterator::createStructure): Deleted.
     60        (JSC::JSPropertyNameIterator::size): Deleted.
     61        (JSC::JSPropertyNameIterator::setCachedStructure): Deleted.
     62        (JSC::JSPropertyNameIterator::cachedStructure): Deleted.
     63        (JSC::JSPropertyNameIterator::setCachedPrototypeChain): Deleted.
     64        (JSC::JSPropertyNameIterator::cachedPrototypeChain): Deleted.
     65        (JSC::JSPropertyNameIterator::finishCreation): Deleted.
     66        (JSC::Register::propertyNameIterator): Deleted.
     67        (JSC::StructureRareData::enumerationCache): Deleted.
     68        (JSC::StructureRareData::setEnumerationCache): Deleted.
     69        * runtime/Structure.cpp:
     70        (JSC::Structure::addPropertyWithoutTransition):
     71        (JSC::Structure::removePropertyWithoutTransition):
     72        * runtime/Structure.h:
     73        * runtime/StructureInlines.h:
     74        (JSC::Structure::setEnumerationCache): Deleted.
     75        (JSC::Structure::enumerationCache): Deleted.
     76        * runtime/StructureRareData.cpp:
     77        (JSC::StructureRareData::visitChildren):
     78        * runtime/StructureRareData.h:
     79        * runtime/VM.cpp:
     80        (JSC::VM::VM):
     81
    1822014-07-25  Saam Barati  <[email protected]>
    283
  • branches/ftlopt/Source/JavaScriptCore/JavaScriptCore.order

    r163027 r171614  
    13551355__ZN3JSC14jsIsObjectTypeEPNS_9ExecStateENS_7JSValueE
    13561356__ZN3JSC6JSCell11getCallDataEPS0_RNS_8CallDataE
    1357 __ZN3JSC22JSPropertyNameIterator6createEPNS_9ExecStateEPNS_8JSObjectE
    13581357__ZN3JSC8JSObject16getPropertyNamesEPS0_PNS_9ExecStateERNS_17PropertyNameArrayENS_15EnumerationModeE
    13591358__ZN3JSC8JSObject19getOwnPropertyNamesEPS0_PNS_9ExecStateERNS_17PropertyNameArrayENS_15EnumerationModeE
     
    16391638__ZN3JSC8Watchdog9isEnabledEv
    16401639__ZN3JSC3JIT16emit_op_jeq_nullEPNS_11InstructionE
    1641 __ZN3JSC3JIT18emit_op_get_pnamesEPNS_11InstructionE
    16421640__ZN3JSC3JIT11emit_op_jmpEPNS_11InstructionE
    1643 __ZN3JSC3JIT20emit_op_get_by_pnameEPNS_11InstructionE
    16441641__ZN3JSC3JIT22compileGetDirectOffsetENS_12X86Registers10RegisterIDES2_S2_S2_NS0_15FinalObjectModeE
    16451642__ZN3JSC3JIT17emit_op_new_arrayEPNS_11InstructionE
    16461643__ZN3JSC3JIT17emit_op_nstricteqEPNS_11InstructionE
    1647 __ZN3JSC3JIT18emit_op_next_pnameEPNS_11InstructionE
    16481644__ZN3JSC3JIT11emit_op_incEPNS_11InstructionE
    16491645__ZN3JSC3JIT13emit_op_jlessEPNS_11InstructionE
     
    16641660__ZN3JSC23MacroAssemblerX86Common12branchDoubleENS0_15DoubleConditionENS_12X86Registers13XMMRegisterIDES3_
    16651661__ZN3JSC12X86Assembler23X86InstructionFormatter9twoByteOpENS0_15TwoByteOpcodeIDEiNS_12X86Registers10RegisterIDE
    1666 __ZN3JSC3JIT24emitSlow_op_get_by_pnameEPNS_11InstructionERPNS_13SlowCaseEntryE
    16671662__ZN3JSC3JIT21emitSlow_op_nstricteqEPNS_11InstructionERPNS_13SlowCaseEntryE
    16681663__ZN3JSC3JIT15emitSlow_op_incEPNS_11InstructionERPNS_13SlowCaseEntryE
     
    16761671_cti_op_jtrue
    16771672_cti_op_is_object
    1678 _cti_op_get_pnames
    16791673__ZN3JSC8JSString12toThisObjectEPNS_6JSCellEPNS_9ExecStateE
    16801674__ZN3JSC12StringObjectC1ERNS_2VMEPNS_9StructureE
     
    26242618__ZN3JSC13JSFinalObject13visitChildrenEPNS_6JSCellERNS_11SlotVisitorE
    26252619__ZN3JSC17StructureRareData13visitChildrenEPNS_6JSCellERNS_11SlotVisitorE
    2626 __ZN3JSC22JSPropertyNameIterator13visitChildrenEPNS_6JSCellERNS_11SlotVisitorE
    26272620__ZN3JSC14StructureChain13visitChildrenEPNS_6JSCellERNS_11SlotVisitorE
    26282621__ZN3JSC14MarkStackArray6expandEv
     
    26682661__ZN3JSC17SharedSymbolTable7destroyEPNS_6JSCellE
    26692662__ZN3JSC10JSFunction7destroyEPNS_6JSCellE
    2670 __ZN3JSC22JSPropertyNameIterator7destroyEPNS_6JSCellE
    26712663__ZN3JSC19ResolveGlobalStatus10computeForEPNS_9CodeBlockEiPNS_16ResolveOperationERNS_10IdentifierE
    26722664__ZN3JSC13GetByIdStatus10computeForERNS_2VMEPNS_9StructureERNS_10IdentifierE
     
    49434935_llint_slow_path_get_by_val
    49444936_llint_slow_path_get_argument_by_val
    4945 _llint_slow_path_get_by_pname
    49464937_llint_slow_path_put_by_val
    49474938_llint_slow_path_del_by_val
     
    49714962_llint_slow_path_strcat
    49724963_llint_slow_path_to_primitive
    4973 _llint_slow_path_get_pnames
    4974 _llint_slow_path_next_pname
    49754964_llint_slow_path_push_with_scope
    49764965_llint_slow_path_pop_scope
     
    50395028_llint_op_get_by_val
    50405029_llint_op_get_argument_by_val
    5041 _llint_op_get_by_pname
    50425030_llint_op_put_by_val
    50435031_llint_op_jmp
     
    50545042_llint_op_ret_object_or_this
    50555043_llint_op_to_primitive
    5056 _llint_op_next_pname
    50575044_llint_op_catch
    50585045_llint_op_get_scoped_var
     
    51125099_llint_generic_return_point
    51135100_llint_op_strcat
    5114 _llint_op_get_pnames
    51155101_llint_op_push_with_scope
    51165102_llint_op_pop_scope
  • branches/ftlopt/Source/JavaScriptCore/JavaScriptCore.vcxproj/JavaScriptCore.vcxproj

    r171495 r171614  
    681681    <ClCompile Include="..\runtime\JSPromiseReaction.cpp" />
    682682    <ClCompile Include="..\runtime\JSPromisePrototype.cpp" />
    683     <ClCompile Include="..\runtime\JSPropertyNameIterator.cpp" />
    684683    <ClCompile Include="..\runtime\JSProxy.cpp" />
    685684    <ClCompile Include="..\runtime\JSScope.cpp" />
     
    13721371    <ClInclude Include="..\runtime\JSPromiseReaction.h" />
    13731372    <ClInclude Include="..\runtime\JSPromisePrototype.h" />
    1374     <ClInclude Include="..\runtime\JSPropertyNameIterator.h" />
    13751373    <ClInclude Include="..\runtime\JSProxy.h" />
    13761374    <ClInclude Include="..\runtime\JSScope.h" />
  • branches/ftlopt/Source/JavaScriptCore/JavaScriptCore.vcxproj/JavaScriptCore.vcxproj.filters

    r170399 r171614  
    649649      <Filter>runtime</Filter>
    650650    </ClCompile>
    651     <ClCompile Include="..\runtime\JSPropertyNameIterator.cpp">
    652       <Filter>runtime</Filter>
    653     </ClCompile>
    654651    <ClCompile Include="..\runtime\JSProxy.cpp">
    655652      <Filter>runtime</Filter>
     
    23052302    </ClInclude>
    23062303    <ClInclude Include="..\runtime\JSONObject.h">
    2307       <Filter>runtime</Filter>
    2308     </ClInclude>
    2309     <ClInclude Include="..\runtime\JSPropertyNameIterator.h">
    23102304      <Filter>runtime</Filter>
    23112305    </ClInclude>
  • branches/ftlopt/Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj

    r171605 r171614  
    17321732                A72700900DAC6BBC00E548D7 /* JSNotAnObject.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A72700780DAC605600E548D7 /* JSNotAnObject.cpp */; };
    17331733                A72701B90DADE94900E548D7 /* ExceptionHelpers.h in Headers */ = {isa = PBXBuildFile; fileRef = A72701B30DADE94900E548D7 /* ExceptionHelpers.h */; };
    1734                 A727FF6B0DA3092200E548D7 /* JSPropertyNameIterator.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A727FF660DA3053B00E548D7 /* JSPropertyNameIterator.cpp */; };
    17351734                A7280A2811557E3000D56957 /* JSObjectRefPrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = A79EDB0811531CD60019E912 /* JSObjectRefPrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };
    17361735                A729009C17976C6000317298 /* MacroAssemblerARMv7.cpp in Sources */ = {isa = PBXBuildFile; fileRef = A729009B17976C6000317298 /* MacroAssemblerARMv7.cpp */; };
     
    34053404                A72700780DAC605600E548D7 /* JSNotAnObject.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSNotAnObject.cpp; sourceTree = "<group>"; };
    34063405                A72701B30DADE94900E548D7 /* ExceptionHelpers.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ExceptionHelpers.h; sourceTree = "<group>"; };
    3407                 A727FF650DA3053B00E548D7 /* JSPropertyNameIterator.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = JSPropertyNameIterator.h; sourceTree = "<group>"; };
    3408                 A727FF660DA3053B00E548D7 /* JSPropertyNameIterator.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSPropertyNameIterator.cpp; sourceTree = "<group>"; };
    34093406                A729009B17976C6000317298 /* MacroAssemblerARMv7.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MacroAssemblerARMv7.cpp; sourceTree = "<group>"; };
    34103407                A7299D9B17D12837005F5FF9 /* JSSet.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = JSSet.cpp; sourceTree = "<group>"; };
     
    48004797                                7C008CDC1871258D00955C24 /* JSPromiseReaction.cpp */,
    48014798                                7C008CDD1871258D00955C24 /* JSPromiseReaction.h */,
    4802                                 A727FF660DA3053B00E548D7 /* JSPropertyNameIterator.cpp */,
    4803                                 A727FF650DA3053B00E548D7 /* JSPropertyNameIterator.h */,
    48044799                                862553CE16136AA5009F17D0 /* JSProxy.cpp */,
    48054800                                862553CF16136AA5009F17D0 /* JSProxy.h */,
     
    79817976                                7C184E1E17BEE22E007CB63A /* JSPromisePrototype.cpp in Sources */,
    79827977                                7C008CDE1871258D00955C24 /* JSPromiseReaction.cpp in Sources */,
    7983                                 A727FF6B0DA3092200E548D7 /* JSPropertyNameIterator.cpp in Sources */,
    79847978                                862553D116136DA9009F17D0 /* JSProxy.cpp in Sources */,
    79857979                                9928FF3B18AC4AEC00B8CF12 /* JSReplayInputs.cpp in Sources */,
  • branches/ftlopt/Source/JavaScriptCore/bytecode/BytecodeBasicBlock.cpp

    r163844 r171614  
    5353    case op_switch_char:
    5454    case op_switch_string:
    55     case op_get_pnames:
    56     case op_next_pname:
    5755    case op_check_has_instance:
    5856        return true;
  • branches/ftlopt/Source/JavaScriptCore/bytecode/BytecodeList.json

    r171605 r171614  
    7171            { "name" : "op_get_by_val", "length" : 6 },
    7272            { "name" : "op_get_argument_by_val", "length" : 6 },
    73             { "name" : "op_get_by_pname", "length" : 7 },
    7473            { "name" : "op_put_by_val", "length" : 5 },
    7574            { "name" : "op_put_by_val_direct", "length" : 5 },
     
    109108            { "name" : "op_strcat", "length" : 4 },
    110109            { "name" : "op_to_primitive", "length" : 3 },
    111             { "name" : "op_get_pnames", "length" : 6 },
    112             { "name" : "op_next_pname", "length" : 7 },
    113110            { "name" : "op_resolve_scope", "length" : 6 },
    114111            { "name" : "op_get_from_scope", "length" : 8 },
  • branches/ftlopt/Source/JavaScriptCore/bytecode/BytecodeUseDef.h

    r171605 r171614  
    147147    case op_new_array_with_size:
    148148    case op_create_this:
    149     case op_get_pnames:
    150149    case op_del_by_id:
    151150    case op_unsigned: {
     
    195194        return;
    196195    }
    197     case op_get_direct_pname:
    198     case op_next_pname: {
     196    case op_get_direct_pname: {
    199197        functor(codeBlock, instruction, opcodeID, instruction[2].u.operand);
    200198        functor(codeBlock, instruction, opcodeID, instruction[3].u.operand);
    201199        functor(codeBlock, instruction, opcodeID, instruction[4].u.operand);
    202200        functor(codeBlock, instruction, opcodeID, instruction[5].u.operand);
    203         return;
    204     }
    205     case op_get_by_pname: {
    206         functor(codeBlock, instruction, opcodeID, instruction[2].u.operand);
    207         functor(codeBlock, instruction, opcodeID, instruction[3].u.operand);
    208         functor(codeBlock, instruction, opcodeID, instruction[4].u.operand);
    209         functor(codeBlock, instruction, opcodeID, instruction[5].u.operand);
    210         functor(codeBlock, instruction, opcodeID, instruction[6].u.operand);
    211201        return;
    212202    }
     
    317307    case op_get_structure_property_enumerator:
    318308    case op_next_enumerator_pname:
    319     case op_next_pname:
    320309    case op_resolve_scope:
    321310    case op_strcat:
     
    345334    case op_get_by_val:
    346335    case op_get_argument_by_val:
    347     case op_get_by_pname:
    348336    case op_get_arguments_length:
    349337    case op_typeof:
     
    395383        return;
    396384    }
    397     case op_get_pnames: {
    398         functor(codeBlock, instruction, opcodeID, instruction[1].u.operand);
    399         functor(codeBlock, instruction, opcodeID, instruction[3].u.operand);
    400         functor(codeBlock, instruction, opcodeID, instruction[4].u.operand);
    401         return;
    402     }
    403385    case op_enter: {
    404386        for (unsigned i = codeBlock->m_numVars; i--;)
  • branches/ftlopt/Source/JavaScriptCore/bytecode/CodeBlock.cpp

    r171611 r171614  
    11201120            break;
    11211121        }
    1122         case op_get_by_pname: {
    1123             int r0 = (++it)->u.operand;
    1124             int r1 = (++it)->u.operand;
    1125             int r2 = (++it)->u.operand;
    1126             int r3 = (++it)->u.operand;
    1127             int r4 = (++it)->u.operand;
    1128             int r5 = (++it)->u.operand;
    1129             printLocationAndOp(out, exec, location, it, "get_by_pname");
    1130             out.printf("%s, %s, %s, %s, %s, %s", registerName(r0).data(), registerName(r1).data(), registerName(r2).data(), registerName(r3).data(), registerName(r4).data(), registerName(r5).data());
    1131             break;
    1132         }
    11331122        case op_put_by_val: {
    11341123            int r0 = (++it)->u.operand;
     
    13751364            printLocationAndOp(out, exec, location, it, "to_primitive");
    13761365            out.printf("%s, %s", registerName(r0).data(), registerName(r1).data());
    1377             break;
    1378         }
    1379         case op_get_pnames: {
    1380             int r0 = it[1].u.operand;
    1381             int r1 = it[2].u.operand;
    1382             int r2 = it[3].u.operand;
    1383             int r3 = it[4].u.operand;
    1384             int offset = it[5].u.operand;
    1385             printLocationAndOp(out, exec, location, it, "get_pnames");
    1386             out.printf("%s, %s, %s, %s, %d(->%d)", registerName(r0).data(), registerName(r1).data(), registerName(r2).data(), registerName(r3).data(), offset, location + offset);
    1387             it += OPCODE_LENGTH(op_get_pnames) - 1;
    1388             break;
    1389         }
    1390         case op_next_pname: {
    1391             int dest = it[1].u.operand;
    1392             int base = it[2].u.operand;
    1393             int i = it[3].u.operand;
    1394             int size = it[4].u.operand;
    1395             int iter = it[5].u.operand;
    1396             int offset = it[6].u.operand;
    1397             printLocationAndOp(out, exec, location, it, "next_pname");
    1398             out.printf("%s, %s, %s, %s, %s, %d(->%d)", registerName(dest).data(), registerName(base).data(), registerName(i).data(), registerName(size).data(), registerName(iter).data(), offset, location + offset);
    1399             it += OPCODE_LENGTH(op_next_pname) - 1;
    14001366            break;
    14011367        }
  • branches/ftlopt/Source/JavaScriptCore/bytecode/PreciseJumpTargets.cpp

    r163844 r171614  
    7474        break;
    7575    }
    76     case op_get_pnames:
    77         out.append(bytecodeOffset + current[5].u.operand);
    78         break;
    79     case op_next_pname:
    80         out.append(bytecodeOffset + current[6].u.operand);
    81         break;
    8276    case op_check_has_instance:
    8377        out.append(bytecodeOffset + current[4].u.operand);
  • branches/ftlopt/Source/JavaScriptCore/bytecompiler/BytecodeGenerator.cpp

    r171605 r171614  
    22872287}
    22882288
    2289 RegisterID* BytecodeGenerator::emitGetPropertyNames(RegisterID* dst, RegisterID* base, RegisterID* i, RegisterID* size, Label* breakTarget)
    2290 {
    2291     size_t begin = instructions().size();
    2292 
    2293     emitOpcode(op_get_pnames);
    2294     instructions().append(dst->index());
    2295     instructions().append(base->index());
    2296     instructions().append(i->index());
    2297     instructions().append(size->index());
    2298     instructions().append(breakTarget->bind(begin, instructions().size()));
    2299     return dst;
    2300 }
    2301 
    2302 RegisterID* BytecodeGenerator::emitNextPropertyName(RegisterID* dst, RegisterID* base, RegisterID* i, RegisterID* size, RegisterID* iter, Label* target)
    2303 {
    2304     size_t begin = instructions().size();
    2305 
    2306     emitOpcode(op_next_pname);
    2307     instructions().append(dst->index());
    2308     instructions().append(base->index());
    2309     instructions().append(i->index());
    2310     instructions().append(size->index());
    2311     instructions().append(iter->index());
    2312     instructions().append(target->bind(begin, instructions().size()));
    2313     return dst;
    2314 }
    2315 
    23162289TryData* BytecodeGenerator::pushTry(Label* start)
    23172290{
  • branches/ftlopt/Source/JavaScriptCore/bytecompiler/BytecodeGenerator.h

    r171605 r171614  
    488488        void emitPopScopes(int targetScopeDepth);
    489489
    490         RegisterID* emitGetPropertyNames(RegisterID* dst, RegisterID* base, RegisterID* i, RegisterID* size, Label* breakTarget);
    491         RegisterID* emitNextPropertyName(RegisterID* dst, RegisterID* base, RegisterID* i, RegisterID* size, RegisterID* iter, Label* target);
    492 
    493490        RegisterID* emitHasIndexedProperty(RegisterID* dst, RegisterID* base, RegisterID* propertyName);
    494491        RegisterID* emitHasStructureProperty(RegisterID* dst, RegisterID* base, RegisterID* propertyName, RegisterID* enumerator);
  • branches/ftlopt/Source/JavaScriptCore/interpreter/Interpreter.cpp

    r170564 r171614  
    4848#include "JSNameScope.h"
    4949#include "JSNotAnObject.h"
    50 #include "JSPropertyNameIterator.h"
    5150#include "JSStackInlines.h"
    5251#include "JSString.h"
  • branches/ftlopt/Source/JavaScriptCore/interpreter/Register.h

    r165676 r171614  
    4040    class JSActivation;
    4141    class JSObject;
    42     class JSPropertyNameIterator;
    4342    class JSScope;
    4443
     
    6463        CodeBlock* codeBlock() const;
    6564        JSObject* function() const;
    66         JSPropertyNameIterator* propertyNameIterator() const;
    6765        JSScope* scope() const;
    6866        int32_t unboxedInt32() const;
  • branches/ftlopt/Source/JavaScriptCore/jit/JIT.cpp

    r171605 r171614  
    220220        DEFINE_OP(op_get_by_val)
    221221        DEFINE_OP(op_get_argument_by_val)
    222         DEFINE_OP(op_get_by_pname)
    223         DEFINE_OP(op_get_pnames)
    224222        DEFINE_OP(op_check_has_instance)
    225223        DEFINE_OP(op_instanceof)
     
    259257        DEFINE_OP(op_new_object)
    260258        DEFINE_OP(op_new_regexp)
    261         DEFINE_OP(op_next_pname)
    262259        DEFINE_OP(op_not)
    263260        DEFINE_OP(op_nstricteq)
     
    392389        DEFINE_SLOWCASE_OP(op_get_by_val)
    393390        DEFINE_SLOWCASE_OP(op_get_argument_by_val)
    394         DEFINE_SLOWCASE_OP(op_get_by_pname)
    395391        DEFINE_SLOWCASE_OP(op_check_has_instance)
    396392        DEFINE_SLOWCASE_OP(op_instanceof)
  • branches/ftlopt/Source/JavaScriptCore/jit/JIT.h

    r171605 r171614  
    5757    class FunctionExecutable;
    5858    class JIT;
    59     class JSPropertyNameIterator;
    6059    class Identifier;
    6160    class Interpreter;
     
    484483        void emit_op_get_by_val(Instruction*);
    485484        void emit_op_get_argument_by_val(Instruction*);
    486         void emit_op_get_by_pname(Instruction*);
    487485        void emit_op_init_lazy_reg(Instruction*);
    488486        void emit_op_check_has_instance(Instruction*);
     
    522520        void emit_op_new_object(Instruction*);
    523521        void emit_op_new_regexp(Instruction*);
    524         void emit_op_get_pnames(Instruction*);
    525         void emit_op_next_pname(Instruction*);
    526522        void emit_op_not(Instruction*);
    527523        void emit_op_nstricteq(Instruction*);
     
    585581        void emitSlow_op_get_by_val(Instruction*, Vector<SlowCaseEntry>::iterator&);
    586582        void emitSlow_op_get_argument_by_val(Instruction*, Vector<SlowCaseEntry>::iterator&);
    587         void emitSlow_op_get_by_pname(Instruction*, Vector<SlowCaseEntry>::iterator&);
    588583        void emitSlow_op_check_has_instance(Instruction*, Vector<SlowCaseEntry>::iterator&);
    589584        void emitSlow_op_instanceof(Instruction*, Vector<SlowCaseEntry>::iterator&);
  • branches/ftlopt/Source/JavaScriptCore/jit/JITOpcodes.cpp

    r171605 r171614  
    3838#include "JSFunction.h"
    3939#include "JSPropertyNameEnumerator.h"
    40 #include "JSPropertyNameIterator.h"
    4140#include "LinkBuffer.h"
    4241#include "MaxFrameExtentForSlowPathCall.h"
     
    458457    callOperationNoExceptionCheck(operationThrow, regT0);
    459458    jumpToExceptionHandler();
    460 }
    461 
    462 void JIT::emit_op_get_pnames(Instruction* currentInstruction)
    463 {
    464     int dst = currentInstruction[1].u.operand;
    465     int base = currentInstruction[2].u.operand;
    466     int i = currentInstruction[3].u.operand;
    467     int size = currentInstruction[4].u.operand;
    468     int breakTarget = currentInstruction[5].u.operand;
    469 
    470     JumpList isNotObject;
    471 
    472     emitGetVirtualRegister(base, regT0);
    473     if (!m_codeBlock->isKnownNotImmediate(base))
    474         isNotObject.append(emitJumpIfNotJSCell(regT0));
    475     if (base != m_codeBlock->thisRegister().offset() || m_codeBlock->isStrictMode())
    476         isNotObject.append(emitJumpIfCellNotObject(regT0));
    477 
    478     // We could inline the case where you have a valid cache, but
    479     // this call doesn't seem to be hot.
    480     Label isObject(this);
    481     callOperation(operationGetPNames, regT0);
    482     emitStoreCell(dst, returnValueGPR);
    483     load32(Address(regT0, OBJECT_OFFSETOF(JSPropertyNameIterator, m_jsStringsSize)), regT3);
    484     store64(tagTypeNumberRegister, addressFor(i));
    485     store32(TrustedImm32(Int32Tag), intTagFor(size));
    486     store32(regT3, intPayloadFor(size));
    487     Jump end = jump();
    488 
    489     isNotObject.link(this);
    490     move(regT0, regT1);
    491     and32(TrustedImm32(~TagBitUndefined), regT1);
    492     addJump(branch32(Equal, regT1, TrustedImm32(ValueNull)), breakTarget);
    493     callOperation(operationToObject, base, regT0);
    494     jump().linkTo(isObject, this);
    495    
    496     end.link(this);
    497 }
    498 
    499 void JIT::emit_op_next_pname(Instruction* currentInstruction)
    500 {
    501     int dst = currentInstruction[1].u.operand;
    502     int base = currentInstruction[2].u.operand;
    503     int i = currentInstruction[3].u.operand;
    504     int size = currentInstruction[4].u.operand;
    505     int it = currentInstruction[5].u.operand;
    506     int target = currentInstruction[6].u.operand;
    507    
    508     JumpList callHasProperty;
    509 
    510     Label begin(this);
    511     load32(intPayloadFor(i), regT0);
    512     Jump end = branch32(Equal, regT0, intPayloadFor(size));
    513 
    514     // Grab key @ i
    515     loadPtr(addressFor(it), regT1);
    516     loadPtr(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_jsStrings)), regT2);
    517 
    518     load64(BaseIndex(regT2, regT0, TimesEight), regT2);
    519 
    520     emitPutVirtualRegister(dst, regT2);
    521 
    522     // Increment i
    523     add32(TrustedImm32(1), regT0);
    524     store32(regT0, intPayloadFor(i));
    525 
    526     // Verify that i is valid:
    527     emitGetVirtualRegister(base, regT0);
    528 
    529     // Test base's structure
    530     emitLoadStructure(regT0, regT2, regT3);
    531     callHasProperty.append(branchPtr(NotEqual, regT2, Address(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructure)))));
    532 
    533     // Test base's prototype chain
    534     loadPtr(Address(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedPrototypeChain))), regT3);
    535     loadPtr(Address(regT3, OBJECT_OFFSETOF(StructureChain, m_vector)), regT3);
    536     addJump(branchTestPtr(Zero, Address(regT3)), target);
    537 
    538     Label checkPrototype(this);
    539     load64(Address(regT2, Structure::prototypeOffset()), regT2);
    540     callHasProperty.append(emitJumpIfNotJSCell(regT2));
    541     emitLoadStructure(regT2, regT2, regT1);
    542     callHasProperty.append(branchPtr(NotEqual, regT2, Address(regT3)));
    543     addPtr(TrustedImm32(sizeof(Structure*)), regT3);
    544     branchTestPtr(NonZero, Address(regT3)).linkTo(checkPrototype, this);
    545 
    546     // Continue loop.
    547     addJump(jump(), target);
    548 
    549     // Slow case: Ask the object if i is valid.
    550     callHasProperty.link(this);
    551     emitGetVirtualRegister(dst, regT1);
    552     callOperation(operationHasProperty, regT0, regT1);
    553 
    554     // Test for valid key.
    555     addJump(branchTest32(NonZero, regT0), target);
    556     jump().linkTo(begin, this);
    557 
    558     // End of loop.
    559     end.link(this);
    560459}
    561460
  • branches/ftlopt/Source/JavaScriptCore/jit/JITOpcodes32_64.cpp

    r171605 r171614  
    3838#include "JSFunction.h"
    3939#include "JSPropertyNameEnumerator.h"
    40 #include "JSPropertyNameIterator.h"
    4140#include "JSVariableObject.h"
    4241#include "LinkBuffer.h"
     
    770769}
    771770
    772 void JIT::emit_op_get_pnames(Instruction* currentInstruction)
    773 {
    774     int dst = currentInstruction[1].u.operand;
    775     int base = currentInstruction[2].u.operand;
    776     int i = currentInstruction[3].u.operand;
    777     int size = currentInstruction[4].u.operand;
    778     int breakTarget = currentInstruction[5].u.operand;
    779 
    780     JumpList isNotObject;
    781 
    782     emitLoad(base, regT1, regT0);
    783     if (!m_codeBlock->isKnownNotImmediate(base))
    784         isNotObject.append(branch32(NotEqual, regT1, TrustedImm32(JSValue::CellTag)));
    785     if (VirtualRegister(base) != m_codeBlock->thisRegister() || m_codeBlock->isStrictMode())
    786         isNotObject.append(emitJumpIfCellNotObject(regT0));
    787 
    788     // We could inline the case where you have a valid cache, but
    789     // this call doesn't seem to be hot.
    790     Label isObject(this);
    791     callOperation(operationGetPNames, regT0);
    792     emitStoreCell(dst, returnValueGPR);
    793     load32(Address(regT0, OBJECT_OFFSETOF(JSPropertyNameIterator, m_jsStringsSize)), regT3);
    794     store32(TrustedImm32(Int32Tag), intTagFor(i));
    795     store32(TrustedImm32(0), intPayloadFor(i));
    796     store32(TrustedImm32(Int32Tag), intTagFor(size));
    797     store32(regT3, payloadFor(size));
    798     Jump end = jump();
    799 
    800     isNotObject.link(this);
    801     addJump(branch32(Equal, regT1, TrustedImm32(JSValue::NullTag)), breakTarget);
    802     addJump(branch32(Equal, regT1, TrustedImm32(JSValue::UndefinedTag)), breakTarget);
    803     callOperation(operationToObject, base, regT1, regT0);
    804     jump().linkTo(isObject, this);
    805 
    806     end.link(this);
    807 }
    808 
    809 void JIT::emit_op_next_pname(Instruction* currentInstruction)
    810 {
    811     int dst = currentInstruction[1].u.operand;
    812     int base = currentInstruction[2].u.operand;
    813     int i = currentInstruction[3].u.operand;
    814     int size = currentInstruction[4].u.operand;
    815     int it = currentInstruction[5].u.operand;
    816     int target = currentInstruction[6].u.operand;
    817 
    818     JumpList callHasProperty;
    819 
    820     Label begin(this);
    821     load32(intPayloadFor(i), regT0);
    822     Jump end = branch32(Equal, regT0, intPayloadFor(size));
    823 
    824     // Grab key @ i
    825     loadPtr(payloadFor(it), regT1);
    826     loadPtr(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_jsStrings)), regT2);
    827     load32(BaseIndex(regT2, regT0, TimesEight), regT2);
    828     store32(TrustedImm32(JSValue::CellTag), tagFor(dst));
    829     store32(regT2, payloadFor(dst));
    830 
    831     // Increment i
    832     add32(TrustedImm32(1), regT0);
    833     store32(regT0, intPayloadFor(i));
    834 
    835     // Verify that i is valid:
    836     loadPtr(payloadFor(base), regT0);
    837 
    838     // Test base's structure
    839     loadPtr(Address(regT0, JSCell::structureIDOffset()), regT2);
    840     callHasProperty.append(branchPtr(NotEqual, regT2, Address(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructure)))));
    841 
    842     // Test base's prototype chain
    843     loadPtr(Address(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedPrototypeChain))), regT3);
    844     loadPtr(Address(regT3, OBJECT_OFFSETOF(StructureChain, m_vector)), regT3);
    845     addJump(branchTestPtr(Zero, Address(regT3)), target);
    846 
    847     Label checkPrototype(this);
    848     callHasProperty.append(branch32(Equal, Address(regT2, Structure::prototypeOffset() + OBJECT_OFFSETOF(JSValue, u.asBits.tag)), TrustedImm32(JSValue::NullTag)));
    849     loadPtr(Address(regT2, Structure::prototypeOffset() + OBJECT_OFFSETOF(JSValue, u.asBits.payload)), regT2);
    850     loadPtr(Address(regT2, JSCell::structureIDOffset()), regT2);
    851     callHasProperty.append(branchPtr(NotEqual, regT2, Address(regT3)));
    852     addPtr(TrustedImm32(sizeof(Structure*)), regT3);
    853     branchTestPtr(NonZero, Address(regT3)).linkTo(checkPrototype, this);
    854 
    855     // Continue loop.
    856     addJump(jump(), target);
    857 
    858     // Slow case: Ask the object if i is valid.
    859     callHasProperty.link(this);
    860     loadPtr(addressFor(dst), regT1);
    861     callOperation(operationHasProperty, regT0, regT1);
    862 
    863     // Test for valid key.
    864     addJump(branchTest32(NonZero, regT0), target);
    865     jump().linkTo(begin, this);
    866 
    867     // End of loop.
    868     end.link(this);
    869 }
    870 
    871771void JIT::emit_op_push_with_scope(Instruction* currentInstruction)
    872772{
  • branches/ftlopt/Source/JavaScriptCore/jit/JITOperations.cpp

    r171605 r171614  
    4646#include "JSNameScope.h"
    4747#include "JSPropertyNameEnumerator.h"
    48 #include "JSPropertyNameIterator.h"
    4948#include "JSStackInlines.h"
    5049#include "JSWithScope.h"
     
    16171616}
    16181617
    1619 JSCell* JIT_OPERATION operationGetPNames(ExecState* exec, JSObject* obj)
    1620 {
    1621     VM& vm = exec->vm();
    1622     NativeCallFrameTracer tracer(&vm, exec);
    1623 
    1624     Structure* structure = obj->structure(vm);
    1625     JSPropertyNameIterator* jsPropertyNameIterator = structure->enumerationCache();
    1626     if (!jsPropertyNameIterator || jsPropertyNameIterator->cachedPrototypeChain() != structure->prototypeChain(exec))
    1627         jsPropertyNameIterator = JSPropertyNameIterator::create(exec, obj);
    1628     return jsPropertyNameIterator;
    1629 }
    1630 
    16311618EncodedJSValue JIT_OPERATION operationInstanceOf(ExecState* exec, EncodedJSValue encodedValue, EncodedJSValue encodedProto)
    16321619{
  • branches/ftlopt/Source/JavaScriptCore/jit/JITPropertyAccess.cpp

    r171605 r171614  
    3636#include "JSArray.h"
    3737#include "JSFunction.h"
    38 #include "JSPropertyNameIterator.h"
    3938#include "JSVariableObject.h"
    4039#include "LinkBuffer.h"
     
    261260    signExtend32ToPtr(offset, offset);
    262261    load64(BaseIndex(scratch, offset, TimesEight, (firstOutOfLineOffset - 2) * sizeof(EncodedJSValue)), result);
    263 }
    264 
    265 void JIT::emit_op_get_by_pname(Instruction* currentInstruction)
    266 {
    267     int dst = currentInstruction[1].u.operand;
    268     int base = currentInstruction[2].u.operand;
    269     int property = currentInstruction[3].u.operand;
    270     unsigned expected = currentInstruction[4].u.operand;
    271     int iter = currentInstruction[5].u.operand;
    272     int i = currentInstruction[6].u.operand;
    273 
    274     emitGetVirtualRegister(property, regT0);
    275     addSlowCase(branch64(NotEqual, regT0, addressFor(expected)));
    276     emitGetVirtualRegisters(base, regT0, iter, regT1);
    277     emitJumpSlowCaseIfNotJSCell(regT0, base);
    278 
    279     // Test base's structure
    280     emitLoadStructure(regT0, regT2, regT3);
    281     addSlowCase(branchPtr(NotEqual, regT2, Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructure))));
    282     load32(addressFor(i), regT3);
    283     sub32(TrustedImm32(1), regT3);
    284     addSlowCase(branch32(AboveOrEqual, regT3, Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_numCacheableSlots))));
    285     Jump inlineProperty = branch32(Below, regT3, Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructureInlineCapacity)));
    286     add32(TrustedImm32(firstOutOfLineOffset), regT3);
    287     sub32(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructureInlineCapacity)), regT3);
    288     inlineProperty.link(this);
    289     compileGetDirectOffset(regT0, regT0, regT3, regT1);
    290 
    291     emitPutVirtualRegister(dst, regT0);
    292 }
    293 
    294 void JIT::emitSlow_op_get_by_pname(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
    295 {
    296     int dst = currentInstruction[1].u.operand;
    297     int base = currentInstruction[2].u.operand;
    298     int property = currentInstruction[3].u.operand;
    299 
    300     linkSlowCase(iter);
    301     linkSlowCaseIfNotJSCell(iter, base);
    302     linkSlowCase(iter);
    303     linkSlowCase(iter);
    304 
    305     emitGetVirtualRegister(base, regT0);
    306     emitGetVirtualRegister(property, regT1);
    307     callOperation(operationGetByValGeneric, dst, regT0, regT1);
    308262}
    309263
  • branches/ftlopt/Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp

    r171605 r171614  
    3636#include "JSArray.h"
    3737#include "JSFunction.h"
    38 #include "JSPropertyNameIterator.h"
    3938#include "JSVariableObject.h"
    4039#include "LinkBuffer.h"
     
    607606}
    608607
    609 void JIT::emit_op_get_by_pname(Instruction* currentInstruction)
    610 {
    611     int dst = currentInstruction[1].u.operand;
    612     int base = currentInstruction[2].u.operand;
    613     int property = currentInstruction[3].u.operand;
    614     unsigned expected = currentInstruction[4].u.operand;
    615     int iter = currentInstruction[5].u.operand;
    616     int i = currentInstruction[6].u.operand;
    617    
    618     emitLoad2(property, regT1, regT0, base, regT3, regT2);
    619     emitJumpSlowCaseIfNotJSCell(property, regT1);
    620     addSlowCase(branchPtr(NotEqual, regT0, payloadFor(expected)));
    621     // Property registers are now available as the property is known
    622     emitJumpSlowCaseIfNotJSCell(base, regT3);
    623     emitLoadPayload(iter, regT1);
    624    
    625     // Test base's structure
    626     loadPtr(Address(regT2, JSCell::structureIDOffset()), regT0);
    627     addSlowCase(branchPtr(NotEqual, regT0, Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructure))));
    628     load32(addressFor(i), regT3);
    629     sub32(TrustedImm32(1), regT3);
    630     addSlowCase(branch32(AboveOrEqual, regT3, Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_numCacheableSlots))));
    631     Jump inlineProperty = branch32(Below, regT3, Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructureInlineCapacity)));
    632     add32(TrustedImm32(firstOutOfLineOffset), regT3);
    633     sub32(Address(regT1, OBJECT_OFFSETOF(JSPropertyNameIterator, m_cachedStructureInlineCapacity)), regT3);
    634     inlineProperty.link(this);
    635     compileGetDirectOffset(regT2, regT1, regT0, regT3);   
    636    
    637     emitStore(dst, regT1, regT0);
    638 }
    639 
    640 void JIT::emitSlow_op_get_by_pname(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
    641 {
    642     int dst = currentInstruction[1].u.operand;
    643     int base = currentInstruction[2].u.operand;
    644     int property = currentInstruction[3].u.operand;
    645    
    646     linkSlowCaseIfNotJSCell(iter, property);
    647     linkSlowCase(iter);
    648     linkSlowCaseIfNotJSCell(iter, base);
    649     linkSlowCase(iter);
    650     linkSlowCase(iter);
    651    
    652     emitLoad(base, regT1, regT0);
    653     emitLoad(property, regT3, regT2);
    654     callOperation(operationGetByValGeneric, dst, regT1, regT0, regT3, regT2);
    655 }
    656 
    657608void JIT::emitVarInjectionCheck(bool needsVarInjectionChecks)
    658609{
  • branches/ftlopt/Source/JavaScriptCore/llint/LLIntOffsetsExtractor.cpp

    r163225 r171614  
    4040#include "JSGlobalObject.h"
    4141#include "JSObject.h"
    42 #include "JSPropertyNameIterator.h"
    4342#include "JSStack.h"
    4443#include "JSString.h"
  • branches/ftlopt/Source/JavaScriptCore/llint/LLIntSlowPaths.cpp

    r170855 r171614  
    4545#include "JSGlobalObjectFunctions.h"
    4646#include "JSNameScope.h"
    47 #include "JSPropertyNameIterator.h"
    4847#include "JSStackInlines.h"
    4948#include "JSString.h"
     
    769768}
    770769
    771 LLINT_SLOW_PATH_DECL(slow_path_get_by_pname)
    772 {
    773     LLINT_BEGIN();
    774     LLINT_RETURN(getByVal(exec, LLINT_OP_C(2).jsValue(), LLINT_OP_C(3).jsValue()));
    775 }
    776 
    777770LLINT_SLOW_PATH_DECL(slow_path_put_by_val)
    778771{
     
    12831276}
    12841277
    1285 LLINT_SLOW_PATH_DECL(slow_path_get_pnames)
    1286 {
    1287     LLINT_BEGIN();
    1288     JSValue v = LLINT_OP(2).jsValue();
    1289     if (v.isUndefinedOrNull()) {
    1290         pc += pc[5].u.operand;
    1291         LLINT_END();
    1292     }
    1293    
    1294     JSObject* o = v.toObject(exec);
    1295     Structure* structure = o->structure();
    1296     JSPropertyNameIterator* jsPropertyNameIterator = structure->enumerationCache();
    1297     if (!jsPropertyNameIterator || jsPropertyNameIterator->cachedPrototypeChain() != structure->prototypeChain(exec))
    1298         jsPropertyNameIterator = JSPropertyNameIterator::create(exec, o);
    1299    
    1300     LLINT_OP(1) = JSValue(jsPropertyNameIterator);
    1301     LLINT_OP(2) = JSValue(o);
    1302     LLINT_OP(3) = Register::withInt(0);
    1303     LLINT_OP(4) = Register::withInt(jsPropertyNameIterator->size());
    1304    
    1305     pc += OPCODE_LENGTH(op_get_pnames);
    1306     LLINT_END();
    1307 }
    1308 
    1309 LLINT_SLOW_PATH_DECL(slow_path_next_pname)
    1310 {
    1311     LLINT_BEGIN();
    1312     JSObject* base = asObject(LLINT_OP(2).jsValue());
    1313     JSString* property = asString(LLINT_OP(1).jsValue());
    1314     if (base->hasProperty(exec, Identifier(exec, property->value(exec)))) {
    1315         // Go to target.
    1316         pc += pc[6].u.operand;
    1317     } // Else, don't change the PC, so the interpreter will reloop.
    1318     LLINT_END();
    1319 }
    1320 
    13211278LLINT_SLOW_PATH_DECL(slow_path_push_with_scope)
    13221279{
  • branches/ftlopt/Source/JavaScriptCore/llint/LLIntSlowPaths.h

    r170836 r171614  
    7979LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_get_by_val);
    8080LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_get_argument_by_val);
    81 LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_get_by_pname);
    8281LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_put_by_val);
    8382LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_put_by_val_direct);
     
    110109LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_strcat);
    111110LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_to_primitive);
    112 LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_get_pnames);
    113 LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_next_pname);
    114111LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_push_with_scope);
    115112LLINT_SLOW_PATH_HIDDEN_DECL(slow_path_pop_scope);
  • branches/ftlopt/Source/JavaScriptCore/llint/LowLevelInterpreter.asm

    r171605 r171614  
    11361136
    11371137
    1138 _llint_op_get_pnames:
    1139     traceExecution()
    1140     callSlowPath(_llint_slow_path_get_pnames)
    1141     dispatch(0) # The slow_path either advances the PC or jumps us to somewhere else.
    1142 
    1143 
    11441138_llint_op_push_with_scope:
    11451139    traceExecution()
  • branches/ftlopt/Source/JavaScriptCore/llint/LowLevelInterpreter32_64.asm

    r170382 r171614  
    16141614
    16151615
    1616 _llint_op_get_by_pname:
    1617     traceExecution()
    1618     loadi 12[PC], t0
    1619     loadConstantOrVariablePayload(t0, CellTag, t1, .opGetByPnameSlow)
    1620     loadi 16[PC], t0
    1621     bpneq t1, PayloadOffset[cfr, t0, 8], .opGetByPnameSlow
    1622     loadi 8[PC], t0
    1623     loadConstantOrVariablePayload(t0, CellTag, t2, .opGetByPnameSlow)
    1624     loadi 20[PC], t0
    1625     loadi PayloadOffset[cfr, t0, 8], t3
    1626     loadp JSCell::m_structureID[t2], t0
    1627     bpneq t0, JSPropertyNameIterator::m_cachedStructure[t3], .opGetByPnameSlow
    1628     loadi 24[PC], t0
    1629     loadi [cfr, t0, 8], t0
    1630     subi 1, t0
    1631     biaeq t0, JSPropertyNameIterator::m_numCacheableSlots[t3], .opGetByPnameSlow
    1632     bilt t0, JSPropertyNameIterator::m_cachedStructureInlineCapacity[t3], .opGetByPnameInlineProperty
    1633     addi firstOutOfLineOffset, t0
    1634     subi JSPropertyNameIterator::m_cachedStructureInlineCapacity[t3], t0
    1635 .opGetByPnameInlineProperty:
    1636     loadPropertyAtVariableOffset(t0, t2, t1, t3)
    1637     loadi 4[PC], t0
    1638     storei t1, TagOffset[cfr, t0, 8]
    1639     storei t3, PayloadOffset[cfr, t0, 8]
    1640     dispatch(7)
    1641 
    1642 .opGetByPnameSlow:
    1643     callSlowPath(_llint_slow_path_get_by_pname)
    1644     dispatch(7)
    1645 
    1646 
    16471616macro contiguousPutByVal(storeCallback)
    16481617    biaeq t3, -sizeof IndexingHeader + IndexingHeader::u.lengths.publicLength[t0], .outOfBounds
     
    20402009    callSlowPath(_slow_path_to_primitive)
    20412010    dispatch(3)
    2042 
    2043 
    2044 _llint_op_next_pname:
    2045     traceExecution()
    2046     loadi 12[PC], t1
    2047     loadi 16[PC], t2
    2048     loadi PayloadOffset[cfr, t1, 8], t0
    2049     bieq t0, PayloadOffset[cfr, t2, 8], .opNextPnameEnd
    2050     loadi 20[PC], t2
    2051     loadi PayloadOffset[cfr, t2, 8], t2
    2052     loadp JSPropertyNameIterator::m_jsStrings[t2], t3
    2053     loadi [t3, t0, 8], t3
    2054     addi 1, t0
    2055     storei t0, PayloadOffset[cfr, t1, 8]
    2056     loadi 4[PC], t1
    2057     storei CellTag, TagOffset[cfr, t1, 8]
    2058     storei t3, PayloadOffset[cfr, t1, 8]
    2059     loadi 8[PC], t3
    2060     loadi PayloadOffset[cfr, t3, 8], t3
    2061     loadp JSCell::m_structureID[t3], t1
    2062     bpneq t1, JSPropertyNameIterator::m_cachedStructure[t2], .opNextPnameSlow
    2063     loadp JSPropertyNameIterator::m_cachedPrototypeChain[t2], t0
    2064     loadp StructureChain::m_vector[t0], t0
    2065     btpz [t0], .opNextPnameTarget
    2066 .opNextPnameCheckPrototypeLoop:
    2067     bieq Structure::m_prototype + TagOffset[t1], NullTag, .opNextPnameSlow
    2068     loadp Structure::m_prototype + PayloadOffset[t1], t2
    2069     loadp JSCell::m_structureID[t2], t1
    2070     bpneq t1, [t0], .opNextPnameSlow
    2071     addp 4, t0
    2072     btpnz [t0], .opNextPnameCheckPrototypeLoop
    2073 .opNextPnameTarget:
    2074     dispatchBranch(24[PC])
    2075 
    2076 .opNextPnameEnd:
    2077     dispatch(7)
    2078 
    2079 .opNextPnameSlow:
    2080     callSlowPath(_llint_slow_path_next_pname) # This either keeps the PC where it was (causing us to loop) or sets it to target.
    2081     dispatch(0)
    20822011
    20832012
  • branches/ftlopt/Source/JavaScriptCore/llint/LowLevelInterpreter64.asm

    r170382 r171614  
    14461446    callSlowPath(_llint_slow_path_get_argument_by_val)
    14471447    dispatch(6)
    1448 
    1449 
    1450 _llint_op_get_by_pname:
    1451     traceExecution()
    1452     loadisFromInstruction(3, t1)
    1453     loadConstantOrVariable(t1, t0)
    1454     loadisFromInstruction(4, t1)
    1455     assertNotConstant(t1)
    1456     bqneq t0, [cfr, t1, 8], .opGetByPnameSlow
    1457     loadisFromInstruction(2, t2)
    1458     loadisFromInstruction(5, t3)
    1459     loadConstantOrVariableCell(t2, t0, .opGetByPnameSlow)
    1460     assertNotConstant(t3)
    1461     loadq [cfr, t3, 8], t1
    1462     loadStructureWithScratch(t0, t2, t3)
    1463     bpneq t2, JSPropertyNameIterator::m_cachedStructure[t1], .opGetByPnameSlow
    1464     loadisFromInstruction(6, t3)
    1465     loadi PayloadOffset[cfr, t3, 8], t3
    1466     subi 1, t3
    1467     biaeq t3, JSPropertyNameIterator::m_numCacheableSlots[t1], .opGetByPnameSlow
    1468     bilt t3, JSPropertyNameIterator::m_cachedStructureInlineCapacity[t1], .opGetByPnameInlineProperty
    1469     addi firstOutOfLineOffset, t3
    1470     subi JSPropertyNameIterator::m_cachedStructureInlineCapacity[t1], t3
    1471 .opGetByPnameInlineProperty:
    1472     loadPropertyAtVariableOffset(t3, t0, t0)
    1473     loadisFromInstruction(1, t1)
    1474     storeq t0, [cfr, t1, 8]
    1475     dispatch(7)
    1476 
    1477 .opGetByPnameSlow:
    1478     callSlowPath(_llint_slow_path_get_by_pname)
    1479     dispatch(7)
    14801448
    14811449
     
    18731841    callSlowPath(_slow_path_to_primitive)
    18741842    dispatch(3)
    1875 
    1876 
    1877 _llint_op_next_pname:
    1878     traceExecution()
    1879     loadisFromInstruction(3, t1)
    1880     loadisFromInstruction(4, t2)
    1881     assertNotConstant(t1)
    1882     assertNotConstant(t2)
    1883     loadi PayloadOffset[cfr, t1, 8], t0
    1884     bieq t0, PayloadOffset[cfr, t2, 8], .opNextPnameEnd
    1885     loadisFromInstruction(5, t2)
    1886     assertNotConstant(t2)
    1887     loadp [cfr, t2, 8], t2
    1888     loadp JSPropertyNameIterator::m_jsStrings[t2], t3
    1889     loadq [t3, t0, 8], t3
    1890     addi 1, t0
    1891     storei t0, PayloadOffset[cfr, t1, 8]
    1892     loadisFromInstruction(1, t1)
    1893     storeq t3, [cfr, t1, 8]
    1894     loadisFromInstruction(2, t3)
    1895     assertNotConstant(t3)
    1896     loadq [cfr, t3, 8], t3
    1897     loadStructureWithScratch(t3, t1, t0)
    1898     bpneq t1, JSPropertyNameIterator::m_cachedStructure[t2], .opNextPnameSlow
    1899     loadp JSPropertyNameIterator::m_cachedPrototypeChain[t2], t0
    1900     loadp StructureChain::m_vector[t0], t0
    1901     btpz [t0], .opNextPnameTarget
    1902 .opNextPnameCheckPrototypeLoop:
    1903     bqeq Structure::m_prototype[t1], ValueNull, .opNextPnameSlow
    1904     loadq Structure::m_prototype[t1], t2
    1905     loadStructureWithScratch(t2, t1, t3)
    1906     bpneq t1, [t0], .opNextPnameSlow
    1907     addp 8, t0
    1908     btpnz [t0], .opNextPnameCheckPrototypeLoop
    1909 .opNextPnameTarget:
    1910     dispatchIntIndirect(6)
    1911 
    1912 .opNextPnameEnd:
    1913     dispatch(7)
    1914 
    1915 .opNextPnameSlow:
    1916     callSlowPath(_llint_slow_path_next_pname) # This either keeps the PC where it was (causing us to loop) or sets it to target.
    1917     dispatch(0)
    19181843
    19191844
  • branches/ftlopt/Source/JavaScriptCore/runtime/CommonSlowPaths.cpp

    r171605 r171614  
    4646#include "JSNameScope.h"
    4747#include "JSPropertyNameEnumerator.h"
    48 #include "JSPropertyNameIterator.h"
    4948#include "JSString.h"
    5049#include "JSWithScope.h"
  • branches/ftlopt/Source/JavaScriptCore/runtime/Structure.cpp

    r171605 r171614  
    717717PropertyOffset Structure::addPropertyWithoutTransition(VM& vm, PropertyName propertyName, unsigned attributes)
    718718{
    719     ASSERT(!enumerationCache());
    720 
    721719    DeferGC deferGC(vm.heap);
    722720    materializePropertyMapIfNecessaryForPinning(vm, deferGC);
     
    730728{
    731729    ASSERT(isUncacheableDictionary());
    732     ASSERT(!enumerationCache());
    733730
    734731    DeferGC deferGC(vm.heap);
  • branches/ftlopt/Source/JavaScriptCore/runtime/Structure.h

    r171605 r171614  
    282282    }
    283283
    284     void setEnumerationCache(VM&, JSPropertyNameIterator* enumerationCache); // Defined in JSPropertyNameIterator.h.
    285     JSPropertyNameIterator* enumerationCache(); // Defined in JSPropertyNameIterator.h.
    286 
    287284    void setCachedStructurePropertyNameEnumerator(VM&, JSPropertyNameEnumerator*);
    288285    void setCachedGenericPropertyNameEnumerator(VM&, JSPropertyNameEnumerator*);
  • branches/ftlopt/Source/JavaScriptCore/runtime/StructureInlines.h

    r170855 r171614  
    131131}
    132132
    133 inline void Structure::setEnumerationCache(VM& vm, JSPropertyNameIterator* enumerationCache)
    134 {
    135     ASSERT(!isDictionary());
    136     if (!hasRareData())
    137         allocateRareData(vm);
    138     rareData()->setEnumerationCache(vm, this, enumerationCache);
    139 }
    140 
    141 inline JSPropertyNameIterator* Structure::enumerationCache()
    142 {
    143     if (!hasRareData())
    144         return 0;
    145     return rareData()->enumerationCache();
    146 }
    147 
    148133inline JSValue Structure::prototypeForLookup(JSGlobalObject* globalObject) const
    149134{
  • branches/ftlopt/Source/JavaScriptCore/runtime/StructureRareData.cpp

    r171605 r171614  
    2828
    2929#include "JSPropertyNameEnumerator.h"
    30 #include "JSPropertyNameIterator.h"
    3130#include "JSString.h"
    3231#include "JSCInlines.h"
     
    6968    visitor.append(&thisObject->m_previous);
    7069    visitor.append(&thisObject->m_objectToStringValue);
    71     visitor.append(&thisObject->m_enumerationCache);
    7270    visitor.append(&thisObject->m_cachedStructurePropertyNameEnumerator);
    7371    visitor.append(&thisObject->m_cachedGenericPropertyNameEnumerator);
  • branches/ftlopt/Source/JavaScriptCore/runtime/StructureRareData.h

    r171605 r171614  
    3535
    3636class JSPropertyNameEnumerator;
    37 class JSPropertyNameIterator;
    3837class Structure;
    3938
     
    5857    void setObjectToStringValue(VM&, const JSCell* owner, JSString* value);
    5958
    60     JSPropertyNameIterator* enumerationCache();
    61     void setEnumerationCache(VM&, const Structure* owner, JSPropertyNameIterator* value);
    62    
    6359    DECLARE_EXPORT_INFO;
    6460
     
    7773    WriteBarrier<Structure> m_previous;
    7874    WriteBarrier<JSString> m_objectToStringValue;
    79     WriteBarrier<JSPropertyNameIterator> m_enumerationCache;
    8075    WriteBarrier<JSPropertyNameEnumerator> m_cachedStructurePropertyNameEnumerator;
    8176    WriteBarrier<JSPropertyNameEnumerator> m_cachedGenericPropertyNameEnumerator;
  • branches/ftlopt/Source/JavaScriptCore/runtime/VM.cpp

    r171605 r171614  
    6666#include "JSPromiseReaction.h"
    6767#include "JSPropertyNameEnumerator.h"
    68 #include "JSPropertyNameIterator.h"
    6968#include "JSWithScope.h"
    7069#include "Lexer.h"
     
    259258    stringStructure.set(*this, JSString::createStructure(*this, 0, jsNull()));
    260259    notAnObjectStructure.set(*this, JSNotAnObject::createStructure(*this, 0, jsNull()));
    261     propertyNameIteratorStructure.set(*this, JSPropertyNameIterator::createStructure(*this, 0, jsNull()));
    262260    propertyNameEnumeratorStructure.set(*this, JSPropertyNameEnumerator::createStructure(*this, 0, jsNull()));
    263261    getterSetterStructure.set(*this, GetterSetter::createStructure(*this, 0, jsNull()));
Note: See TracChangeset for help on using the changeset viewer.