This is an archive of the discontinued LLVM Phabricator instance.

[LV] Fix PR34965 - Extend InstWidening with CM_Widen_Recursive
ClosedPublic

Authored by dcaballe on Dec 1 2017, 11:18 AM.

Details

Summary

Changes to the original scalar loop during LV code gen cause the return value of Legal->isConsecutivePtr() to be inconsistent with the return value during legal/cost phases (further analysis and information of the bug is in D39346). This patch is an alternative fix to PR34965 following the CM_Widen approach proposed by Ayal and Gil in D39346. It extends InstWidening enum with CM_Widen_Reverse to properly record the widening decision for consecutive reverse memory accesses and, consequently, get rid of the Legal->isConsetuviePtr() call in LV code gen. I think this is a simpler/cleaner solution to PR34965 than the one in D39346.

Thanks,
Diego

Diff Detail

Repository
rL LLVM

Event Timeline

dcaballe created this revision.Dec 1 2017, 11:18 AM

Ping :)
This patch implements a simpler/cleaner fix for PR34965 than D39346.
Waiting for your approval.

Thanks,
Diego

hfinkel accepted this revision.Dec 11 2017, 9:39 PM
hfinkel added a subscriber: hfinkel.

LGTM

This revision is now accepted and ready to land.Dec 11 2017, 9:39 PM

Thanks, Hal! I will abandon D39346 and proceed with this one.

dcaballe updated this revision to Diff 126630.Dec 12 2017, 2:41 PM

I updated the patch to ToT. Could someone, please, commit the patch for me? I don't have commit access.

Thanks,
Diego

This revision was automatically updated to reflect the committed changes.

Thanks a lot, Hal!