[llvm-branch-commits] [llvm-branch] r236116 - Correct syntax of getelementptr in regression test. NFC
Pawel Bylica
chfast at gmail.com
Wed Apr 29 09:05:29 PDT 2015
Author: chfast
Date: Wed Apr 29 11:05:29 2015
New Revision: 236116
URL: http://llvm.org/viewvc/llvm-project?rev=236116&view=rev
Log:
Correct syntax of getelementptr in regression test. NFC
Bonus: unused variable removed.
Modified:
llvm/branches/release_36/lib/Transforms/Utils/SimplifyIndVar.cpp
llvm/branches/release_36/test/CodeGen/X86/getelementptr.ll
Modified: llvm/branches/release_36/lib/Transforms/Utils/SimplifyIndVar.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_36/lib/Transforms/Utils/SimplifyIndVar.cpp?rev=236116&r1=236115&r2=236116&view=diff
==============================================================================
--- llvm/branches/release_36/lib/Transforms/Utils/SimplifyIndVar.cpp (original)
+++ llvm/branches/release_36/lib/Transforms/Utils/SimplifyIndVar.cpp Wed Apr 29 11:05:29 2015
@@ -288,14 +288,11 @@ bool SimplifyIndvar::strengthenOverflowi
IntegerType *IT = cast<IntegerType>(IVOperand->getType());
Value *OtherOperand = nullptr;
- int OtherOperandIdx = -1;
if (BO->getOperand(0) == IVOperand) {
OtherOperand = BO->getOperand(1);
- OtherOperandIdx = 1;
} else {
assert(BO->getOperand(1) == IVOperand && "only other use!");
OtherOperand = BO->getOperand(0);
- OtherOperandIdx = 0;
}
bool Changed = false;
Modified: llvm/branches/release_36/test/CodeGen/X86/getelementptr.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/release_36/test/CodeGen/X86/getelementptr.ll?rev=236116&r1=236115&r2=236116&view=diff
==============================================================================
--- llvm/branches/release_36/test/CodeGen/X86/getelementptr.ll (original)
+++ llvm/branches/release_36/test/CodeGen/X86/getelementptr.ll Wed Apr 29 11:05:29 2015
@@ -9,35 +9,35 @@
define i8* @test_trunc65(i8* %ptr) nounwind {
; CHECK-LABEL: test_trunc65
; CHECK: 3
- %d = getelementptr i8, i8* %ptr, i65 18446744073709551619 ; 2^64 + 3
+ %d = getelementptr i8* %ptr, i65 18446744073709551619 ; 2^64 + 3
ret i8* %d
}
define i8* @test_trunc128(i8* %ptr) nounwind {
; CHECK-LABEL: test_trunc128
; CHECK: 5
- %d = getelementptr i8, i8* %ptr, i128 18446744073709551621 ; 2^64 + 5
+ %d = getelementptr i8* %ptr, i128 18446744073709551621 ; 2^64 + 5
ret i8* %d
}
define i8* @test_trunc160(i8* %ptr) nounwind {
; CHECK-LABEL: test_trunc160
; CHECK: 8
- %d = getelementptr i8, i8* %ptr, i160 18446744073709551624 ; 2^64 + 8
+ %d = getelementptr i8* %ptr, i160 18446744073709551624 ; 2^64 + 8
ret i8* %d
}
define i8* @test_trunc256(i8* %ptr) nounwind {
; CHECK-LABEL: test_trunc256
; CHECK: 13
- %d = getelementptr i8, i8* %ptr, i256 18446744073709551629 ; 2^64 + 13
+ %d = getelementptr i8* %ptr, i256 18446744073709551629 ; 2^64 + 13
ret i8* %d
}
define i8* @test_trunc2048(i8* %ptr) nounwind {
; CHECK-LABEL: test_trunc2048
; CHECK: 21
- %d = getelementptr i8, i8* %ptr, i2048 18446744073709551637 ; 2^64 + 21
+ %d = getelementptr i8* %ptr, i2048 18446744073709551637 ; 2^64 + 21
ret i8* %d
}
@@ -47,34 +47,34 @@ define i8* @test_trunc2048(i8* %ptr) nou
define i8* @test_sext3(i8* %ptr) nounwind {
; CHECK-LABEL: test_sext3
; CHECK: -3
- %d = getelementptr i8, i8* %ptr, i3 -3
+ %d = getelementptr i8* %ptr, i3 -3
ret i8* %d
}
define i8* @test_sext5(i8* %ptr) nounwind {
; CHECK-LABEL: test_sext5
; CHECK: -5
- %d = getelementptr i8, i8* %ptr, i5 -5
+ %d = getelementptr i8* %ptr, i5 -5
ret i8* %d
}
define i8* @test_sext8(i8* %ptr) nounwind {
; CHECK-LABEL: test_sext8
; CHECK: -8
- %d = getelementptr i8, i8* %ptr, i8 -8
+ %d = getelementptr i8* %ptr, i8 -8
ret i8* %d
}
define i8* @test_sext13(i8* %ptr) nounwind {
; CHECK-LABEL: test_sext13
; CHECK: -13
- %d = getelementptr i8, i8* %ptr, i8 -13
+ %d = getelementptr i8* %ptr, i8 -13
ret i8* %d
}
define i8* @test_sext16(i8* %ptr) nounwind {
; CHECK-LABEL: test_sext16
; CHECK: -21
- %d = getelementptr i8, i8* %ptr, i8 -21
+ %d = getelementptr i8* %ptr, i8 -21
ret i8* %d
}
More information about the llvm-branch-commits
mailing list