summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/StackProtector.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2012-10-09 07:45:08 +0000
committerBill Wendling <isanbard@gmail.com>2012-10-09 07:45:08 +0000
commitc9b22d735a921e335bc02aea0bd4695c5a3e52a9 (patch)
treedbe50cfd0e6565cc868b4210a199c95a9fee5fb7 /llvm/lib/CodeGen/StackProtector.cpp
parent3b95e4da76df2084315368dca15a31a99fd3150e (diff)
downloadbcm5719-llvm-c9b22d735a921e335bc02aea0bd4695c5a3e52a9.tar.gz
bcm5719-llvm-c9b22d735a921e335bc02aea0bd4695c5a3e52a9.zip
Create enums for the different attributes.
We use the enums to query whether an Attributes object has that attribute. The opaque layer is responsible for knowing where that specific attribute is stored. llvm-svn: 165488
Diffstat (limited to 'llvm/lib/CodeGen/StackProtector.cpp')
-rw-r--r--llvm/lib/CodeGen/StackProtector.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/CodeGen/StackProtector.cpp b/llvm/lib/CodeGen/StackProtector.cpp
index 8e18f30a63a..31e9ec0ac0b 100644
--- a/llvm/lib/CodeGen/StackProtector.cpp
+++ b/llvm/lib/CodeGen/StackProtector.cpp
@@ -137,10 +137,10 @@ bool StackProtector::ContainsProtectableArray(Type *Ty, bool InStruct) const {
/// add a guard variable to functions that call alloca, and functions with
/// buffers larger than SSPBufferSize bytes.
bool StackProtector::RequiresStackProtector() const {
- if (F->getFnAttributes().hasStackProtectReqAttr())
+ if (F->getFnAttributes().hasAttribute(Attributes::StackProtectReq))
return true;
- if (!F->getFnAttributes().hasStackProtectAttr())
+ if (!F->getFnAttributes().hasAttribute(Attributes::StackProtect))
return false;
for (Function::iterator I = F->begin(), E = F->end(); I != E; ++I) {
OpenPOWER on IntegriCloud