Ignore:
Timestamp:
Mar 2, 2015, 3:49:29 PM (10 years ago)
Author:
[email protected]
Message:

FTL should correctly document where it puts the argument count for inlined varargs frames
https://bugs.webkit.org/show_bug.cgi?id=142187

Reviewed by Geoffrey Garn.

After LLVM tells us where the captured variables alloca landed in the frame, we need to
tell all of our meta-data about it. We were forgetting to do so for the argument count
register, which is used by inlined varargs calls.

  • ftl/FTLCompile.cpp:

(JSC::FTL::mmAllocateDataSection):

  • tests/stress/inline-varargs-get-arguments.js: Added.

(foo):
(bar):
(baz):

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ftl/FTLCompile.cpp

    r180279 r180903  
    304304        InlineCallFrame* inlineCallFrame = graph.m_inlineVariableData[i].inlineCallFrame;
    305305       
    306         if (inlineCallFrame->argumentsRegister.isValid()) {
    307             inlineCallFrame->argumentsRegister = VirtualRegister(
    308                 inlineCallFrame->argumentsRegister.offset() + localsOffset);
    309         }
     306        if (inlineCallFrame->argumentsRegister.isValid())
     307            inlineCallFrame->argumentsRegister += localsOffset;
     308       
     309        if (inlineCallFrame->argumentCountRegister.isValid())
     310            inlineCallFrame->argumentCountRegister += localsOffset;
    310311       
    311312        for (unsigned argument = inlineCallFrame->arguments.size(); argument-- > 1;) {
Note: See TracChangeset for help on using the changeset viewer.