Changeset 85240 in webkit
- Timestamp:
- Apr 28, 2011 2:37:56 PM (13 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r85236 r85240 1 2011-04-28 Oliver Hunt <oliver@apple.com> 2 3 Reviewed by Gavin Barraclough. 4 5 Remove evil addressOfStructure() function 6 https://bugs.webkit.org/show_bug.cgi?id=59739 7 8 Remove the addressOfStructure function from JSCell, and update 9 callsites to use the same logic as testPrototype() 10 11 * jit/JITPropertyAccess.cpp: 12 (JSC::JIT::privateCompileGetByIdProto): 13 (JSC::JIT::privateCompileGetByIdProtoList): 14 * jit/JITPropertyAccess32_64.cpp: 15 (JSC::JIT::privateCompileGetByIdProto): 16 (JSC::JIT::privateCompileGetByIdProtoList): 17 * runtime/JSCell.h: 18 1 19 2011-04-28 Oliver Hunt <oliver@apple.com> 2 20 -
trunk/Source/JavaScriptCore/jit/JITPropertyAccess.cpp
r85236 r85240 713 713 714 714 // Check the prototype object's Structure had not changed. 715 const void* prototypeStructureAddress = protoObject->addressOfStructure(); 716 #if CPU(X86_64) 717 move(TrustedImmPtr(prototypeStructure), regT3); 718 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), regT3); 719 #else 720 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), TrustedImmPtr(prototypeStructure)); 721 #endif 715 move(TrustedImmPtr(protoObject), regT3); 716 Jump failureCases2 = branchPtr(NotEqual, Address(regT3, JSCell::structureOffset()), TrustedImmPtr(prototypeStructure)); 722 717 723 718 bool needsStubLink = false; … … 835 830 836 831 // Check the prototype object's Structure had not changed. 837 const void* prototypeStructureAddress = protoObject->addressOfStructure(); 838 #if CPU(X86_64) 839 move(TrustedImmPtr(prototypeStructure), regT3); 840 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), regT3); 841 #else 842 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), TrustedImmPtr(prototypeStructure)); 843 #endif 832 move(TrustedImmPtr(protoObject), regT3); 833 Jump failureCases2 = branchPtr(NotEqual, Address(regT3, JSCell::structureOffset()), TrustedImmPtr(prototypeStructure)); 844 834 845 835 // Checks out okay! -
trunk/Source/JavaScriptCore/jit/JITPropertyAccess32_64.cpp
r85226 r85240 741 741 742 742 // Check the prototype object's Structure had not changed. 743 const void* prototypeStructureAddress = protoObject->addressOfStructure(); 744 #if CPU(X86_64) 745 move(TrustedImmPtr(prototypeStructure), regT3); 746 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), regT3); 747 #else 748 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), TrustedImmPtr(prototypeStructure)); 749 #endif 743 move(TrustedImmPtr(protoObject), regT3); 744 Jump failureCases2 = branchPtr(NotEqual, Address(regT3, JSCell::structureOffset()), TrustedImmPtr(prototypeStructure)); 745 750 746 bool needsStubLink = false; 751 747 // Checks out okay! … … 867 863 868 864 // Check the prototype object's Structure had not changed. 869 const void* prototypeStructureAddress = protoObject->addressOfStructure(); 870 #if CPU(X86_64) 871 move(TrustedImmPtr(prototypeStructure), regT3); 872 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), regT3); 873 #else 874 Jump failureCases2 = branchPtr(NotEqual, AbsoluteAddress(prototypeStructureAddress), TrustedImmPtr(prototypeStructure)); 875 #endif 865 move(TrustedImmPtr(protoObject), regT3); 866 Jump failureCases2 = branchPtr(NotEqual, Address(regT3, JSCell::structureOffset()), TrustedImmPtr(prototypeStructure)); 876 867 877 868 bool needsStubLink = false; -
trunk/Source/JavaScriptCore/runtime/JSCell.h
r84800 r85240 148 148 } 149 149 150 const void* addressOfStructure() const151 {152 return &m_structure;153 }154 155 150 protected: 156 151 static const unsigned AnonymousSlotCount = 0;
Note: See TracChangeset
for help on using the changeset viewer.