summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/DataStructure
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-04-05 01:30:19 +0000
committerChris Lattner <sabre@nondot.org>2004-04-05 01:30:19 +0000
commit69193f93b689d3cc03ec9e685d662003d06134ea (patch)
treeed36e2aa107383c32cc79bfb71deb1547afed277 /llvm/lib/Analysis/DataStructure
parentfd9fbe187d9d4143f07f575f0722f185ab0ce945 (diff)
downloadbcm5719-llvm-69193f93b689d3cc03ec9e685d662003d06134ea.tar.gz
bcm5719-llvm-69193f93b689d3cc03ec9e685d662003d06134ea.zip
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. llvm-svn: 12653
Diffstat (limited to 'llvm/lib/Analysis/DataStructure')
-rw-r--r--llvm/lib/Analysis/DataStructure/Local.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/llvm/lib/Analysis/DataStructure/Local.cpp b/llvm/lib/Analysis/DataStructure/Local.cpp
index 26bd17bde3f..c969cc6621b 100644
--- a/llvm/lib/Analysis/DataStructure/Local.cpp
+++ b/llvm/lib/Analysis/DataStructure/Local.cpp
@@ -350,7 +350,8 @@ void GraphBuilder::visitGetElementPtrInst(User &GEP) {
#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) {
OpenPOWER on IntegriCloud