1; RUN: llc -verify-machineinstrs < %s -mtriple=powerpc64-unknown-linux-gnu -mcpu=pwr7 2 3define void @test1(i1 %x, i8 %x2, ptr %x3, i64 %x4) { 4entry: 5 %tmp3 = and i64 %x4, 16 6 %bf.shl = trunc i64 %tmp3 to i8 7 %bf.clear = and i8 %x2, -17 8 %bf.set = or i8 %bf.shl, %bf.clear 9 br i1 %x, label %if.then, label %if.end 10 11if.then: 12 ret void 13 14if.end: 15 store i8 %bf.set, ptr %x3, align 4 16 ret void 17} 18 19; A BUILD_VECTOR of 1 element caused a crash in combineBVOfConsecutiveLoads() 20; Test that this is no longer the case 21define signext i32 @test2() { 22entry: 23 %retval = alloca i32, align 4 24 %__a = alloca i128, align 16 25 %b = alloca i64, align 8 26 store i32 0, ptr %retval, align 4 27 %0 = load i128, ptr %__a, align 16 28 %splat.splatinsert = insertelement <1 x i128> undef, i128 %0, i32 0 29 %splat.splat = shufflevector <1 x i128> %splat.splatinsert, <1 x i128> undef, <1 x i32> zeroinitializer 30 %1 = bitcast <1 x i128> %splat.splat to <2 x i64> 31 %2 = extractelement <2 x i64> %1, i32 0 32 store i64 %2, ptr %b, align 8 33 ret i32 0 34} 35