This is an archive of the discontinued LLVM Phabricator instance.

[AArch64][GlobalISel] Enable some select combines after legalization
ClosedPublic

Authored by aemerson on Jul 25 2021, 12:49 AM.

Details

Summary

The legalizer generates selects for some operations, which can have constant condition values, resulting in lots of dead code if it's not folded away.

Diff Detail

Event Timeline

aemerson created this revision.Jul 25 2021, 12:49 AM
aemerson requested review of this revision.Jul 25 2021, 12:49 AM
This revision is now accepted and ready to land.Jul 25 2021, 10:44 PM
jroelofs accepted this revision.Jul 26 2021, 10:44 AM
This revision was landed with ongoing or failed builds.Jul 26 2021, 10:49 AM
This revision was automatically updated to reflect the committed changes.
tpopp added a subscriber: tpopp.Jul 27 2021, 6:25 AM

Hello, unless I'm mistaken, this is breaking CodeGen/AArch64/arm64-ldxr-stxr.ll. Can you confirm if that's correct and rollback this commit until it's fixed?

tpopp added a comment.Jul 27 2021, 6:54 AM

An important piece of information: this seems to happen only with assertions disabled (-DLLVM_ENABLE_ASSERTIONS=OFF)

An important piece of information: this seems to happen only with assertions disabled (-DLLVM_ENABLE_ASSERTIONS=OFF)

Thanks, I'll take a look.

An important piece of information: this seems to happen only with assertions disabled (-DLLVM_ENABLE_ASSERTIONS=OFF)

Thanks, I'll take a look.

This could be just exposing an existing issue that previously we fell back on, but without asserts we try to continue with codegen.

Ok, should be fixed in a11d9a1f480f.

tpopp added a comment.Jul 28 2021, 1:48 AM

Ok, should be fixed in a11d9a1f480f.

Thank you :)