[PATCH] D109243: AMDGPU/GlobalISel: Add build_vector_trunc post-legalizer combine
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Jan 16 17:48:13 PST 2022
arsenm added inline comments.
================
Comment at: llvm/lib/Target/AMDGPU/AMDGPUPostLegalizerCombiner.cpp:279
+ getDefIgnoringCopies(MI.getOperand(2).getReg(), MRI);
+ if (!SecondElt || !isa<GImplicitDef>(SecondElt))
+ return false;
----------------
getDefIgnoringCopies cannot fail, so no point in the null check. Also you can fold this into return of the bool expression
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D109243/new/
https://reviews.llvm.org/D109243
More information about the llvm-commits
mailing list