1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 02:33:06 +01:00
llvm-mirror/utils/unittest
Evgenii Stepanov 60a4b60e92 Cherry-pick gtest fix for asan tests.
Summary:
681454dae4

Clone+exec death test allocates a single page of stack to run chdir + exec on.
This is not enough when gtest is built with ASan and run on particular
hardware.

With ASan on x86_64, ExecDeathTestChildMain has frame size of 1728 bytes.

Call to chdir() in ExecDeathTestChildMain ends up in
_dl_runtime_resolve_xsavec, which attempts to save register state on the stack;
according to cpuid(0xd) XSAVE register save area size is 2568 on my machine.

This results in something like this in all death tests:
  Result: died but not with expected error.
  ...
  [  DEATH   ] AddressSanitizer:DEADLYSIGNAL
  [  DEATH   ] =================================================================
  [  DEATH   ] ==178637==ERROR: AddressSanitizer: stack-overflow on address ...

PiperOrigin-RevId: 278709790

Reviewers: pcc

Subscribers: llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D70332
2019-11-20 14:12:51 -08:00
..
googlemock [unittests] Mark private gmock headers with IWYU pragmas. NFC 2019-08-07 08:45:38 +00:00
googletest Cherry-pick gtest fix for asan tests. 2019-11-20 14:12:51 -08:00
UnitTestMain Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
CMakeLists.txt Revert CMake: Make most target symbols hidden by default 2019-06-11 03:21:13 +00:00
LLVMBuild.txt Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00