[PATCH] Skip promotable allocas to improve performance at -O0

Anna Zaks zaks.anna at gmail.com
Mon Feb 23 18:57:18 PST 2015


I've addressed the outstanding comments:

- Refactored the code to reuse isInterestingAlloca() from within isInterestingMemoryAccess().
- Addressed Kostya's latest comments about "if" re-structuring as well.
- Kuba is helping out by modifying the compiler-rt tests so that they are not sensitive to optimization levels :)

Kostya,
As I've commented on the other thread, I don't think http://reviews.llvm.org/D7583 is currently doing the right thing (skipping "inbounds" geps). Though, I do believe we can achieve optimizations by building on top of this and excluding allocas that only have constant and provably in bounds accesses.


http://reviews.llvm.org/D7741

Files:
  lib/Transforms/Instrumentation/AddressSanitizer.cpp
  test/Instrumentation/AddressSanitizer/debug_info.ll
  test/Instrumentation/AddressSanitizer/do-not-instrument-promotable-allocas.ll
  test/Instrumentation/AddressSanitizer/instrument-dynamic-allocas.ll
  test/Instrumentation/AddressSanitizer/lifetime-uar.ll
  test/Instrumentation/AddressSanitizer/lifetime.ll
  test/Instrumentation/AddressSanitizer/stack_dynamic_alloca.ll
  test/Instrumentation/AddressSanitizer/stack_layout.ll

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7741.20566.patch
Type: text/x-patch
Size: 13638 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150224/1504e0c1/attachment.bin>


More information about the llvm-commits mailing list