[all-commits] [llvm/llvm-project] e9ac18: Preserve param alignment in NVPTXLowerArgs pass.
Justin Lebar via All-commits
all-commits at lists.llvm.org
Wed Oct 14 11:15:59 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: e9ac1869a82a37bd385fccd15c33599807cea3f4
https://github.com/llvm/llvm-project/commit/e9ac1869a82a37bd385fccd15c33599807cea3f4
Author: Justin Lebar <justin.lebar at gmail.com>
Date: 2020-10-14 (Wed, 14 Oct 2020)
Changed paths:
M llvm/lib/Target/NVPTX/NVPTXLowerArgs.cpp
A llvm/test/CodeGen/NVPTX/lower-args.ll
Log Message:
-----------
Preserve param alignment in NVPTXLowerArgs pass.
NVPTXLowerArgs works as follows.
* Create a regular alloca with alignment identical to arg.
* Copy arg from param space (and ASC'ing it from generic AS first) to
the alloca (it's still in generic AS).
* Replace loads of arg with loads of alloca.
The bug here is that we did not preserve the arg's alignment when
loading from the alloca.
The impact of this bug is that sometimes param loads would be lowered as
a series of u8 loads, because we're incorrectly assuming everything has
alignment 1.
Differential Revision: https://reviews.llvm.org/D89404
More information about the All-commits
mailing list