From 0769ecd70dcc82d61d0176fb392607ea9bb580bd Mon Sep 17 00:00:00 2001 From: Daniel James Date: Fri, 29 Jul 2016 12:19:50 +0100 Subject: [PATCH 1/7] Some more checks. The intel-linux failures I'm getting now are odd. This find test is failing for iterator, but not const_iterator. So maybe it's a problem with the iterator object. The failures I was getting before have disappeared, so I'm not sure about that. --- test/unordered/find_tests.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/unordered/find_tests.cpp b/test/unordered/find_tests.cpp index a310d40c..5c864788 100644 --- a/test/unordered/find_tests.cpp +++ b/test/unordered/find_tests.cpp @@ -38,10 +38,10 @@ void find_tests1(X*, test::random_generator generator) { BOOST_DEDUCED_TYPENAME X::key_type key = test::get_key(*it1); iterator pos = x.find(key); - BOOST_DEDUCED_TYPENAME X::const_iterator - const_pos = x_const.find(key); - BOOST_TEST(pos != x.end() && - x.key_eq()(key, test::get_key(*pos))); + BOOST_DEDUCED_TYPENAME X::const_iterator const_pos = x_const.find(key); + BOOST_TEST(pos != x.end()); + BOOST_TEST(pos != x.end() && x.key_eq()(key, test::get_key(*pos))); + BOOST_TEST(const_pos != x_const.end()); BOOST_TEST(const_pos != x_const.end() && x_const.key_eq()(key, test::get_key(*const_pos))); From e3dd1f276e4b1fefc1200a78be19053c2c4f31b2 Mon Sep 17 00:00:00 2001 From: Daniel James Date: Wed, 3 Aug 2016 14:19:56 +0100 Subject: [PATCH 2/7] Use clang and gcc's sanitizers in travis. --- .travis.yml | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/.travis.yml b/.travis.yml index 732a983f..ffa6bbf8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -24,13 +24,19 @@ matrix: env: BJAM_TOOLSET=clang - compiler: clang env: BJAM_TOOLSET=clang-std11 + - compiler: clang + env: BJAM_TOOLSET=clang-mem + - compiler: clang + env: BJAM_TOOLSET=clang-mem-std11 before_script: - | - echo "using gcc : : g++-4.8 --std=c++03 ;" > ~/user-config.jam - echo "using gcc : std11 : g++-4.8 --std=c++11 ;" >> ~/user-config.jam - echo "using clang : : clang++ --std=c++03 ;" >> ~/user-config.jam - echo "using clang : std11 : clang++ --std=c++11 ;" >> ~/user-config.jam + echo "using gcc : : g++-4.8 --std=c++03 -fsanitize=address ;" > ~/user-config.jam + echo "using gcc : std11 : g++-4.8 --std=c++11 -fsanitize=address ;" >> ~/user-config.jam + echo "using clang : : clang++ --std=c++03 -fsanitize=address ;" >> ~/user-config.jam + echo "using clang : std11 : clang++ --std=c++11 -fsanitize=address ;" >> ~/user-config.jam + echo "using clang : mem : clang++ --std=c++03 -fsanitize=memory ;" >> ~/user-config.jam + echo "using clang : mem-std11 : clang++ --std=c++11 -fsanitize=memory ;" >> ~/user-config.jam - cat ~/user-config.jam - touch Jamroot.jam From 041fee64df06be6275421a24e8ed8a29f739adc9 Mon Sep 17 00:00:00 2001 From: Daniel James Date: Thu, 4 Aug 2016 13:35:46 +0100 Subject: [PATCH 3/7] Don't stop Boost.Build on error. --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index ffa6bbf8..da4f5aaa 100644 --- a/.travis.yml +++ b/.travis.yml @@ -41,4 +41,4 @@ before_script: - touch Jamroot.jam script: - - cd test && bjam -q ${BJAM_TOOLSET} include=${TRAVIS_BUILD_DIR}/include + - cd test && bjam ${BJAM_TOOLSET} include=${TRAVIS_BUILD_DIR}/include From cdb887e880f86618714f82d3f3c7450d805290fa Mon Sep 17 00:00:00 2001 From: Daniel James Date: Thu, 4 Aug 2016 13:35:47 +0100 Subject: [PATCH 4/7] Clean up a memory leak in a test. --- test/unordered/compile_tests.hpp | 1 + 1 file changed, 1 insertion(+) diff --git a/test/unordered/compile_tests.hpp b/test/unordered/compile_tests.hpp index 38d7dda2..c83ae41f 100644 --- a/test/unordered/compile_tests.hpp +++ b/test/unordered/compile_tests.hpp @@ -148,6 +148,7 @@ void unordered_destructible_test(X&) X* ptr = new X(); X& a1 = *ptr; (&a1)->~X(); + ::operator delete((void*)(&a1)); X a,b; X const a_const; From 81cc7730139be71e19171997ebd96d4153ef9c5a Mon Sep 17 00:00:00 2001 From: Daniel James Date: Thu, 4 Aug 2016 13:35:48 +0100 Subject: [PATCH 5/7] Try to fix mem/std11 toolset. --- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index da4f5aaa..114fd8db 100644 --- a/.travis.yml +++ b/.travis.yml @@ -27,7 +27,7 @@ matrix: - compiler: clang env: BJAM_TOOLSET=clang-mem - compiler: clang - env: BJAM_TOOLSET=clang-mem-std11 + env: BJAM_TOOLSET=clang-mem_std11 before_script: - | @@ -36,7 +36,7 @@ before_script: echo "using clang : : clang++ --std=c++03 -fsanitize=address ;" >> ~/user-config.jam echo "using clang : std11 : clang++ --std=c++11 -fsanitize=address ;" >> ~/user-config.jam echo "using clang : mem : clang++ --std=c++03 -fsanitize=memory ;" >> ~/user-config.jam - echo "using clang : mem-std11 : clang++ --std=c++11 -fsanitize=memory ;" >> ~/user-config.jam + echo "using clang : mem_std11 : clang++ --std=c++11 -fsanitize=memory ;" >> ~/user-config.jam - cat ~/user-config.jam - touch Jamroot.jam From 7687c99708ee0af13b43e3a802c84859320a1dc6 Mon Sep 17 00:00:00 2001 From: Daniel James Date: Thu, 4 Aug 2016 13:35:48 +0100 Subject: [PATCH 6/7] Disable clang c++03 memory sanitizer tests. --- .travis.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 114fd8db..95158896 100644 --- a/.travis.yml +++ b/.travis.yml @@ -24,8 +24,10 @@ matrix: env: BJAM_TOOLSET=clang - compiler: clang env: BJAM_TOOLSET=clang-std11 - - compiler: clang - env: BJAM_TOOLSET=clang-mem + # Unfortunately the memory sanitizer was just finding issues with + # the standard containers for this toolset. So not very useful right now. + #- compiler: clang + # env: BJAM_TOOLSET=clang-mem - compiler: clang env: BJAM_TOOLSET=clang-mem_std11 From 992f9ccf211402f26c812400f5a39ab82509780a Mon Sep 17 00:00:00 2001 From: Daniel James Date: Sun, 14 Aug 2016 20:39:46 +0100 Subject: [PATCH 7/7] Turn off memory sanitizer on travis. It's not working at all. --- .travis.yml | 8 -------- 1 file changed, 8 deletions(-) diff --git a/.travis.yml b/.travis.yml index 95158896..6f98b329 100644 --- a/.travis.yml +++ b/.travis.yml @@ -24,12 +24,6 @@ matrix: env: BJAM_TOOLSET=clang - compiler: clang env: BJAM_TOOLSET=clang-std11 - # Unfortunately the memory sanitizer was just finding issues with - # the standard containers for this toolset. So not very useful right now. - #- compiler: clang - # env: BJAM_TOOLSET=clang-mem - - compiler: clang - env: BJAM_TOOLSET=clang-mem_std11 before_script: - | @@ -37,8 +31,6 @@ before_script: echo "using gcc : std11 : g++-4.8 --std=c++11 -fsanitize=address ;" >> ~/user-config.jam echo "using clang : : clang++ --std=c++03 -fsanitize=address ;" >> ~/user-config.jam echo "using clang : std11 : clang++ --std=c++11 -fsanitize=address ;" >> ~/user-config.jam - echo "using clang : mem : clang++ --std=c++03 -fsanitize=memory ;" >> ~/user-config.jam - echo "using clang : mem_std11 : clang++ --std=c++11 -fsanitize=memory ;" >> ~/user-config.jam - cat ~/user-config.jam - touch Jamroot.jam