This is an archive of the discontinued LLVM Phabricator instance.

[DAG] SimplifyMultipleUseDemandedBits - remove superfluous bitcasts
ClosedPublic

Authored by RKSimon on May 7 2020, 6:42 AM.

Details

Summary

If the SimplifyMultipleUseDemandedBits calls BITCASTs that peek through back to the original type then we can remove the BITCASTs entirely.

I think this is a win in all cases but wanted to double check with AMDGPU/THUMB2 guys.

Diff Detail

Event Timeline

RKSimon created this revision.May 7 2020, 6:42 AM
Herald added a project: Restricted Project. · View Herald TranscriptMay 7 2020, 6:42 AM
dmgreen added inline comments.May 7 2020, 9:15 AM
llvm/test/CodeGen/Thumb2/mve-vld3.ll
6

These are both OK I think. Both tests are mostly "we don't crash" kind of tests, and the changes look OK, considering the input.

foad added a subscriber: foad.May 8 2020, 1:02 AM

@arsenm Does the amdgpu/fshr.ll change look ok to you?

arsenm added inline comments.May 8 2020, 6:26 AM
llvm/test/CodeGen/AMDGPU/fshr.ll
786

This is better

spatel accepted this revision.May 8 2020, 7:25 AM

Seems obviously correct and x86 diffs LGTM.

This revision is now accepted and ready to land.May 8 2020, 7:25 AM
This revision was automatically updated to reflect the committed changes.