[PATCH] D45847: [HWASan] Introduce non-zero based and dynamic shadow memory (compiler-rt).

Aleksey Shlyapnikov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 19 16:08:31 PDT 2018


alekseyshl created this revision.
alekseyshl added a reviewer: eugenis.
Herald added subscribers: Sanitizers, delcypher, kristof.beyls, mgorny, dberris, kubamracek, srhines.

Retire the fixed shadow memory mapping to avoid conflicts with default
process memory mapping (currently manifests on Android).

Tests on AArch64 show <1% performance loss and code size increase,
making it possible to use dynamic shadow memory by default.

For the simplicity and unifirmity sake, use dynamic shadow memory mapping
with base address accessed via ifunc resolver on all supported platforms.

Keep the fixed shadow memory mapping around to be able to run
performance comparison tests later.

Complementing https://reviews.llvm.org/D45840.


Repository:
  rCRT Compiler Runtime

https://reviews.llvm.org/D45847

Files:
  lib/hwasan/CMakeLists.txt
  lib/hwasan/hwasan.cc
  lib/hwasan/hwasan.h
  lib/hwasan/hwasan_allocator.cc
  lib/hwasan/hwasan_dynamic_shadow.cc
  lib/hwasan/hwasan_dynamic_shadow.h
  lib/hwasan/hwasan_interceptors.cc
  lib/hwasan/hwasan_interface_internal.h
  lib/hwasan/hwasan_linux.cc
  lib/hwasan/hwasan_mapping.h
  lib/hwasan/hwasan_poisoning.cc
  lib/hwasan/hwasan_report.cc
  lib/hwasan/hwasan_thread.cc

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D45847.143183.patch
Type: text/x-patch
Size: 24575 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20180419/248738b9/attachment.bin>


More information about the llvm-commits mailing list