This is an archive of the discontinued LLVM Phabricator instance.

[InstCombine] Make InstCombine's IRBuilder be passed by reference everywhere
ClosedPublic

Authored by craig.topper on Jul 6 2017, 4:06 PM.

Details

Summary

Previously the InstCombiner class contained a pointer to an IR builder that had been passed to the constructor. Sometimes this would be passed to helper functions as either a pointer or the pointer would be dereferenced to be passed by reference.

This patch makes it a reference everywhere including the InstCombiner class itself so there is more inconsistency. This a large, but mechanical patch. I've done very minimal formatting changes on it despite what clang-format wanted to do.

Diff Detail

Event Timeline

craig.topper created this revision.Jul 6 2017, 4:06 PM
spatel accepted this revision.Jul 7 2017, 12:03 PM

LGTM.

This revision is now accepted and ready to land.Jul 7 2017, 12:03 PM

I committed but forgot the differential revision line so it didn't close