[llvm-commits] CVS: llvm/lib/Analysis/DataStructure/Local.cpp

Chris Lattner lattner at cs.uiuc.edu
Sun Apr 4 20:29:37 PDT 2004


Changes in directory llvm/lib/Analysis/DataStructure:

Local.cpp updated: 1.101 -> 1.102

---
Log message:

Support getelementptr instructions which use uint's to index into structure 
types and can have arbitrary 32- and 64-bit integer types indexing into 
sequential types.



---
Diffs of the changes:  (+2 -1)

Index: llvm/lib/Analysis/DataStructure/Local.cpp
diff -u llvm/lib/Analysis/DataStructure/Local.cpp:1.101 llvm/lib/Analysis/DataStructure/Local.cpp:1.102
--- llvm/lib/Analysis/DataStructure/Local.cpp:1.101	Fri Mar 12 18:23:25 2004
+++ llvm/lib/Analysis/DataStructure/Local.cpp	Sun Apr  4 20:28:23 2004
@@ -350,7 +350,8 @@
 #if 0
   // Handle the pointer index specially...
   if (GEP.getNumOperands() > 1 &&
-      GEP.getOperand(1) != ConstantSInt::getNullValue(Type::LongTy)) {
+      (!isa<Constant>(GEP.getOperand(1)) ||
+       !cast<Constant>(GEP.getOperand(1))->isNullValue())) {
 
     // If we already know this is an array being accessed, don't do anything...
     if (!TopTypeRec.isArray) {





More information about the llvm-commits mailing list