diff options
| author | Simon Pilgrim <llvm-dev@redking.me.uk> | 2019-09-25 14:55:57 +0000 |
|---|---|---|
| committer | Simon Pilgrim <llvm-dev@redking.me.uk> | 2019-09-25 14:55:57 +0000 |
| commit | 5f2d8b261828590946c1ac8d684737c3f5e25da4 (patch) | |
| tree | 400872192f8cb196738a4dfd301667c87a0c4a1d /llvm/lib/CodeGen | |
| parent | f8067c7f7c774899c18c03e6b4e0375350436bac (diff) | |
| download | bcm5719-llvm-5f2d8b261828590946c1ac8d684737c3f5e25da4.tar.gz bcm5719-llvm-5f2d8b261828590946c1ac8d684737c3f5e25da4.zip | |
[TargetInstrInfo] Let findCommutedOpIndices take const MachineInstr&
Neither the base implementation of findCommutedOpIndices nor any in-tree target modifies the instruction passed in and there is no reason why they would in the future.
Committed on behalf of @hvdijk (Harald van Dijk)
Differential Revision: https://reviews.llvm.org/D66138
llvm-svn: 372882
Diffstat (limited to 'llvm/lib/CodeGen')
| -rw-r--r-- | llvm/lib/CodeGen/TargetInstrInfo.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/TargetInstrInfo.cpp b/llvm/lib/CodeGen/TargetInstrInfo.cpp index fefae2eb5bb..0e9eb77ea26 100644 --- a/llvm/lib/CodeGen/TargetInstrInfo.cpp +++ b/llvm/lib/CodeGen/TargetInstrInfo.cpp @@ -282,7 +282,7 @@ bool TargetInstrInfo::fixCommutedOpIndices(unsigned &ResultIdx1, return true; } -bool TargetInstrInfo::findCommutedOpIndices(MachineInstr &MI, +bool TargetInstrInfo::findCommutedOpIndices(const MachineInstr &MI, unsigned &SrcOpIdx1, unsigned &SrcOpIdx2) const { assert(!MI.isBundle() && |

