diff options
author | Dan Liew <delcypher@gmail.com> | 2024-05-16 15:24:11 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-16 15:24:11 -0700 |
commit | 84abe0a6d4face73c15ed6344be74ae231f18718 (patch) | |
tree | b976cc795420b1cfeae8e9e9b137e2bbc332d6c4 /llvm/lib/Analysis/ModuleSummaryAnalysis.cpp | |
parent | e578314c049bb9ae6dc3983db5cf27513e29517b (diff) | |
download | llvm-84abe0a6d4face73c15ed6344be74ae231f18718.zip llvm-84abe0a6d4face73c15ed6344be74ae231f18718.tar.gz llvm-84abe0a6d4face73c15ed6344be74ae231f18718.tar.bz2 |
[Bounds-Safety] Reserve slot in SanitizerHandler enum for Bounds-Safety (#91032)
Due to how `CodeGenFunction::EmitTrapCheck` is implemented
`SanitizerHandler` with numeric value 0x19 needs to be reserved because
`-fbounds-safety` generates trap instructions with that value embedded
in the trap instructions for x86_64 and arm64 just like for UBSan traps.
** x86_64 **
```
ud1l 0x19(%eax), %eax
```
** arm64 **
```
brk #0x5519
```
To avoid upstream Clang and AppleClang diverging their ABIs for
`-fbounds-safety` the slot is being reserved in this patch.
`SanitizerHandler::BoundsSafety` currently has no uses in the code but
uses will be introduced when the CodeGen side of `-fbounds-safety`'s
implementation is upstreamed.
rdar://126884014
Co-authored-by: Dan Liew <dan@su-root.co.uk>
Diffstat (limited to 'llvm/lib/Analysis/ModuleSummaryAnalysis.cpp')
0 files changed, 0 insertions, 0 deletions