Lines Matching full:builder
60 return CGF.Builder.CreatePtrToInt(V, IntType);
71 return CGF.Builder.CreateIntToPtr(V, ResultType);
97 Args[0] = CGF.Builder.CreateBitCast(DestPtr, IntPtrType);
103 CGF.Builder.CreateAtomicRMW(Kind, Args[0], Args[1],
134 Args[0] = CGF.Builder.CreateBitCast(DestPtr, IntPtrType);
137 CGF.Builder.CreateAtomicRMW(Kind, Args[0], Args[1],
139 Result = CGF.Builder.CreateBinOp(Op, Result, Args[1]);
191 llvm::Value *Tmp = CGF.Builder.CreateCall2(Callee, X, Y);
192 Carry = CGF.Builder.CreateExtractValue(Tmp, 1);
193 return CGF.Builder.CreateExtractValue(Tmp, 0);
221 ArgValue = Builder.CreateBitCast(ArgValue, DestType,
226 return RValue::get(Builder.CreateCall(CGM.getIntrinsic(inst), ArgValue));
234 DstPtr = Builder.CreateBitCast(DstPtr, Type);
235 SrcPtr = Builder.CreateBitCast(SrcPtr, Type);
236 return RValue::get(Builder.CreateCall2(CGM.getIntrinsic(Intrinsic::vacopy),
244 Value *NegOp = Builder.CreateNeg(ArgValue, "neg");
246 Builder.CreateICmpSGE(ArgValue,
250 Builder.CreateSelect(CmpResult, ArgValue, NegOp, "abs");
266 Imag = Builder.CreateFSub(Zero, Imag, "sub");
299 Value *ZeroUndef = Builder.getInt1(getTarget().isCLZForZeroUndef());
300 Value *Result = Builder.CreateCall2(F, ArgValue, ZeroUndef);
302 Result = Builder.CreateIntCast(Result, ResultType, /*isSigned*/true,
316 Value *ZeroUndef = Builder.getInt1(getTarget().isCLZForZeroUndef());
317 Value *Result = Builder.CreateCall2(F, ArgValue, ZeroUndef);
319 Result = Builder.CreateIntCast(Result, ResultType, /*isSigned*/true,
333 Value *Tmp = Builder.CreateAdd(Builder.CreateCall2(F, ArgValue,
334 Builder.getTrue()),
337 Value *IsZero = Builder.CreateICmpEQ(ArgValue, Zero, "iszero");
338 Value *Result = Builder.CreateSelect(IsZero, Zero, Tmp, "ffs");
340 Result = Builder.CreateIntCast(Result, ResultType, /*isSigned*/true,
354 Value *Tmp = Builder.CreateCall(F, ArgValue);
355 Value *Result = Builder.CreateAnd(Tmp, llvm::ConstantInt::get(ArgType, 1));
357 Result = Builder.CreateIntCast(Result, ResultType, /*isSigned*/true,
370 Value *Result = Builder.CreateCall(F, ArgValue);
372 Result = Builder.CreateIntCast(Result, ResultType, /*isSigned*/true,
383 Value *Result = Builder.CreateCall2(FnExpect, ArgValue, ExpectedValue,
393 return RValue::get(Builder.CreateCall(F, ArgValue));
410 CI = ConstantInt::get(Builder.getInt1Ty(), (val & 0x2) >> 1);
413 return RValue::get(Builder.CreateCall2(F, EmitScalarExpr(E->getArg(0)),CI));
424 return RValue::get(Builder.CreateCall4(F, Address, RW, Locality, Data));
428 return RValue::get(Builder.CreateCall(F));
432 return RValue::get(Builder.CreateCall(F));
436 return RValue::get(Builder.CreateCall(F));
440 EmitCheck(Builder.getFalse(), "builtin_unreachable",
444 Builder.CreateUnreachable();
459 return RValue::get(Builder.CreateCall2(F, Base, Exponent));
476 LHS = Builder.CreateFCmpOGT(LHS, RHS, "cmp");
479 LHS = Builder.CreateFCmpOGE(LHS, RHS, "cmp");
482 LHS = Builder.CreateFCmpOLT(LHS, RHS, "cmp");
485 LHS = Builder.CreateFCmpOLE(LHS, RHS, "cmp");
488 LHS = Builder.CreateFCmpONE(LHS, RHS, "cmp");
491 LHS = Builder.CreateFCmpUNO(LHS, RHS, "cmp");
495 return RValue::get(Builder.CreateZExt(LHS, ConvertType(E->getType())));
499 V = Builder.CreateFCmpUNO(V, V, "cmp");
500 return RValue::get(Builder.CreateZExt(V, ConvertType(E->getType())));
508 V = Builder.CreateFCmpOEQ(V, ConstantFP::getInfinity(V->getType()),"isinf");
509 return RValue::get(Builder.CreateZExt(V, ConvertType(E->getType())));
518 Value *Eq = Builder.CreateFCmpOEQ(V, V, "iseq");
522 Builder.CreateFCmpULT(Abs, ConstantFP::getInfinity(V->getType()),"isinf");
526 Builder.CreateFCmpUGE(Abs, ConstantFP::get(V->getContext(), Smallest),
528 V = Builder.CreateAnd(Eq, IsLessThanInf, "and");
529 V = Builder.CreateAnd(V, IsNormal, "and");
530 return RValue::get(Builder.CreateZExt(V, ConvertType(E->getType())));
536 Value *Eq = Builder.CreateFCmpOEQ(V, V, "iseq");
540 Builder.CreateFCmpUNE(Abs, ConstantFP::getInfinity(V->getType()),"isinf");
542 V = Builder.CreateAnd(Eq, IsNotInf, "and");
543 return RValue::get(Builder.CreateZExt(V, ConvertType(E->getType())));
551 BasicBlock *Begin = Builder.GetInsertBlock();
553 Builder.SetInsertPoint(End);
555 Builder.CreatePHI(ConvertType(E->getArg(0)->getType()), 4,
559 Builder.SetInsertPoint(Begin);
560 Value *IsZero = Builder.CreateFCmpOEQ(V, Constant::getNullValue(Ty),
564 Builder.CreateCondBr(IsZero, End, NotZero);
568 Builder.SetInsertPoint(NotZero);
569 Value *IsNan = Builder.CreateFCmpUNO(V, V, "cmp");
572 Builder.CreateCondBr(IsNan, End, NotNan);
576 Builder.SetInsertPoint(NotNan);
579 Builder.CreateFCmpOEQ(VAbs, ConstantFP::getInfinity(V->getType()),
583 Builder.CreateCondBr(IsInf, End, NotInf);
587 Builder.SetInsertPoint(NotInf);
591 Builder.CreateFCmpUGE(VAbs, ConstantFP::get(V->getContext(), Smallest),
594 Builder.CreateSelect(IsNormal, EmitScalarExpr(E->getArg(2)),
596 Builder.CreateBr(End);
600 Builder.SetInsertPoint(End);
607 return RValue::get(Builder.CreateAlloca(Builder.getInt8Ty(), Size));
614 Builder.CreateMemSet(Dest.first, Builder.getInt8(0), SizeVal,
626 Builder.CreateMemCpy(Dest.first, Src.first, SizeVal, Align, false);
642 Value *SizeVal = llvm::ConstantInt::get(Builder.getContext(), Size);
644 Builder.CreateMemCpy(Dest.first, Src.first, SizeVal, Align, false);
669 Value *SizeVal = llvm::ConstantInt::get(Builder.getContext(), Size);
671 Builder.CreateMemMove(Dest.first, Src.first, SizeVal, Align, false);
683 Builder.CreateMemMove(Dest.first, Src.first, SizeVal, Align, false);
690 Value *ByteVal = Builder.CreateTrunc(EmitScalarExpr(E->getArg(1)),
691 Builder.getInt8Ty());
693 Builder.CreateMemSet(Dest.first, ByteVal, SizeVal, Dest.second, false);
706 Value *ByteVal = Builder.CreateTrunc(EmitScalarExpr(E->getArg(1)),
707 Builder.getInt8Ty());
708 Value *SizeVal = llvm::ConstantInt::get(Builder.getContext(), Size);
709 Builder.CreateMemSet(Dest.first, ByteVal, SizeVal, Dest.second, false);
724 return RValue::get(Builder.CreateCall(F,
729 Depth = Builder.CreateIntCast(Depth, Int32Ty, false);
731 return RValue::get(Builder.CreateCall(F, Depth));
735 Depth = Builder.CreateIntCast(Depth, Int32Ty, false);
737 return RValue::get(Builder.CreateCall(F, Depth));
775 Builder.CreateCall2(F, Int, Ptr);
776 Builder.CreateUnreachable();
785 return RValue::get(Builder.CreateCall(F));
800 Value *Result = Builder.CreatePtrToInt(Ptr, IntPtrTy, "extend.cast");
808 return RValue::get(Builder.CreateSExt(Result, Int64Ty, "extend.sext"));
810 return RValue::get(Builder.CreateZExt(Result, Int64Ty, "extend.zext"));
818 Builder.CreateCall(CGM.getIntrinsic(Intrinsic::frameaddress),
820 Builder.CreateStore(FrameAddr, Buf);
824 Builder.CreateCall(CGM.getIntrinsic(Intrinsic::stacksave));
826 Builder.CreateGEP(Buf, ConstantInt::get(Int32Ty, 2));
827 Builder.CreateStore(StackAddr, StackSaveSlot);
831 Buf = Builder.CreateBitCast(Buf, Int8PtrTy);
832 return RValue::get(Builder.CreateCall(F, Buf));
836 Buf = Builder.CreateBitCast(Buf, Int8PtrTy);
839 Builder.CreateCall(CGM.getIntrinsic(Intrinsic::eh_sjlj_longjmp), Buf);
842 Builder.CreateUnreachable();
957 Args[0] = Builder.CreateBitCast(DestPtr, IntPtrType);
963 Value *Result = Builder.CreateAtomicCmpXchg(Args[0], Args[1], Args[2],
984 Args[0] = Builder.CreateBitCast(DestPtr, IntPtrType);
989 Value *PrevVal = Builder.CreateAtomicCmpXchg(Args[0], Args[1], Args[2],
991 Value *Result = Builder.CreateICmpEQ(PrevVal, OldVal);
993 Result = Builder.CreateZExt(Result, ConvertType(E->getType()));
1021 Ptr = Builder.CreateBitCast(Ptr, ITy->getPointerTo());
1023 Builder.CreateStore(llvm::Constant::getNullValue(ITy), Ptr);
1037 Builder.CreateFence(llvm::SequentiallyConsistent);
1074 Ptr = Builder.CreateBitCast(Ptr, Int8Ty->getPointerTo(AddrSpace));
1075 Value *NewVal = Builder.getInt8(1);
1083 Result = Builder.CreateAtomicRMW(llvm::AtomicRMWInst::Xchg,
1089 Result = Builder.CreateAtomicRMW(llvm::AtomicRMWInst::Xchg,
1094 Result = Builder.CreateAtomicRMW(llvm::AtomicRMWInst::Xchg,
1099 Result = Builder.CreateAtomicRMW(llvm::AtomicRMWInst::Xchg,
1104 Result = Builder.CreateAtomicRMW(llvm::AtomicRMWInst::Xchg,
1110 return RValue::get(Builder.CreateIsNotNull(Result, "tobool"));
1127 Order = Builder.CreateIntCast(Order, Builder.getInt32Ty(), false);
1128 llvm::SwitchInst *SI = Builder.CreateSwitch(Order, BBs[0]);
1130 Builder.SetInsertPoint(ContBB);
1131 PHINode *Result = Builder.CreatePHI(Int8Ty, 5, "was_set");
1134 Builder.SetInsertPoint(BBs[i]);
1135 AtomicRMWInst *RMW = Builder.CreateAtomicRMW(llvm::AtomicRMWInst::Xchg,
1139 Builder.CreateBr(ContBB);
1142 SI->addCase(Builder.getInt32(0), BBs[0]);
1143 SI->addCase(Builder.getInt32(1), BBs[1]);
1144 SI->addCase(Builder.getInt32(2), BBs[1]);
1145 SI->addCase(Builder.getInt32(3), BBs[2]);
1146 SI->addCase(Builder.getInt32(4), BBs[3]);
1147 SI->addCase(Builder.getInt32(5), BBs[4]);
1149 Builder.SetInsertPoint(ContBB);
1150 return RValue::get(Builder.CreateIsNotNull(Result, "tobool"));
1160 Ptr = Builder.CreateBitCast(Ptr, Int8Ty->getPointerTo(AddrSpace));
1161 Value *NewVal = Builder.getInt8(0);
1165 StoreInst *Store = Builder.CreateStore(NewVal, Ptr, Volatile);
1193 Order = BuilderBuilder.getInt32Ty(), false);
1194 llvm::SwitchInst *SI = Builder.CreateSwitch(Order, BBs[0]);
1197 Builder.SetInsertPoint(BBs[i]);
1198 StoreInst *Store = Builder.CreateStore(NewVal, Ptr, Volatile);
1201 Builder.CreateBr(ContBB);
1204 SI->addCase(Builder.getInt32(0), BBs[0]);
1205 SI->addCase(Builder.getInt32(3), BBs[1]);
1206 SI->addCase(Builder.getInt32(5), BBs[2]);
1208 Builder.SetInsertPoint(ContBB);
1231 Builder.CreateFence(llvm::Acquire, Scope);
1234 Builder.CreateFence(llvm::Release, Scope);
1237 Builder.CreateFence(llvm::AcquireRelease, Scope);
1240 Builder.CreateFence(llvm::SequentiallyConsistent, Scope);
1253 Order = Builder.CreateIntCast(Order, Builder.getInt32Ty(), false);
1254 llvm::SwitchInst *SI = Builder.CreateSwitch(Order, ContBB);
1256 Builder.SetInsertPoint(AcquireBB);
1257 Builder.CreateFence(llvm::Acquire, Scope);
1258 Builder.CreateBr(ContBB);
1259 SI->addCase(Builder.getInt32(1), AcquireBB);
1260 SI->addCase(Builder.getInt32(2), AcquireBB);
1262 Builder.SetInsertPoint(ReleaseBB);
1263 Builder.CreateFence(llvm::Release, Scope);
1264 Builder.CreateBr(ContBB);
1265 SI->addCase(Builder.getInt32(3), ReleaseBB);
1267 Builder.SetInsertPoint(AcqRelBB);
1268 Builder.CreateFence(llvm::AcquireRelease, Scope);
1269 Builder.CreateBr(ContBB);
1270 SI->addCase(Builder.getInt32(4), AcqRelBB);
1272 Builder.SetInsertPoint(SeqCstBB);
1273 Builder.CreateFence(llvm::SequentiallyConsistent, Scope);
1274 Builder.CreateBr(ContBB);
1275 SI->addCase(Builder.getInt32(5), SeqCstBB);
1277 Builder.SetInsertPoint(ContBB);
1303 return RValue::get(Builder.CreateCall2(F, Base, Exponent));
1317 return RValue::get(Builder.CreateCall3(F, FirstArg,
1333 Value *BCArg = Builder.CreateBitCast(Arg, ArgIntTy);
1335 Value *Result = Builder.CreateICmpSLT(BCArg, ZeroCmp);
1336 return RValue::get(Builder.CreateZExt(Result, ConvertType(E->getType())));
1411 llvm::Value *CarryOut = Builder.CreateZExt(Builder.CreateOr(Carry1, Carry2),
1413 llvm::StoreInst *CarryOutStore = Builder.CreateStore(CarryOut,
1484 llvm::StoreInst *SumOutStore = Builder.CreateStore(Sum, SumOutPtr.first);
1548 ArgValue = Builder.CreateBitCast(ArgValue, PTy);
1554 Value *V = Builder.CreateCall(F, Args);
1564 V = Builder.CreateBitCast(V, RetTy);
1626 return Builder.CreateShuffleVector(V, V, SV, "lane");
1638 Ops[j] = Builder.CreateBitCast(Ops[j], ai->getType(), name);
1640 return Builder.CreateCall(F, Ops, name);
1664 Ptr.first = Builder.CreateBitCast(Ptr.first,
1870 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
1871 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
1872 Ops[1] = Builder.CreateFNeg(Ops[1]);
1873 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
1877 return Builder.CreateCall3(F, Ops[1], Ops[2], Ops[0]);
1939 Value *Val = Builder.CreateCall(F, Builder.CreateBitCast(LdPtr, Int8PtrTy),
1942 Value *Val0 = Builder.CreateExtractValue(Val, 1);
1943 Value *Val1 = Builder.CreateExtractValue(Val, 0);
1944 Val0 = Builder.CreateZExt(Val0, Int64Ty);
1945 Val1 = Builder.CreateZExt(Val1, Int64Ty);
1948 Val = Builder.CreateShl(Val0, ShiftCst, "shl", true /* nuw */);
1949 Val = Builder.CreateOr(Val, Val1);
1950 return Builder.CreateBitCast(Val, ConvertType(E->getType()));
1960 LoadAddr = Builder.CreateBitCast(LoadAddr, IntResTy->getPointerTo());
1963 Value *Val = Builder.CreateCall(F, LoadAddr, "ldrex");
1966 return Builder.CreateIntToPtr(Val, RealResTy);
1968 Val = Builder.CreateTruncOrBitCast(Val, IntResTy);
1969 return Builder.CreateBitCast(Val, RealResTy);
1980 Value *Tmp = Builder.CreateAlloca(ConvertType(E->getArg(0)->getType()),
1983 Builder.CreateStore(Val, Tmp);
1985 Value *LdPtr = Builder.CreateBitCast(Tmp,llvm::PointerType::getUnqual(STy));
1986 Val = Builder.CreateLoad(LdPtr);
1988 Value *Arg0 = Builder.CreateExtractValue(Val, 0);
1989 Value *Arg1 = Builder.CreateExtractValue(Val, 1);
1990 Value *StPtr = Builder.CreateBitCast(EmitScalarExpr(E->getArg(1)), Int8PtrTy);
1991 return Builder.CreateCall3(F, Arg0, Arg1, StPtr, "strexd");
2001 StoreAddr = Builder.CreateBitCast(StoreAddr, StoreTy->getPointerTo());
2004 StoreVal = Builder.CreatePtrToInt(StoreVal, Int32Ty);
2006 StoreVal = Builder.CreateBitCast(StoreVal, StoreTy);
2007 StoreVal = Builder.CreateZExtOrBitCast(StoreVal, Int32Ty);
2011 return Builder.CreateCall2(F, StoreVal, StoreAddr, "strex");
2016 return Builder.CreateCall(F);
2051 Align = Builder.getInt32(Src.second);
2077 Align = Builder.getInt32(Src.second);
2098 return Builder.CreateExtractElement(Ops[0], EmitScalarExpr(E->getArg(1)),
2111 return Builder.CreateInsertElement(Ops[1], Ops[0], Ops[2], "vset_lane");
2135 return Builder.CreateCall(F, Ops, "vcvtr");
2201 Ops.push_back(Builder.getInt1(getTarget().isCLZForZeroUndef()));
2224 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2226 return usgn ? Builder.CreateUIToFP(Ops[0], Ty, "vcvt")
2227 : Builder.CreateSIToFP(Ops[0], Ty, "vcvt");
2234 Ops[0] = Builder.CreateBitCast(Ops[0], FloatTy);
2235 return usgn ? Builder.CreateFPToUI(Ops[0], Ty, "vcvt")
2236 : Builder.CreateFPToSI(Ops[0], Ty, "vcvt");
2267 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2268 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2270 return Builder.CreateShuffleVector(Ops[0], Ops[1], SV, "vext");
2290 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2293 Ops[1] = Builder.CreateShuffleVector(Ops[1], Ops[1], SV);
2297 Value *Ld = Builder.CreateCall2(F, Ops[0], Align);
2303 return Builder.CreateShuffleVector(Ops[1], Ld, SV, "vld1q_lane");
2307 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2309 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2310 LoadInst *Ld = Builder.CreateLoad(Ops[0]);
2312 return Builder.CreateInsertElement(Ops[1], Ld, Ops[2], "vld1_lane");
2318 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2319 LoadInst *Ld = Builder.CreateLoad(Ops[0]);
2322 Ops[0] = Builder.CreateInsertElement(V, Ld, CI);
2328 Ops[1] = Builder.CreateCall2(F, Ops[1], Align, "vld2");
2330 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2331 return Builder.CreateStore(Ops[1], Ops[0]);
2336 Ops[1] = Builder.CreateCall2(F, Ops[1], Align, "vld3");
2338 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2339 return Builder.CreateStore(Ops[1], Ops[0]);
2344 Ops[1] = Builder.CreateCall2(F, Ops[1], Align, "vld4");
2346 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2347 return Builder.CreateStore(Ops[1], Ops[0]);
2352 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
2353 Ops[3] = Builder.CreateBitCast(Ops[3], Ty);
2355 Ops[1] = Builder.CreateCall(F, makeArrayRef(Ops).slice(1), "vld2_lane");
2357 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2358 return Builder.CreateStore(Ops[1], Ops[0]);
2363 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
2364 Ops[3] = Builder.CreateBitCast(Ops[3], Ty);
2365 Ops[4] = Builder.CreateBitCast(Ops[4], Ty);
2367 Ops[1] = Builder.CreateCall(F, makeArrayRef(Ops).slice(1), "vld3_lane");
2369 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2370 return Builder.CreateStore(Ops[1], Ops[0]);
2375 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
2376 Ops[3] = Builder.CreateBitCast(Ops[3], Ty);
2377 Ops[4] = Builder.CreateBitCast(Ops[4], Ty);
2378 Ops[5] = Builder.CreateBitCast(Ops[5], Ty);
2380 Ops[1] = Builder.CreateCall(F, makeArrayRef(Ops).slice(1), "vld3_lane");
2382 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2383 return Builder.CreateStore(Ops[1], Ops[0]);
2403 Ops[1] = Builder.CreateCall2(F, Ops[1], Align, "vld_dup");
2405 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2406 return Builder.CreateStore(Ops[1], Ops[0]);
2431 Ops[1] = Builder.CreateCall(F, Args, "vld_dup");
2434 Value *Val = Builder.CreateExtractValue(Ops[1], i);
2435 Value *Elt = Builder.CreateBitCast(Val, Ty);
2437 Elt = Builder.CreateBitCast(Elt, Val->getType());
2438 Ops[1] = Builder.CreateInsertValue(Ops[1], Elt, i);
2441 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2442 return Builder.CreateStore(Ops[1], Ops[0]);
2454 Ops[0] = Builder.CreateBitCast(Ops[0], DTy);
2456 return Builder.CreateZExt(Ops[0], Ty, "vmovl");
2457 return Builder.CreateSExt(Ops[0], Ty, "vmovl");
2461 Ops[0] = Builder.CreateBitCast(Ops[0], QTy);
2462 return Builder.CreateTrunc(Ops[0], Ty, "vmovn");
2476 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2477 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2478 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
2481 return Builder.CreateCall3(F, Ops[1], Ops[2], Ops[0]);
2622 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2623 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2626 Ops[1] = Builder.CreateCall2(CGM.getIntrinsic(Int, Ty), Ops[1], Ops[2]);
2627 return Builder.CreateAdd(Ops[0], Ops[1], "vrsra_n");
2641 return Builder.CreateShl(Builder.CreateBitCast(Ops[0],Ty), Ops[1],
2648 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2651 return Builder.CreateLShr(Ops[0], Ops[1], "vshr_n");
2653 return Builder.CreateAShr(Ops[0], Ops[1], "vshr_n");
2664 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2665 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2668 Ops[1] = Builder.CreateLShr(Ops[1], Ops[2], "vsra_n");
2670 Ops[1] = Builder.CreateAShr(Ops[1], Ops[2], "vsra_n");
2671 return Builder.CreateAdd(Ops[0], Ops[1]);
2681 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2683 Ops[1] = Builder.CreateShuffleVector(Ops[1], Ops[1], SV);
2685 return Builder.CreateCall(CGM.getIntrinsic(Intrinsic::arm_neon_vst1,
2690 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2691 Ops[1] = Builder.CreateExtractElement(Ops[1], Ops[2]);
2693 StoreInst *St = Builder.CreateStore(Ops[1],
2694 Builder.CreateBitCast(Ops[0], Ty));
2757 Ops[0] = Builder.CreateBitCast(Ops[0], Ty);
2758 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2759 Ops[0] = Builder.CreateAnd(Ops[0], Ops[1]);
2760 Ops[0] = Builder.CreateICmp(ICmpInst::ICMP_NE, Ops[0],
2762 return Builder.CreateSExt(Ops[0], Ty, "vtst");
2766 Ops[0] = Builder.CreateBitCast(Ops[0], llvm::PointerType::getUnqual(Ty));
2767 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2768 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
2774 Indices.push_back(Builder.getInt32(i+vi));
2775 Indices.push_back(Builder.getInt32(i+e+vi));
2777 Value *Addr = Builder.CreateConstInBoundsGEP1_32(Ops[0], vi);
2779 SV = Builder.CreateShuffleVector(Ops[1], Ops[2], SV, "vtrn");
2780 SV = Builder.CreateStore(SV, Addr);
2786 Ops[0] = Builder.CreateBitCast(Ops[0], llvm::PointerType::getUnqual(Ty));
2787 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2788 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
2796 Value *Addr = Builder.CreateConstInBoundsGEP1_32(Ops[0], vi);
2798 SV = Builder.CreateShuffleVector(Ops[1], Ops[2], SV, "vuzp");
2799 SV = Builder.CreateStore(SV, Addr);
2805 Ops[0] = Builder.CreateBitCast(Ops[0], llvm::PointerType::getUnqual(Ty));
2806 Ops[1] = Builder.CreateBitCast(Ops[1], Ty);
2807 Ops[2] = Builder.CreateBitCast(Ops[2], Ty);
2816 Value *Addr = Builder.CreateConstInBoundsGEP1_32(Ops[0], vi);
2818 SV = Builder.CreateShuffleVector(Ops[1], Ops[2], SV, "vzip");
2819 SV = Builder.CreateStore(SV, Addr);
2847 Result = Builder.CreateInsertElement(Result, Ops[i], Builder.getInt32(i));
2882 return Builder.CreateBitCast(BuildVector(Ops),
2885 return Builder.CreateExtractElement(Ops[0],
2890 Value *Tmp = Builder.CreateAlloca(Int32Ty, One);
2891 Builder.CreateStore(Ops[0], Tmp);
2892 return Builder.CreateCall(CGM.getIntrinsic(Intrinsic::x86_sse_ldmxcsr),
2893 Builder.CreateBitCast(Tmp, PtrTy));
2898 Value *Tmp = Builder.CreateAlloca(Int32Ty, One);
2899 Builder.CreateCall(CGM.getIntrinsic(Intrinsic::x86_sse_stmxcsr),
2900 Builder.CreateBitCast(Tmp, PtrTy));
2901 return Builder.CreateLoad(Tmp, "stmxcsr");
2909 Ops[1] = Builder.CreateBitCast(Ops[1], VecTy, "cast");
2914 Ops[1] = Builder.CreateExtractElement(Ops[1], Idx, "extract");
2917 Ops[0] = Builder.CreateBitCast(Ops[0], PtrTy);
2918 return Builder.CreateStore(Ops[1], Ops[0]);
2931 return Builder.CreateShuffleVector(Ops[1], Ops[0], SV, "palignr");
2940 Ops[0] = Builder.CreateBitCast(Ops[0], VecTy, "cast");
2945 return Builder.CreateCall(F, makeArrayRef(&Ops[0], 2), "palignr");
2962 return Builder.CreateShuffleVector(Ops[1], Ops[0], SV, "palignr");
2970 Ops[0] = Builder.CreateBitCast(Ops[0], VecTy, "cast");
2975 return Builder.CreateCall(F, makeArrayRef(&Ops[0], 2), "palignr");
3000 return Builder.CreateShuffleVector(Ops[1], Ops[0], SV, "palignr");
3008 Ops[0] = Builder.CreateBitCast(Ops[0], VecTy, "cast");
3013 return Builder.CreateCall(F, makeArrayRef(&Ops[0], 2), "palignr");
3027 Builder.getInt32(1));
3030 Value *BC = Builder.CreateBitCast(Ops[0],
3033 StoreInst *SI = Builder.CreateStore(Ops[1], BC);
3052 Ops[0] = Builder.CreateBitCast(Ops[0], MMXTy, "cast");
3054 return Builder.CreateCall(F, Ops, name);
3085 Value *Call = Builder.CreateCall(CGM.getIntrinsic(ID));
3086 Builder.CreateStore(Builder.CreateExtractValue(Call, 0), Ops[0]);
3087 return Builder.CreateExtractValue(Call, 1);
3114 Ops[1] = Builder.CreateBitCast(Ops[1], Int8PtrTy);
3116 Ops[0] = Builder.CreateGEP(Ops[1], Ops[0]);
3144 return Builder.CreateCall(F, Ops, "");
3154 Builder.CreateBitCast(Ops[2], Int8PtrTy);
3155 Ops[1] = Builder.CreateGEP(Ops[2], Ops[1]);
3177 return Builder.CreateCall(F, Ops, "");