LLVM
24.0.0git
include
llvm
Transforms
Instrumentation
AddressSanitizerCommon.h
Go to the documentation of this file.
1
//===--------- Definition of the AddressSanitizer class ---------*- C++ -*-===//
2
//
3
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4
// See https://llvm.org/LICENSE.txt for license information.
5
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6
//
7
//===----------------------------------------------------------------------===//
8
//
9
// This file declares common infrastructure for AddressSanitizer and
10
// HWAddressSanitizer.
11
//
12
//===----------------------------------------------------------------------===//
13
#ifndef LLVM_TRANSFORMS_INSTRUMENTATION_ADDRESSSANITIZERCOMMON_H
14
#define LLVM_TRANSFORMS_INSTRUMENTATION_ADDRESSSANITIZERCOMMON_H
15
16
#include "
llvm/Analysis/CFG.h
"
17
#include "
llvm/Analysis/InterestingMemoryOperand.h
"
18
#include "
llvm/Analysis/PostDominators.h
"
19
#include "
llvm/IR/Dominators.h
"
20
#include "
llvm/IR/Instruction.h
"
21
#include "
llvm/IR/IntrinsicInst.h
"
22
#include "
llvm/IR/Module.h
"
23
#include "
llvm/Support/Compiler.h
"
24
25
namespace
llvm
{
26
// Get AddressSanitizer parameters.
27
LLVM_ABI
void
getAddressSanitizerParams
(
const
LLVMContext
&Ctx,
28
const
Triple
&TargetTriple,
29
int
LongSize,
bool
IsKasan,
30
uint64_t
*ShadowBase,
int
*MappingScale,
31
bool
*OrShadowOffset);
32
33
/// Remove memory attributes that are incompatible with the instrumentation
34
/// added by AddressSanitizer and HWAddressSanitizer.
35
/// \p ReadsArgMem - indicates whether function arguments may be read by
36
/// instrumentation and require removing `writeonly` attributes.
37
LLVM_ABI
void
removeASanIncompatibleFnAttributes
(
Function
&
F
,
bool
ReadsArgMem);
38
39
}
// namespace llvm
40
41
#endif
uint64_t
uint64_t uint64_t
Definition
AMDGPUDisassembler.cpp:553
CFG.h
Compiler.h
LLVM_ABI
#define LLVM_ABI
Definition
Compiler.h:211
Dominators.h
Instruction.h
IntrinsicInst.h
Module.h
Module.h This file contains the declarations for the Module class.
InterestingMemoryOperand.h
F
#define F(x, y, z)
Definition
MD5.cpp:54
PostDominators.h
llvm::Function
Definition
Function.h:65
llvm::LLVMContext
This is an important class for using LLVM in a threaded context.
Definition
LLVMContext.h:76
llvm::Triple
Triple - Helper class for working with autoconf configuration names.
Definition
Triple.h:48
llvm
This is an optimization pass for GlobalISel generic memory operations.
Definition
DefaultTargetInfo.h:21
llvm::getAddressSanitizerParams
LLVM_ABI void getAddressSanitizerParams(const LLVMContext &Ctx, const Triple &TargetTriple, int LongSize, bool IsKasan, uint64_t *ShadowBase, int *MappingScale, bool *OrShadowOffset)
Definition
AddressSanitizer.cpp:353
llvm::removeASanIncompatibleFnAttributes
LLVM_ABI void removeASanIncompatibleFnAttributes(Function &F, bool ReadsArgMem)
Remove memory attributes that are incompatible with the instrumentation added by AddressSanitizer and...
Definition
AddressSanitizer.cpp:365
Generated on
for LLVM by
1.14.0