Home | History | Annotate | Download | only in CodeGen

Lines Matching refs:Builder

49   CGBuilderTy &Builder;
54 : CGF(cgf), Builder(CGF.Builder), IgnoreReal(ir), IgnoreImag(ii) {
306 return Builder.CreateStructGEP(addr, 0, offset, addr.getName() + ".realp");
313 return Builder.CreateStructGEP(addr, 1, offset, addr.getName() + ".imagp");
331 Real = Builder.CreateLoad(RealP, isVolatile, SrcPtr.getName() + ".real");
336 Imag = Builder.CreateLoad(ImagP, isVolatile, SrcPtr.getName() + ".imag");
354 Builder.CreateStore(Val.first, RealPtr, lvalue.isVolatileQualified());
355 Builder.CreateStore(Val.second, ImagPtr, lvalue.isVolatileQualified());
440 V = Builder.CreateElementBitCast(V, CGF.ConvertType(DestTy));
512 ResR = Builder.CreateFNeg(Op.first, "neg.r");
513 ResI = Builder.CreateFNeg(Op.second, "neg.i");
515 ResR = Builder.CreateNeg(Op.first, "neg.r");
516 ResI = Builder.CreateNeg(Op.second, "neg.i");
528 ResI = Builder.CreateFNeg(Op.second, "conj.i");
530 ResI = Builder.CreateNeg(Op.second, "conj.i");
539 ResR = Builder.CreateFAdd(Op.LHS.first, Op.RHS.first, "add.r");
541 ResI = Builder.CreateFAdd(Op.LHS.second, Op.RHS.second, "add.i");
546 ResR = Builder.CreateAdd(Op.LHS.first, Op.RHS.first, "add.r");
549 ResI = Builder.CreateAdd(Op.LHS.second, Op.RHS.second, "add.i");
557 ResR = Builder.CreateFSub(Op.LHS.first, Op.RHS.first, "sub.r");
559 ResI = Builder.CreateFSub(Op.LHS.second, Op.RHS.second, "sub.i");
562 : Builder.CreateFNeg(Op.RHS.second, "sub.i");
565 ResR = Builder.CreateSub(Op.LHS.first, Op.RHS.first, "sub.r");
568 ResI = Builder.CreateSub(Op.LHS.second, Op.RHS.second, "sub.i");
659 Value *AC = Builder.CreateFMul(Op.LHS.first, Op.RHS.first, "mul_ac");
660 Value *BD = Builder.CreateFMul(Op.LHS.second, Op.RHS.second, "mul_bd");
661 Value *AD = Builder.CreateFMul(Op.LHS.first, Op.RHS.second, "mul_ad");
662 Value *BC = Builder.CreateFMul(Op.LHS.second, Op.RHS.first, "mul_bc");
666 ResR = Builder.CreateFSub(AC, BD, "mul_r");
667 ResI = Builder.CreateFAdd(AD, BC, "mul_i");
671 Value *IsRNaN = Builder.CreateFCmpUNO(ResR, ResR, "isnan_cmp");
674 llvm::Instruction *Branch = Builder.CreateCondBr(IsRNaN, INaNBB, ContBB);
684 Value *IsINaN = Builder.CreateFCmpUNO(ResI, ResI, "isnan_cmp");
686 Branch = Builder.CreateCondBr(IsINaN, LibCallBB, ContBB);
694 Builder.CreateBr(ContBB);
699 llvm::PHINode *RealPHI = Builder.CreatePHI(ResR->getType(), 3, "real_mul_phi");
703 llvm::PHINode *ImagPHI = Builder.CreatePHI(ResI->getType(), 3, "imag_mul_phi");
715 ResR = Builder.CreateFMul(Op.LHS.first, Op.RHS.first, "mul.rl");
718 ? Builder.CreateFMul(Op.LHS.second, Op.RHS.first, "mul.il")
719 : Builder.CreateFMul(Op.LHS.first, Op.RHS.second, "mul.ir");
723 Value *ResRl = Builder.CreateMul(Op.LHS.first, Op.RHS.first, "mul.rl");
724 Value *ResRr = Builder.CreateMul(Op.LHS.second, Op.RHS.second, "mul.rr");
725 ResR = Builder.CreateSub(ResRl, ResRr, "mul.r");
727 Value *ResIl = Builder.CreateMul(Op.LHS.second, Op.RHS.first, "mul.il");
728 Value *ResIr = Builder.CreateMul(Op.LHS.first, Op.RHS.second, "mul.ir");
729 ResI = Builder.CreateAdd(ResIl, ResIr, "mul.i");
774 DSTr = Builder.CreateFDiv(LHSr, RHSr);
775 DSTi = Builder.CreateFDiv(LHSi, RHSr);
780 llvm::Value *Tmp1 = Builder.CreateMul(LHSr, RHSr); // a*c
781 llvm::Value *Tmp2 = Builder.CreateMul(LHSi, RHSi); // b*d
782 llvm::Value *Tmp3 = Builder.CreateAdd(Tmp1, Tmp2); // ac+bd
784 llvm::Value *Tmp4 = Builder.CreateMul(RHSr, RHSr); // c*c
785 llvm::Value *Tmp5 = Builder.CreateMul(RHSi, RHSi); // d*d
786 llvm::Value *Tmp6 = Builder.CreateAdd(Tmp4, Tmp5); // cc+dd
788 llvm::Value *Tmp7 = Builder.CreateMul(LHSi, RHSr); // b*c
789 llvm::Value *Tmp8 = Builder.CreateMul(LHSr, RHSi); // a*d
790 llvm::Value *Tmp9 = Builder.CreateSub(Tmp7, Tmp8); // bc-ad
793 DSTr = Builder.CreateUDiv(Tmp3, Tmp6);
794 DSTi = Builder.CreateUDiv(Tmp9, Tmp6);
796 DSTr = Builder.CreateSDiv(Tmp3, Tmp6);
797 DSTi = Builder.CreateSDiv(Tmp9, Tmp6);
970 LHSBlock = Builder.GetInsertBlock();
977 RHSBlock = Builder.GetInsertBlock();
982 llvm::PHINode *RealPN = Builder.CreatePHI(LHS.first->getType(), 2, "cond.r");
987 llvm::PHINode *ImagPN = Builder.CreatePHI(LHS.first->getType(), 2, "cond.i");