[ 0:00] compiling /home/xrockai/src/divine/nightly/test/libcxx/containers/count.pass.cpp [ 0:00] In file included from /home/xrockai/src/divine/nightly/test/libcxx/containers/count.pass.cpp:18: [ 0:00] In file included from /dios/libcxx/include/set:427: [ 0:00] In file included from /dios/libcxx/include/__tree:14: [ 0:00] In file included from /dios/libcxx/include/iterator:420: [ 0:00] In file included from /dios/libcxx/include/iosfwd:95: [ 0:00] In file included from /dios/libcxx/include/wchar.h:118: [ 0:00] In file included from /dios/include/wchar.h:9: [ 0:00] In file included from /dios/include/_PDCLIB/int.h:16: [ 0:00] /dios/include/_PDCLIB/cdefs.h:69:10: warning: Unsupported _ _cplusplus (__cplusplus) (too new) (supported: ISO/IEC 14882:1997, ISO/IEC 14882:2011). [ 0:00] #warning Unsupported _ _cplusplus (__cplusplus) (too new) (supported: ISO/IEC 14882:1997, ISO/IEC 14882:2011). [ 0:00] ^ [ 0:00] 1 warning generated. [ 0:02] compiling /dios/lib/config/seqklee.bc [ 0:02] setting up pass: functionmeta, options = [ 0:06] setting up pass: fuse-ctors, options = [ 0:06] KLEE: output directory is "/var/obj/divine-nightly/semidbg/test/__test_work_dir.18/_klee_out" [ 0:14] KLEE: Using Z3 solver backend [ 0:14] WARNING: this target does not support the llvm.stacksave intrinsic. [ 0:14] warning: Linking two modules of different target triples: klee_div_zero_check.bc' is 'x86_64-unknown-linux-gnu' whereas 'klee.bc' is 'x86_64-unknown-none-elf' [ 0:15] [ 0:15] KLEE: WARNING: undefined reference to function: _Z10klee_abortv [ 0:28] KLEE: WARNING: undefined reference to function: __dios_tainted_init [ 0:28] KLEE: WARNING: undefined reference to function: klee_free [ 0:28] KLEE: WARNING: undefined reference to function: klee_malloc [ 0:28] KLEE: WARNING ONCE: Using zero size array fix for landingpad instruction filter [ 0:29] i:1 [ 0:29] KLEE: WARNING ONCE: Alignment of memory from call "klee_malloc" is not modelled. Using alignment of 8. [ 0:29] about to __boot:0 [ 0:29] about to run the scheduler:0 [ 0:29] KLEE: WARNING ONCE: calling external: __dios_tainted_init() at /dios/libc/sys/start.cpp:49 5 [ 0:29] KLEE: ERROR: /dios/libc/sys/start.cpp:87: failed external call: __dios_tainted_init [ 0:29] KLEE: NOTE: now ignoring this error at this location [ 0:29] KLEE: ERROR: EXITING ON ERROR: [ 0:31] Error: failed external call: __dios_tainted_init [ 0:31] File: /dios/libc/sys/start.cpp [ 0:31] Line: 87 [ 0:31] assembly.ll line: 92263 [ 0:31] Stack: [ 0:31] #000092263 in __dios_start (l=2, argc=1, argv=94089958695944, envp=94089958765064) at /dios/libc/sys/start.cpp:87 [ 0:31] #100040092 in _ZN6__dios10sched_nullINS_5ClockINS_10NondetKleeINS_4BaseEEEEEE13run_schedulerINS_7ContextEEEvv () at /dios/sys/sched_null.hpp:163 [ 0:31] #200100843 in klee_boot (argc=2, argv=94089776397824) at /dios/arch/klee/boot.c:41 [ 0:31] [ 0:31] [ 0:31] 1 /* TAGS: c++ fin */ [ 0:31] 2 /* CC_OPTS: -std=c++2a */ [ 0:31] 3 /* VERIFY_OPTS: -o nofail:malloc */ [ 0:31] 4 //===----------------------------------------------------------------------===// [ 0:31] 5 // [ 0:31] 6 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. [ 0:31] 7 // See https://llvm.org/LICENSE.txt for license information. [ 0:31] 8 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception [ 0:31] 9 // [ 0:31] 10 //===----------------------------------------------------------------------===// [ 0:31] 11 [ 0:31] 12 // [ 0:31] 13 [ 0:31] 14 // class set [ 0:31] 15 [ 0:31] 16 // size_type count(const key_type& k) const; [ 0:31] 17 [ 0:31] 18 #include [ 0:31] 19 #include [ 0:31] 20 [ 0:31] 21 #include "test_macros.h" [ 0:31] 22 #include "min_allocator.h" [ 0:31] 23 #include "private_constructor.hpp" [ 0:31] 24 [ 0:31] 25 int main(int, char**) [ 0:31] 26 { [ 0:31] 27 { [ 0:31] 28 typedef int V; [ 0:31] 29 typedef std::set M; [ 0:31] 30 typedef M::size_type R; [ 0:31] 31 V ar[] = [ 0:31] 32 { [ 0:31] 33 5, [ 0:31] 34 6, [ 0:31] 35 7, [ 0:31] 36 8, [ 0:31] 37 9, [ 0:31] 38 10, [ 0:31] 39 11, [ 0:31] 40 12 [ 0:31] 41 }; [ 0:31] 42 const M m(ar, ar+sizeof(ar)/sizeof(ar[0])); [ 0:31] 43 R r = m.count(5); [ 0:31] 44 assert(r == 1); [ 0:31] 45 r = m.count(6); [ 0:31] 46 assert(r == 1); [ 0:31] 47 r = m.count(7); [ 0:31] 48 assert(r == 1); [ 0:31] 49 r = m.count(8); [ 0:31] 50 assert(r == 1); [ 0:31] 51 r = m.count(9); [ 0:31] 52 assert(r == 1); [ 0:31] 53 r = m.count(10); [ 0:31] 54 assert(r == 1); [ 0:31] 55 r = m.count(11); [ 0:31] 56 assert(r == 1); [ 0:31] 57 r = m.count(12); [ 0:31] 58 assert(r == 1); [ 0:31] 59 r = m.count(4); [ 0:31] 60 assert(r == 0); [ 0:31] 61 } [ 0:31] 62 #if TEST_STD_VER >= 11 [ 0:31] 63 { [ 0:31] 64 typedef int V; [ 0:31] 65 typedef std::set, min_allocator> M; [ 0:31] 66 typedef M::size_type R; [ 0:31] 67 V ar[] = [ 0:31] 68 { [ 0:31] 69 5, [ 0:31] 70 6, [ 0:31] 71 7, [ 0:31] 72 8, [ 0:31] 73 9, [ 0:31] 74 10, [ 0:31] 75 11, [ 0:31] 76 12 [ 0:31] 77 }; [ 0:31] 78 const M m(ar, ar+sizeof(ar)/sizeof(ar[0])); [ 0:31] 79 R r = m.count(5); [ 0:31] 80 assert(r == 1); [ 0:31] 81 r = m.count(6); [ 0:31] 82 assert(r == 1); [ 0:31] 83 r = m.count(7); [ 0:31] 84 assert(r == 1); [ 0:31] 85 r = m.count(8); [ 0:31] 86 assert(r == 1); [ 0:31] 87 r = m.count(9); [ 0:31] 88 assert(r == 1); [ 0:31] 89 r = m.count(10); [ 0:31] 90 assert(r == 1); [ 0:31] 91 r = m.count(11); [ 0:31] 92 assert(r == 1); [ 0:31] 93 r = m.count(12); [ 0:31] 94 assert(r == 1); [ 0:31] 95 r = m.count(4); [ 0:31] 96 assert(r == 0); [ 0:31] 97 } [ 0:31] 98 #endif [ 0:31] 99 #if TEST_STD_VER > 11 [ 0:31] 100 { [ 0:31] 101 typedef int V; [ 0:31] 102 typedef std::set> M; [ 0:31] 103 typedef M::size_type R; [ 0:31] 104 V ar[] = [ 0:31] 105 { [ 0:31] 106 5, [ 0:31] 107 6, [ 0:31] 108 7, [ 0:31] 109 8, [ 0:31] 110 9, [ 0:31] 111 10, [ 0:31] 112 11, [ 0:31] 113 12 [ 0:31] 114 }; [ 0:31] 115 const M m(ar, ar+sizeof(ar)/sizeof(ar[0])); [ 0:31] 116 R r = m.count(5); [ 0:31] 117 assert(r == 1); [ 0:31] 118 r = m.count(6); [ 0:31] 119 assert(r == 1); [ 0:31] 120 r = m.count(7); [ 0:31] 121 assert(r == 1); [ 0:31] 122 r = m.count(8); [ 0:31] 123 assert(r == 1); [ 0:31] 124 r = m.count(9); [ 0:31] 125 assert(r == 1); [ 0:31] 126 r = m.count(10); [ 0:31] 127 assert(r == 1); [ 0:31] 128 r = m.count(11); [ 0:31] 129 assert(r == 1); [ 0:31] 130 r = m.count(12); [ 0:31] 131 assert(r == 1); [ 0:31] 132 r = m.count(4); [ 0:31] 133 assert(r == 0); [ 0:31] 134 } [ 0:31] 135 { [ 0:31] 136 typedef PrivateConstructor V; [ 0:31] 137 typedef std::set> M; [ 0:31] 138 typedef M::size_type R; [ 0:31] 139 [ 0:31] 140 M m; [ 0:31] 141 m.insert ( V::make ( 5 )); [ 0:31] 142 m.insert ( V::make ( 6 )); [ 0:31] 143 m.insert ( V::make ( 7 )); [ 0:31] 144 m.insert ( V::make ( 8 )); [ 0:31] 145 m.insert ( V::make ( 9 )); [ 0:31] 146 m.insert ( V::make ( 10 )); [ 0:31] 147 m.insert ( V::make ( 11 )); [ 0:31] 148 m.insert ( V::make ( 12 )); [ 0:31] 149 [ 0:31] 150 const M& mc = m; [ 0:31] 151 [ 0:31] 152 R r = mc.count(5); [ 0:31] 153 assert(r == 1); [ 0:31] 154 r = mc.count(6); [ 0:31] 155 assert(r == 1); [ 0:31] 156 r = mc.count(7); [ 0:31] 157 assert(r == 1); [ 0:31] 158 r = mc.count(8); [ 0:31] 159 assert(r == 1); [ 0:31] 160 r = mc.count(9); [ 0:31] 161 assert(r == 1); [ 0:31] 162 r = mc.count(10); [ 0:31] 163 assert(r == 1); [ 0:31] 164 r = mc.count(11); [ 0:31] 165 assert(r == 1); [ 0:31] 166 r = mc.count(12); [ 0:31] 167 assert(r == 1); [ 0:31] 168 r = mc.count(4); [ 0:31] 169 assert(r == 0); [ 0:31] 170 } [ 0:31] 171 #endif [ 0:31] 172 [ 0:31] 173 [ 0:31] 174 return 0; [ 0:31] 175 } [ 0:31] # no errors were expected but one was found anyway