[libcxx] r273372 - UBSan doesn't globally replace new/delete but it still makes some tests fail. Investigation needed.

Eric Fiselier via cfe-commits cfe-commits at lists.llvm.org
Tue Jun 21 21:00:46 PDT 2016


Author: ericwf
Date: Tue Jun 21 23:00:45 2016
New Revision: 273372

URL: http://llvm.org/viewvc/llvm-project?rev=273372&view=rev
Log:
UBSan doesn't globally replace new/delete but it still makes some tests fail. Investigation needed.

Modified:
    libcxx/trunk/test/libcxx/test/config.py
    libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow_replace.pass.cpp
    libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_replace.pass.cpp
    libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new.pass.cpp
    libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow_replace.pass.cpp
    libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_calls_unsized_delete.pass.cpp
    libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.sh.cpp

Modified: libcxx/trunk/test/libcxx/test/config.py
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/libcxx/test/config.py?rev=273372&r1=273371&r2=273372&view=diff
==============================================================================
--- libcxx/trunk/test/libcxx/test/config.py (original)
+++ libcxx/trunk/test/libcxx/test/config.py Tue Jun 21 23:00:45 2016
@@ -628,7 +628,6 @@ class Configuration(object):
                 self.cxx.compile_flags += ['-O3']
                 self.env['UBSAN_OPTIONS'] = 'print_stacktrace=1'
                 self.config.available_features.add('ubsan')
-                self.config.available_features.add('sanitizer-new-delete')
             elif san == 'Thread':
                 self.cxx.flags += ['-fsanitize=thread']
                 self.config.available_features.add('tsan')

Modified: libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow_replace.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow_replace.pass.cpp?rev=273372&r1=273371&r2=273372&view=diff
==============================================================================
--- libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow_replace.pass.cpp (original)
+++ libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow_replace.pass.cpp Tue Jun 21 23:00:45 2016
@@ -11,6 +11,10 @@
 
 // UNSUPPORTED: sanitizer-new-delete
 
+// TODO Investigate why UBSAN prevents new from calling our replacement.
+// XFAIL: ubsan
+
+
 #include <new>
 #include <cstddef>
 #include <cstdlib>

Modified: libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_replace.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_replace.pass.cpp?rev=273372&r1=273371&r2=273372&view=diff
==============================================================================
--- libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_replace.pass.cpp (original)
+++ libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.array/new_array_replace.pass.cpp Tue Jun 21 23:00:45 2016
@@ -11,6 +11,10 @@
 
 // UNSUPPORTED: sanitizer-new-delete
 
+// TODO Investigate why UBSAN prevents new from calling our replacement.
+// XFAIL: ubsan
+
+
 #include <new>
 #include <cstddef>
 #include <cstdlib>

Modified: libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new.pass.cpp?rev=273372&r1=273371&r2=273372&view=diff
==============================================================================
--- libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new.pass.cpp (original)
+++ libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new.pass.cpp Tue Jun 21 23:00:45 2016
@@ -8,6 +8,7 @@
 //===----------------------------------------------------------------------===//
 
 // XFAIL: libcpp-no-exceptions
+
 // test operator new
 
 // asan and msan will not call the new handler.

Modified: libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow_replace.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow_replace.pass.cpp?rev=273372&r1=273371&r2=273372&view=diff
==============================================================================
--- libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow_replace.pass.cpp (original)
+++ libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow_replace.pass.cpp Tue Jun 21 23:00:45 2016
@@ -11,6 +11,10 @@
 
 // UNSUPPORTED: sanitizer-new-delete
 
+// TODO Investigate why UBSAN prevents nothrow new from calling our replacement.
+// XFAIL: ubsan
+
+
 #include <new>
 #include <cstddef>
 #include <cstdlib>

Modified: libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_calls_unsized_delete.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_calls_unsized_delete.pass.cpp?rev=273372&r1=273371&r2=273372&view=diff
==============================================================================
--- libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_calls_unsized_delete.pass.cpp (original)
+++ libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_calls_unsized_delete.pass.cpp Tue Jun 21 23:00:45 2016
@@ -13,6 +13,10 @@
 
 // UNSUPPORTED: sanitizer-new-delete
 
+// TODO Investigate why UBSAN prevents new from calling our replacement.
+// XFAIL: ubsan
+
+
 #include <new>
 #include <cstddef>
 #include <cstdlib>

Modified: libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.sh.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.sh.cpp?rev=273372&r1=273371&r2=273372&view=diff
==============================================================================
--- libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.sh.cpp (original)
+++ libcxx/trunk/test/std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.sh.cpp Tue Jun 21 23:00:45 2016
@@ -14,6 +14,9 @@
 
 // UNSUPPORTED: sanitizer-new-delete
 
+// TODO Investigate why UBSAN prevents new from calling our replacement.
+// XFAIL: ubsan
+
 // NOTE: Only clang-3.7 and GCC 5.1 and greater support -fsized-deallocation.
 // REQUIRES: fsized-deallocation
 




More information about the cfe-commits mailing list