[all-commits] [llvm/llvm-project] 555661: [GWP-ASan] Port tests to Fuchsia

Kostya Kortchinsky via All-commits all-commits at lists.llvm.org
Wed Nov 18 13:36:42 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 5556616b5b5223f95607ad94053a55f0deaf2762
      https://github.com/llvm/llvm-project/commit/5556616b5b5223f95607ad94053a55f0deaf2762
  Author: Kostya Kortchinsky <kostyak at google.com>
  Date:   2020-11-18 (Wed, 18 Nov 2020)

  Changed paths:
    M compiler-rt/lib/gwp_asan/tests/alignment.cpp
    M compiler-rt/lib/gwp_asan/tests/compression.cpp
    M compiler-rt/lib/gwp_asan/tests/crash_handler_api.cpp
    M compiler-rt/lib/gwp_asan/tests/driver.cpp
    M compiler-rt/lib/gwp_asan/tests/harness.cpp
    M compiler-rt/lib/gwp_asan/tests/harness.h
    M compiler-rt/lib/gwp_asan/tests/iterate.cpp
    M compiler-rt/lib/gwp_asan/tests/late_init.cpp
    M compiler-rt/lib/gwp_asan/tests/mutex_test.cpp
    M compiler-rt/lib/gwp_asan/tests/slot_reuse.cpp

  Log Message:
  -----------
  [GWP-ASan] Port tests to Fuchsia

This modifies the tests so that they can be run on Fuchsia:
- add the necessary includes for `set`/`vector` etc
- do the few modifications required to use zxtest instead og gtest

`backtrace.cpp` requires stacktrace support that Fuchsia doesn't have
yet, and `enable_disable.cpp` currently uses `fork()` which Fuchsia
doesn't support yet. I'll revisit this later.

I chose to use `harness.h` to hold my "platform-specific" include and
namespace, and using this header in tests rather than `gtest.h`,
which I am open to change if someone would rather go another direction.

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




More information about the All-commits mailing list