diff options
Diffstat (limited to 'backend/lib/CodeGen/MachineFunctionCloner.cpp')
| -rw-r--r-- | backend/lib/CodeGen/MachineFunctionCloner.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/backend/lib/CodeGen/MachineFunctionCloner.cpp b/backend/lib/CodeGen/MachineFunctionCloner.cpp index 0048194..1a66e66 100644 --- a/backend/lib/CodeGen/MachineFunctionCloner.cpp +++ b/backend/lib/CodeGen/MachineFunctionCloner.cpp @@ -202,6 +202,14 @@ cloneMemOperand(const MachineMemOperand &SourceOperand, CloneState &State) { if (!DestinationReg) return std::unexpected(DestinationReg.error()); + if (SourceInfo.Name) { + auto DestinationInfo = + State.Destination.registerInfo().virtualRegisterInfo(*DestinationReg); + if (!DestinationInfo) + return std::unexpected(DestinationInfo.error()); + DestinationInfo->get().Name = SourceInfo.Name; + } + if (SourceInfo.Bank) { auto SetResult = State.Destination.registerInfo().setRegisterBank(*DestinationReg, *SourceInfo.Bank); |
