Changes in directory llvm/lib/Target:
TargetData.cpp updated: 1.70.4.1 -> 1.70.4.2 --- Log message: Make some simplifications for ConstantInt: 1. Get rid of getRawValue, replace with getZExtValue 2. Single constructor (uint64_t) and get method (int64_t) 3. Canonicalize the constant to a zero extended unsigned 64-bit integer when it is created. 4. Adjust getZExtValue() to be a do-nothing (just returns the already canonicalized value). 5. Compensate for above changes everywhere else. --- Diffs of the changes: (+1 -1) TargetData.cpp | 2 +- 1 files changed, 1 insertion(+), 1 deletion(-) Index: llvm/lib/Target/TargetData.cpp diff -u llvm/lib/Target/TargetData.cpp:1.70.4.1 llvm/lib/Target/TargetData.cpp:1.70.4.2 --- llvm/lib/Target/TargetData.cpp:1.70.4.1 Wed Oct 18 22:57:56 2006 +++ llvm/lib/Target/TargetData.cpp Thu Oct 19 19:34:43 2006 @@ -346,7 +346,7 @@ Ty = cast<SequentialType>(Ty)->getElementType(); // Get the array index and the size of each array element. - int64_t arrayIdx = cast<ConstantInt>(Idx[CurIDX])->getRawValue(); + int64_t arrayIdx = cast<ConstantInt>(Idx[CurIDX])->getZExtValue(); Result += arrayIdx * (int64_t)getTypeSize(Ty); } } _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits