[PATCH] D138420: [SelectionDAG] Remove deprecated MemSDNode->getAlignment()
Guillaume Chatelet via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 21 06:01:23 PST 2022
gchatelet accepted this revision.
gchatelet added a comment.
This revision is now accepted and ready to land.
Thx a lot for this patch. It was on my plate for a very long time but I haven't had time to do it.
Please fix the `M68k` issue before submitting.
================
Comment at: llvm/lib/Target/AMDGPU/R600ISelLowering.cpp:1006
if (Store->getMemoryVT() == MVT::i8) {
- assert(Store->getAlignment() >= 1);
+ assert(Store->getAlign() >= 1);
Mask = DAG.getConstant(0xff, DL, MVT::i32);
----------------
You may want to keep it for documentation purposes but this is always true by definition. The `Align` type guarantees to be `>=1`.
================
Comment at: llvm/lib/Target/M68k/M68kInstrInfo.td:525
if (ExtType == ISD::EXTLOAD)
- return LD->getAlignment() >= 2 && !LD->isSimple();
+ return Ld->getAlign() >= 2 && !LD->isSimple();
return false;
----------------
This should be `LD->getAlign()`. Same below.
`M68k` is not part of `LLVM_TARGETS_TO_BUILD`, it's actually part of `LLVM_EXPERIMENTAL_TARGETS_TO_BUILD` so I guess it went undetected.
I ran the test on my side with the patch applied. Using `LD` instead of `Ld` fixes the build for `M68k`.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D138420/new/
https://reviews.llvm.org/D138420
More information about the llvm-commits
mailing list