[PATCH] D63560: AMDGPU: Treat undef as an inline immediate
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 19 15:55:18 PDT 2019
arsenm marked an inline comment as done.
arsenm added inline comments.
================
Comment at: lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp:497
bool Negated) const {
- // TODO: Handle undef
+ if (N->isUndef())
+ return true;
----------------
rampitec wrote:
> There is another use of isInlineImmediate (check case ISD::ConstantFP) around line 761. You will return true, but you do not initialize Imm with zero there.
The check for ConstantFP selection isn't using the value of this, and just uses it to fallback to selection patterns which handles undef. It doesn't need to be and shouldn't be 0 always, it's just useful in this context
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D63560/new/
https://reviews.llvm.org/D63560
More information about the llvm-commits
mailing list