aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/CodeGen/CodeGenFunction.cpp
diff options
context:
space:
mode:
authorJacek Caban <jacek@codeweavers.com>2024-07-27 14:29:05 +0200
committerGitHub <noreply@github.com>2024-07-27 14:29:05 +0200
commitea98dc8b8f508b8393651992830e5e51d3876728 (patch)
treec9c7d34f1ff04c37739a26127e02ab89b28e67d7 /clang/lib/CodeGen/CodeGenFunction.cpp
parentae4f2495a460d973e471626fb6fdaeec6d5c494e (diff)
downloadllvm-ea98dc8b8f508b8393651992830e5e51d3876728.zip
llvm-ea98dc8b8f508b8393651992830e5e51d3876728.tar.gz
llvm-ea98dc8b8f508b8393651992830e5e51d3876728.tar.bz2
[clang][ARM64EC] Add support for hybrid_patchable attribute. (#99478)
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp')
-rw-r--r--clang/lib/CodeGen/CodeGenFunction.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenFunction.cpp b/clang/lib/CodeGen/CodeGenFunction.cpp
index d607869..af20155 100644
--- a/clang/lib/CodeGen/CodeGenFunction.cpp
+++ b/clang/lib/CodeGen/CodeGenFunction.cpp
@@ -991,6 +991,9 @@ void CodeGenFunction::StartFunction(GlobalDecl GD, QualType RetTy,
if (D && D->hasAttr<NoProfileFunctionAttr>())
Fn->addFnAttr(llvm::Attribute::NoProfile);
+ if (D && D->hasAttr<HybridPatchableAttr>())
+ Fn->addFnAttr(llvm::Attribute::HybridPatchable);
+
if (D) {
// Function attributes take precedence over command line flags.
if (auto *A = D->getAttr<FunctionReturnThunksAttr>()) {