From 22fe18625de76e06edbd0c329949cb064dddf1ff Mon Sep 17 00:00:00 2001 From: Charles Davis Date: Mon, 25 Oct 2010 15:37:09 +0000 Subject: Add a new 'hotpatch' attribute. This attribute will insert a two-byte no-op instruction at the beginning of each function that has the attribute, allowing the function to be easily hooked and/or patched. llvm-svn: 117264 --- llvm/lib/AsmParser/LLParser.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'llvm/lib/AsmParser/LLParser.cpp') diff --git a/llvm/lib/AsmParser/LLParser.cpp b/llvm/lib/AsmParser/LLParser.cpp index 4d3bd879320..a1f70fb0249 100644 --- a/llvm/lib/AsmParser/LLParser.cpp +++ b/llvm/lib/AsmParser/LLParser.cpp @@ -982,6 +982,7 @@ bool LLParser::ParseOptionalAttrs(unsigned &Attrs, unsigned AttrKind) { case lltok::kw_noredzone: Attrs |= Attribute::NoRedZone; break; case lltok::kw_noimplicitfloat: Attrs |= Attribute::NoImplicitFloat; break; case lltok::kw_naked: Attrs |= Attribute::Naked; break; + case lltok::kw_hotpatch: Attrs |= Attribute::Hotpatch; break; case lltok::kw_alignstack: { unsigned Alignment; -- cgit v1.2.3