llvm-6502/lib
Kostya Serebryany 3016056769 [asan] Change the way we report the alloca frame on stack-buff-overflow.
Before: the function name was stored by the compiler as a constant string
and the run-time was printing it.
Now: the PC is stored instead and the run-time prints the full symbolized frame.
This adds a couple of instructions into every function with non-empty stack frame,
but also reduces the binary size because we store less strings (I saw 2% size reduction).
This change bumps the asan ABI version to v3.

llvm part.

Example of report (now):
==31711==ERROR: AddressSanitizer: stack-buffer-overflow on address 0x7fffa77cf1c5 at pc 0x41feb0 bp 0x7fffa77cefb0 sp 0x7fffa77cefa8
READ of size 1 at 0x7fffa77cf1c5 thread T0
    #0 0x41feaf in Frame0(int, char*, char*, char*) stack-oob-frames.cc:20
    #1 0x41f7ff in Frame1(int, char*, char*) stack-oob-frames.cc:24
    #2 0x41f477 in Frame2(int, char*) stack-oob-frames.cc:28
    #3 0x41f194 in Frame3(int) stack-oob-frames.cc:32
    #4 0x41eee0 in main stack-oob-frames.cc:38
    #5 0x7f0c5566f76c (/lib/x86_64-linux-gnu/libc.so.6+0x2176c)
    #6 0x41eb1c (/usr/local/google/kcc/llvm_cmake/a.out+0x41eb1c)
Address 0x7fffa77cf1c5 is located in stack of thread T0 at offset 293 in frame
    #0 0x41f87f in Frame0(int, char*, char*, char*) stack-oob-frames.cc:12  <<<<<<<<<<<<<< this is new
  This frame has 6 object(s):
    [32, 36) 'frame.addr'
    [96, 104) 'a.addr'
    [160, 168) 'b.addr'
    [224, 232) 'c.addr'
    [288, 292) 's'
    [352, 360) 'd'




git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@177724 91177308-0d34-0410-b5e6-96231b3b80d8
2013-03-22 10:37:20 +00:00
..
Analysis Remove 'else' after 'return'. 2013-03-20 23:53:45 +00:00
Archive Fix auto_ptr is deprecated warnings 2013-02-26 21:20:35 +00:00
AsmParser Unify clang/llvm attributes for asan/tsan/msan (LLVM part) 2013-02-26 06:58:09 +00:00
Bitcode Simplify code. No functionality change. 2013-02-19 09:48:30 +00:00
CodeGen Remove ScavengedRC from RegisterScavenging 2013-03-22 07:27:44 +00:00
DebugInfo Fix missing std::. Not sure how this compiles for anyone else. 2013-03-21 00:57:21 +00:00
ExecutionEngine Formatting, grammar 2013-02-20 18:24:34 +00:00
IR InstCombine: Improve the result bitvect type when folding (cmp pred (load (gep GV, i)) C) to a bit test. 2013-03-22 08:25:01 +00:00
Linker The Linker interface has some dead code after the cleanup in r172749 2013-03-19 15:26:24 +00:00
MC Dead code. 2013-03-19 22:13:05 +00:00
Object Move an assert earlier in a file and check that the result of 2013-02-28 20:26:17 +00:00
Option
Support Revert r177543: Add timing of the IR parsing code with a new 2013-03-22 02:20:34 +00:00
TableGen Make sure TableGen exits with an error code after printing errors. 2013-03-20 20:43:11 +00:00
Target Fix the invalid opcode for Mips branch instructions in the assembler 2013-03-22 00:29:10 +00:00
Transforms [asan] Change the way we report the alloca frame on stack-buff-overflow. 2013-03-22 10:37:20 +00:00
CMakeLists.txt
LLVMBuild.txt
Makefile