This is an archive of the discontinued LLVM Phabricator instance.

[CGP] CodeGenPrepare sinks addrspacecast
ClosedPublic

Authored by jingyue on May 19 2014, 3:12 PM.

Details

Reviewers
chandlerc
arsenm
Summary

Similar to bitcast, treat addrspacecast as a foldable operand.

Added a test sink-addrspacecast.ll to verify this change.

Diff Detail

Event Timeline

jingyue updated this revision to Diff 9587.May 19 2014, 3:12 PM
jingyue retitled this revision from to [CGP] CodeGenPrepare sinks addrspacecast.
jingyue updated this object.
jingyue edited the test plan for this revision. (Show Details)
jingyue added a reviewer: chandlerc.
jingyue added a subscriber: Unknown Object (MLST).

ping :) it's a fairly small patch. Besides the test, I only added two lines. Thanks!

arsenm accepted this revision.May 21 2014, 3:52 PM
arsenm added a reviewer: arsenm.
arsenm added a subscriber: arsenm.

LGTM

test/Transforms/CodeGenPrepare/X86/sink-addrspacecast.ll
2

Move the argument before the < %s

This revision is now accepted and ready to land.May 21 2014, 3:52 PM
jingyue updated this revision to Diff 9669.May 21 2014, 4:40 PM
jingyue edited edge metadata.

Matt, thanks for reviewing this!

eliben added a subscriber: eliben.May 21 2014, 5:52 PM

Committed in r209343

jingyue closed this revision.May 22 2014, 11:20 AM