This change adds two FP16 extraction and two insertion patterns
(one per possible vector length).
Extractions are handled by copying a Q/D register into one of VFP2
class registers, where single FP32 sub-registers can be accessed. Then
the extraction of even lanes are simple sub-register extractions
(because we don't care about the top parts of registers for FP16
operations). Odd lanes need an additional VMOVX instruction.
Unfortunately, insertions cannot be handled in the same way, because:
- There is no instruction to insert FP16 into an even lane (VINS only works with odd lanes)
- The patterns for odd lanes will have a form of a DAG (not a tree), and will not be implementable in pure tablegen
Because of this insertions are handled in the same way as 16-bit
integer insertions (with conversions between FP registers and GPRs
using VMOVHR instructions).
Without these patterns the ARM backend would sometimes fail during
This patch also adds patterns which combine:
- an FP16 element extraction and a store into a single VST1 instruction
- an FP16 load and insertion into a single VLD1 instruction