This is an archive of the discontinued LLVM Phabricator instance.

[ADT] Switch from a hacky use of PointerIntPair and poorly chosen arbitrary integers cast to Instruction pointers to a sum type over Instruction * and a PointerEmbeddedInt.
ClosedPublic

Authored by chandlerc on Jan 2 2016, 2:53 AM.

Details

Summary

This is a good example of how PointerSumType and PointerEmbeddedInt can be used
to create a more clean sum type abstraction.

No functionality changed.

Depends on D15843.
Depneds on D15844.

Diff Detail

Repository
rL LLVM

Event Timeline

chandlerc updated this revision to Diff 43846.Jan 2 2016, 2:53 AM
chandlerc retitled this revision from to [ADT] Switch from a hacky use of PointerIntPair and poorly chosen arbitrary integers cast to Instruction pointers to a sum type over Instruction * and a PointerEmbeddedInt..
chandlerc updated this object.
chandlerc added a subscriber: llvm-commits.
chandlerc updated this revision to Diff 49941.Mar 7 2016, 2:54 AM

Rebase on top of my cleanups to memdep.

chandlerc updated this revision to Diff 49942.Mar 7 2016, 3:01 AM

FIx my bad merge.

bkramer accepted this revision.Mar 7 2016, 3:06 AM
bkramer added a reviewer: bkramer.
bkramer added a subscriber: bkramer.

LGTM

This revision is now accepted and ready to land.Mar 7 2016, 3:06 AM
This revision was automatically updated to reflect the committed changes.