diff options
-rw-r--r-- | lib/CodeGen/CGDecl.cpp | 4 | ||||
-rw-r--r-- | lib/CodeGen/CGExpr.cpp | 2 | ||||
-rw-r--r-- | lib/CodeGen/CGExprAgg.cpp | 2 | ||||
-rw-r--r-- | lib/CodeGen/CGStmt.cpp | 10 | ||||
-rw-r--r-- | lib/CodeGen/CodeGenTypes.cpp | 4 |
5 files changed, 11 insertions, 11 deletions
diff --git a/lib/CodeGen/CGDecl.cpp b/lib/CodeGen/CGDecl.cpp index bd68288bba..6e40ea0582 100644 --- a/lib/CodeGen/CGDecl.cpp +++ b/lib/CodeGen/CGDecl.cpp @@ -169,9 +169,9 @@ void CodeGenFunction::EmitParmDecl(const ParmVarDecl &D, llvm::Value *Arg) { } else if (Target.useGlobalsForAutomaticVariables()) { DeclPtr = GenerateStaticBlockVarDecl(D, true, ".arg."); } else { - // A fixed sized first class variable becomes an alloca in the entry block. + // A fixed sized single-value variable becomes an alloca in the entry block. const llvm::Type *LTy = ConvertType(Ty); - if (LTy->isFirstClassType()) { + if (LTy->isSingleValueType()) { // TODO: Alignment DeclPtr = new llvm::AllocaInst(LTy, 0, std::string(D.getName())+".addr", AllocaInsertPt); diff --git a/lib/CodeGen/CGExpr.cpp b/lib/CodeGen/CGExpr.cpp index b124e34be3..d715b45229 100644 --- a/lib/CodeGen/CGExpr.cpp +++ b/lib/CodeGen/CGExpr.cpp @@ -133,7 +133,7 @@ RValue CodeGenFunction::EmitLoadOfLValue(LValue LV, QualType ExprType) { cast<llvm::PointerType>(Ptr->getType())->getElementType(); // Simple scalar l-value. - if (EltTy->isFirstClassType()) { + if (EltTy->isSingleValueType()) { llvm::Value *V = Builder.CreateLoad(Ptr, "tmp"); // Bool can have different representation in memory than in registers. diff --git a/lib/CodeGen/CGExprAgg.cpp b/lib/CodeGen/CGExprAgg.cpp index 2ac473439e..f584980d7f 100644 --- a/lib/CodeGen/CGExprAgg.cpp +++ b/lib/CodeGen/CGExprAgg.cpp @@ -298,7 +298,7 @@ void AggExprEmitter::EmitNonConstInit(InitListExpr *E) { const llvm::Type *EType = AType->getElementType(); for (/*Do not initialize i*/; i < NumArrayElements; ++i) { llvm::Value *NextVal = Builder.CreateStructGEP(DestPtr, i, ".array"); - if (EType->isFirstClassType()) + if (EType->isSingleValueType()) Builder.CreateStore(llvm::Constant::getNullValue(EType), NextVal); else EmitAggregateClear(NextVal, QType); diff --git a/lib/CodeGen/CGStmt.cpp b/lib/CodeGen/CGStmt.cpp index 0148ab0d84..c38ad04001 100644 --- a/lib/CodeGen/CGStmt.cpp +++ b/lib/CodeGen/CGStmt.cpp @@ -688,7 +688,7 @@ void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) { // If the first output operand is not a memory dest, we'll // make it the return value. if (i == 0 && !(Info & TargetInfo::CI_AllowsMemory) && - DestValueType->isFirstClassType()) { + DestValueType->isSingleValueType()) { ResultAddr = Dest.getAddress(); ResultType = DestValueType; Constraints += "=" + OutputConstraint; @@ -709,10 +709,10 @@ void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) { llvm::Value *Arg; if ((Info & TargetInfo::CI_AllowsRegister) || !(Info & TargetInfo::CI_AllowsMemory)) { - if (ConvertType(InputExpr->getType())->isFirstClassType()) { + if (ConvertType(InputExpr->getType())->isSingleValueType()) { Arg = EmitScalarExpr(InputExpr); } else { - assert(0 && "FIXME: Implement passing non first class types as inputs"); + assert(0 && "FIXME: Implement passing multiple-value types as inputs"); } } else { LValue Dest = EmitLValue(InputExpr); @@ -750,10 +750,10 @@ void CodeGenFunction::EmitAsmStmt(const AsmStmt &S) { if ((Info & TargetInfo::CI_AllowsRegister) || !(Info & TargetInfo::CI_AllowsMemory)) { - if (ConvertType(InputExpr->getType())->isFirstClassType()) { + if (ConvertType(InputExpr->getType())->isSingleValueType()) { Arg = EmitScalarExpr(InputExpr); } else { - assert(0 && "FIXME: Implement passing non first class types as inputs"); + assert(0 && "FIXME: Implement passing multiple-value types as inputs"); } } else { LValue Dest = EmitLValue(InputExpr); diff --git a/lib/CodeGen/CodeGenTypes.cpp b/lib/CodeGen/CodeGenTypes.cpp index 1544050155..bd375ee6a9 100644 --- a/lib/CodeGen/CodeGenTypes.cpp +++ b/lib/CodeGen/CodeGenTypes.cpp @@ -279,7 +279,7 @@ const llvm::Type *CodeGenTypes::ConvertNewType(QualType T) { std::vector<const llvm::Type*> ArgTys; // Struct return passes the struct byref. - if (!ResultType->isFirstClassType() && ResultType != llvm::Type::VoidTy) { + if (!ResultType->isSingleValueType() && ResultType != llvm::Type::VoidTy) { ArgTys.push_back(llvm::PointerType::get(ResultType, FP.getResultType().getAddressSpace())); ResultType = llvm::Type::VoidTy; @@ -352,7 +352,7 @@ void CodeGenTypes::DecodeArgumentTypes(const FunctionTypeProto &FTP, std::vector<const llvm::Type*> &ArgTys) { for (unsigned i = 0, e = FTP.getNumArgs(); i != e; ++i) { const llvm::Type *Ty = ConvertTypeRecursive(FTP.getArgType(i)); - if (Ty->isFirstClassType()) + if (Ty->isSingleValueType()) ArgTys.push_back(Ty); else // byval arguments are always on the stack, which is addr space #0. |