This is an archive of the discontinued LLVM Phabricator instance.

[SCEV] Add a threshold to restrict number of mul operands to be inlined into SCEV
AbandonedPublic

Authored by lihuang on Oct 18 2016, 11:15 PM.

Details

Summary

[SCEV] Add a threshold to restrict number of mul operands to be inlined into SCEV

This is to solve the same slow-compile issue in SCEV that D3127 was trying to solve. But that patch is no longer active.

Without a threshold for mul ops inlining, getMulExpr could have exponential time complexity in the worst case. The case in PR18606 is an example that causes clang to hang.

However, this patch does not completely solve the slow-compile issue in SCEV. SCEVRewriteVisiter is another bottleneck that could take exponential time to finish. I will upload another patch to fix it.

Diff Detail

Event Timeline

lihuang updated this revision to Diff 75108.Oct 18 2016, 11:15 PM
lihuang retitled this revision from to [SCEV] Add a threshold to restrict number of mul operands to be inlined into SCEV.
lihuang updated this object.
sanjoy edited edge metadata.Oct 19 2016, 1:03 PM

Hi Li,

I know this sounds stupid, but can you please re-create the revision with llvm-commits added as a subscriber from the very beginning? I don't remember clearly, but at least the last version of phabricator had some issues if you didn't do that.

Okay, I will re-create a revision.

lihuang abandoned this revision.Oct 19 2016, 2:21 PM