Only use 16 VFP registers if !CPU(ARM_NEON).
authormark.lam@apple.com <mark.lam@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 17 Aug 2017 19:57:46 +0000 (19:57 +0000)
committermark.lam@apple.com <mark.lam@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 17 Aug 2017 19:57:46 +0000 (19:57 +0000)
commit6a6d62d49ec90b808e6f63e88ec0df06f068e164
treeba3a7b2391403784615f9b7816ee9a21e3bb754c
parent75032930ae8e278221d138494684235a0792782b
Only use 16 VFP registers if !CPU(ARM_NEON).
https://bugs.webkit.org/show_bug.cgi?id=175514

Reviewed by JF Bastien.

Source/JavaScriptCore:

Deleted q16-q31 FPQuadRegisterID enums in ARMv7Assembler.h.  The NEON spec
says that there are only 16 128-bit NEON registers.  This change is merely to
correct the code documentation of these registers.  The FPQuadRegisterID are
currently unused.

* assembler/ARMAssembler.h:
(JSC::ARMAssembler::lastFPRegister):
(JSC::ARMAssembler::fprName):
* assembler/ARMv7Assembler.h:
(JSC::ARMv7Assembler::lastFPRegister):
(JSC::ARMv7Assembler::fprName):
* assembler/MacroAssemblerARM.cpp:
* assembler/MacroAssemblerARMv7.cpp:

Source/WTF:

If CPU(ARM_NEON) is not enabled, we'll conservatively assume only VFP2 support is
available. Hence, we'll only the first 16 FPDoubleRegisterIDs are available.

For reference, see:
NEON registers: http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0473c/CJACABEJ.html
VFP2 and VFP3 registers: http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0473c/CIHDIBDG.html
NEON to VFP register mapping: http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0473c/CJAIJHFC.html

This is mostly for GTK toolchains which may target older ARM CPUs which only have
VFP2 support.

* wtf/Platform.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@220871 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/assembler/ARMAssembler.h
Source/JavaScriptCore/assembler/ARMv7Assembler.h
Source/JavaScriptCore/assembler/MacroAssemblerARM.cpp
Source/JavaScriptCore/assembler/MacroAssemblerARMv7.cpp
Source/WTF/ChangeLog
Source/WTF/wtf/Platform.h