[all-commits] [llvm/llvm-project] 03d593: [sanitizers][test] Test sanitizer_common and ubsan...

rorth via All-commits all-commits at lists.llvm.org
Fri Nov 20 05:07:16 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 03d593dd7e6de269381ac71d0269a207f4dd1eeb
      https://github.com/llvm/llvm-project/commit/03d593dd7e6de269381ac71d0269a207f4dd1eeb
  Author: Rainer Orth <ro at gcc.gnu.org>
  Date:   2020-11-20 (Fri, 20 Nov 2020)

  Changed paths:
    M compiler-rt/lib/sanitizer_common/sanitizer_platform_interceptors.h
    M compiler-rt/test/sanitizer_common/CMakeLists.txt
    M compiler-rt/test/sanitizer_common/TestCases/Posix/fgetln.cpp
    M compiler-rt/test/sanitizer_common/TestCases/Posix/getpass.cpp
    M compiler-rt/test/sanitizer_common/TestCases/Posix/getpw_getgr.cpp
    M compiler-rt/test/sanitizer_common/TestCases/Posix/lstat.cpp
    M compiler-rt/test/sanitizer_common/TestCases/Posix/uname.c
    M compiler-rt/test/sanitizer_common/lit.common.cfg.py
    M compiler-rt/test/ubsan_minimal/lit.common.cfg.py

  Log Message:
  -----------
  [sanitizers][test] Test sanitizer_common and ubsan_minimal on Solaris

During the initial Solaris sanitizer port, I missed to enable the
`sanitizer_common` and `ubsan_minimal` testsuites.  This patch fixes this,
correcting a few unportabilities:

- `Posix/getpass.cpp` failed to link since Solaris lacks `libutil`.
  Omitting the library lets the test `PASS`, but I thought adding `%libutil`
  along the lines of `%librt` to be overkill.
- One subtest of `Posix/getpw_getgr.cpp` is disabled because Solaris
  `getpwent_r` has a different signature than expected.
- `/dev/null` is a symlink on Solaris.
- XPG7 specifies that `uname` returns a non-negative value on success.

Tested on `amd64-pc-solaris2.11` and `sparcv9-sun-solaris2.11`.

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




More information about the All-commits mailing list