Mercurial > hg > CbC > CbC_llvm
changeset 227:21e6aa2e49ef
...
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 19 Jul 2021 06:57:16 +0900 |
parents | f48a93eada0e |
children | c2fc9aeb158b |
files | clang/lib/CodeGen/CGCall.cpp clang/lib/Sema/SemaType.cpp llvm/lib/IR/LLVMContextImpl.cpp |
diffstat | 3 files changed, 3 insertions(+), 22 deletions(-) [+] |
line wrap: on
line diff
--- a/clang/lib/CodeGen/CGCall.cpp Mon Jul 19 03:57:43 2021 +0900 +++ b/clang/lib/CodeGen/CGCall.cpp Mon Jul 19 06:57:16 2021 +0900 @@ -2193,14 +2193,9 @@ // Add "sample-profile-suffix-elision-policy" attribute for internal linkage // functions with -funique-internal-linkage-names. if (TargetDecl && CodeGenOpts.UniqueInternalLinkageNames) { -<<<<<<< working copy - if (auto *Fn = dyn_cast<FunctionDecl>(TargetDecl)) { - if (this->getFunctionLinkage(Fn) == llvm::GlobalValue::InternalLinkage) -======= if (isa<FunctionDecl>(TargetDecl)) { if (this->getFunctionLinkage(CalleeInfo.getCalleeDecl()) == llvm::GlobalValue::InternalLinkage) ->>>>>>> merge rev FuncAttrs.addAttribute("sample-profile-suffix-elision-policy", "selected"); } @@ -3462,12 +3457,8 @@ --EI; llvm::Value *ArgStruct = &*EI; llvm::Value *SRet = Builder.CreateStructGEP( -<<<<<<< working copy - nullptr, ArgStruct, RetAI.getInAllocaFieldIndex()); -======= EI->getType()->getPointerElementType(), ArgStruct, RetAI.getInAllocaFieldIndex()); ->>>>>>> merge rev llvm::Type *Ty = cast<llvm::GetElementPtrInst>(SRet)->getResultElementType(); RV = Builder.CreateAlignedLoad(Ty, SRet, getPointerAlign(), "sret"); @@ -4058,19 +4049,11 @@ // later, so we can't check it directly. static bool hasInAllocaArgs(CodeGenModule &CGM, CallingConv ExplicitCC, ArrayRef<QualType> ArgTypes) { -<<<<<<< working copy - // The Swift calling convention doesn't go through the target-specific - // argument classification, so it never uses inalloca. - // TODO: Consider limiting inalloca use to only calling conventions supported - // by MSVC. - if (ExplicitCC == CC_Swift) -======= // The Swift calling conventions don't go through the target-specific // argument classification, they never use inalloca. // TODO: Consider limiting inalloca use to only calling conventions supported // by MSVC. if (ExplicitCC == CC_Swift || ExplicitCC == CC_SwiftAsync) ->>>>>>> merge rev return false; if (!CGM.getTarget().getCXXABI().isMicrosoft()) return false;
--- a/clang/lib/Sema/SemaType.cpp Mon Jul 19 03:57:43 2021 +0900 +++ b/clang/lib/Sema/SemaType.cpp Mon Jul 19 06:57:16 2021 +0900 @@ -2826,9 +2826,6 @@ // SwiftAsyncContext is not limited to swiftasynccall functions. case ParameterABI::SwiftAsyncContext: - continue; - - case ParameterABI::SwiftAsyncContext: // FIXME: might want to require swiftasynccc when it exists continue;
--- a/llvm/lib/IR/LLVMContextImpl.cpp Mon Jul 19 03:57:43 2021 +0900 +++ b/llvm/lib/IR/LLVMContextImpl.cpp Mon Jul 19 06:57:16 2021 +0900 @@ -36,9 +36,10 @@ X86_FP80Ty(C, Type::X86_FP80TyID), FP128Ty(C, Type::FP128TyID), PPC_FP128Ty(C, Type::PPC_FP128TyID), X86_MMXTy(C, Type::X86_MMXTyID), #ifndef noCbC - __CodeTy(C, Type::__CodeTyID), + X86_AMXTy(C, Type::X86_AMXTyID), __CodeTy(C, Type::__CodeTyID), Int1Ty(C, 1), Int8Ty(C, 8), +#else + X86_AMXTy(C, Type::X86_AMXTyID), Int1Ty(C, 1), Int8Ty(C, 8), #endif - X86_AMXTy(C, Type::X86_AMXTyID), Int1Ty(C, 1), Int8Ty(C, 8), Int16Ty(C, 16), Int32Ty(C, 32), Int64Ty(C, 64), Int128Ty(C, 128), ForceOpaquePointers(ForceOpaquePointersCL) {}