This is an archive of the discontinued LLVM Phabricator instance.

[RewriteStatepointsForGC] Exclude noreturn calls from doing GC liveness analysis
AbandonedPublic

Authored by chenli on May 19 2015, 1:27 PM.

Details

Reviewers
reames
sanjoy
Summary

noreturn calls can never return normally so they do not need GC safepoints. Therefore, don't waste time on doing liveness analysis for them.

Diff Detail

Event Timeline

chenli updated this revision to Diff 26087.May 19 2015, 1:27 PM
chenli retitled this revision from to [RewriteStatepointsForGC] Exclude noreturn calls from doing GC liveness analysis.
chenli updated this object.
chenli edited the test plan for this revision. (Show Details)
chenli added reviewers: sanjoy, reames.
chenli added a subscriber: Unknown Object (MLST).
reames added inline comments.May 19 2015, 4:50 PM
lib/Transforms/Scalar/RewriteStatepointsForGC.cpp
1009

I'd rename this slightly. NoReturn is a well defined concept. Given the invoke case, this is more like doesntNeedLivePointers or something.

1035

I'd be tempted to move this check inside the liveness analysis since you're still returning the correct result, just differently.

Also, what are you actually saving in compute time here? Isn't walking back from the end of the block just as fast?

test/Transforms/RewriteStatepointsForGC/noreturn-calls.ll
6

Please don't check for this debug output. Checking that there are no gc.relocates would be more appropriate.

20

Please trim unneeded deopt args.

chenli abandoned this revision.May 19 2015, 6:02 PM