[all-commits] [llvm/llvm-project] 1abcf5: [lsan][Fuchsia] Fix bounds checking for thread_loc...

PiJoules via All-commits all-commits at lists.llvm.org
Wed Aug 30 13:50:54 PDT 2023

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1abcf584023e400e33ed66ab9042f75990adbf4c
  Author: Leonard Chan <leonardchan at google.com>
  Date:   2023-08-30 (Wed, 30 Aug 2023)

  Changed paths:
    M compiler-rt/lib/lsan/lsan_common_fuchsia.cpp

  Log Message:
  [lsan][Fuchsia] Fix bounds checking for thread_local allocator cache when scanning TLS regions

When scanning over TLS regions, we attempt to check if one of the regions is
one of the thread_local allocator caches which would be located in one of the
TLS blocks pointer to by the DTV. This is to prevent marking a pointer that was
allocated by the primary allocator (from a thread_local cache) as reachable. The
check is a simple bounds check to see if the allocator cache is within the
bounds of one of the TLS block we're iterating over, but it looks like the check
for the end of the cache is slightly incorrect.

Differential Revision: https://reviews.llvm.org/D156015

More information about the All-commits mailing list