[PATCH] D85909: [SVE][CodeGen] Fix scalable vector issues in DAGTypeLegalizer::GenWidenVectorLoads
David Sherwood via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 13 08:20:15 PDT 2020
david-arm created this revision.
david-arm added reviewers: sdesmalen, efriedma, fpetrogalli.
Herald added subscribers: llvm-commits, psnobl, hiraditya, kristof.beyls, tschuett.
Herald added a reviewer: rengolin.
Herald added a project: LLVM.
david-arm requested review of this revision.
In DAGTypeLegalizer::GenWidenVectorLoads the algorithm assumes it only
ever deals with fixed width types, hence the offsets for each individual
store never take 'vscale' into account. I've changed the code in that
function to use TypeSize instead of unsigned for tracking the remaining
load amount. In addition, I've changed the load loop to use the new
IncrementPointer helper function for updating the addresses in each
iteration, since this handles scalable vector types.
Also, I've added a report_fatal_error in GenWidenVectorExtLoads, since
this code currently uses a sequence of element-by-element scalar loads.
In a similar vein, I've also added a fatal error report in
FindMemType for the case when we decide to return the element type for
a scalable vector type.
I've added new tests in
CodeGen/AArch64/sve-split-load.ll
CodeGen/AArch64/sve-ld-addressing-mode-reg-imm.ll
for the changes in GenWidenVectorLoads.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D85909
Files:
llvm/include/llvm/Support/TypeSize.h
llvm/lib/CodeGen/SelectionDAG/LegalizeVectorTypes.cpp
llvm/test/CodeGen/AArch64/sve-ld1-addressing-mode-reg-imm.ll
llvm/test/CodeGen/AArch64/sve-split-load.ll
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D85909.285378.patch
Type: text/x-patch
Size: 10780 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200813/ae31de51/attachment.bin>
More information about the llvm-commits
mailing list