Changeset 194208 in webkit


Ignore:
Timestamp:
Dec 16, 2015 9:02:49 PM (8 years ago)
Author:
msaboff@apple.com
Message:

ARM64 MacroAssembler improperly reuses data temp register in test32() and test8() calls
https://bugs.webkit.org/show_bug.cgi?id=152370

Reviewed by Benjamin Poulain.

Changed the test8/32(Address, Register) flavors to use the memoryTempRegister for loading the value
att Address so that it doesn't collide with the subsequent use of dataTempRegister by the
test32(Register, Register) function.

  • assembler/MacroAssemblerARM64.h:

(JSC::MacroAssemblerARM64::test32):
(JSC::MacroAssemblerARM64::test8):

Location:
trunk/Source/JavaScriptCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r194185 r194208  
     12015-12-16  Michael Saboff  <msaboff@apple.com>
     2
     3        ARM64 MacroAssembler improperly reuses data temp register in test32() and test8() calls
     4        https://bugs.webkit.org/show_bug.cgi?id=152370
     5
     6        Reviewed by Benjamin Poulain.
     7
     8        Changed the test8/32(Address, Register) flavors to use the memoryTempRegister for loading the value
     9        att Address so that it doesn't collide with the subsequent use of dataTempRegister by the
     10        test32(Register, Register) function.
     11
     12        * assembler/MacroAssemblerARM64.h:
     13        (JSC::MacroAssemblerARM64::test32):
     14        (JSC::MacroAssemblerARM64::test8):
     15
    1162015-12-16  Filip Pizlo  <fpizlo@apple.com>
    217
  • trunk/Source/JavaScriptCore/assembler/MacroAssemblerARM64.h

    r194062 r194208  
    23292329    void test32(ResultCondition cond, Address address, TrustedImm32 mask, RegisterID dest)
    23302330    {
    2331         load32(address, getCachedDataTempRegisterIDAndInvalidate());
    2332         test32(cond, dataTempRegister, mask, dest);
     2331        load32(address, getCachedMemoryTempRegisterIDAndInvalidate());
     2332        test32(cond, memoryTempRegister, mask, dest);
    23332333    }
    23342334
    23352335    void test8(ResultCondition cond, Address address, TrustedImm32 mask, RegisterID dest)
    23362336    {
    2337         load8(address, getCachedDataTempRegisterIDAndInvalidate());
    2338         test32(cond, dataTempRegister, mask, dest);
     2337        load8(address, getCachedMemoryTempRegisterIDAndInvalidate());
     2338        test32(cond, memoryTempRegister, mask, dest);
    23392339    }
    23402340
Note: See TracChangeset for help on using the changeset viewer.