This is an archive of the discontinued LLVM Phabricator instance.

SpeculateAroundPHIs: Respect convergent
ClosedPublic

Authored by arsenm on May 28 2019, 8:55 AM.

Details

Summary

This would break for speculatable and convergent intrinsic calls.

Diff Detail

Event Timeline

arsenm created this revision.May 28 2019, 8:55 AM

I don't think we need the AMDGPU test case specialization here. A generic test with a convergent and one with a non-duplicatable call would make more sense to me.

I don't think we need the AMDGPU test case specialization here. A generic test with a convergent and one with a non-duplicatable call would make more sense to me.

It concludes an arbitrary call is too expensive, so the problem doesn't manifest. I didn't see any control to override the cost

arsenm updated this revision to Diff 201731.May 28 2019, 11:33 AM

A fake intrinsic with an llvm. prefix works for the test

jdoerfert accepted this revision.May 28 2019, 11:42 AM

Last request from my side, a positive test that looks exactly the same but without the convergent/noduplicate to make sure it is actually transformed.

Otherwise, this looks good to me.

This revision is now accepted and ready to land.May 28 2019, 11:42 AM
arsenm closed this revision.May 29 2019, 7:07 AM

r361957