<html>
    <head>
      <base href="https://bugs.webkit.org/" />
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - JSC: DFG::SpeculativeJIT::compile special case for MIPS for PutByValWithThis"
   href="https://bugs.webkit.org/show_bug.cgi?id=157741#c10">Comment # 10</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - JSC: DFG::SpeculativeJIT::compile special case for MIPS for PutByValWithThis"
   href="https://bugs.webkit.org/show_bug.cgi?id=157741">bug 157741</a>
              from <span class="vcard"><a class="email" href="mailto:sbarati&#64;apple.com" title="Saam Barati &lt;sbarati&#64;apple.com&gt;"> <span class="fn">Saam Barati</span></a>
</span></b>
        <pre>(In reply to <a href="show_bug.cgi?id=157741#c9">comment #9</a>)
<span class="quote">&gt; Comment on <span class=""><a href="attachment.cgi?id=279023&amp;action=diff" name="attach_279023" title="Patch">attachment 279023</a> <a href="attachment.cgi?id=279023&amp;action=edit" title="Patch">[details]</a></span>
&gt; Patch
&gt; 
&gt; View in context:
&gt; <a href="https://bugs.webkit.org/attachment.cgi?id=279023&amp;action=review">https://bugs.webkit.org/attachment.cgi?id=279023&amp;action=review</a>
&gt; 
&gt; &gt;&gt;&gt;&gt; Source/JavaScriptCore/dfg/DFGSpeculativeJIT32_64.cpp:2947
&gt; &gt;&gt;&gt;&gt; +            m_jit.move(baseTag, GPRInfo::argumentGPR3);
&gt; &gt;&gt;&gt; 
&gt; &gt;&gt;&gt; This is wrong if basePayload/baseTag are aliased to argument registers w/ each other.
&gt; &gt;&gt;&gt; i.e, if basePayload is argumentGPR3 and baseTag is argumentGPR2, this code will do the wrong thing.
&gt; &gt;&gt; 
&gt; &gt;&gt; I thought this was not possible because the argumentGPR's are not in GPRInfo::toRegister() (and not counted in GPRInfo::numberOfRegisters). Including them might be an idea for the future though, as I suspect more registers available might improve performances (and ARM does that so it's probably possible), but I think that's a trickier change, and I'd like to get the build unbroken.
&gt; &gt; 
&gt; &gt; I don't quite understand your response here. Tag/Payload regs will be allocated by the DFG's register allocator. It will happily use argument registers.
&gt; &gt; I don't think this makes the code harder to read. All code we write that sets up a call frame must account for this.
&gt; 
&gt; Sorry if that wasn't clear, and there is a possibility that I misunderstand
&gt; something. What I mean is that DFG::RegisterBank&lt;GPRInfo&gt;::allocate() (see
&gt; ::allocateInternal()) uses GPRInfo::toRegister() (and
&gt; GPRInfo::numberOfRegisters as RegisterBank::NUM_REGS) as its source of
&gt; registers. In the case of MIPS, GPRInfo::toRegister() never returns an
&gt; argumentGPRx. Therefore baseTag and basePayload cannot be an argumentGPRx
&gt; register. That's my current understanding at least.</span >
I see. Makes sense.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>