projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
775a948
)
[IR] Add doc about Function::createWithDefaultAttr. NFC
author
Fangrui Song
<i@maskray.me>
Wed, 21 Apr 2021 23:20:50 +0000
(16:20 -0700)
committer
Fangrui Song
<i@maskray.me>
Wed, 21 Apr 2021 23:20:50 +0000
(16:20 -0700)
llvm/include/llvm/IR/Function.h
patch
|
blob
|
history
diff --git
a/llvm/include/llvm/IR/Function.h
b/llvm/include/llvm/IR/Function.h
index
8bc5e12
..
e0094e2
100644
(file)
--- a/
llvm/include/llvm/IR/Function.h
+++ b/
llvm/include/llvm/IR/Function.h
@@
-153,6
+153,11
@@
public:
static Function *Create(FunctionType *Ty, LinkageTypes Linkage,
const Twine &N, Module &M);
+ /// Creates a function with some attributes recorded in llvm.module.flags
+ /// applied.
+ ///
+ /// Use this when synthesizing new functions that need attributes that would
+ /// have been set by command line options.
static Function *createWithDefaultAttr(FunctionType *Ty, LinkageTypes Linkage,
unsigned AddrSpace,
const Twine &N = "",