Ignore:
Timestamp:
Mar 10, 2011, 11:27:49 AM (14 years ago)
Author:
[email protected]
Message:

2011-03-10 Oliver Hunt <[email protected]>

Reviewed by Gavin Barraclough.

jquery/manipulation.html fails after r80598
https://bugs.webkit.org/show_bug.cgi?id=56019

Removed jQuery tests from skiplists

  • platform/gtk/Skipped:
  • platform/qt/Skipped:

2011-03-09 Oliver Hunt <[email protected]>

Reviewed by Gavin Barraclough.

jquery/manipulation.html fails after r80598
https://bugs.webkit.org/show_bug.cgi?id=56019

When linking a call, codeblock now takes ownership of the linked function
This removes the need for unlinking, and thus the incorrectness that was
showing up in these tests.

  • bytecode/CodeBlock.cpp: (JSC::CodeBlock::~CodeBlock): (JSC::CodeBlock::markAggregate):
  • bytecode/CodeBlock.h: (JSC::CallLinkInfo::CallLinkInfo): (JSC::CallLinkInfo::setUnlinked): (JSC::CodeBlock::addCaller):
  • jit/JIT.cpp: (JSC::JIT::privateCompile): (JSC::JIT::linkCall): (JSC::JIT::linkConstruct):
  • jit/JIT.h:
  • runtime/Executable.cpp:
  • runtime/Executable.h:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/bytecode/CodeBlock.h

    r80684 r80738  
    9797    struct CallLinkInfo {
    9898        CallLinkInfo()
    99             : callee(0)
    100             , position(0)
     99            : position(0)
    101100            , hasSeenShouldRepatch(0)
    102101        {
     
    106105        CodeLocationDataLabelPtr hotPathBegin;
    107106        CodeLocationNearCall hotPathOther;
    108         CodeBlock* ownerCodeBlock;
    109         CodeBlock* callee;
     107        WriteBarrier<JSFunction> callee;
    110108        unsigned position : 31;
    111109        unsigned hasSeenShouldRepatch : 1;
    112110       
    113         void setUnlinked() { callee = 0; }
     111        void setUnlinked() { callee.clear(); }
    114112        bool isLinked() { return callee; }
    115113
     
    258256        void refStructures(Instruction* vPC) const;
    259257        void derefStructures(Instruction* vPC) const;
    260 #if ENABLE(JIT_OPTIMIZE_CALL)
    261         void unlinkCallers();
    262 #endif
    263258
    264259        static void dumpStatistics();
     
    293288
    294289#if ENABLE(JIT)
    295         void addCaller(CallLinkInfo* caller)
    296         {
    297             caller->callee = this;
     290        void addCaller(JSGlobalData& globalData, CallLinkInfo* caller, JSFunction* callee)
     291        {
     292            caller->callee.set(globalData, ownerExecutable(), callee);
    298293            caller->position = m_linkedCallerList.size();
    299294            m_linkedCallerList.append(caller);
    300         }
    301 
    302         void removeCaller(CallLinkInfo* caller)
    303         {
    304             unsigned pos = caller->position;
    305             unsigned lastPos = m_linkedCallerList.size() - 1;
    306 
    307             if (pos != lastPos) {
    308                 m_linkedCallerList[pos] = m_linkedCallerList[lastPos];
    309                 m_linkedCallerList[pos]->position = pos;
    310             }
    311             m_linkedCallerList.shrink(lastPos);
    312295        }
    313296
Note: See TracChangeset for help on using the changeset viewer.