[PATCH] D55238: MIR: Preserve incoming frame index numbers
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 4 12:35:14 PST 2018
arsenm updated this revision to Diff 176692.
arsenm added a comment.
Attach correct patch
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D55238/new/
https://reviews.llvm.org/D55238
Files:
lib/CodeGen/MIRPrinter.cpp
Index: lib/CodeGen/MIRPrinter.cpp
===================================================================
--- lib/CodeGen/MIRPrinter.cpp
+++ lib/CodeGen/MIRPrinter.cpp
@@ -352,7 +352,7 @@
const TargetRegisterInfo *TRI = MF.getSubtarget().getRegisterInfo();
// Process fixed stack objects.
unsigned ID = 0;
- for (int I = MFI.getObjectIndexBegin(); I < 0; ++I) {
+ for (int I = MFI.getObjectIndexBegin(); I < 0; ++I, ++ID) {
if (MFI.isDeadObjectIndex(I))
continue;
@@ -369,12 +369,12 @@
YamlObject.IsAliased = MFI.isAliasedObjectIndex(I);
YMF.FixedStackObjects.push_back(YamlObject);
StackObjectOperandMapping.insert(
- std::make_pair(I, FrameIndexOperand::createFixed(ID++)));
+ std::make_pair(I, FrameIndexOperand::createFixed(ID)));
}
// Process ordinary stack objects.
ID = 0;
- for (int I = 0, E = MFI.getObjectIndexEnd(); I < E; ++I) {
+ for (int I = 0, E = MFI.getObjectIndexEnd(); I < E; ++I, ++ID) {
if (MFI.isDeadObjectIndex(I))
continue;
@@ -395,7 +395,7 @@
YMF.StackObjects.push_back(YamlObject);
StackObjectOperandMapping.insert(std::make_pair(
- I, FrameIndexOperand::create(YamlObject.Name.Value, ID++)));
+ I, FrameIndexOperand::create(YamlObject.Name.Value, ID)));
}
for (const auto &CSInfo : MFI.getCalleeSavedInfo()) {
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D55238.176692.patch
Type: text/x-patch
Size: 1348 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181204/e6f33720/attachment.bin>
More information about the llvm-commits
mailing list