[PATCH] D73214: [MIPS GlobalISel] Select count leading zeros
Simon Atanasyan via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Jan 23 04:59:36 PST 2020
atanasyan added inline comments.
================
Comment at: llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp:980
case TargetOpcode::G_CTPOP:
- if (TypeIdx != 0)
- return UnableToLegalize; // TODO
+ if (TypeIdx == 1)
+ switch (MI.getOpcode()) {
----------------
arsenm wrote:
> atanasyan wrote:
> > Is it possible that `TypeIdx != 0 && TypeIdx != 1` ?
> That would be an invalid case as these instructions only have 2 type indexes
Yeah, I understand that this case is invalid. Does it make a sense to note this fact and add some sort of assert?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D73214/new/
https://reviews.llvm.org/D73214
More information about the llvm-commits
mailing list