diff options
| author | Evgeniy Stepanov <eugeni.stepanov@gmail.com> | 2017-12-09 01:32:07 +0000 |
|---|---|---|
| committer | Evgeniy Stepanov <eugeni.stepanov@gmail.com> | 2017-12-09 01:32:07 +0000 |
| commit | 0d53760ddd0c37bc0455844acf3b5cb33d71fe65 (patch) | |
| tree | 4a5f8fef4f26b6ecc9c358feeb5778ec2a5e9d40 /lib/CodeGen/CodeGenFunction.cpp | |
| parent | b517f5fe7e05ab715ef8fdf6fccbaa29b8feca34 (diff) | |
| download | clang-0d53760ddd0c37bc0455844acf3b5cb33d71fe65.tar.gz | |
Hardware-assisted AddressSanitizer (clang part).
Summary:
Driver, frontend and LLVM codegen for HWASan.
A clone of ASan, basically.
Reviewers: kcc, pcc, alekseyshl
Subscribers: srhines, javed.absar, cfe-commits
Differential Revision: https://reviews.llvm.org/D40936
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@320232 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CodeGenFunction.cpp')
| -rw-r--r-- | lib/CodeGen/CodeGenFunction.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/CodeGen/CodeGenFunction.cpp b/lib/CodeGen/CodeGenFunction.cpp index 6633320de1..a8dac422a6 100644 --- a/lib/CodeGen/CodeGenFunction.cpp +++ b/lib/CodeGen/CodeGenFunction.cpp @@ -846,6 +846,8 @@ void CodeGenFunction::StartFunction(GlobalDecl GD, // Apply sanitizer attributes to the function. if (SanOpts.hasOneOf(SanitizerKind::Address | SanitizerKind::KernelAddress)) Fn->addFnAttr(llvm::Attribute::SanitizeAddress); + if (SanOpts.hasOneOf(SanitizerKind::HWAddress)) + Fn->addFnAttr(llvm::Attribute::SanitizeHWAddress); if (SanOpts.has(SanitizerKind::Thread)) Fn->addFnAttr(llvm::Attribute::SanitizeThread); if (SanOpts.has(SanitizerKind::Memory)) |
