This is an archive of the discontinued LLVM Phabricator instance.

[PowerPC] expand SCEV with correct type
ClosedPublic

Authored by shchenz on Oct 25 2021, 6:38 PM.

Details

Reviewers
jsji
nemanjai
Group Reviewers
Restricted Project
Commits
rG631f44f3381f: [PowerPC] use right extend type for SCEV
Summary

This is to fix an internal issue caused by D108750

We get assertion on AIX 32 target for the SCEV expansion.

lib/Transforms/Utils/ScalarEvolutionExpander.cpp:1847: llvm::Value *llvm::SCEVExpander::expandCodeForImpl(const llvm::SCEV *, llvm::Type *, bool): Assertion `SE.getTypeSizeInBits(Ty) == SE.getTypeSizeInBits(SH->getType()) && "non-trivial casts should be done with the SCEVs directly!"' failed.

Diff Detail

Unit TestsFailed

Event Timeline

shchenz created this revision.Oct 25 2021, 6:38 PM
shchenz requested review of this revision.Oct 25 2021, 6:38 PM
Herald added a project: Restricted Project. · View Herald TranscriptOct 25 2021, 6:38 PM
nemanjai accepted this revision.Oct 26 2021, 5:34 AM

Seems like an obvious fix. LGTM.

This revision is now accepted and ready to land.Oct 26 2021, 5:34 AM
This revision was landed with ongoing or failed builds.Oct 26 2021, 6:33 AM
This revision was automatically updated to reflect the committed changes.