forked from OSchip/llvm-project
AMDGPU/GlobalISel: Remove unnecessary legality constraint for G_EXTRACT
Summary: We were marking G_EXTRACT operations unsupported if the output type was larger than the input type. I don't see how this could ever actually happen, so I dropped the constraint. Doing this makes it possible to reuse the same legality code for G_INSERT. Reviewers: arsenm Reviewed By: arsenm Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, rovka, kristof.beyls, dstuttard, tpr, t-tye, llvm-commits Differential Revision: https://reviews.llvm.org/D49600 llvm-svn: 337794
This commit is contained in:
parent
6c3a74edc9
commit
2d37929c10
|
@ -173,9 +173,6 @@ AMDGPULegalizerInfo::AMDGPULegalizerInfo(const GCNSubtarget &ST,
|
|||
|
||||
// FIXME: Doesn't handle extract of illegal sizes.
|
||||
getActionDefinitionsBuilder(G_EXTRACT)
|
||||
.unsupportedIf([=](const LegalityQuery &Query) {
|
||||
return Query.Types[0].getSizeInBits() >= Query.Types[1].getSizeInBits();
|
||||
})
|
||||
.legalIf([=](const LegalityQuery &Query) {
|
||||
const LLT &Ty0 = Query.Types[0];
|
||||
const LLT &Ty1 = Query.Types[1];
|
||||
|
|
Loading…
Reference in New Issue