[PowerPC][GISel] Add initial GlobalISel support for vector functions.
authorAmy Kwan <amy.kwan1@ibm.com>
Sun, 26 Mar 2023 04:04:53 +0000 (23:04 -0500)
committerAmy Kwan <amy.kwan1@ibm.com>
Mon, 27 Mar 2023 13:23:05 +0000 (08:23 -0500)
commit3508f123353c0a145ee79cebb972f46fcb97bf1e
tree9bb2756a3ea09df24e6eee49f17e41761ff448e3
parent6126356d829be32e2195b8ddf8b908ab417ff7f5
[PowerPC][GISel] Add initial GlobalISel support for vector functions.

This patch adds the initial support for vector functions and register banks
within GlobalISel. With this patch, we are able to support simple functions that
return vectors, and also functions that perform simple operations.

This patch also:
- Legalizes vector types for G_AND, G_OR, G_XOR, G_ADD, G_SUB, G_BITCAST, G_FADD, G_FSUB
- Introduce initial support for bitcasting (that will need to be extended upon)
- Add various different test cases to for test vector support within GlobalISel

Differential Revision: https://reviews.llvm.org/D137785
llvm/lib/Target/PowerPC/GISel/PPCInstructionSelector.cpp
llvm/lib/Target/PowerPC/GISel/PPCLegalizerInfo.cpp
llvm/lib/Target/PowerPC/GISel/PPCRegisterBankInfo.cpp
llvm/lib/Target/PowerPC/GISel/PPCRegisterBankInfo.h
llvm/lib/Target/PowerPC/GISel/PPCRegisterBanks.td
llvm/lib/Target/PowerPC/PPCGenRegisterBankInfo.def
llvm/test/CodeGen/PowerPC/GlobalISel/float-arithmetic.ll
llvm/test/CodeGen/PowerPC/GlobalISel/ppc-isel-arithmentic-vec.ll [new file with mode: 0644]
llvm/test/CodeGen/PowerPC/GlobalISel/ppc-isel-logical-vec.ll [new file with mode: 0644]
llvm/test/CodeGen/PowerPC/GlobalISel/ppc-isel-ret-and-bitcast-vec.ll [new file with mode: 0644]