[Webkit-unassigned] [Bug 184584] [MIPS] Optimize generated JIT code using mips32r2 instructions

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu May 3 17:35:34 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=184584

Yusuke Suzuki <utatane.tea at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |utatane.tea at gmail.com
 Attachment #337882|review?                     |review-
              Flags|                            |

--- Comment #7 from Yusuke Suzuki <utatane.tea at gmail.com> ---
Comment on attachment 337882
  --> https://bugs.webkit.org/attachment.cgi?id=337882
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=337882&action=review

The logic of the code looks good, but there are so much duplicate code. Can we clean up them?

> Source/JavaScriptCore/assembler/MacroAssemblerMIPS.h:2933
> +            if (!address.scale)
> +                m_assembler.addu(addrTempRegister, address.index, address.base);
> +            else {
> +                m_assembler.sll(addrTempRegister, address.index, address.scale);
> +                m_assembler.addu(addrTempRegister, addrTempRegister, address.base);
> +            }
> +            if (address.offset < -32768 || address.offset > 32767) {
> +                m_assembler.lui(immTempRegister, (address.offset + 0x8000) >> 16);
> +                m_assembler.addu(addrTempRegister, addrTempRegister, immTempRegister);
> +            }

This code pattern is so repeated. Can we extract this pattern to remove duplicate code?

> Source/JavaScriptCore/assembler/MacroAssemblerMIPS.h:2934
> +                m_assembler.swc1(src, addrTempRegister, address.offset);

Fix this indent.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180504/d6d14674/attachment-0001.html>


More information about the webkit-unassigned mailing list