Correctly add an array marker on a node when appropriate!

llvm-svn: 12055
diff --git a/llvm/lib/Analysis/DataStructure/Local.cpp b/llvm/lib/Analysis/DataStructure/Local.cpp
index 471eeb9..dea8e9f 100644
--- a/llvm/lib/Analysis/DataStructure/Local.cpp
+++ b/llvm/lib/Analysis/DataStructure/Local.cpp
@@ -383,6 +383,10 @@
     if (const StructType *STy = dyn_cast<StructType>(*I)) {
       unsigned FieldNo = cast<ConstantUInt>(I.getOperand())->getValue();
       Offset += TD.getStructLayout(STy)->MemberOffsets[FieldNo];
+    } else if (const PointerType *PTy = dyn_cast<PointerType>(*I)) {
+      if (!isa<Constant>(I.getOperand()) ||
+          !cast<Constant>(I.getOperand())->isNullValue())
+        Value.getNode()->setArrayMarker();
     }