This is an archive of the discontinued LLVM Phabricator instance.

[DAGCombiner][TargetLowering] Pass SDValue by value to isMulAddWithConstProfitable.
ClosedPublic

Authored by craig.topper on Feb 23 2022, 9:45 AM.

Details

Summary

Internally to DAGCombiner the SDValues were passed by non-const
reference despite not being modified. They were then passed by
const reference to TLI.

This patch passes them by value which is consistent with the vast
majority of code.

Diff Detail

Event Timeline

craig.topper created this revision.Feb 23 2022, 9:45 AM
craig.topper requested review of this revision.Feb 23 2022, 9:45 AM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 23 2022, 9:45 AM
This revision is now accepted and ready to land.Feb 23 2022, 10:25 AM
This revision was landed with ongoing or failed builds.Feb 23 2022, 12:41 PM
This revision was automatically updated to reflect the committed changes.