[llvm-commits] CVS: llvm/lib/Analysis/DataStructure/DataStructure.cpp Local.cpp Printer.cpp
Chris Lattner
lattner at cs.uiuc.edu
Fri Oct 18 13:23:03 PDT 2002
Changes in directory llvm/lib/Analysis/DataStructure:
DataStructure.cpp updated: 1.24 -> 1.25
Local.cpp updated: 1.15 -> 1.16
Printer.cpp updated: 1.21 -> 1.22
---
Log message:
Convert typerec to be a structure instead of a pair
---
Diffs of the changes:
Index: llvm/lib/Analysis/DataStructure/DataStructure.cpp
diff -u llvm/lib/Analysis/DataStructure/DataStructure.cpp:1.24 llvm/lib/Analysis/DataStructure/DataStructure.cpp:1.25
--- llvm/lib/Analysis/DataStructure/DataStructure.cpp:1.24 Thu Oct 17 15:09:52 2002
+++ llvm/lib/Analysis/DataStructure/DataStructure.cpp Fri Oct 18 13:22:46 2002
@@ -61,7 +61,7 @@
}
}
- TypeEntries.push_back(std::make_pair(T, 0));
+ TypeEntries.push_back(TypeRec(T, 0));
}
// DSNode copy constructor... do not copy over the referrers list!
@@ -323,9 +323,9 @@
// If this merging into node has more than just void nodes in it, merge!
assert(!N->TypeEntries.empty() && "TypeEntries is empty for a node?");
- if (N->TypeEntries.size() != 1 || N->TypeEntries[0].first != Type::VoidTy) {
+ if (N->TypeEntries.size() != 1 || N->TypeEntries[0].Ty != Type::VoidTy) {
// If the current node just has a Void entry in it, remove it.
- if (TypeEntries.size() == 1 && TypeEntries[0].first == Type::VoidTy)
+ if (TypeEntries.size() == 1 && TypeEntries[0].Ty == Type::VoidTy)
TypeEntries.clear();
// Adjust all of the type entries we are merging in by the offset... and add
@@ -334,7 +334,7 @@
if (NOffset != 0) { // This case is common enough to optimize for
// Offset all of the TypeEntries in N with their new offset
for (unsigned i = 0, e = N->TypeEntries.size(); i != e; ++i)
- N->TypeEntries[i].second += NOffset;
+ N->TypeEntries[i].Offset += NOffset;
}
MergeSortedVectors(TypeEntries, N->TypeEntries);
Index: llvm/lib/Analysis/DataStructure/Local.cpp
diff -u llvm/lib/Analysis/DataStructure/Local.cpp:1.15 llvm/lib/Analysis/DataStructure/Local.cpp:1.16
--- llvm/lib/Analysis/DataStructure/Local.cpp:1.15 Thu Oct 17 17:13:19 2002
+++ llvm/lib/Analysis/DataStructure/Local.cpp Fri Oct 18 13:22:46 2002
@@ -413,4 +413,3 @@
DSInfo.insert(std::make_pair(I, new DSGraph(*I)));
return false;
}
-
Index: llvm/lib/Analysis/DataStructure/Printer.cpp
diff -u llvm/lib/Analysis/DataStructure/Printer.cpp:1.21 llvm/lib/Analysis/DataStructure/Printer.cpp:1.22
--- llvm/lib/Analysis/DataStructure/Printer.cpp:1.21 Thu Oct 17 17:13:28 2002
+++ llvm/lib/Analysis/DataStructure/Printer.cpp Fri Oct 18 13:22:46 2002
@@ -28,9 +28,9 @@
Module *M = G && &G->getFunction() ? G->getFunction().getParent() : 0;
for (unsigned i = 0, e = N->getTypeEntries().size(); i != e; ++i) {
- WriteTypeSymbolic(OS, N->getTypeEntries()[i].first, M);
- if (N->getTypeEntries()[i].second)
- OS << "@" << N->getTypeEntries()[i].second;
+ WriteTypeSymbolic(OS, N->getTypeEntries()[i].Ty, M);
+ if (N->getTypeEntries()[i].Offset)
+ OS << "@" << N->getTypeEntries()[i].Offset;
OS << "\n";
}
More information about the llvm-commits
mailing list