This is an archive of the discontinued LLVM Phabricator instance.

[ARM] Prevent PerformVCVTCombine from combining a vmul/vcvt with 8 lanes
ClosedPublic

Authored by bsmith on Dec 15 2014, 6:57 AM.

Details

Reviewers
HaoLiu
Summary

This patch addresses the crash raised in PR21572. The problem occurs when PerformVCVTCombine tries to combine vmul and vcvt with 8 lane vectors. This results in use of v8i32 types which the intrinsic used does not support. This patch prevents this crash by bailing out when >4 lanes are used.

Regards,
Bradley Smith

Diff Detail

Repository
rL LLVM

Event Timeline

bsmith updated this revision to Diff 17281.Dec 15 2014, 6:57 AM
bsmith retitled this revision from to [ARM] Prevent PerformVCVTCombine from combining a vmul/vcvt with 8 lanes.
bsmith updated this object.
bsmith edited the test plan for this revision. (Show Details)
bsmith set the repository for this revision to rL LLVM.
bsmith added a subscriber: Unknown Object (MLST).

Hi Bradley,

It's a simple and clear fix. LGTM.

Thanks,
-Hao

HaoLiu accepted this revision.Dec 15 2014, 5:35 PM
HaoLiu added a reviewer: HaoLiu.
This revision is now accepted and ready to land.Dec 15 2014, 5:35 PM

Hi Bradley,

AArch64 backend also has such instructions (It even support double type), but it doesn't have such combine function to do such optimization. I think maybe we can also port this function to AArch64 backend.

Thanks,
-Hao

bsmith closed this revision.Dec 16 2014, 3:00 AM