[ 0:00] compiling /home/xrockai/src/divine/nightly/test/libcxx/forwardlist/iterators.pass.cpp [ 0:00] compiling /dios/lib/config/seqklee.bc [ 0:01] setting up pass: functionmeta, options = [ 0:03] setting up pass: fuse-ctors, options = [ 0:03] KLEE: output directory is "/var/obj/divine-nightly/semidbg/test/__test_work_dir.8/_klee_out" [ 0:06] KLEE: Using Z3 solver backend [ 0:06] WARNING: this target does not support the llvm.stacksave intrinsic. [ 0:06] 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:06] [ 0:06] KLEE: WARNING: undefined reference to function: _Z10klee_abortv [ 0:10] KLEE: WARNING: undefined reference to function: __dios_tainted_init [ 0:10] KLEE: WARNING: undefined reference to function: klee_free [ 0:10] KLEE: WARNING: undefined reference to function: klee_malloc [ 0:10] KLEE: WARNING ONCE: Using zero size array fix for landingpad instruction filter [ 0:10] i:1 [ 0:10] KLEE: WARNING ONCE: Alignment of memory from call "klee_malloc" is not modelled. Using alignment of 8. [ 0:10] about to __boot:0 [ 0:10] about to run the scheduler:0 [ 0:10] KLEE: WARNING ONCE: calling external: __dios_tainted_init() at /dios/libc/sys/start.cpp:49 5 [ 0:10] KLEE: ERROR: /dios/libc/sys/start.cpp:87: failed external call: __dios_tainted_init [ 0:10] KLEE: NOTE: now ignoring this error at this location [ 0:10] KLEE: ERROR: EXITING ON ERROR: [ 0:11] Error: failed external call: __dios_tainted_init [ 0:11] File: /dios/libc/sys/start.cpp [ 0:11] Line: 87 [ 0:11] assembly.ll line: 71623 [ 0:11] Stack: [ 0:11] #000071623 in __dios_start (l=0, argc=1, argv=94379473056264, envp=94379473125384) at /dios/libc/sys/start.cpp:87 [ 0:11] #100019452 in _ZN6__dios10sched_nullINS_5ClockINS_10NondetKleeINS_4BaseEEEEEE13run_schedulerINS_7ContextEEEvv () at /dios/sys/sched_null.hpp:163 [ 0:11] #200080203 in klee_boot (argc=2, argv=94379439074688) at /dios/arch/klee/boot.c:41 [ 0:11] [ 0:11] [ 0:11] 1 /* TAGS: c++ */ [ 0:11] 2 /* VERIFY_OPTS: -o nofail:malloc */ [ 0:11] 3 //===----------------------------------------------------------------------===// [ 0:11] 4 // [ 0:11] 5 // The LLVM Compiler Infrastructure [ 0:11] 6 // [ 0:11] 7 // This file is dual licensed under the MIT and the University of Illinois Open [ 0:11] 8 // Source Licenses. See LICENSE.TXT for details. [ 0:11] 9 // [ 0:11] 10 //===----------------------------------------------------------------------===// [ 0:11] 11 [ 0:11] 12 // [ 0:11] 13 [ 0:11] 14 // iterator begin(); [ 0:11] 15 // iterator end(); [ 0:11] 16 // const_iterator begin() const; [ 0:11] 17 // const_iterator end() const; [ 0:11] 18 // const_iterator cbegin() const; [ 0:11] 19 // const_iterator cend() const; [ 0:11] 20 [ 0:11] 21 #include [ 0:11] 22 #include [ 0:11] 23 #include [ 0:11] 24 [ 0:11] 25 #include "min_allocator.h" [ 0:11] 26 [ 0:11] 27 int main() [ 0:11] 28 { [ 0:11] 29 { [ 0:11] 30 typedef int T; [ 0:11] 31 typedef std::forward_list C; [ 0:11] 32 C c; [ 0:11] 33 C::iterator i = c.begin(); [ 0:11] 34 C::iterator j = c.end(); [ 0:11] 35 assert(std::distance(i, j) == 0); [ 0:11] 36 assert(i == j); [ 0:11] 37 } [ 0:11] 38 { [ 0:11] 39 typedef int T; [ 0:11] 40 typedef std::forward_list C; [ 0:11] 41 const C c; [ 0:11] 42 C::const_iterator i = c.begin(); [ 0:11] 43 C::const_iterator j = c.end(); [ 0:11] 44 assert(std::distance(i, j) == 0); [ 0:11] 45 assert(i == j); [ 0:11] 46 } [ 0:11] 47 { [ 0:11] 48 typedef int T; [ 0:11] 49 typedef std::forward_list C; [ 0:11] 50 C c; [ 0:11] 51 C::const_iterator i = c.cbegin(); [ 0:11] 52 C::const_iterator j = c.cend(); [ 0:11] 53 assert(std::distance(i, j) == 0); [ 0:11] 54 assert(i == j); [ 0:11] 55 assert(i == c.end()); [ 0:11] 56 } [ 0:11] 57 { [ 0:11] 58 typedef int T; [ 0:11] 59 typedef std::forward_list C; [ 0:11] 60 const T t[] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9}; [ 0:11] 61 C c(std::begin(t), std::end(t)); [ 0:11] 62 C::iterator i = c.begin(); [ 0:11] 63 assert(*i == 0); [ 0:11] 64 ++i; [ 0:11] 65 assert(*i == 1); [ 0:11] 66 *i = 10; [ 0:11] 67 assert(*i == 10); [ 0:11] 68 assert(std::distance(c.begin(), c.end()) == 10); [ 0:11] 69 } [ 0:11] 70 { [ 0:11] 71 typedef int T; [ 0:11] 72 typedef std::forward_list C; [ 0:11] 73 C::iterator i; [ 0:11] 74 C::const_iterator j; [ 0:11] 75 } [ 0:11] 76 #if __cplusplus >= 201103L [ 0:11] 77 { [ 0:11] 78 typedef int T; [ 0:11] 79 typedef std::forward_list> C; [ 0:11] 80 C c; [ 0:11] 81 C::iterator i = c.begin(); [ 0:11] 82 C::iterator j = c.end(); [ 0:11] 83 assert(std::distance(i, j) == 0); [ 0:11] 84 assert(i == j); [ 0:11] 85 } [ 0:11] 86 { [ 0:11] 87 typedef int T; [ 0:11] 88 typedef std::forward_list> C; [ 0:11] 89 const C c; [ 0:11] 90 C::const_iterator i = c.begin(); [ 0:11] 91 C::const_iterator j = c.end(); [ 0:11] 92 assert(std::distance(i, j) == 0); [ 0:11] 93 assert(i == j); [ 0:11] 94 } [ 0:11] 95 { [ 0:11] 96 typedef int T; [ 0:11] 97 typedef std::forward_list> C; [ 0:11] 98 C c; [ 0:11] 99 C::const_iterator i = c.cbegin(); [ 0:11] 100 C::const_iterator j = c.cend(); [ 0:11] 101 assert(std::distance(i, j) == 0); [ 0:11] 102 assert(i == j); [ 0:11] 103 assert(i == c.end()); [ 0:11] 104 } [ 0:11] 105 { [ 0:11] 106 typedef int T; [ 0:11] 107 typedef std::forward_list> C; [ 0:11] 108 const T t[] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9}; [ 0:11] 109 C c(std::begin(t), std::end(t)); [ 0:11] 110 C::iterator i = c.begin(); [ 0:11] 111 assert(*i == 0); [ 0:11] 112 ++i; [ 0:11] 113 assert(*i == 1); [ 0:11] 114 *i = 10; [ 0:11] 115 assert(*i == 10); [ 0:11] 116 assert(std::distance(c.begin(), c.end()) == 10); [ 0:11] 117 } [ 0:11] 118 { [ 0:11] 119 typedef int T; [ 0:11] 120 typedef std::forward_list> C; [ 0:11] 121 C::iterator i; [ 0:11] 122 C::const_iterator j; [ 0:11] 123 } [ 0:11] 124 #endif [ 0:11] 125 #if _LIBCPP_STD_VER > 11 [ 0:11] 126 { // N3644 testing [ 0:11] 127 std::forward_list::iterator ii1{}, ii2{}; [ 0:11] 128 std::forward_list::iterator ii4 = ii1; [ 0:11] 129 std::forward_list::const_iterator cii{}; [ 0:11] 130 assert ( ii1 == ii2 ); [ 0:11] 131 assert ( ii1 == ii4 ); [ 0:11] 132 [ 0:11] 133 assert (!(ii1 != ii2 )); [ 0:11] 134 [ 0:11] 135 assert ( (ii1 == cii )); [ 0:11] 136 assert ( (cii == ii1 )); [ 0:11] 137 assert (!(ii1 != cii )); [ 0:11] 138 assert (!(cii != ii1 )); [ 0:11] 139 [ 0:11] 140 // std::forward_list c; [ 0:11] 141 // assert ( ii1 != c.cbegin()); [ 0:11] 142 // assert ( cii != c.begin()); [ 0:11] 143 // assert ( cii != c.cend()); [ 0:11] 144 // assert ( ii1 != c.end()); [ 0:11] 145 } [ 0:11] 146 #endif [ 0:11] 147 } [ 0:11] # no errors were expected but one was found anyway