1; RUN: opt < %s -passes=loop-vectorize -S | FileCheck %s 2 3; getDemandedBits() is called on the pointer-typed GEP instruction here. 4; Only make sure we do not crash. 5 6; CHECK: @test 7define void @test(ptr %ptr, ptr %ptr_end) { 8start: 9 br label %loop 10 11loop: 12 %ptr2 = phi ptr [ %ptr3, %loop ], [ %ptr, %start ] 13 %x = sext i8 undef to i64 14 %ptr3 = getelementptr inbounds i8, ptr %ptr2, i64 1 15 %cmp = icmp ult ptr %ptr3, %ptr_end 16 br i1 %cmp, label %loop, label %end 17 18end: 19 ret void 20} 21