mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-09-24 23:28:41 +00:00
[asan] enable asan only for the functions that have Attribute::AddressSafety
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148846 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -608,6 +608,7 @@ bool AddressSanitizer::runOnModule(Module &M) {
|
||||
bool AddressSanitizer::handleFunction(Module &M, Function &F) {
|
||||
if (BL->isIn(F)) return false;
|
||||
if (&F == AsanCtorFunction) return false;
|
||||
if (!F.hasFnAttr(Attribute::AddressSafety)) return false;
|
||||
|
||||
if (!ClDebugFunc.empty() && ClDebugFunc != F.getName())
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user