aboutsummaryrefslogtreecommitdiff
path: root/lib/ExecutionEngine/Interpreter/Execution.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/ExecutionEngine/Interpreter/Execution.cpp')
-rw-r--r--lib/ExecutionEngine/Interpreter/Execution.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ExecutionEngine/Interpreter/Execution.cpp b/lib/ExecutionEngine/Interpreter/Execution.cpp
index 909f568a58..ac011d743b 100644
--- a/lib/ExecutionEngine/Interpreter/Execution.cpp
+++ b/lib/ExecutionEngine/Interpreter/Execution.cpp
@@ -823,7 +823,7 @@ static GenericValue executeGEPOperation(Value *Ptr, User::op_iterator I,
// Get the index number for the array... which must be uint type...
assert((*I)->getType() == Type::LongTy);
- unsigned Idx = getOperandValue(*I, SF).UIntVal;
+ unsigned Idx = getOperandValue(*I, SF).LongVal;
if (const ArrayType *AT = dyn_cast<ArrayType>(ST))
if (Idx >= AT->getNumElements() && ArrayChecksEnabled) {
cerr << "Out of range memory access to element #" << Idx