Changeset 215731 in webkit


Ignore:
Timestamp:
Apr 25, 2017 7:15:42 AM (7 years ago)
Author:
zandobersek@gmail.com
Message:

[aarch64] moveConditionally32(), moveConditionallyTest32() should move from/to 64-bit registers
https://bugs.webkit.org/show_bug.cgi?id=170891

Reviewed by Saam Barati.

moveConditionally32() and moveConditionallyTest32() operations in
MacroAssemblerARM64 properly perform comparisons and tests on 32-bit
values, but end up performing the moves from and to 32-bit registers.

Move operations should instead be done on 64-bit registers, just like
on the X86_64 platform. This is achieved by specifying 64 as the data
size for the csel instructions.

  • assembler/MacroAssemblerARM64.h:

(JSC::MacroAssemblerARM64::moveConditionally32):
(JSC::MacroAssemblerARM64::moveConditionallyTest32):

Location:
trunk/Source/JavaScriptCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r215723 r215731  
     12017-04-25  Zan Dobersek  <zdobersek@igalia.com>
     2
     3        [aarch64] moveConditionally32(), moveConditionallyTest32() should move from/to 64-bit registers
     4        https://bugs.webkit.org/show_bug.cgi?id=170891
     5
     6        Reviewed by Saam Barati.
     7
     8        moveConditionally32() and moveConditionallyTest32() operations in
     9        MacroAssemblerARM64 properly perform comparisons and tests on 32-bit
     10        values, but end up performing the moves from and to 32-bit registers.
     11
     12        Move operations should instead be done on 64-bit registers, just like
     13        on the X86_64 platform. This is achieved by specifying 64 as the data
     14        size for the csel instructions.
     15
     16        * assembler/MacroAssemblerARM64.h:
     17        (JSC::MacroAssemblerARM64::moveConditionally32):
     18        (JSC::MacroAssemblerARM64::moveConditionallyTest32):
     19
    1202017-04-24  Joseph Pecoraro  <pecoraro@apple.com>
    221
  • trunk/Source/JavaScriptCore/assembler/MacroAssemblerARM64.h

    r215592 r215731  
    22342234    {
    22352235        m_assembler.cmp<32>(left, right);
    2236         m_assembler.csel<32>(dest, src, dest, ARM64Condition(cond));
     2236        m_assembler.csel<64>(dest, src, dest, ARM64Condition(cond));
    22372237    }
    22382238
     
    22402240    {
    22412241        m_assembler.cmp<32>(left, right);
    2242         m_assembler.csel<32>(dest, thenCase, elseCase, ARM64Condition(cond));
     2242        m_assembler.csel<64>(dest, thenCase, elseCase, ARM64Condition(cond));
    22432243    }
    22442244
     
    22982298    {
    22992299        m_assembler.tst<32>(testReg, mask);
    2300         m_assembler.csel<32>(dest, src, dest, ARM64Condition(cond));
     2300        m_assembler.csel<64>(dest, src, dest, ARM64Condition(cond));
    23012301    }
    23022302
     
    23042304    {
    23052305        m_assembler.tst<32>(left, right);
    2306         m_assembler.csel<32>(dest, thenCase, elseCase, ARM64Condition(cond));
     2306        m_assembler.csel<64>(dest, thenCase, elseCase, ARM64Condition(cond));
    23072307    }
    23082308
     
    23102310    {
    23112311        test32(left, right);
    2312         m_assembler.csel<32>(dest, thenCase, elseCase, ARM64Condition(cond));
     2312        m_assembler.csel<64>(dest, thenCase, elseCase, ARM64Condition(cond));
    23132313    }
    23142314
Note: See TracChangeset for help on using the changeset viewer.