This is an archive of the discontinued LLVM Phabricator instance.

[compiler-rt] Move ASan non-Linux-specific tests out of the Linux/ directory
ClosedPublic

Authored by kubamracek on Nov 12 2014, 7:58 PM.

Details

Reviewers
samsonov
timurrrr
Summary

I noticed that several testcases in the test/asan/TestCases/Linux/ directory are not really Linux specific. The following tests from the Linux directory pass on OS X 10.10:

  • glob.cc
  • glob_test_root
  • heap-overflow-large.cc
  • heavy_uar_test.cc
  • interception_failure_test.cc
  • new_array_cookie_test.cc
  • new_array_cookie_uaf_test.cc
  • new_array_cookie_with_new_from_class.cc
  • tsd_dtor_leak.cc

Let's move them one directory up, so they are run on other platforms as well.

Diff Detail

Event Timeline

kubamracek updated this revision to Diff 16131.Nov 12 2014, 7:58 PM
kubamracek retitled this revision from to [compiler-rt] Move ASan non-Linux-specific tests out of the Linux/ directory.
kubamracek updated this object.
kubamracek edited the test plan for this revision. (Show Details)
kubamracek added subscribers: Unknown Object (MLST), samsonov, glider.
samsonov added inline comments.
test/asan/TestCases/glob.cc
10

This test should go to TestCases/Posix. Sooner or later we'll start to run tests from TestCases on Windows.

test/asan/TestCases/interception_failure_test.cc
3

I'm not sure this works on Windows. Timur?

test/asan/TestCases/new_array_cookie_test.cc
1

This is also not implemented for Windows

test/asan/TestCases/tsd_dtor_leak.cc
8

This test is also Posix-specific.

samsonov added a subscriber: timurrrr.
timurrrr added inline comments.Nov 13 2014, 1:56 PM
test/asan/TestCases/interception_failure_test.cc
3

I don't know. If this is an important feature, I'm fine if you put it into the directory with common tests and I'll take a look later when I get my hands to enabling these tests on Windows.

Moving the new_array_*, tsd_dtor_leak.cc, glob.cc to Posix.

emaste added a subscriber: emaste.Nov 17 2014, 10:55 AM
samsonov accepted this revision.Nov 20 2014, 3:46 PM
samsonov edited edge metadata.

LGTM, Please watch for the buildbots after the commit. I hope that these tests will work on FreeBSD, but don't have confidence in it. Thanks for doing this!

interception_failure_test.cc
1 ↗(On Diff #16298)

Wow, glad to hear this test works on Mac.

This revision is now accepted and ready to land.Nov 20 2014, 3:46 PM
kubamracek closed this revision.Nov 20 2014, 4:22 PM

Landed in r222486.

I hope that these tests will work on FreeBSD, but don't have confidence in it.

Some of them do not pass, but let's consider them one by one.

test/asan/TestCases/Linux/new_array_cookie_with_new_from_class.cc