mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-20 16:17:38 +00:00
Extend 'readonly' and 'readnone' to work on function arguments as well as
functions. Make the function attributes pass add it to known library functions and when it can deduce it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185735 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -552,6 +552,12 @@ CodeGenIntrinsic::CodeGenIntrinsic(Record *R) {
|
||||
else if (Property->isSubClassOf("NoCapture")) {
|
||||
unsigned ArgNo = Property->getValueAsInt("ArgNo");
|
||||
ArgumentAttributes.push_back(std::make_pair(ArgNo, NoCapture));
|
||||
} else if (Property->isSubClassOf("ReadOnly")) {
|
||||
unsigned ArgNo = Property->getValueAsInt("ArgNo");
|
||||
ArgumentAttributes.push_back(std::make_pair(ArgNo, ReadOnly));
|
||||
} else if (Property->isSubClassOf("ReadNone")) {
|
||||
unsigned ArgNo = Property->getValueAsInt("ArgNo");
|
||||
ArgumentAttributes.push_back(std::make_pair(ArgNo, ReadNone));
|
||||
} else
|
||||
llvm_unreachable("Unknown property!");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user