[PATCH] D118443: Add support for atomic memory copy lowering
Evgeniy via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 4 23:18:16 PDT 2022
ebrevnov added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.h:138
unsigned SrcAddrSpace, unsigned DestAddrSpace,
- unsigned SrcAlign, unsigned DestAlign) const;
-
- void getMemcpyLoopResidualLoweringType(SmallVectorImpl<Type *> &OpsOut,
- LLVMContext &Context,
- unsigned RemainingBytes,
- unsigned SrcAddrSpace,
- unsigned DestAddrSpace,
- unsigned SrcAlign,
- unsigned DestAlign) const;
+ unsigned SrcAlign, unsigned DestAlign,
+ Optional<uint32_t> AtomicElementSize) const;
----------------
arsenm wrote:
> We should probably move these to use Align (separate patch)
yep.
================
Comment at: llvm/lib/Transforms/Utils/LowerMemIntrinsics.cpp:307
+ Value *SrcAsResLoopOpType = ResBuilder.CreateBitCast(
+ SrcAddr, PointerType::get(ResLoopOpType, SrcAS));
+ Value *DstAsResLoopOpType = ResBuilder.CreateBitCast(
----------------
arsenm wrote:
> Might as well make this opaque pointer friendly with getWithSamePointeeType
Generated bitcast changes pointee type... getWithSamePointeeType is not applicable here...
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D118443/new/
https://reviews.llvm.org/D118443
More information about the llvm-commits
mailing list