[all-commits] [llvm/llvm-project] 129827: msan: account for AVX state when unpoison ucontext_t

Dmitry Vyukov via All-commits all-commits at lists.llvm.org
Wed Jan 5 04:20:53 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1298273e8206a8fc28369c1ac8dc71a0c9b3851e
      https://github.com/llvm/llvm-project/commit/1298273e8206a8fc28369c1ac8dc71a0c9b3851e
  Author: Dmitry Vyukov <dvyukov at google.com>
  Date:   2022-01-05 (Wed, 05 Jan 2022)

  Changed paths:
    M compiler-rt/lib/msan/msan_interceptors.cpp
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_freebsd.cpp
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_freebsd.h
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_netbsd.cpp
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_netbsd.h
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.cpp
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_posix.h
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_solaris.cpp
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_limits_solaris.h
    M compiler-rt/lib/sanitizer_common/sanitizer_syscalls_netbsd.inc
    A compiler-rt/test/msan/Linux/signal_mcontext.cpp

  Log Message:
  -----------
  msan: account for AVX state when unpoison ucontext_t

ucontext_t can be larger than its static size if it contains
AVX state and YMM/ZMM registers.
Currently a signal handler that tries to access that state
can produce false positives with random origins on stack.
Account for the additional ucontext_t state.

Reviewed By: vitalybuka

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




More information about the All-commits mailing list