projects
/
oota-llvm.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Implement function prefix data as an IR feature.
[oota-llvm.git]
/
include
/
llvm
/
IR
/
Function.h
diff --git
a/include/llvm/IR/Function.h
b/include/llvm/IR/Function.h
index 0e51c6f7565e915198028464a54db61380051253..bba7ecdd2372d3cf5671d873c3bfa992ab6589cd 100644
(file)
--- a/
include/llvm/IR/Function.h
+++ b/
include/llvm/IR/Function.h
@@
-159,11
+159,11
@@
public:
/// calling convention of this function. The enum values for the known
/// calling conventions are defined in CallingConv.h.
CallingConv::ID getCallingConv() const {
/// calling convention of this function. The enum values for the known
/// calling conventions are defined in CallingConv.h.
CallingConv::ID getCallingConv() const {
- return static_cast<CallingConv::ID>(getSubclassDataFromValue() >>
1
);
+ return static_cast<CallingConv::ID>(getSubclassDataFromValue() >>
2
);
}
void setCallingConv(CallingConv::ID CC) {
}
void setCallingConv(CallingConv::ID CC) {
- setValueSubclassData((getSubclassDataFromValue() &
1
) |
- (static_cast<unsigned>(CC) <<
1
));
+ setValueSubclassData((getSubclassDataFromValue() &
3
) |
+ (static_cast<unsigned>(CC) <<
2
));
}
/// @brief Return the attribute list for this Function.
}
/// @brief Return the attribute list for this Function.
@@
-427,6
+427,13
@@
public:
size_t arg_size() const;
bool arg_empty() const;
size_t arg_size() const;
bool arg_empty() const;
+ bool hasPrefixData() const {
+ return getSubclassDataFromValue() & 2;
+ }
+
+ Constant *getPrefixData() const;
+ void setPrefixData(Constant *PrefixData);
+
/// viewCFG - This function is meant for use from the debugger. You can just
/// say 'call F->viewCFG()' and a ghostview window should pop up from the
/// program, displaying the CFG of the current function with the code for each
/// viewCFG - This function is meant for use from the debugger. You can just
/// say 'call F->viewCFG()' and a ghostview window should pop up from the
/// program, displaying the CFG of the current function with the code for each