diff options
| author | Diana Picus <diana.picus@linaro.org> | 2019-05-02 09:28:00 +0000 |
|---|---|---|
| committer | Diana Picus <diana.picus@linaro.org> | 2019-05-02 09:28:00 +0000 |
| commit | 06a61ccc42ae55a35becc4c0516af2db1a3977f8 (patch) | |
| tree | e705c97c30fb250203a7ee6ed9f785d4639c3b90 /llvm/lib/Target | |
| parent | 7da389818d9d1bade4493a71bee9fa3119eb2080 (diff) | |
| download | bcm5719-llvm-06a61ccc42ae55a35becc4c0516af2db1a3977f8.tar.gz bcm5719-llvm-06a61ccc42ae55a35becc4c0516af2db1a3977f8.zip | |
[ARM GlobalISel] Select extensions to < 32 bits
Select G_SEXT and G_ZEXT with destination types smaller than 32 bits in
the exact same way as 32 bits. This overwrites the higher bits, but that
should be ok since all legal users of types smaller than 32 bits ignore
those bits anyway.
llvm-svn: 359768
Diffstat (limited to 'llvm/lib/Target')
| -rw-r--r-- | llvm/lib/Target/ARM/ARMInstructionSelector.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/llvm/lib/Target/ARM/ARMInstructionSelector.cpp b/llvm/lib/Target/ARM/ARMInstructionSelector.cpp index 52fae86bb7d..54402ddc718 100644 --- a/llvm/lib/Target/ARM/ARMInstructionSelector.cpp +++ b/llvm/lib/Target/ARM/ARMInstructionSelector.cpp @@ -862,11 +862,8 @@ bool ARMInstructionSelector::select(MachineInstr &I, LLVM_FALLTHROUGH; case G_ZEXT: { LLT DstTy = MRI.getType(I.getOperand(0).getReg()); - // FIXME: Smaller destination sizes coming soon! - if (DstTy.getSizeInBits() != 32) { - LLVM_DEBUG(dbgs() << "Unsupported destination size for extension"); - return false; - } + assert(DstTy.getSizeInBits() <= 32 && + "Unsupported destination size for extension"); LLT SrcTy = MRI.getType(I.getOperand(1).getReg()); unsigned SrcSize = SrcTy.getSizeInBits(); |

