[llvm-commits] CVS: llvm/lib/Transforms/IPO/GlobalOpt.cpp
Chris Lattner
lattner at cs.uiuc.edu
Wed Feb 23 08:53:11 PST 2005
Changes in directory llvm/lib/Transforms/IPO:
GlobalOpt.cpp updated: 1.35 -> 1.36
---
Log message:
make this more efficient. Scan up to 16 nodes, not the whole list.
---
Diffs of the changes: (+1 -1)
GlobalOpt.cpp | 2 +-
1 files changed, 1 insertion(+), 1 deletion(-)
Index: llvm/lib/Transforms/IPO/GlobalOpt.cpp
diff -u llvm/lib/Transforms/IPO/GlobalOpt.cpp:1.35 llvm/lib/Transforms/IPO/GlobalOpt.cpp:1.36
--- llvm/lib/Transforms/IPO/GlobalOpt.cpp:1.35 Thu Feb 10 12:36:30 2005
+++ llvm/lib/Transforms/IPO/GlobalOpt.cpp Wed Feb 23 10:52:58 2005
@@ -377,7 +377,7 @@
else
assert(0 && "Unknown aggregate sequential type!");
- if (NumElements > 16 && GV->getNumUses() > 16)
+ if (NumElements > 16 && GV->hasNUsesOrMore(16))
return 0; // It's not worth it.
NewGlobals.reserve(NumElements);
for (unsigned i = 0, e = NumElements; i != e; ++i) {
More information about the llvm-commits
mailing list