LLVMFuzzerTestOneInput:
   24|  1.89k|extern "C" int LLVMFuzzerTestOneInput(const uint8_t *Data, size_t Size) {
   25|  1.89k|    igraph_t graph;
   26|  1.89k|    igraph_vector_int_t edges;
   27|       |
   28|  1.89k|    igraph_set_warning_handler(igraph_warning_handler_ignore);
   29|       |
   30|  1.89k|    if (Size % 2 == 0 || Size > 512+1 || Size < 1) {
  ------------------
  |  Branch (30:9): [True: 4, False: 1.89k]
  |  Branch (30:26): [True: 10, False: 1.88k]
  |  Branch (30:42): [True: 0, False: 1.88k]
  ------------------
   31|     14|        return 0;
   32|     14|    }
   33|       |
   34|  1.88k|    igraph_vector_int_init(&edges, Size-1);
   35|   137k|    for (size_t i=0; i < Size-1; ++i) {
  ------------------
  |  Branch (35:22): [True: 135k, False: 1.88k]
  ------------------
   36|   135k|        VECTOR(edges)[i] = Data[i+1];
  ------------------
  |  |   65|   135k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   37|   135k|    }
   38|       |
   39|  1.88k|    igraph_rng_seed(igraph_rng_default(), 137);
   40|       |
   41|       |    /* Directed */
   42|  1.88k|    if (igraph_create(&graph, &edges, Data[0], IGRAPH_DIRECTED) == IGRAPH_SUCCESS) {
  ------------------
  |  Branch (42:9): [True: 1.88k, False: 0]
  ------------------
   43|  1.88k|        igraph_vector_int_list_t ivl1;
   44|  1.88k|        igraph_vector_t v1, v2;
   45|  1.88k|        igraph_vector_int_t iv1, iv2;
   46|  1.88k|        igraph_t g;
   47|       |
   48|  1.88k|        igraph_vector_int_list_init(&ivl1, 0);
   49|  1.88k|        igraph_vector_init(&v1, 0);
   50|  1.88k|        igraph_vector_init(&v2, 0);
   51|  1.88k|        igraph_vector_int_init(&iv1, 0);
   52|  1.88k|        igraph_vector_int_init(&iv2, 0);
   53|       |
   54|  1.88k|        igraph_minimum_cycle_basis(&graph, &ivl1, -1, true, true, NULL);
   55|  1.88k|        igraph_fundamental_cycles(&graph, &ivl1, -1, -1, NULL);
   56|       |
   57|  1.88k|        igraph_motifs_randesu(&graph, &v1, 3, NULL);
   58|       |
   59|  1.88k|        igraph_list_triangles(&graph, &iv1);
   60|       |
   61|  1.88k|        igraph_ecc(&graph, &v1, igraph_ess_all(IGRAPH_EDGEORDER_ID), 3, false, true);
   62|       |
   63|  1.88k|        igraph_count_reachable(&graph, &iv1, IGRAPH_OUT);
   64|  1.88k|        igraph_transitive_closure(&graph, &g);
   65|  1.88k|        igraph_destroy(&g);
   66|       |
   67|  1.88k|        if (igraph_vcount(&graph) >= 2) {
  ------------------
  |  Branch (67:13): [True: 1.86k, False: 22]
  ------------------
   68|  1.86k|            igraph_get_all_simple_paths(&graph, &ivl1, 0, igraph_vss_1(1), -1, 5, IGRAPH_ALL);
   69|  1.86k|        }
   70|       |
   71|  1.88k|        if (igraph_vcount(&graph) >= 1) {
  ------------------
  |  Branch (71:13): [True: 1.88k, False: 1]
  ------------------
   72|  1.88k|            igraph_t subg;
   73|       |
   74|  1.88k|            igraph_random_walk(&graph, NULL, &iv1, &iv2, 0, IGRAPH_ALL, igraph_ecount(&graph), IGRAPH_RANDOM_WALK_STUCK_RETURN);
   75|       |
   76|  1.88k|            igraph_induced_subgraph(&graph, &subg, igraph_vss_vector(&iv1), IGRAPH_SUBGRAPH_AUTO);
   77|  1.88k|            igraph_destroy(&subg);
   78|       |
   79|  1.88k|            igraph_subgraph_from_edges(&graph, &subg, igraph_ess_vector(&iv2), true);
   80|  1.88k|            igraph_destroy(&subg);
   81|       |
   82|  1.88k|            igraph_reverse_edges(&graph, igraph_ess_vector(&iv2));
   83|  1.88k|        }
   84|       |
   85|  1.88k|        igraph_to_undirected(&graph, IGRAPH_TO_UNDIRECTED_COLLAPSE, NULL);
   86|       |
   87|  1.88k|        igraph_vector_resize(&v2, 4);
   88|  1.88k|        igraph_vector_null(&v2);
   89|  1.88k|        igraph_motifs_randesu(&graph, &v1, 4, &v2);
   90|       |
   91|  1.88k|        if (igraph_vcount(&graph) >= 1) {
  ------------------
  |  Branch (91:13): [True: 1.88k, False: 1]
  ------------------
   92|  1.88k|            igraph_random_walk(&graph, NULL, &iv1, &iv2, 0, IGRAPH_ALL, igraph_ecount(&graph), IGRAPH_RANDOM_WALK_STUCK_RETURN);
   93|  1.88k|        }
   94|       |
   95|  1.88k|        igraph_vector_int_destroy(&iv2);
   96|  1.88k|        igraph_vector_int_destroy(&iv1);
   97|  1.88k|        igraph_vector_destroy(&v2);
   98|  1.88k|        igraph_vector_destroy(&v1);
   99|  1.88k|        igraph_vector_int_list_destroy(&ivl1);
  100|       |
  101|  1.88k|        igraph_destroy(&graph);
  102|  1.88k|    }
  103|       |
  104|  1.88k|    igraph_vector_int_destroy(&edges);
  105|       |
  106|  1.88k|    IGRAPH_ASSERT(IGRAPH_FINALLY_STACK_EMPTY);
  ------------------
  |  |  916|  1.88k|    do { \
  |  |  917|  1.88k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  ------------------
  |  |  |  |  406|      0|#  define IGRAPH_FILE_BASENAME __FILE__
  |  |  ------------------
  |  |  919|      0|        } \
  |  |  920|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  107|       |
  108|  1.88k|    return 0;  // Non-zero return values are reserved for future use.
  109|  1.88k|}

igraph_connected_components:
   87|  5.65k|) {
   88|  5.65k|    if (mode == IGRAPH_WEAK || !igraph_is_directed(graph)) {
  ------------------
  |  Branch (88:9): [True: 1.88k, False: 3.76k]
  |  Branch (88:32): [True: 0, False: 3.76k]
  ------------------
   89|  1.88k|        return igraph_i_connected_components_weak(graph, membership, csize, no);
   90|  3.76k|    } else if (mode == IGRAPH_STRONG) {
  ------------------
  |  Branch (90:16): [True: 3.76k, False: 0]
  ------------------
   91|  3.76k|        return igraph_i_connected_components_strong(graph, membership, csize, no);
   92|  3.76k|    }
   93|       |
   94|      0|    IGRAPH_ERROR("Invalid connectedness mode.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   95|      0|}
components.c:igraph_i_connected_components_weak:
  100|  1.88k|) {
  101|       |
  102|  1.88k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  103|  1.88k|    igraph_integer_t no_of_components;
  104|  1.88k|    igraph_bitset_t already_added;
  105|  1.88k|    igraph_dqueue_int_t q = IGRAPH_DQUEUE_NULL;
  ------------------
  |  |   61|  1.88k|#define IGRAPH_DQUEUE_NULL { 0,0,0,0 }
  ------------------
  106|  1.88k|    igraph_vector_int_t neis = IGRAPH_VECTOR_NULL;
  ------------------
  |  |  104|  1.88k|    #define IGRAPH_VECTOR_NULL { 0,0,0 }
  ------------------
  107|       |
  108|       |    /* Memory for result, csize is dynamically allocated */
  109|  1.88k|    if (membership) {
  ------------------
  |  Branch (109:9): [True: 0, False: 1.88k]
  ------------------
  110|      0|        IGRAPH_CHECK(igraph_vector_int_resize(membership, no_of_nodes));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  111|      0|    }
  112|  1.88k|    if (csize) {
  ------------------
  |  Branch (112:9): [True: 0, False: 1.88k]
  ------------------
  113|      0|        igraph_vector_int_clear(csize);
  114|      0|    }
  115|       |
  116|       |    /* Try to make use of cached information. */
  117|  1.88k|    if (igraph_i_property_cache_has(graph, IGRAPH_PROP_IS_WEAKLY_CONNECTED) &&
  ------------------
  |  Branch (117:9): [True: 0, False: 1.88k]
  ------------------
  118|  1.88k|        igraph_i_property_cache_get_bool(graph, IGRAPH_PROP_IS_WEAKLY_CONNECTED)) {
  ------------------
  |  Branch (118:9): [True: 0, False: 0]
  ------------------
  119|       |        /* If we know that the graph is weakly connected from the cache,
  120|       |         * we can return the result right away. We keep in mind that
  121|       |         * the null graph is considered disconnected, therefore any connected
  122|       |         * graph has precisely one component. */
  123|      0|        if (membership) {
  ------------------
  |  Branch (123:13): [True: 0, False: 0]
  ------------------
  124|       |            /* All vertices are members of the same component,
  125|       |             * component number 0. */
  126|      0|            igraph_vector_int_null(membership);
  127|      0|        }
  128|      0|        if (csize) {
  ------------------
  |  Branch (128:13): [True: 0, False: 0]
  ------------------
  129|       |            /* The size of the single component is the same as the vertex count. */
  130|      0|            IGRAPH_CHECK(igraph_vector_int_push_back(csize, no_of_nodes));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  131|      0|        }
  132|      0|        if (no) {
  ------------------
  |  Branch (132:13): [True: 0, False: 0]
  ------------------
  133|       |            /* There is one component. */
  134|      0|            *no = 1;
  135|      0|        }
  136|      0|        return IGRAPH_SUCCESS;
  137|      0|    }
  138|       |
  139|  1.88k|    IGRAPH_BITSET_INIT_FINALLY(&already_added, no_of_nodes);
  ------------------
  |  |  261|  1.88k|#define IGRAPH_BITSET_INIT_FINALLY(bitset, size) \
  |  |  262|  1.88k|do { IGRAPH_CHECK(igraph_bitset_init(bitset, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  263|  1.88k|     IGRAPH_FINALLY(igraph_bitset_destroy, bitset); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (263:62): [Folded - Ignored]
  |  |  ------------------
  ------------------
  140|  1.88k|    IGRAPH_DQUEUE_INT_INIT_FINALLY(&q, no_of_nodes > 100000 ? 10000 : no_of_nodes / 10);
  ------------------
  |  |   66|  1.88k|    do { IGRAPH_CHECK(igraph_dqueue_int_init(q, capacity)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (649:40): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   67|  1.88k|        IGRAPH_FINALLY(igraph_dqueue_int_destroy, q); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (67:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  141|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&neis, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  142|       |
  143|       |    /* The algorithm */
  144|       |
  145|  1.88k|    no_of_components = 0;
  146|   375k|    for (igraph_integer_t first_node = 0; first_node < no_of_nodes; ++first_node) {
  ------------------
  |  Branch (146:43): [True: 373k, False: 1.88k]
  ------------------
  147|   373k|        igraph_integer_t act_component_size;
  148|       |
  149|   373k|        if (IGRAPH_BIT_TEST(already_added, first_node)) {
  ------------------
  |  |  144|   373k|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|   373k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|   373k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:36): [True: 34.7k, False: 338k]
  |  |  ------------------
  ------------------
  150|  34.7k|            continue;
  151|  34.7k|        }
  152|   338k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|   338k|    do { \
  |  |   48|   338k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 338k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|   338k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  153|       |
  154|   338k|        IGRAPH_BIT_SET(already_added, first_node);
  ------------------
  |  |  105|   338k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|   338k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|   338k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   338k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|   338k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   338k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  155|   338k|        act_component_size = 1;
  156|   338k|        if (membership) {
  ------------------
  |  Branch (156:13): [True: 0, False: 338k]
  ------------------
  157|      0|            VECTOR(*membership)[first_node] = no_of_components;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  158|      0|        }
  159|   338k|        IGRAPH_CHECK(igraph_dqueue_int_push(&q, first_node));
  ------------------
  |  |  648|   338k|    do { \
  |  |  649|   338k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   338k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   338k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 338k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   338k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  160|       |
  161|   712k|        while ( !igraph_dqueue_int_empty(&q) ) {
  ------------------
  |  Branch (161:17): [True: 373k, False: 338k]
  ------------------
  162|   373k|            igraph_integer_t act_node = igraph_dqueue_int_pop(&q);
  163|   373k|            IGRAPH_CHECK(igraph_neighbors(graph, &neis, act_node, IGRAPH_ALL));
  ------------------
  |  |  648|   373k|    do { \
  |  |  649|   373k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   373k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   373k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 373k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   373k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  164|   373k|            igraph_integer_t nei_count = igraph_vector_int_size(&neis);
  165|   508k|            for (igraph_integer_t i = 0; i < nei_count; i++) {
  ------------------
  |  Branch (165:42): [True: 135k, False: 373k]
  ------------------
  166|   135k|                igraph_integer_t neighbor = VECTOR(neis)[i];
  ------------------
  |  |   65|   135k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  167|   135k|                if (IGRAPH_BIT_TEST(already_added, neighbor)) {
  ------------------
  |  |  144|   135k|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|   135k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|   135k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   135k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|   135k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   135k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:36): [True: 100k, False: 34.7k]
  |  |  ------------------
  ------------------
  168|   100k|                    continue;
  169|   100k|                }
  170|  34.7k|                IGRAPH_CHECK(igraph_dqueue_int_push(&q, neighbor));
  ------------------
  |  |  648|  34.7k|    do { \
  |  |  649|  34.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  34.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  34.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 34.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  34.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  171|  34.7k|                IGRAPH_BIT_SET(already_added, neighbor);
  ------------------
  |  |  105|  34.7k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  34.7k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  34.7k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  34.7k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  34.7k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  34.7k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  172|  34.7k|                act_component_size++;
  173|  34.7k|                if (membership) {
  ------------------
  |  Branch (173:21): [True: 0, False: 34.7k]
  ------------------
  174|      0|                    VECTOR(*membership)[neighbor] = no_of_components;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  175|      0|                }
  176|  34.7k|            }
  177|   373k|        }
  178|       |
  179|   338k|        no_of_components++;
  180|   338k|        if (csize) {
  ------------------
  |  Branch (180:13): [True: 0, False: 338k]
  ------------------
  181|      0|            IGRAPH_CHECK(igraph_vector_int_push_back(csize, act_component_size));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  182|      0|        }
  183|   338k|    }
  184|       |
  185|       |    /* Cleaning up */
  186|       |
  187|  1.88k|    if (no) {
  ------------------
  |  Branch (187:9): [True: 1.88k, False: 0]
  ------------------
  188|  1.88k|        *no = no_of_components;
  189|  1.88k|    }
  190|       |
  191|       |    /* Clean up */
  192|  1.88k|    igraph_bitset_destroy(&already_added);
  193|  1.88k|    igraph_dqueue_int_destroy(&q);
  194|  1.88k|    igraph_vector_int_destroy(&neis);
  195|  1.88k|    IGRAPH_FINALLY_CLEAN(3);
  196|       |
  197|       |    /* Update cache */
  198|  1.88k|    igraph_i_property_cache_set_bool_checked(graph, IGRAPH_PROP_IS_WEAKLY_CONNECTED, no_of_components == 1);
  199|       |
  200|  1.88k|    return IGRAPH_SUCCESS;
  201|  1.88k|}
components.c:igraph_i_connected_components_strong:
  206|  3.76k|) {
  207|  3.76k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  208|  3.76k|    igraph_vector_int_t next_nei = IGRAPH_VECTOR_NULL;
  ------------------
  |  |  104|  3.76k|    #define IGRAPH_VECTOR_NULL { 0,0,0 }
  ------------------
  209|  3.76k|    igraph_integer_t num_seen;
  210|  3.76k|    igraph_dqueue_int_t q = IGRAPH_DQUEUE_NULL;
  ------------------
  |  |   61|  3.76k|#define IGRAPH_DQUEUE_NULL { 0,0,0,0 }
  ------------------
  211|  3.76k|    igraph_integer_t no_of_components = 0;
  212|  3.76k|    igraph_vector_int_t out = IGRAPH_VECTOR_NULL;
  ------------------
  |  |  104|  3.76k|    #define IGRAPH_VECTOR_NULL { 0,0,0 }
  ------------------
  213|  3.76k|    igraph_adjlist_t adjlist;
  214|       |
  215|       |    /* Memory for result, csize is dynamically allocated */
  216|  3.76k|    if (membership) {
  ------------------
  |  Branch (216:9): [True: 3.76k, False: 0]
  ------------------
  217|  3.76k|        IGRAPH_CHECK(igraph_vector_int_resize(membership, no_of_nodes));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  218|  3.76k|    }
  219|  3.76k|    if (csize) {
  ------------------
  |  Branch (219:9): [True: 0, False: 3.76k]
  ------------------
  220|      0|        igraph_vector_int_clear(csize);
  221|      0|    }
  222|       |
  223|       |    /* Try to make use of cached information. */
  224|  3.76k|    if (igraph_i_property_cache_has(graph, IGRAPH_PROP_IS_STRONGLY_CONNECTED) &&
  ------------------
  |  Branch (224:9): [True: 1.88k, False: 1.88k]
  ------------------
  225|  3.76k|        igraph_i_property_cache_get_bool(graph, IGRAPH_PROP_IS_STRONGLY_CONNECTED)) {
  ------------------
  |  Branch (225:9): [True: 50, False: 1.83k]
  ------------------
  226|       |        /* If we know that the graph is strongly connected from the cache,
  227|       |         * we can return the result right away. We keep in mind that
  228|       |         * the null graph is considered disconnected, therefore any connected
  229|       |         * graph has precisely one component. */
  230|     50|        if (membership) {
  ------------------
  |  Branch (230:13): [True: 50, False: 0]
  ------------------
  231|       |            /* All vertices are members of the same component,
  232|       |             * component number 0. */
  233|     50|            igraph_vector_int_null(membership);
  234|     50|        }
  235|     50|        if (csize) {
  ------------------
  |  Branch (235:13): [True: 0, False: 50]
  ------------------
  236|       |            /* The size of the single component is the same as the vertex count. */
  237|      0|            IGRAPH_CHECK(igraph_vector_int_push_back(csize, no_of_nodes));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  238|      0|        }
  239|     50|        if (no) {
  ------------------
  |  Branch (239:13): [True: 50, False: 0]
  ------------------
  240|       |            /* There is one component. */
  241|     50|            *no = 1;
  242|     50|        }
  243|     50|        return IGRAPH_SUCCESS;
  244|     50|    }
  245|       |
  246|       |    /* The result */
  247|       |
  248|  3.71k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&next_nei, no_of_nodes);
  ------------------
  |  |  124|  3.71k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  3.71k|    do { \
  |  |  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  3.71k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  3.71k|    do { \
  |  |  |  |  592|  3.71k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  3.71k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  3.71k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  3.71k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  3.71k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  249|  3.71k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&out, 0);
  ------------------
  |  |  124|  3.71k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  3.71k|    do { \
  |  |  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  3.71k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  3.71k|    do { \
  |  |  |  |  592|  3.71k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  3.71k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  3.71k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  3.71k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  3.71k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  250|  3.71k|    IGRAPH_DQUEUE_INT_INIT_FINALLY(&q, 100);
  ------------------
  |  |   66|  3.71k|    do { IGRAPH_CHECK(igraph_dqueue_int_init(q, capacity)); \
  |  |  ------------------
  |  |  |  |  648|  3.71k|    do { \
  |  |  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   67|  3.71k|        IGRAPH_FINALLY(igraph_dqueue_int_destroy, q); } while (0)
  |  |  ------------------
  |  |  |  |  591|  3.71k|    do { \
  |  |  |  |  592|  3.71k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  3.71k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  3.71k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  3.71k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  3.71k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (67:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  251|       |
  252|  3.71k|    IGRAPH_CHECK(igraph_vector_int_reserve(&out, no_of_nodes));
  ------------------
  |  |  648|  3.71k|    do { \
  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.71k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  253|       |
  254|  3.71k|    IGRAPH_CHECK(igraph_adjlist_init(graph, &adjlist, IGRAPH_OUT, IGRAPH_LOOPS_ONCE, IGRAPH_MULTIPLE));
  ------------------
  |  |  648|  3.71k|    do { \
  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.71k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  255|  3.71k|    IGRAPH_FINALLY(igraph_adjlist_destroy, &adjlist);
  ------------------
  |  |  591|  3.71k|    do { \
  |  |  592|  3.71k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.71k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.71k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.71k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.71k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.71k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  256|       |
  257|  3.71k|    num_seen = 0;
  258|   750k|    for (igraph_integer_t i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (258:34): [True: 746k, False: 3.71k]
  ------------------
  259|   746k|        const igraph_vector_int_t *tmp;
  260|       |
  261|   746k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|   746k|    do { \
  |  |   48|   746k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 746k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  262|       |
  263|   746k|        tmp = igraph_adjlist_get(&adjlist, i);
  ------------------
  |  |   78|   746k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  264|   746k|        if (VECTOR(next_nei)[i] > igraph_vector_int_size(tmp)) {
  ------------------
  |  |   65|   746k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (264:13): [True: 50.5k, False: 696k]
  ------------------
  265|  50.5k|            continue;
  266|  50.5k|        }
  267|       |
  268|   696k|        IGRAPH_CHECK(igraph_dqueue_int_push(&q, i));
  ------------------
  |  |  648|   696k|    do { \
  |  |  649|   696k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   696k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   696k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 696k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   696k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  269|  2.32M|        while (!igraph_dqueue_int_empty(&q)) {
  ------------------
  |  Branch (269:16): [True: 1.62M, False: 696k]
  ------------------
  270|  1.62M|            igraph_integer_t act_node = igraph_dqueue_int_back(&q);
  271|  1.62M|            tmp = igraph_adjlist_get(&adjlist, act_node);
  ------------------
  |  |   78|  1.62M|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  272|  1.62M|            if (VECTOR(next_nei)[act_node] == 0) {
  ------------------
  |  |   65|  1.62M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (272:17): [True: 746k, False: 880k]
  ------------------
  273|       |                /* this is the first time we've met this vertex */
  274|   746k|                VECTOR(next_nei)[act_node]++;
  ------------------
  |  |   65|   746k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  275|   880k|            } else if (VECTOR(next_nei)[act_node] <= igraph_vector_int_size(tmp)) {
  ------------------
  |  |   65|   880k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (275:24): [True: 133k, False: 746k]
  ------------------
  276|       |                /* we've already met this vertex but it has more children */
  277|   133k|                igraph_integer_t neighbor = VECTOR(*tmp)[VECTOR(next_nei)[act_node] - 1];
  ------------------
  |  |   65|   133k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              igraph_integer_t neighbor = VECTOR(*tmp)[VECTOR(next_nei)[act_node] - 1];
  ------------------
  |  |   65|   133k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  278|   133k|                if (VECTOR(next_nei)[neighbor] == 0) {
  ------------------
  |  |   65|   133k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (278:21): [True: 50.5k, False: 82.8k]
  ------------------
  279|  50.5k|                    IGRAPH_CHECK(igraph_dqueue_int_push(&q, neighbor));
  ------------------
  |  |  648|  50.5k|    do { \
  |  |  649|  50.5k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  50.5k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  50.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 50.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  50.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  280|  50.5k|                }
  281|   133k|                VECTOR(next_nei)[act_node]++;
  ------------------
  |  |   65|   133k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  282|   746k|            } else {
  283|       |                /* we've met this vertex and it has no more children */
  284|   746k|                IGRAPH_CHECK(igraph_vector_int_push_back(&out, act_node));
  ------------------
  |  |  648|   746k|    do { \
  |  |  649|   746k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   746k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   746k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 746k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  285|   746k|                igraph_dqueue_int_pop_back(&q);
  286|   746k|                num_seen++;
  287|       |
  288|   746k|                if (num_seen % 10000 == 0) {
  ------------------
  |  Branch (288:21): [True: 0, False: 746k]
  ------------------
  289|       |                    /* time to report progress and allow the user to interrupt */
  290|      0|                    IGRAPH_PROGRESS("Strongly connected components: ",
  ------------------
  |  |  174|      0|    do { \
  |  |  175|      0|        IGRAPH_CHECK(igraph_progress((message), (percent), (data))); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  176|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (176:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  291|      0|                                    num_seen * 50.0 / no_of_nodes, NULL);
  292|      0|                    IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|      0|    do { \
  |  |   48|      0|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  293|      0|                }
  294|   746k|            }
  295|  1.62M|        } /* while q */
  296|   696k|    }  /* for */
  297|       |
  298|  3.71k|    IGRAPH_PROGRESS("Strongly connected components: ", 50.0, NULL);
  ------------------
  |  |  174|  3.71k|    do { \
  |  |  175|  3.71k|        IGRAPH_CHECK(igraph_progress((message), (percent), (data))); \
  |  |  ------------------
  |  |  |  |  648|  3.71k|    do { \
  |  |  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  176|  3.71k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (176:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  299|       |
  300|  3.71k|    igraph_adjlist_destroy(&adjlist);
  301|  3.71k|    IGRAPH_FINALLY_CLEAN(1);
  302|       |
  303|  3.71k|    IGRAPH_CHECK(igraph_adjlist_init(graph, &adjlist, IGRAPH_IN, IGRAPH_LOOPS_ONCE, IGRAPH_MULTIPLE));
  ------------------
  |  |  648|  3.71k|    do { \
  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.71k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  304|  3.71k|    IGRAPH_FINALLY(igraph_adjlist_destroy, &adjlist);
  ------------------
  |  |  591|  3.71k|    do { \
  |  |  592|  3.71k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.71k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.71k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.71k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.71k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.71k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  305|       |
  306|       |    /* OK, we've the 'out' values for the nodes, let's use them in
  307|       |       decreasing order with the help of a heap */
  308|       |
  309|  3.71k|    igraph_vector_int_null(&next_nei);             /* mark already added vertices */
  310|  3.71k|    num_seen = 0;
  311|       |
  312|   750k|    while (!igraph_vector_int_empty(&out)) {
  ------------------
  |  Branch (312:12): [True: 746k, False: 3.71k]
  ------------------
  313|   746k|        igraph_integer_t act_component_size;
  314|   746k|        igraph_integer_t grandfather = igraph_vector_int_pop_back(&out);
  315|       |
  316|   746k|        if (VECTOR(next_nei)[grandfather] != 0) {
  ------------------
  |  |   65|   746k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (316:13): [True: 25.7k, False: 720k]
  ------------------
  317|  25.7k|            continue;
  318|  25.7k|        }
  319|   720k|        VECTOR(next_nei)[grandfather] = 1;
  ------------------
  |  |   65|   720k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  320|   720k|        act_component_size = 1;
  321|   720k|        if (membership) {
  ------------------
  |  Branch (321:13): [True: 720k, False: 0]
  ------------------
  322|   720k|            VECTOR(*membership)[grandfather] = no_of_components;
  ------------------
  |  |   65|   720k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  323|   720k|        }
  324|   720k|        IGRAPH_CHECK(igraph_dqueue_int_push(&q, grandfather));
  ------------------
  |  |  648|   720k|    do { \
  |  |  649|   720k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   720k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   720k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 720k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   720k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  325|       |
  326|   720k|        num_seen++;
  327|   720k|        if (num_seen % 10000 == 0) {
  ------------------
  |  Branch (327:13): [True: 0, False: 720k]
  ------------------
  328|       |            /* time to report progress and allow the user to interrupt */
  329|      0|            IGRAPH_PROGRESS("Strongly connected components: ",
  ------------------
  |  |  174|      0|    do { \
  |  |  175|      0|        IGRAPH_CHECK(igraph_progress((message), (percent), (data))); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  176|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (176:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  330|      0|                            50.0 + num_seen * 50.0 / no_of_nodes, NULL);
  331|      0|            IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|      0|    do { \
  |  |   48|      0|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  332|      0|        }
  333|       |
  334|  1.46M|        while (!igraph_dqueue_int_empty(&q)) {
  ------------------
  |  Branch (334:16): [True: 746k, False: 720k]
  ------------------
  335|   746k|            igraph_integer_t act_node = igraph_dqueue_int_pop_back(&q);
  336|   746k|            const igraph_vector_int_t *tmp = igraph_adjlist_get(&adjlist, act_node);
  ------------------
  |  |   78|   746k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  337|   746k|            const igraph_integer_t n = igraph_vector_int_size(tmp);
  338|   880k|            for (igraph_integer_t i = 0; i < n; i++) {
  ------------------
  |  Branch (338:42): [True: 133k, False: 746k]
  ------------------
  339|   133k|                igraph_integer_t neighbor = VECTOR(*tmp)[i];
  ------------------
  |  |   65|   133k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  340|   133k|                if (VECTOR(next_nei)[neighbor] != 0) {
  ------------------
  |  |   65|   133k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (340:21): [True: 107k, False: 25.7k]
  ------------------
  341|   107k|                    continue;
  342|   107k|                }
  343|  25.7k|                IGRAPH_CHECK(igraph_dqueue_int_push(&q, neighbor));
  ------------------
  |  |  648|  25.7k|    do { \
  |  |  649|  25.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  25.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  25.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 25.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  25.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  344|  25.7k|                VECTOR(next_nei)[neighbor] = 1;
  ------------------
  |  |   65|  25.7k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  345|  25.7k|                act_component_size++;
  346|  25.7k|                if (membership) {
  ------------------
  |  Branch (346:21): [True: 25.7k, False: 0]
  ------------------
  347|  25.7k|                    VECTOR(*membership)[neighbor] = no_of_components;
  ------------------
  |  |   65|  25.7k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  348|  25.7k|                }
  349|       |
  350|  25.7k|                num_seen++;
  351|  25.7k|                if (num_seen % 10000 == 0) {
  ------------------
  |  Branch (351:21): [True: 0, False: 25.7k]
  ------------------
  352|       |                    /* time to report progress and allow the user to interrupt */
  353|      0|                    IGRAPH_PROGRESS("Strongly connected components: ",
  ------------------
  |  |  174|      0|    do { \
  |  |  175|      0|        IGRAPH_CHECK(igraph_progress((message), (percent), (data))); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  176|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (176:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  354|      0|                                    50.0 + num_seen * 50.0 / no_of_nodes, NULL);
  355|      0|                    IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|      0|    do { \
  |  |   48|      0|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 0]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  356|      0|                }
  357|  25.7k|            }
  358|   746k|        }
  359|       |
  360|   720k|        no_of_components++;
  361|   720k|        if (csize) {
  ------------------
  |  Branch (361:13): [True: 0, False: 720k]
  ------------------
  362|      0|            IGRAPH_CHECK(igraph_vector_int_push_back(csize, act_component_size));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  363|      0|        }
  364|   720k|    }
  365|       |
  366|  3.71k|    IGRAPH_PROGRESS("Strongly connected components: ", 100.0, NULL);
  ------------------
  |  |  174|  3.71k|    do { \
  |  |  175|  3.71k|        IGRAPH_CHECK(igraph_progress((message), (percent), (data))); \
  |  |  ------------------
  |  |  |  |  648|  3.71k|    do { \
  |  |  |  |  649|  3.71k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.71k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.71k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.71k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.71k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  176|  3.71k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (176:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  367|       |
  368|  3.71k|    if (no) {
  ------------------
  |  Branch (368:9): [True: 3.71k, False: 0]
  ------------------
  369|  3.71k|        *no = no_of_components;
  370|  3.71k|    }
  371|       |
  372|       |    /* Clean up */
  373|  3.71k|    igraph_adjlist_destroy(&adjlist);
  374|  3.71k|    igraph_vector_int_destroy(&out);
  375|  3.71k|    igraph_dqueue_int_destroy(&q);
  376|  3.71k|    igraph_vector_int_destroy(&next_nei);
  377|  3.71k|    IGRAPH_FINALLY_CLEAN(4);
  378|       |
  379|       |    /* Update cache */
  380|  3.71k|    igraph_i_property_cache_set_bool_checked(graph, IGRAPH_PROP_IS_STRONGLY_CONNECTED, no_of_components == 1);
  381|  3.71k|    if (no_of_components == 1) {
  ------------------
  |  Branch (381:9): [True: 50, False: 3.66k]
  ------------------
  382|     50|        igraph_i_property_cache_set_bool_checked(graph, IGRAPH_PROP_IS_WEAKLY_CONNECTED, true);
  383|     50|    }
  384|       |
  385|  3.71k|    return IGRAPH_SUCCESS;
  386|  3.71k|}

igraph_reachability:
   80|  3.76k|        igraph_neimode_t mode) {
   81|       |
   82|  3.76k|    const igraph_integer_t no_of_nodes = igraph_vcount(graph);
   83|  3.76k|    igraph_integer_t no_of_comps;
   84|  3.76k|    igraph_adjlist_t adjlist, dag;
   85|       |
   86|  3.76k|    if (mode != IGRAPH_ALL && mode != IGRAPH_OUT && mode != IGRAPH_IN) {
  ------------------
  |  Branch (86:9): [True: 3.76k, False: 0]
  |  Branch (86:31): [True: 0, False: 3.76k]
  |  Branch (86:53): [True: 0, False: 0]
  ------------------
   87|      0|        IGRAPH_ERROR("Invalid mode for reachability.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   88|      0|    }
   89|       |
   90|  3.76k|    if (! igraph_is_directed(graph)) {
  ------------------
  |  Branch (90:9): [True: 0, False: 3.76k]
  ------------------
   91|      0|        mode = IGRAPH_ALL;
   92|      0|    }
   93|       |
   94|  3.76k|    IGRAPH_CHECK(igraph_connected_components(graph,
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  7.53k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  ------------------
  |  |  |  Branch (649:40): [True: 0, False: 3.76k]
  |  |  ------------------
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   95|  3.76k|                                             membership, csize, &no_of_comps,
   96|  3.76k|                                             mode == IGRAPH_ALL ? IGRAPH_WEAK : IGRAPH_STRONG));
   97|       |
   98|  3.76k|    if (no_of_components) {
  ------------------
  |  Branch (98:9): [True: 0, False: 3.76k]
  ------------------
   99|      0|        *no_of_components = no_of_comps;
  100|      0|    }
  101|       |
  102|  3.76k|    IGRAPH_CHECK(igraph_bitset_list_resize(reach, no_of_comps));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  103|       |
  104|   724k|    for (igraph_integer_t comp = 0; comp < no_of_comps; comp++) {
  ------------------
  |  Branch (104:37): [True: 721k, False: 3.76k]
  ------------------
  105|   721k|        IGRAPH_CHECK(igraph_bitset_resize(igraph_bitset_list_get_ptr(reach, comp), no_of_nodes));
  ------------------
  |  |  648|   721k|    do { \
  |  |  649|   721k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   721k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  106|   721k|    }
  107|   750k|    for (igraph_integer_t v = 0; v < no_of_nodes; v++) {
  ------------------
  |  Branch (107:34): [True: 746k, False: 3.76k]
  ------------------
  108|   746k|        IGRAPH_BIT_SET(*igraph_bitset_list_get_ptr(reach, VECTOR(*membership)[v]), v);
  ------------------
  |  |  105|   746k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|   746k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|   746k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   746k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|   746k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   746k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  109|   746k|    }
  110|       |
  111|  3.76k|    if (mode == IGRAPH_ALL) {
  ------------------
  |  Branch (111:9): [True: 0, False: 3.76k]
  ------------------
  112|      0|        return IGRAPH_SUCCESS;
  113|      0|    }
  114|       |
  115|  3.76k|    IGRAPH_CHECK(igraph_adjlist_init(graph, &adjlist, mode, IGRAPH_LOOPS_ONCE, IGRAPH_MULTIPLE));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  116|  3.76k|    IGRAPH_FINALLY(igraph_adjlist_destroy, &adjlist);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  117|       |
  118|  3.76k|    IGRAPH_CHECK(igraph_adjlist_init_empty(&dag, no_of_comps));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  119|  3.76k|    IGRAPH_FINALLY(igraph_adjlist_destroy, &dag);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  120|       |
  121|   750k|    for (igraph_integer_t v = 0; v < no_of_nodes; v++) {
  ------------------
  |  Branch (121:34): [True: 746k, False: 3.76k]
  ------------------
  122|   746k|        const igraph_vector_int_t *neighbours = igraph_adjlist_get(&adjlist, v);
  ------------------
  |  |   78|   746k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  123|   746k|        igraph_vector_int_t *dag_neighbours = igraph_adjlist_get(&dag, VECTOR(*membership)[v]);
  ------------------
  |  |   78|   746k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  124|   746k|        const igraph_integer_t n = igraph_vector_int_size(neighbours);
  125|   881k|        for (igraph_integer_t i = 0; i < n; i++) {
  ------------------
  |  Branch (125:38): [True: 135k, False: 746k]
  ------------------
  126|   135k|            igraph_integer_t w = VECTOR(*neighbours)[i];
  ------------------
  |  |   65|   135k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  127|   135k|            if (VECTOR(*membership)[v] != VECTOR(*membership)[w]) {
  ------------------
  |  |   65|   135k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          if (VECTOR(*membership)[v] != VECTOR(*membership)[w]) {
  ------------------
  |  |   65|   135k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (127:17): [True: 60.1k, False: 75.0k]
  ------------------
  128|  60.1k|                IGRAPH_CHECK(igraph_vector_int_push_back(dag_neighbours, VECTOR(*membership)[w]));
  ------------------
  |  |  648|  60.1k|    do { \
  |  |  649|  60.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  60.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  60.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 60.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  60.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  129|  60.1k|            }
  130|   135k|        }
  131|   746k|    }
  132|       |
  133|       |    /* Iterate through strongly connected components in reverser topological order,
  134|       |     * exploiting the fact that they are indexed in topological order. */
  135|   724k|    for (igraph_integer_t i = 0; i < no_of_comps; i++) {
  ------------------
  |  Branch (135:34): [True: 721k, False: 3.76k]
  ------------------
  136|   721k|        const igraph_integer_t comp = mode == IGRAPH_IN ? i : no_of_comps - i - 1;
  ------------------
  |  Branch (136:39): [True: 0, False: 721k]
  ------------------
  137|   721k|        const igraph_vector_int_t *dag_neighbours = igraph_adjlist_get(&dag, comp);
  ------------------
  |  |   78|   721k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  138|   721k|        igraph_bitset_t *from_bitset = igraph_bitset_list_get_ptr(reach, comp);
  139|   721k|        const igraph_integer_t n = igraph_vector_int_size(dag_neighbours);
  140|   781k|        for (igraph_integer_t j = 0; j < n; j++) {
  ------------------
  |  Branch (140:38): [True: 60.1k, False: 721k]
  ------------------
  141|  60.1k|            const igraph_bitset_t *to_bitset = igraph_bitset_list_get_ptr(reach, VECTOR(*dag_neighbours)[j]);
  ------------------
  |  |   65|  60.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  142|  60.1k|            igraph_bitset_or(from_bitset, from_bitset, to_bitset);
  143|  60.1k|        }
  144|   721k|    }
  145|       |
  146|  3.76k|    igraph_adjlist_destroy(&adjlist);
  147|  3.76k|    igraph_adjlist_destroy(&dag);
  148|  3.76k|    IGRAPH_FINALLY_CLEAN(2);
  149|       |
  150|  3.76k|    return IGRAPH_SUCCESS;
  151|  3.76k|}
igraph_count_reachable:
  185|  1.88k|                                      igraph_neimode_t mode) {
  186|       |
  187|  1.88k|    igraph_vector_int_t membership;
  188|  1.88k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  189|  1.88k|    igraph_bitset_list_t reach;
  190|       |
  191|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&membership, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  192|  1.88k|    IGRAPH_BITSET_LIST_INIT_FINALLY(&reach, 0);
  ------------------
  |  |   43|  1.88k|    do { IGRAPH_CHECK(igraph_bitset_list_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   44|  1.88k|        IGRAPH_FINALLY(igraph_bitset_list_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (44:65): [Folded - Ignored]
  |  |  ------------------
  ------------------
  193|       |
  194|  1.88k|    IGRAPH_CHECK(igraph_reachability(graph, &membership, NULL, NULL, &reach, mode));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  195|       |
  196|  1.88k|    IGRAPH_CHECK(igraph_vector_int_resize(counts, igraph_vcount(graph)));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  197|   375k|    for (igraph_integer_t i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (197:34): [True: 373k, False: 1.88k]
  ------------------
  198|   373k|        VECTOR(*counts)[i] = igraph_bitset_popcount(igraph_bitset_list_get_ptr(&reach, VECTOR(membership)[i]));
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      VECTOR(*counts)[i] = igraph_bitset_popcount(igraph_bitset_list_get_ptr(&reach, VECTOR(membership)[i]));
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  199|   373k|    }
  200|       |
  201|  1.88k|    igraph_bitset_list_destroy(&reach);
  202|  1.88k|    igraph_vector_int_destroy(&membership);
  203|  1.88k|    IGRAPH_FINALLY_CLEAN(2);
  204|       |
  205|  1.88k|    return IGRAPH_SUCCESS;
  206|  1.88k|}
igraph_transitive_closure:
  231|  1.88k|igraph_error_t igraph_transitive_closure(const igraph_t *graph, igraph_t *closure) {
  232|  1.88k|    const igraph_integer_t no_of_nodes = igraph_vcount(graph);
  233|  1.88k|    const igraph_bool_t directed = igraph_is_directed(graph);
  234|  1.88k|    igraph_vector_int_t membership, edges;
  235|  1.88k|    igraph_bitset_list_t reach;
  236|       |
  237|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&membership, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  238|  1.88k|    IGRAPH_BITSET_LIST_INIT_FINALLY(&reach, 0);
  ------------------
  |  |   43|  1.88k|    do { IGRAPH_CHECK(igraph_bitset_list_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   44|  1.88k|        IGRAPH_FINALLY(igraph_bitset_list_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (44:65): [Folded - Ignored]
  |  |  ------------------
  ------------------
  239|       |
  240|  1.88k|    IGRAPH_CHECK(igraph_reachability(graph, &membership, NULL, NULL, &reach, IGRAPH_OUT));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  241|       |
  242|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&edges, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  243|   375k|    for (igraph_integer_t u = 0; u < no_of_nodes; u++) {
  ------------------
  |  Branch (243:34): [True: 373k, False: 1.88k]
  ------------------
  244|   373k|        const igraph_bitset_t *row = igraph_bitset_list_get_ptr(&reach, VECTOR(membership)[u]);
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  245|  89.0M|        for (igraph_integer_t v = directed ? 0 : u + 1; v < no_of_nodes; v++) {
  ------------------
  |  Branch (245:35): [True: 373k, False: 0]
  |  Branch (245:57): [True: 88.6M, False: 373k]
  ------------------
  246|  88.6M|            if (u != v && IGRAPH_BIT_TEST(*row, v)) {
  ------------------
  |  |  144|  88.2M|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  88.2M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  88.2M|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  88.2M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  88.2M|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  88.2M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:36): [True: 1.02M, False: 87.2M]
  |  |  ------------------
  ------------------
  |  Branch (246:17): [True: 88.2M, False: 373k]
  ------------------
  247|  1.02M|                IGRAPH_CHECK(igraph_vector_int_push_back(&edges, u));
  ------------------
  |  |  648|  1.02M|    do { \
  |  |  649|  1.02M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.02M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.02M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.02M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.02M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  248|  1.02M|                IGRAPH_CHECK(igraph_vector_int_push_back(&edges, v));
  ------------------
  |  |  648|  1.02M|    do { \
  |  |  649|  1.02M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.02M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.02M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.02M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.02M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  249|  1.02M|            }
  250|  88.6M|        }
  251|   373k|    }
  252|       |
  253|  1.88k|    igraph_bitset_list_destroy(&reach);
  254|  1.88k|    igraph_vector_int_destroy(&membership);
  255|  1.88k|    IGRAPH_FINALLY_CLEAN(2);
  256|       |
  257|  1.88k|    IGRAPH_CHECK(igraph_create(closure, &edges, no_of_nodes, directed));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  258|       |
  259|  1.88k|    igraph_vector_int_destroy(&edges);
  260|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  261|       |
  262|  1.88k|    return IGRAPH_SUCCESS;
  263|  1.88k|}

igraph_create:
   65|  9.12k|                  igraph_integer_t n, igraph_bool_t directed) {
   66|  9.12k|    igraph_bool_t has_edges = igraph_vector_int_size(edges) > 0;
   67|  9.12k|    igraph_integer_t max;
   68|       |
   69|  9.12k|    if (igraph_vector_int_size(edges) % 2 != 0) {
  ------------------
  |  Branch (69:9): [True: 0, False: 9.12k]
  ------------------
   70|      0|        IGRAPH_ERROR("Invalid (odd) edges vector.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   71|      0|    }
   72|  9.12k|    if (!igraph_vector_int_isininterval(edges, 0, IGRAPH_VCOUNT_MAX-1)) {
  ------------------
  |  |  105|  9.12k|#define IGRAPH_VCOUNT_MAX (IGRAPH_INTEGER_MAX-1)
  |  |  ------------------
  |  |  |  |   77|  9.12k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  |  |  ------------------
  ------------------
  |  Branch (72:9): [True: 0, False: 9.12k]
  ------------------
   73|      0|        IGRAPH_ERROR("Invalid (negative or too large) vertex ID.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   74|      0|    }
   75|       |
   76|       |    /* The + 1 here cannot overflow as above we have already
   77|       |     * checked that vertex IDs are within range. */
   78|  9.12k|    max = has_edges ? igraph_vector_int_max(edges) + 1 : 0;
  ------------------
  |  Branch (78:11): [True: 8.26k, False: 866]
  ------------------
   79|       |
   80|  9.12k|    IGRAPH_CHECK(igraph_empty(graph, n, directed));
  ------------------
  |  |  648|  9.12k|    do { \
  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   81|  9.12k|    IGRAPH_FINALLY(igraph_destroy, graph);
  ------------------
  |  |  591|  9.12k|    do { \
  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   82|  9.12k|    if (has_edges) {
  ------------------
  |  Branch (82:9): [True: 8.26k, False: 866]
  ------------------
   83|  8.26k|        n = igraph_vcount(graph);
   84|  8.26k|        if (n < max) {
  ------------------
  |  Branch (84:13): [True: 1.61k, False: 6.64k]
  ------------------
   85|  1.61k|            IGRAPH_CHECK(igraph_add_vertices(graph, (max - n), 0));
  ------------------
  |  |  648|  1.61k|    do { \
  |  |  649|  1.61k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.61k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.61k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.61k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   86|  1.61k|        }
   87|  8.26k|        IGRAPH_CHECK(igraph_add_edges(graph, edges, 0));
  ------------------
  |  |  648|  8.26k|    do { \
  |  |  649|  8.26k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  8.26k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  8.26k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.26k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   88|  8.26k|    }
   89|       |
   90|  9.12k|    IGRAPH_FINALLY_CLEAN(1);
   91|  9.12k|    return IGRAPH_SUCCESS;
   92|  9.12k|}

igraph_bitset_init:
  175|   730k|igraph_error_t igraph_bitset_init(igraph_bitset_t *bitset, igraph_integer_t size) {
  176|   730k|    igraph_integer_t alloc_size = IGRAPH_BIT_NSLOTS(size);
  ------------------
  |  |  163|   730k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   730k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   730k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
  177|   730k|    bitset->stor_begin = IGRAPH_CALLOC(alloc_size, igraph_uint_t);
  ------------------
  |  |   38|   730k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  1.46M|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 730k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 730k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 9.58k, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  178|   730k|    IGRAPH_CHECK_OOM(bitset->stor_begin, "Cannot initialize bitset.");
  ------------------
  |  |  701|   730k|    do { \
  |  |  702|   730k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|   730k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 730k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|   730k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  179|   730k|    bitset->size = size;
  180|   730k|    bitset->stor_end = bitset->stor_begin + alloc_size;
  181|   730k|    return IGRAPH_SUCCESS;
  182|   730k|}
igraph_bitset_destroy:
  202|   730k|void igraph_bitset_destroy(igraph_bitset_t *bitset) {
  203|   730k|    IGRAPH_ASSERT(bitset != NULL);
  ------------------
  |  |  916|   730k|    do { \
  |  |  917|   730k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   730k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 730k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   730k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  204|   730k|    IGRAPH_FREE(bitset->stor_begin);
  ------------------
  |  |   41|   730k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  205|   730k|    bitset->size = 0;
  206|   730k|}
igraph_bitset_capacity:
  290|   721k|igraph_integer_t igraph_bitset_capacity(const igraph_bitset_t *bitset) {
  291|   721k|    return IGRAPH_INTEGER_SIZE * (bitset->stor_end - bitset->stor_begin);
  ------------------
  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  ------------------
  292|   721k|}
igraph_bitset_reserve:
  342|   721k|igraph_error_t igraph_bitset_reserve(igraph_bitset_t *bitset, igraph_integer_t capacity) {
  343|   721k|    igraph_integer_t current_capacity;
  344|   721k|    igraph_uint_t *tmp;
  345|       |
  346|   721k|    IGRAPH_ASSERT(bitset != NULL);
  ------------------
  |  |  916|   721k|    do { \
  |  |  917|   721k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  347|   721k|    IGRAPH_ASSERT(bitset->stor_begin != NULL);
  ------------------
  |  |  916|   721k|    do { \
  |  |  917|   721k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  348|   721k|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|   721k|    do { \
  |  |  917|   721k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  349|       |
  350|   721k|    current_capacity = igraph_bitset_capacity(bitset);
  351|       |
  352|   721k|    if (IGRAPH_BIT_NSLOTS(capacity) <= IGRAPH_BIT_NSLOTS(current_capacity)) {
  ------------------
  |  |  163|   721k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
                  if (IGRAPH_BIT_NSLOTS(capacity) <= IGRAPH_BIT_NSLOTS(current_capacity)) {
  ------------------
  |  |  163|   721k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
  |  Branch (352:9): [True: 0, False: 721k]
  ------------------
  353|      0|        return IGRAPH_SUCCESS;
  354|      0|    }
  355|       |
  356|   721k|    tmp = IGRAPH_REALLOC(bitset->stor_begin, IGRAPH_BIT_NSLOTS(capacity), igraph_uint_t);
  ------------------
  |  |   40|   721k|#define IGRAPH_REALLOC(p,n,t) IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, realloc((void*)(p), sizeof(t) * ((n) > 0 ? (n) : 1)))
  |  |  ------------------
  |  |  |  |   36|  1.44M|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 721k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 721k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 721k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  357|   721k|    IGRAPH_CHECK_OOM(tmp, "Cannot reserve space for bitset.");
  ------------------
  |  |  701|   721k|    do { \
  |  |  702|   721k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  358|       |
  359|   721k|    bitset->stor_begin = tmp;
  360|   721k|    bitset->stor_end = bitset->stor_begin + IGRAPH_BIT_NSLOTS(capacity);
  ------------------
  |  |  163|   721k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
  361|       |
  362|   721k|    return IGRAPH_SUCCESS;
  363|   721k|}
igraph_bitset_resize:
  395|   721k|igraph_error_t igraph_bitset_resize(igraph_bitset_t *bitset, igraph_integer_t new_size) {
  396|   721k|    IGRAPH_ASSERT(bitset != NULL);
  ------------------
  |  |  916|   721k|    do { \
  |  |  917|   721k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  397|   721k|    IGRAPH_ASSERT(bitset->stor_begin != NULL);
  ------------------
  |  |  916|   721k|    do { \
  |  |  917|   721k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  398|   721k|    IGRAPH_CHECK(igraph_bitset_reserve(bitset, new_size));
  ------------------
  |  |  648|   721k|    do { \
  |  |  649|   721k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   721k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  399|       |
  400|   721k|    if (new_size > bitset->size) {
  ------------------
  |  Branch (400:9): [True: 721k, False: 0]
  ------------------
  401|   721k|        for (igraph_integer_t i = bitset->size; i % IGRAPH_INTEGER_SIZE != 0; ++i) {
  ------------------
  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  ------------------
  |  Branch (401:49): [True: 0, False: 721k]
  ------------------
  402|      0|            IGRAPH_BIT_CLEAR(*bitset, i);
  ------------------
  |  |  123|      0|#define IGRAPH_BIT_CLEAR(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] &= ~IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_CLEAR(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] &= ~IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|      0|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|      0|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_CLEAR(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] &= ~IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|      0|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|      0|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  403|      0|        }
  404|   721k|        memset(bitset->stor_begin + IGRAPH_BIT_NSLOTS(bitset->size), 0,
  ------------------
  |  |  163|   721k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
  405|   721k|               sizeof(igraph_uint_t) * (IGRAPH_BIT_NSLOTS(new_size) - IGRAPH_BIT_NSLOTS(bitset->size)));
  ------------------
  |  |  163|   721k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
                             sizeof(igraph_uint_t) * (IGRAPH_BIT_NSLOTS(new_size) - IGRAPH_BIT_NSLOTS(bitset->size)));
  ------------------
  |  |  163|   721k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   721k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
  406|   721k|    }
  407|   721k|    bitset->size = new_size;
  408|       |
  409|   721k|    return IGRAPH_SUCCESS;
  410|   721k|}
igraph_bitset_popcount:
  428|   373k|igraph_integer_t igraph_bitset_popcount(const igraph_bitset_t *bitset) {
  429|   373k|    const igraph_integer_t final_block_size = bitset->size % IGRAPH_INTEGER_SIZE ? bitset->size % IGRAPH_INTEGER_SIZE : IGRAPH_INTEGER_SIZE;
  ------------------
  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  ------------------
                  const igraph_integer_t final_block_size = bitset->size % IGRAPH_INTEGER_SIZE ? bitset->size % IGRAPH_INTEGER_SIZE : IGRAPH_INTEGER_SIZE;
  ------------------
  |  |   36|   151k|#define IGRAPH_INTEGER_SIZE 64
  ------------------
                  const igraph_integer_t final_block_size = bitset->size % IGRAPH_INTEGER_SIZE ? bitset->size % IGRAPH_INTEGER_SIZE : IGRAPH_INTEGER_SIZE;
  ------------------
  |  |   36|   221k|#define IGRAPH_INTEGER_SIZE 64
  ------------------
  |  Branch (429:47): [True: 151k, False: 221k]
  ------------------
  430|   373k|    const igraph_integer_t slots = IGRAPH_BIT_NSLOTS(bitset->size);
  ------------------
  |  |  163|   373k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
  431|   373k|    const igraph_uint_t one = 1, zero = 0; /* to avoid the need to cast 1 and 0 to igraph_uint_t below */
  432|   373k|    const igraph_uint_t mask = final_block_size == IGRAPH_INTEGER_SIZE ? ~zero : ((one << final_block_size) - 1);
  ------------------
  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  ------------------
  |  Branch (432:32): [True: 221k, False: 151k]
  ------------------
  433|   373k|    igraph_integer_t count = 0;
  434|       |
  435|  1.43M|    for (igraph_integer_t i = 0; i + 1 < slots; ++i) {
  ------------------
  |  Branch (435:34): [True: 1.05M, False: 373k]
  ------------------
  436|  1.05M|        count += IGRAPH_POPCOUNT(VECTOR(*bitset)[i]);
  ------------------
  |  |  219|  1.05M|    #define IGRAPH_POPCOUNT IGRAPH_I_POPCOUNT64
  |  |  ------------------
  |  |  |  |  170|  1.05M|    #define IGRAPH_I_POPCOUNT64(x) __builtin_popcountll(x)
  |  |  ------------------
  ------------------
  437|  1.05M|    }
  438|   373k|    if (bitset->size) {
  ------------------
  |  Branch (438:9): [True: 373k, False: 0]
  ------------------
  439|   373k|        count += IGRAPH_POPCOUNT(mask & VECTOR(*bitset)[slots - 1]);
  ------------------
  |  |  219|   373k|    #define IGRAPH_POPCOUNT IGRAPH_I_POPCOUNT64
  |  |  ------------------
  |  |  |  |  170|   373k|    #define IGRAPH_I_POPCOUNT64(x) __builtin_popcountll(x)
  |  |  ------------------
  ------------------
  440|   373k|    }
  441|       |
  442|   373k|    return count;
  443|   373k|}
igraph_bitset_or:
  703|  60.1k|                      const igraph_bitset_t *src1, const igraph_bitset_t *src2) {
  704|   287k|    for (igraph_integer_t i = 0; i < IGRAPH_BIT_NSLOTS(dest->size); ++i) {
  ------------------
  |  |  163|   287k|#define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   287k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  |  |               #define IGRAPH_BIT_NSLOTS(nbits) ((nbits + IGRAPH_INTEGER_SIZE - (igraph_integer_t)(1)) / IGRAPH_INTEGER_SIZE)
  |  |  ------------------
  |  |  |  |   36|   287k|#define IGRAPH_INTEGER_SIZE 64
  |  |  ------------------
  ------------------
  |  Branch (704:34): [True: 227k, False: 60.1k]
  ------------------
  705|   227k|        VECTOR(*dest)[i] = VECTOR(*src1)[i] | VECTOR(*src2)[i];
  ------------------
  |  |   65|   227k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      VECTOR(*dest)[i] = VECTOR(*src1)[i] | VECTOR(*src2)[i];
  ------------------
  |  |   65|   227k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      VECTOR(*dest)[i] = VECTOR(*src1)[i] | VECTOR(*src2)[i];
  ------------------
  |  |   65|   227k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  706|   227k|    }
  707|  60.1k|}

bitset_list.c:igraph_i_bitset_list_init_item:
   37|   721k|) {
   38|   721k|    IGRAPH_UNUSED(list);
  ------------------
  |  |   32|   721k|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
   39|   721k|    return igraph_bitset_init(item, 0);
   40|   721k|}
bitset_list.c:igraph_i_bitset_list_destroy_item:
   48|   721k|static void igraph_i_bitset_list_destroy_item(igraph_bitset_t* item) {
   49|   721k|    igraph_bitset_destroy(item);
   50|   721k|}

igraph_dqueue_int_init:
   76|   359k|igraph_error_t FUNCTION(igraph_dqueue, init)(TYPE(igraph_dqueue)* q, igraph_integer_t capacity) {
   77|   359k|    IGRAPH_ASSERT(q != NULL);
  ------------------
  |  |  916|   359k|    do { \
  |  |  917|   359k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   359k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 359k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   359k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   78|   359k|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|   359k|    do { \
  |  |  917|   359k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   359k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 359k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   359k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   79|       |
   80|   359k|    if (capacity == 0) capacity = 1;
  ------------------
  |  Branch (80:9): [True: 353k, False: 5.44k]
  ------------------
   81|       |
   82|   359k|    q->stor_begin = IGRAPH_CALLOC(capacity, BASE);
  ------------------
  |  |   38|   359k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|   718k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 359k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 359k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 359k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   83|   359k|    IGRAPH_CHECK_OOM(q->stor_begin, "Cannot initialize dqueue.");
  ------------------
  |  |  701|   359k|    do { \
  |  |  702|   359k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|   359k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 359k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|   359k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   84|   359k|    q->stor_end = q->stor_begin + capacity;
   85|   359k|    q->begin = q->stor_begin;
   86|   359k|    q->end = NULL;
   87|       |
   88|   359k|    return IGRAPH_SUCCESS;
   89|   359k|}
igraph_dqueue_int_destroy:
  101|   359k|void FUNCTION(igraph_dqueue, destroy)(TYPE(igraph_dqueue)* q) {
  102|   359k|    IGRAPH_ASSERT(q != NULL);
  ------------------
  |  |  916|   359k|    do { \
  |  |  917|   359k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   359k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 359k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   359k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  103|   359k|    IGRAPH_FREE(q->stor_begin); /* sets to NULL */
  ------------------
  |  |   41|   359k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  104|   359k|}
igraph_dqueue_int_empty:
  118|  5.91M|igraph_bool_t FUNCTION(igraph_dqueue, empty)(const TYPE(igraph_dqueue)* q) {
  119|  5.91M|    IGRAPH_ASSERT(q != NULL);
  ------------------
  |  |  916|  5.91M|    do { \
  |  |  917|  5.91M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.91M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.91M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.91M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  120|  5.91M|    IGRAPH_ASSERT(q->stor_begin != NULL);
  ------------------
  |  |  916|  5.91M|    do { \
  |  |  917|  5.91M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.91M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.91M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.91M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  121|  5.91M|    return q->end == NULL;
  122|  5.91M|}
igraph_dqueue_int_back:
  217|  1.62M|BASE FUNCTION(igraph_dqueue, back)(const TYPE(igraph_dqueue)* q) {
  218|  1.62M|    IGRAPH_ASSERT(q != NULL);
  ------------------
  |  |  916|  1.62M|    do { \
  |  |  917|  1.62M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.62M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.62M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.62M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  219|  1.62M|    IGRAPH_ASSERT(q->stor_begin != NULL);
  ------------------
  |  |  916|  1.62M|    do { \
  |  |  917|  1.62M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.62M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.62M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.62M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  220|  1.62M|    IGRAPH_ASSERT(q->stor_end != NULL); /* queue is not empty */
  ------------------
  |  |  916|  1.62M|    do { \
  |  |  917|  1.62M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.62M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.62M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.62M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  221|  1.62M|    if (q->end == q->stor_begin) {
  ------------------
  |  Branch (221:9): [True: 350, False: 1.62M]
  ------------------
  222|    350|        return *(q->stor_end - 1);
  223|    350|    }
  224|  1.62M|    return *(q->end - 1);
  225|  1.62M|}
igraph_dqueue_int_pop:
  241|  2.49M|BASE FUNCTION(igraph_dqueue, pop)(TYPE(igraph_dqueue)* q) {
  242|  2.49M|    IGRAPH_ASSERT(q != NULL);
  ------------------
  |  |  916|  2.49M|    do { \
  |  |  917|  2.49M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  2.49M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.49M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  2.49M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  243|  2.49M|    IGRAPH_ASSERT(q->stor_begin != NULL);
  ------------------
  |  |  916|  2.49M|    do { \
  |  |  917|  2.49M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  2.49M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.49M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  2.49M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  244|  2.49M|    IGRAPH_ASSERT(q->stor_end != NULL); /* queue is not empty */
  ------------------
  |  |  916|  2.49M|    do { \
  |  |  917|  2.49M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  2.49M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.49M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  2.49M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  245|  2.49M|    BASE tmp = *(q->begin);
  ------------------
  |  |   71|  2.49M|    #define BASE igraph_integer_t
  ------------------
  246|  2.49M|    (q->begin)++;
  247|  2.49M|    if (q->begin == q->stor_end) {
  ------------------
  |  Branch (247:9): [True: 444k, False: 2.04M]
  ------------------
  248|   444k|        q->begin = q->stor_begin;
  249|   444k|    }
  250|  2.49M|    if (q->begin == q->end) {
  ------------------
  |  Branch (250:9): [True: 728k, False: 1.76M]
  ------------------
  251|   728k|        q->end = NULL;
  252|   728k|    }
  253|       |
  254|  2.49M|    return tmp;
  255|  2.49M|}
igraph_dqueue_int_pop_back:
  271|  1.49M|BASE FUNCTION(igraph_dqueue, pop_back)(TYPE(igraph_dqueue)* q) {
  272|  1.49M|    BASE tmp;
  ------------------
  |  |   71|  1.49M|    #define BASE igraph_integer_t
  ------------------
  273|  1.49M|    IGRAPH_ASSERT(q != NULL);
  ------------------
  |  |  916|  1.49M|    do { \
  |  |  917|  1.49M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.49M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.49M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.49M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  274|  1.49M|    IGRAPH_ASSERT(q->stor_begin != NULL);
  ------------------
  |  |  916|  1.49M|    do { \
  |  |  917|  1.49M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.49M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.49M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.49M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  275|  1.49M|    IGRAPH_ASSERT(q->stor_end != NULL); /* queue is not empty */
  ------------------
  |  |  916|  1.49M|    do { \
  |  |  917|  1.49M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.49M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.49M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.49M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  276|  1.49M|    if (q->end != q->stor_begin) {
  ------------------
  |  Branch (276:9): [True: 1.49M, False: 78]
  ------------------
  277|  1.49M|        tmp = *((q->end) - 1);
  278|  1.49M|        q->end = (q->end) - 1;
  279|  1.49M|    } else {
  280|     78|        tmp = *((q->stor_end) - 1);
  281|     78|        q->end = (q->stor_end) - 1;
  282|     78|    }
  283|  1.49M|    if (q->begin == q->end) {
  ------------------
  |  Branch (283:9): [True: 1.42M, False: 65.5k]
  ------------------
  284|  1.42M|        q->end = NULL;
  285|  1.42M|    }
  286|       |
  287|  1.49M|    return tmp;
  288|  1.49M|}
igraph_dqueue_int_push:
  308|  3.98M|igraph_error_t FUNCTION(igraph_dqueue, push)(TYPE(igraph_dqueue)* q, BASE elem) {
  309|  3.98M|    IGRAPH_ASSERT(q != NULL);
  ------------------
  |  |  916|  3.98M|    do { \
  |  |  917|  3.98M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.98M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.98M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.98M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  310|  3.98M|    IGRAPH_ASSERT(q->stor_begin != NULL);
  ------------------
  |  |  916|  3.98M|    do { \
  |  |  917|  3.98M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.98M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.98M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.98M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  311|  3.98M|    if (q->begin != q->end) {
  ------------------
  |  Branch (311:9): [True: 3.58M, False: 405k]
  ------------------
  312|       |        /* not full */
  313|  3.58M|        if (q->end == NULL) {
  ------------------
  |  Branch (313:13): [True: 2.15M, False: 1.42M]
  ------------------
  314|  2.15M|            q->end = q->begin;
  315|  2.15M|        }
  316|  3.58M|        *(q->end) = elem;
  317|  3.58M|        (q->end)++;
  318|  3.58M|        if (q->end == q->stor_end) {
  ------------------
  |  Branch (318:13): [True: 496k, False: 3.08M]
  ------------------
  319|   496k|            q->end = q->stor_begin;
  320|   496k|        }
  321|  3.58M|    } else {
  322|       |        /* full, allocate more storage */
  323|       |
  324|   405k|        BASE *bigger = NULL, *old = q->stor_begin;
  ------------------
  |  |   71|   405k|    #define BASE igraph_integer_t
  ------------------
  325|   405k|        igraph_integer_t old_size = q->stor_end - q->stor_begin;
  326|   405k|        igraph_integer_t new_capacity = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|   405k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
                      igraph_integer_t new_capacity = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|   405k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (326:41): [True: 405k, False: 0]
  ------------------
  327|       |
  328|   405k|        if (old_size == IGRAPH_INTEGER_MAX) {
  ------------------
  |  |   77|   405k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (328:13): [True: 0, False: 405k]
  ------------------
  329|      0|            IGRAPH_ERROR("Cannot push to dqueue, already at maximum size.", IGRAPH_EOVERFLOW);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  330|      0|        }
  331|   405k|        if (new_capacity == 0) {
  ------------------
  |  Branch (331:13): [True: 0, False: 405k]
  ------------------
  332|      0|            new_capacity = 1;
  333|      0|        }
  334|       |
  335|   405k|        bigger = IGRAPH_CALLOC(new_capacity, BASE);
  ------------------
  |  |   38|   405k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|   810k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 405k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 405k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 405k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  336|   405k|        IGRAPH_CHECK_OOM(bigger, "Cannot push to dqueue.");
  ------------------
  |  |  701|   405k|    do { \
  |  |  702|   405k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|   405k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 405k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|   405k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  337|       |
  338|   405k|        if (q->stor_end - q->begin > 0) {
  ------------------
  |  Branch (338:13): [True: 405k, False: 0]
  ------------------
  339|   405k|            memcpy(bigger, q->begin,
  340|   405k|                   (size_t)(q->stor_end - q->begin) * sizeof(BASE));
  341|   405k|        }
  342|   405k|        if (q->end - q->stor_begin > 0) {
  ------------------
  |  Branch (342:13): [True: 17.6k, False: 387k]
  ------------------
  343|  17.6k|            memcpy(bigger + (q->stor_end - q->begin), q->stor_begin,
  344|  17.6k|                   (size_t)(q->end - q->stor_begin) * sizeof(BASE));
  345|  17.6k|        }
  346|       |
  347|   405k|        q->end        = bigger + old_size;
  348|   405k|        q->stor_end   = bigger + new_capacity;
  349|   405k|        q->stor_begin = bigger;
  350|   405k|        q->begin      = bigger;
  351|       |
  352|   405k|        *(q->end) = elem;
  353|   405k|        (q->end)++;
  354|   405k|        if (q->end == q->stor_end) {
  ------------------
  |  Branch (354:13): [True: 353k, False: 51.6k]
  ------------------
  355|   353k|            q->end = q->stor_begin;
  356|   353k|        }
  357|       |
  358|   405k|        IGRAPH_FREE(old);
  ------------------
  |  |   41|   405k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  359|   405k|    }
  360|       |
  361|  3.98M|    return IGRAPH_SUCCESS;
  362|  3.98M|}

IGRAPH_FINALLY_REAL:
  320|  2.94M|void IGRAPH_FINALLY_REAL(void (*func)(void*), void* ptr) {
  321|  2.94M|    int no = igraph_i_finally_stack_size;
  322|  2.94M|    if (no < 0) {
  ------------------
  |  Branch (322:9): [True: 0, False: 2.94M]
  ------------------
  323|       |        /* Reset finally stack in case fatal error handler does a longjmp instead of terminating the process: */
  324|      0|        igraph_i_reset_finally_stack();
  325|      0|        IGRAPH_FATALF("Corrupt finally stack: it contains %d elements.", no);
  ------------------
  |  |  867|      0|    do { \
  |  |  868|      0|        igraph_fatalf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  869|      0|                      __VA_ARGS__); \
  |  |  870|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (870:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  326|      0|    }
  327|  2.94M|    if (no >= (int) (sizeof(igraph_i_finally_stack) / sizeof(igraph_i_finally_stack[0]))) {
  ------------------
  |  Branch (327:9): [True: 0, False: 2.94M]
  ------------------
  328|       |        /* Reset finally stack in case fatal error handler does a longjmp instead of terminating the process: */
  329|      0|        igraph_i_reset_finally_stack();
  330|      0|        IGRAPH_FATALF("Finally stack too large: it contains %d elements.", no);
  ------------------
  |  |  867|      0|    do { \
  |  |  868|      0|        igraph_fatalf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  869|      0|                      __VA_ARGS__); \
  |  |  870|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (870:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  331|      0|    }
  332|  2.94M|    igraph_i_finally_stack[no].ptr = ptr;
  333|  2.94M|    igraph_i_finally_stack[no].func = func;
  334|  2.94M|    igraph_i_finally_stack[no].level = igraph_i_finally_stack_level;
  335|  2.94M|    igraph_i_finally_stack_size++;
  336|  2.94M|}
IGRAPH_FINALLY_CLEAN:
  338|  1.48M|void IGRAPH_FINALLY_CLEAN(int minus) {
  339|  1.48M|    igraph_i_finally_stack_size -= minus;
  340|  1.48M|    if (igraph_i_finally_stack_size < 0) {
  ------------------
  |  Branch (340:9): [True: 0, False: 1.48M]
  ------------------
  341|      0|        int left = igraph_i_finally_stack_size + minus;
  342|       |        /* Reset finally stack in case fatal error handler does a longjmp instead of terminating the process: */
  343|      0|        igraph_i_reset_finally_stack();
  344|      0|        IGRAPH_FATALF("Corrupt finally stack: trying to pop %d element(s) when only %d left.", minus, left);
  ------------------
  |  |  867|      0|    do { \
  |  |  868|      0|        igraph_fatalf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  869|      0|                      __VA_ARGS__); \
  |  |  870|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (870:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  345|      0|    }
  346|  1.48M|}
IGRAPH_FINALLY_STACK_SIZE:
  359|  1.88k|int IGRAPH_FINALLY_STACK_SIZE(void) {
  360|  1.88k|    return igraph_i_finally_stack_size;
  361|  1.88k|}
IGRAPH_FINALLY_ENTER:
  377|  8.26k|void IGRAPH_FINALLY_ENTER(void) {
  378|  8.26k|    int no = igraph_i_finally_stack_size;
  379|       |    /* Level indices must always be in increasing order in the finally stack */
  380|  8.26k|    if (no > 0 && igraph_i_finally_stack[no-1].level > igraph_i_finally_stack_level) {
  ------------------
  |  Branch (380:9): [True: 8.26k, False: 0]
  |  Branch (380:19): [True: 0, False: 8.26k]
  ------------------
  381|       |        /* Reset finally stack in case fatal error handler does a longjmp instead of terminating the process: */
  382|      0|        igraph_i_reset_finally_stack();
  383|      0|        IGRAPH_FATAL("Corrupt finally stack: cannot create new finally stack level before last one is freed.");
  ------------------
  |  |  887|      0|    do { \
  |  |  888|      0|        igraph_fatal(reason, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  889|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (889:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  384|      0|    }
  385|  8.26k|    igraph_i_finally_stack_level++;
  386|  8.26k|}
IGRAPH_FINALLY_EXIT:
  399|  8.26k|void IGRAPH_FINALLY_EXIT(void) {
  400|  8.26k|    igraph_i_finally_stack_level--;
  401|  8.26k|    if (igraph_i_finally_stack_level < 0) {
  ------------------
  |  Branch (401:9): [True: 0, False: 8.26k]
  ------------------
  402|       |        /* Reset finally stack in case fatal error handler does a longjmp instead of terminating the process: */
  403|      0|        igraph_i_reset_finally_stack();
  404|      0|        IGRAPH_FATAL("Corrupt finally stack: trying to exit outermost finally stack level.");
  ------------------
  |  |  887|      0|    do { \
  |  |  888|      0|        igraph_fatal(reason, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  889|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (889:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  405|      0|    }
  406|  8.26k|}
igraph_set_warning_handler:
  523|  1.89k|igraph_warning_handler_t *igraph_set_warning_handler(igraph_warning_handler_t *new_handler) {
  524|  1.89k|    igraph_warning_handler_t *previous_handler = igraph_i_warning_handler;
  525|  1.89k|    igraph_i_warning_handler = new_handler;
  526|  1.89k|    return previous_handler;
  527|  1.89k|}

igraph_free:
   62|  1.88k|void igraph_free(void *ptr) {
   63|  1.88k|    IGRAPH_FREE(ptr);
  ------------------
  |  |   41|  1.88k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
   64|  1.88k|}

igraph_progress:
   54|  7.43k|igraph_error_t igraph_progress(const char *message, igraph_real_t percent, void *data) {
   55|  7.43k|    if (igraph_i_progress_handler) {
  ------------------
  |  Branch (55:9): [True: 0, False: 7.43k]
  ------------------
   56|      0|        return igraph_i_progress_handler(message, percent, data);
   57|      0|    }
   58|  7.43k|    return IGRAPH_SUCCESS;
   59|  7.43k|}

igraph_stack_int_init:
   45|  3.76k|igraph_error_t FUNCTION(igraph_stack, init)(TYPE(igraph_stack)* s, igraph_integer_t capacity) {
   46|  3.76k|    igraph_integer_t alloc_size;
   47|  3.76k|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   48|  3.76k|    alloc_size = capacity > 0 ? capacity : 1;
  ------------------
  |  Branch (48:18): [True: 0, False: 3.76k]
  ------------------
   49|  3.76k|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   50|  3.76k|    s->stor_begin = IGRAPH_CALLOC(alloc_size, BASE);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   51|  3.76k|    if (s->stor_begin == NULL) {
  ------------------
  |  Branch (51:9): [True: 0, False: 3.76k]
  ------------------
   52|      0|        IGRAPH_ERROR("Cannot initialize stack.", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   53|      0|    }
   54|  3.76k|    s->stor_end = s->stor_begin + alloc_size;
   55|  3.76k|    s->end = s->stor_begin;
   56|       |
   57|  3.76k|    return IGRAPH_SUCCESS;
   58|  3.76k|}
igraph_stack_int_destroy:
   73|  3.76k|void FUNCTION(igraph_stack, destroy)    (TYPE(igraph_stack)* s) {
   74|  3.76k|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   75|  3.76k|    if (s->stor_begin != NULL) {
  ------------------
  |  Branch (75:9): [True: 3.76k, False: 0]
  ------------------
   76|  3.76k|        IGRAPH_FREE(s->stor_begin);
  ------------------
  |  |   41|  3.76k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
   77|  3.76k|        s->stor_begin = NULL;
   78|  3.76k|    }
   79|  3.76k|}
igraph_stack_int_capacity:
   99|  13.5k|igraph_integer_t FUNCTION(igraph_stack, capacity)(const TYPE(igraph_stack) *s) {
  100|  13.5k|    return s->stor_end - s->stor_begin;
  101|  13.5k|}
igraph_stack_int_reserve:
  119|  13.5k|igraph_error_t FUNCTION(igraph_stack, reserve)(TYPE(igraph_stack)* s, igraph_integer_t capacity) {
  120|  13.5k|    igraph_integer_t current_capacity;
  121|  13.5k|    BASE *tmp;
  ------------------
  |  |   71|  13.5k|    #define BASE igraph_integer_t
  ------------------
  122|       |
  123|  13.5k|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|  13.5k|    do { \
  |  |  917|  13.5k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  13.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  13.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  124|  13.5k|    IGRAPH_ASSERT(s->stor_begin != NULL);
  ------------------
  |  |  916|  13.5k|    do { \
  |  |  917|  13.5k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  13.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  13.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  125|  13.5k|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|  13.5k|    do { \
  |  |  917|  13.5k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  13.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  13.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  126|       |
  127|  13.5k|    current_capacity = FUNCTION(igraph_stack, capacity)(s);
  ------------------
  |  |  183|  13.5k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  13.5k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  13.5k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  128|       |
  129|  13.5k|    if (capacity <= current_capacity) {
  ------------------
  |  Branch (129:9): [True: 0, False: 13.5k]
  ------------------
  130|      0|        return IGRAPH_SUCCESS;
  131|      0|    }
  132|       |
  133|  13.5k|    tmp = IGRAPH_REALLOC(s->stor_begin, capacity, BASE);
  ------------------
  |  |   40|  13.5k|#define IGRAPH_REALLOC(p,n,t) IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, realloc((void*)(p), sizeof(t) * ((n) > 0 ? (n) : 1)))
  |  |  ------------------
  |  |  |  |   36|  27.1k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 13.5k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 13.5k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 13.5k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  134|  13.5k|    IGRAPH_CHECK_OOM(tmp, "Cannot reserve space for stack.");
  ------------------
  |  |  701|  13.5k|    do { \
  |  |  702|  13.5k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  13.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  13.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  135|       |
  136|  13.5k|    s->end = tmp + (s->end - s->stor_begin);
  137|  13.5k|    s->stor_begin = tmp;
  138|  13.5k|    s->stor_end = s->stor_begin + capacity;
  139|       |
  140|  13.5k|    return IGRAPH_SUCCESS;
  141|  13.5k|}
igraph_stack_int_empty:
  155|   812k|igraph_bool_t FUNCTION(igraph_stack, empty)(TYPE(igraph_stack)* s) {
  156|   812k|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|   812k|    do { \
  |  |  917|   812k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   812k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 812k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   812k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  157|   812k|    IGRAPH_ASSERT(s->stor_begin != NULL);
  ------------------
  |  |  916|   812k|    do { \
  |  |  917|   812k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   812k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 812k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   812k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  158|   812k|    return s->stor_begin == s->end;
  159|   812k|}
igraph_stack_int_size:
  172|  13.5k|igraph_integer_t FUNCTION(igraph_stack, size)(const TYPE(igraph_stack)* s) {
  173|  13.5k|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|  13.5k|    do { \
  |  |  917|  13.5k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  13.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  13.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  174|  13.5k|    IGRAPH_ASSERT(s->stor_begin != NULL);
  ------------------
  |  |  916|  13.5k|    do { \
  |  |  917|  13.5k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  13.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  13.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  175|  13.5k|    return s->end - s->stor_begin;
  176|  13.5k|}
igraph_stack_int_clear:
  188|   746k|void FUNCTION(igraph_stack, clear)(TYPE(igraph_stack)* s) {
  189|   746k|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|   746k|    do { \
  |  |  917|   746k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   746k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 746k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  190|   746k|    IGRAPH_ASSERT(s->stor_begin != NULL);
  ------------------
  |  |  916|   746k|    do { \
  |  |  917|   746k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   746k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 746k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  191|   746k|    s->end = s->stor_begin;
  192|   746k|}
igraph_stack_int_push:
  209|  1.34M|igraph_error_t FUNCTION(igraph_stack, push)(TYPE(igraph_stack)* s, BASE elem) {
  210|  1.34M|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|  1.34M|    do { \
  |  |  917|  1.34M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.34M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.34M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.34M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  211|  1.34M|    IGRAPH_ASSERT(s->stor_begin != NULL);
  ------------------
  |  |  916|  1.34M|    do { \
  |  |  917|  1.34M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.34M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.34M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.34M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  212|       |
  213|  1.34M|    if (s->stor_end == s->end) {
  ------------------
  |  Branch (213:9): [True: 13.5k, False: 1.33M]
  ------------------
  214|       |        /* full, allocate more storage */
  215|  13.5k|        igraph_integer_t old_size = FUNCTION(igraph_stack, size)(s);
  ------------------
  |  |  183|  13.5k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  13.5k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  13.5k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  216|  13.5k|        igraph_integer_t new_size = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|  13.5k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
                      igraph_integer_t new_size = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|  13.5k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (216:37): [True: 13.5k, False: 0]
  ------------------
  217|  13.5k|        if (old_size == IGRAPH_INTEGER_MAX) {
  ------------------
  |  |   77|  13.5k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (217:13): [True: 0, False: 13.5k]
  ------------------
  218|      0|            IGRAPH_ERROR("Cannot push to stack, already at maximum size.", IGRAPH_EOVERFLOW);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  219|      0|        }
  220|  13.5k|        if (new_size == 0) {
  ------------------
  |  Branch (220:13): [True: 0, False: 13.5k]
  ------------------
  221|      0|            new_size = 1;
  222|      0|        }
  223|  13.5k|        IGRAPH_CHECK(FUNCTION(igraph_stack, reserve)(s, new_size));
  ------------------
  |  |  648|  13.5k|    do { \
  |  |  649|  13.5k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  13.5k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  13.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  13.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  224|  13.5k|    }
  225|       |
  226|  1.34M|    *(s->end) = elem;
  227|  1.34M|    s->end += 1;
  228|       |
  229|  1.34M|    return IGRAPH_SUCCESS;
  230|  1.34M|}
igraph_stack_int_pop:
  245|  1.09M|BASE FUNCTION(igraph_stack, pop)(TYPE(igraph_stack)* s) {
  246|  1.09M|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|  1.09M|    do { \
  |  |  917|  1.09M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.09M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.09M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.09M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  247|  1.09M|    IGRAPH_ASSERT(s->stor_begin != NULL);
  ------------------
  |  |  916|  1.09M|    do { \
  |  |  917|  1.09M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.09M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.09M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.09M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  248|  1.09M|    IGRAPH_ASSERT(s->end != NULL);
  ------------------
  |  |  916|  1.09M|    do { \
  |  |  917|  1.09M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.09M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.09M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.09M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  249|  1.09M|    IGRAPH_ASSERT(s->end != s->stor_begin);
  ------------------
  |  |  916|  1.09M|    do { \
  |  |  917|  1.09M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.09M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.09M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.09M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  250|       |
  251|  1.09M|    (s->end)--;
  252|       |
  253|  1.09M|    return *(s->end);
  254|  1.09M|}
igraph_stack_int_top:
  269|   812k|BASE FUNCTION(igraph_stack, top)(const TYPE(igraph_stack)* s) {
  270|   812k|    IGRAPH_ASSERT(s != NULL);
  ------------------
  |  |  916|   812k|    do { \
  |  |  917|   812k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   812k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 812k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   812k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  271|   812k|    IGRAPH_ASSERT(s->stor_begin != NULL);
  ------------------
  |  |  916|   812k|    do { \
  |  |  917|   812k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   812k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 812k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   812k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  272|   812k|    IGRAPH_ASSERT(s->end != NULL);
  ------------------
  |  |  916|   812k|    do { \
  |  |  917|   812k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   812k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 812k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   812k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  273|   812k|    IGRAPH_ASSERT(s->end != s->stor_begin);
  ------------------
  |  |  916|   812k|    do { \
  |  |  917|   812k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   812k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 812k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   812k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  274|       |
  275|   812k|    return *(s->end - 1);
  276|   812k|}

igraph_vector_int_list_init:
  110|  5.65k|igraph_error_t FUNCTION(init)(TYPE *v, igraph_integer_t size) {
  111|  5.65k|    igraph_integer_t alloc_size = size > 0 ? size : 1;
  ------------------
  |  Branch (111:35): [True: 0, False: 5.65k]
  ------------------
  112|  5.65k|    IGRAPH_ASSERT(size >= 0);
  ------------------
  |  |  916|  5.65k|    do { \
  |  |  917|  5.65k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.65k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  113|  5.65k|    v->stor_begin = IGRAPH_CALLOC(alloc_size, ITEM_TYPE);
  ------------------
  |  |   38|  5.65k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  11.3k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 5.65k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 5.65k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 5.65k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  114|  5.65k|    if (v->stor_begin == 0) {
  ------------------
  |  Branch (114:9): [True: 0, False: 5.65k]
  ------------------
  115|      0|        IGRAPH_ERROR("Cannot initialize list.", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  116|      0|    }
  117|  5.65k|    v->stor_end = v->stor_begin + alloc_size;
  118|  5.65k|    v->end = v->stor_begin + size;
  119|       |
  120|  5.65k|    IGRAPH_CHECK(INTERNAL_FUNCTION(init_slice)(v, v->stor_begin, v->end));
  ------------------
  |  |  648|  5.65k|    do { \
  |  |  649|  5.65k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  5.65k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  5.65k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  121|       |
  122|  5.65k|    return IGRAPH_SUCCESS;
  123|  5.65k|}
igraph_vector_int_list_destroy:
  177|  5.65k|void FUNCTION(destroy)(TYPE *v) {
  178|  5.65k|    IGRAPH_ASSERT(v != 0);
  ------------------
  |  |  916|  5.65k|    do { \
  |  |  917|  5.65k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.65k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  179|       |
  180|  5.65k|    if (v->stor_begin != 0) {
  ------------------
  |  Branch (180:9): [True: 5.65k, False: 0]
  ------------------
  181|  5.65k|        FUNCTION(clear)(v);
  ------------------
  |  |  141|  5.65k|        #define FUNCTION(c) CONCAT4(igraph_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|  5.65k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|  5.65k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  182|  5.65k|        IGRAPH_FREE(v->stor_begin);
  ------------------
  |  |   41|  5.65k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  183|  5.65k|        v->stor_begin = NULL;
  184|  5.65k|    }
  185|  5.65k|}
igraph_vector_int_list_capacity:
  204|  14.3k|igraph_integer_t FUNCTION(capacity)(const TYPE *v) {
  205|  14.3k|    return v->stor_end - v->stor_begin;
  206|  14.3k|}
igraph_vector_int_list_reserve:
  234|  14.3k|igraph_error_t FUNCTION(reserve)(TYPE *v, igraph_integer_t capacity) {
  235|  14.3k|    igraph_integer_t current_capacity;
  236|  14.3k|    ITEM_TYPE *tmp;
  ------------------
  |  |   32|  14.3k|    #define ITEM_TYPE BASE_VECTOR
  |  |  ------------------
  |  |  |  |   72|  14.3k|    #define BASE_VECTOR igraph_vector_int_t
  |  |  ------------------
  ------------------
  237|       |
  238|  14.3k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  14.3k|    do { \
  |  |  917|  14.3k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.3k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.3k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.3k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  239|  14.3k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  14.3k|    do { \
  |  |  917|  14.3k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.3k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.3k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.3k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  240|  14.3k|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|  14.3k|    do { \
  |  |  917|  14.3k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.3k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.3k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.3k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  241|       |
  242|  14.3k|    current_capacity = FUNCTION(capacity)(v);
  ------------------
  |  |  141|  14.3k|        #define FUNCTION(c) CONCAT4(igraph_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|  14.3k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|  14.3k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  243|       |
  244|  14.3k|    if (capacity <= current_capacity) {
  ------------------
  |  Branch (244:9): [True: 3.16k, False: 11.2k]
  ------------------
  245|  3.16k|        return IGRAPH_SUCCESS;
  246|  3.16k|    }
  247|       |
  248|  11.2k|    tmp = IGRAPH_REALLOC(v->stor_begin, capacity, ITEM_TYPE);
  ------------------
  |  |   40|  11.2k|#define IGRAPH_REALLOC(p,n,t) IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, realloc((void*)(p), sizeof(t) * ((n) > 0 ? (n) : 1)))
  |  |  ------------------
  |  |  |  |   36|  22.4k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 11.2k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 11.2k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 11.2k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  249|  11.2k|    IGRAPH_CHECK_OOM(tmp, "Cannot reserve space for list.");
  ------------------
  |  |  701|  11.2k|    do { \
  |  |  702|  11.2k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  11.2k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 11.2k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  11.2k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  250|       |
  251|  11.2k|    v->end = tmp + (v->end - v->stor_begin);
  252|  11.2k|    v->stor_begin = tmp;
  253|  11.2k|    v->stor_end = v->stor_begin + capacity;
  254|       |
  255|  11.2k|    return IGRAPH_SUCCESS;
  256|  11.2k|}
igraph_vector_int_list_size:
  288|   188k|igraph_integer_t FUNCTION(size)(const TYPE *v) {
  289|   188k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|   188k|    do { \
  |  |  917|   188k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   188k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 188k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   188k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  290|   188k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|   188k|    do { \
  |  |  917|   188k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   188k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 188k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   188k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  291|   188k|    return v->end - v->stor_begin;
  292|   188k|}
igraph_vector_int_list_clear:
  358|  11.2k|void FUNCTION(clear)(TYPE *v) {
  359|  11.2k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  11.2k|    do { \
  |  |  917|  11.2k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  11.2k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 11.2k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  11.2k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  360|  11.2k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  11.2k|    do { \
  |  |  917|  11.2k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  11.2k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 11.2k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  11.2k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  361|  11.2k|    INTERNAL_FUNCTION(destroy_slice)(v, v->stor_begin, v->end);
  ------------------
  |  |  142|  11.2k|        #define INTERNAL_FUNCTION(c) CONCAT4(igraph_i_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|  11.2k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|  11.2k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  362|  11.2k|    v->end = v->stor_begin;
  363|  11.2k|}
igraph_vector_int_list_get_ptr:
  378|   775k|ITEM_TYPE *FUNCTION(get_ptr)(const TYPE *v, igraph_integer_t pos) {
  379|   775k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|   775k|    do { \
  |  |  917|   775k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   775k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 775k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   775k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  380|   775k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|   775k|    do { \
  |  |  917|   775k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   775k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 775k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   775k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  381|   775k|    return v->stor_begin + pos;
  382|   775k|}
igraph_vector_int_list_push_back:
  588|   787k|igraph_error_t FUNCTION(push_back)(TYPE *v, ITEM_TYPE *e) {
  589|   787k|    IGRAPH_CHECK(INTERNAL_FUNCTION(expand_if_full)(v));
  ------------------
  |  |  648|   787k|    do { \
  |  |  649|   787k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   787k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   787k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 787k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   787k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  590|   787k|    *(v->end) = *e;
  591|   787k|    v->end += 1;
  592|   787k|    return IGRAPH_SUCCESS;
  593|   787k|}
igraph_vector_int_list_push_back_copy:
  613|  80.1k|igraph_error_t FUNCTION(push_back_copy)(TYPE *v, const ITEM_TYPE *e) {
  614|  80.1k|    ITEM_TYPE copy;
  ------------------
  |  |   32|  80.1k|    #define ITEM_TYPE BASE_VECTOR
  |  |  ------------------
  |  |  |  |   72|  80.1k|    #define BASE_VECTOR igraph_vector_int_t
  |  |  ------------------
  ------------------
  615|  80.1k|    IGRAPH_CHECK(INTERNAL_FUNCTION(copy_item)(&copy, e));
  ------------------
  |  |  648|  80.1k|    do { \
  |  |  649|  80.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  80.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  80.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 80.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  80.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  616|  80.1k|    IGRAPH_FINALLY(INTERNAL_FUNCTION(destroy_item), &copy);
  ------------------
  |  |  591|  80.1k|    do { \
  |  |  592|  80.1k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  80.1k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  80.1k|         * incorrect destructor function with the pointer */ \
  |  |  595|  80.1k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  80.1k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  80.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  617|  80.1k|    IGRAPH_CHECK(FUNCTION(push_back)(v, &copy));
  ------------------
  |  |  648|  80.1k|    do { \
  |  |  649|  80.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  80.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  80.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 80.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  80.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  618|  80.1k|    IGRAPH_FINALLY_CLEAN(1);
  619|  80.1k|    return IGRAPH_SUCCESS;
  620|  80.1k|}
igraph_vector_int_list_insert:
  670|  32.7k|igraph_error_t FUNCTION(insert)(TYPE *v, igraph_integer_t pos, ITEM_TYPE *e) {
  671|  32.7k|    igraph_integer_t size = FUNCTION(size)(v);
  ------------------
  |  |  141|  32.7k|        #define FUNCTION(c) CONCAT4(igraph_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|  32.7k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|  32.7k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  672|  32.7k|    IGRAPH_ASSERT(0 <= pos && pos <= size);
  ------------------
  |  |  916|  32.7k|    do { \
  |  |  917|  32.7k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  65.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  |  Branch (604:50): [True: 32.7k, False: 0]
  |  |  |  |  |  Branch (604:50): [True: 32.7k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  673|  32.7k|    IGRAPH_CHECK(INTERNAL_FUNCTION(expand_if_full)(v));
  ------------------
  |  |  648|  32.7k|    do { \
  |  |  649|  32.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  32.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  674|  32.7k|    if (pos < size) {
  ------------------
  |  Branch (674:9): [True: 14.9k, False: 17.8k]
  ------------------
  675|  14.9k|        memmove(v->stor_begin + pos + 1, v->stor_begin + pos, sizeof(ITEM_TYPE) * (size - pos));
  676|  14.9k|    }
  677|  32.7k|    v->end += 1;
  678|  32.7k|    v->stor_begin[pos] = *e;
  679|  32.7k|    return IGRAPH_SUCCESS;
  680|  32.7k|}
igraph_vector_int_list_sort:
  916|  1.88k|void FUNCTION(sort)(TYPE *v, int (*cmp)(const ITEM_TYPE*, const ITEM_TYPE*)) {
  917|  1.88k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  1.88k|    do { \
  |  |  917|  1.88k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  918|  1.88k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  1.88k|    do { \
  |  |  917|  1.88k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  919|  1.88k|    igraph_qsort(
  920|  1.88k|        v->stor_begin, FUNCTION(size)(v), sizeof(ITEM_TYPE),
  ------------------
  |  |  141|  1.88k|        #define FUNCTION(c) CONCAT4(igraph_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|  1.88k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|  1.88k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  921|  1.88k|        (int(*)(const void*, const void*))cmp
  922|  1.88k|    );
  923|  1.88k|}
igraph_vector_int_list_remove_consecutive_duplicates:
 1005|  1.88k|) {
 1006|  1.88k|    igraph_integer_t i, j, n = FUNCTION(size)(v);
  ------------------
  |  |  141|  1.88k|        #define FUNCTION(c) CONCAT4(igraph_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|  1.88k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|  1.88k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1007|  1.88k|    ITEM_TYPE *p = v->stor_begin;
  ------------------
  |  |   32|  1.88k|    #define ITEM_TYPE BASE_VECTOR
  |  |  ------------------
  |  |  |  |   72|  1.88k|    #define BASE_VECTOR igraph_vector_int_t
  |  |  ------------------
  ------------------
 1008|       |
 1009|  1.88k|    if (n < 2) {
  ------------------
  |  Branch (1009:9): [True: 565, False: 1.31k]
  ------------------
 1010|    565|        return;
 1011|    565|    }
 1012|       |
 1013|   673k|    for (i=0, j=0; i < n-1; ++i) {
  ------------------
  |  Branch (1013:20): [True: 672k, False: 1.31k]
  ------------------
 1014|   672k|        if (eq(&p[i], &p[i+1])) {
  ------------------
  |  Branch (1014:13): [True: 570k, False: 102k]
  ------------------
 1015|   570k|            INTERNAL_FUNCTION(destroy_item)(&p[i]);
  ------------------
  |  |  142|   570k|        #define INTERNAL_FUNCTION(c) CONCAT4(igraph_i_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|   570k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|   570k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1016|   570k|        } else {
 1017|   102k|            p[j++] = p[i];
 1018|   102k|        }
 1019|   672k|    }
 1020|  1.31k|    p[j++] = p[n-1];
 1021|       |
 1022|  1.31k|    v->end = p + j;
 1023|  1.31k|}
vector_list.c:igraph_i_vector_int_list_copy_item:
 1057|  80.1k|static igraph_error_t INTERNAL_FUNCTION(copy_item)(ITEM_TYPE *dest, const ITEM_TYPE *source) {
 1058|  80.1k|    return ITEM_FUNCTION(init_copy)(dest, source);
  ------------------
  |  |   43|  80.1k|        #define ITEM_FUNCTION(f) CONCAT3(igraph_vector,SHORT,f)
  |  |  ------------------
  |  |  |  |   27|  80.1k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  80.1k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1059|  80.1k|}
vector_list.c:igraph_i_vector_int_list_destroy_item:
 1061|   819k|static void INTERNAL_FUNCTION(destroy_item)(ITEM_TYPE *item) {
 1062|   819k|    ITEM_FUNCTION(destroy)(item);
  ------------------
  |  |   43|   819k|        #define ITEM_FUNCTION(f) CONCAT3(igraph_vector,SHORT,f)
  |  |  ------------------
  |  |  |  |   27|   819k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   819k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1063|   819k|}
vector_list.c:igraph_i_vector_int_list_init_slice:
 1069|  5.65k|static igraph_error_t INTERNAL_FUNCTION(init_slice)(const TYPE *list, ITEM_TYPE *start, ITEM_TYPE *end) {
 1070|  5.65k|    ITEM_TYPE *current;
  ------------------
  |  |   32|  5.65k|    #define ITEM_TYPE BASE_VECTOR
  |  |  ------------------
  |  |  |  |   72|  5.65k|    #define BASE_VECTOR igraph_vector_int_t
  |  |  ------------------
  ------------------
 1071|  5.65k|    igraph_error_t retval;
 1072|       |
 1073|  5.65k|    for (current = start; current < end; current++) {
  ------------------
  |  Branch (1073:27): [True: 0, False: 5.65k]
  ------------------
 1074|      0|        retval = INTERNAL_FUNCTION(init_item)(list, current);
  ------------------
  |  |  142|      0|        #define INTERNAL_FUNCTION(c) CONCAT4(igraph_i_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|      0|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|      0|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1075|      0|        if (retval) {
  ------------------
  |  Branch (1075:13): [True: 0, False: 0]
  ------------------
 1076|      0|            INTERNAL_FUNCTION(destroy_slice)(list, start, current);
  ------------------
  |  |  142|      0|        #define INTERNAL_FUNCTION(c) CONCAT4(igraph_i_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|      0|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|      0|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1077|      0|            IGRAPH_CHECK(retval);
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1078|      0|        }
 1079|      0|    }
 1080|       |
 1081|  5.65k|    return IGRAPH_SUCCESS;
 1082|  5.65k|}
vector_list.c:igraph_i_vector_int_list_destroy_slice:
 1084|  11.2k|static void INTERNAL_FUNCTION(destroy_slice)(const TYPE *list, ITEM_TYPE *start, ITEM_TYPE *end) {
 1085|  11.2k|    IGRAPH_UNUSED(list);
  ------------------
  |  |   32|  11.2k|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
 1086|   260k|    for (; start < end; start++) {
  ------------------
  |  Branch (1086:12): [True: 249k, False: 11.2k]
  ------------------
 1087|   249k|        INTERNAL_FUNCTION(destroy_item)(start);
  ------------------
  |  |  142|   249k|        #define INTERNAL_FUNCTION(c) CONCAT4(igraph_i_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|   249k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|   249k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1088|   249k|    }
 1089|  11.2k|}
vector_list.c:igraph_i_vector_int_list_expand_if_full:
 1095|   819k|static igraph_error_t INTERNAL_FUNCTION(expand_if_full)(TYPE *v) {
 1096|   819k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|   819k|    do { \
  |  |  917|   819k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   819k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 819k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   819k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1097|   819k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|   819k|    do { \
  |  |  917|   819k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   819k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 819k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   819k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1098|       |
 1099|   819k|    if (v->stor_end == v->end) {
  ------------------
  |  Branch (1099:9): [True: 8.72k, False: 811k]
  ------------------
 1100|  8.72k|        igraph_integer_t old_size = FUNCTION(size)(v);
  ------------------
  |  |  141|  8.72k|        #define FUNCTION(c) CONCAT4(igraph_vector,SHORT,list,c)
  |  |  ------------------
  |  |  |  |   29|  8.72k|#define CONCAT4(a,b,c,d) CONCAT4x(a,b,c,d)
  |  |  |  |  ------------------
  |  |  |  |  |  |   28|  8.72k|#define CONCAT4x(a,b,c,d) a ## _ ## b ## _ ## c ## _ ## d
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1101|  8.72k|        igraph_integer_t new_size = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|  8.72k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
                      igraph_integer_t new_size = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|  8.72k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (1101:37): [True: 8.72k, False: 0]
  ------------------
 1102|  8.72k|        if (old_size == IGRAPH_INTEGER_MAX) {
  ------------------
  |  |   77|  8.72k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (1102:13): [True: 0, False: 8.72k]
  ------------------
 1103|      0|            IGRAPH_ERROR("Cannot add new item to list, already at maximum size.", IGRAPH_EOVERFLOW);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1104|      0|        }
 1105|  8.72k|        if (new_size == 0) {
  ------------------
  |  Branch (1105:13): [True: 0, False: 8.72k]
  ------------------
 1106|      0|            new_size = 1;
 1107|      0|        }
 1108|  8.72k|        IGRAPH_CHECK(FUNCTION(reserve)(v, new_size));
  ------------------
  |  |  648|  8.72k|    do { \
  |  |  649|  8.72k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  8.72k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  8.72k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.72k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  8.72k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1109|  8.72k|    }
 1110|       |
 1111|   819k|    return IGRAPH_SUCCESS;
 1112|   819k|}
igraph_bitset_list_init:
  110|  3.76k|igraph_error_t FUNCTION(init)(TYPE *v, igraph_integer_t size) {
  111|  3.76k|    igraph_integer_t alloc_size = size > 0 ? size : 1;
  ------------------
  |  Branch (111:35): [True: 0, False: 3.76k]
  ------------------
  112|  3.76k|    IGRAPH_ASSERT(size >= 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  113|  3.76k|    v->stor_begin = IGRAPH_CALLOC(alloc_size, ITEM_TYPE);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  114|  3.76k|    if (v->stor_begin == 0) {
  ------------------
  |  Branch (114:9): [True: 0, False: 3.76k]
  ------------------
  115|      0|        IGRAPH_ERROR("Cannot initialize list.", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  116|      0|    }
  117|  3.76k|    v->stor_end = v->stor_begin + alloc_size;
  118|  3.76k|    v->end = v->stor_begin + size;
  119|       |
  120|  3.76k|    IGRAPH_CHECK(INTERNAL_FUNCTION(init_slice)(v, v->stor_begin, v->end));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  121|       |
  122|  3.76k|    return IGRAPH_SUCCESS;
  123|  3.76k|}
igraph_bitset_list_destroy:
  177|  3.76k|void FUNCTION(destroy)(TYPE *v) {
  178|  3.76k|    IGRAPH_ASSERT(v != 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  179|       |
  180|  3.76k|    if (v->stor_begin != 0) {
  ------------------
  |  Branch (180:9): [True: 3.76k, False: 0]
  ------------------
  181|  3.76k|        FUNCTION(clear)(v);
  ------------------
  |  |  170|  3.76k|    #define FUNCTION(c) CONCAT2x(igraph_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|  3.76k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
  182|  3.76k|        IGRAPH_FREE(v->stor_begin);
  ------------------
  |  |   41|  3.76k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  183|  3.76k|        v->stor_begin = NULL;
  184|  3.76k|    }
  185|  3.76k|}
igraph_bitset_list_capacity:
  204|  3.76k|igraph_integer_t FUNCTION(capacity)(const TYPE *v) {
  205|  3.76k|    return v->stor_end - v->stor_begin;
  206|  3.76k|}
igraph_bitset_list_reserve:
  234|  3.76k|igraph_error_t FUNCTION(reserve)(TYPE *v, igraph_integer_t capacity) {
  235|  3.76k|    igraph_integer_t current_capacity;
  236|  3.76k|    ITEM_TYPE *tmp;
  ------------------
  |  |   62|  3.76k|    #define ITEM_TYPE BASE
  |  |  ------------------
  |  |  |  |  123|  3.76k|    #define BASE igraph_bitset_t
  |  |  ------------------
  ------------------
  237|       |
  238|  3.76k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  239|  3.76k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  240|  3.76k|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  241|       |
  242|  3.76k|    current_capacity = FUNCTION(capacity)(v);
  ------------------
  |  |  170|  3.76k|    #define FUNCTION(c) CONCAT2x(igraph_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|  3.76k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
  243|       |
  244|  3.76k|    if (capacity <= current_capacity) {
  ------------------
  |  Branch (244:9): [True: 102, False: 3.66k]
  ------------------
  245|    102|        return IGRAPH_SUCCESS;
  246|    102|    }
  247|       |
  248|  3.66k|    tmp = IGRAPH_REALLOC(v->stor_begin, capacity, ITEM_TYPE);
  ------------------
  |  |   40|  3.66k|#define IGRAPH_REALLOC(p,n,t) IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, realloc((void*)(p), sizeof(t) * ((n) > 0 ? (n) : 1)))
  |  |  ------------------
  |  |  |  |   36|  7.33k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.66k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.66k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.66k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  249|  3.66k|    IGRAPH_CHECK_OOM(tmp, "Cannot reserve space for list.");
  ------------------
  |  |  701|  3.66k|    do { \
  |  |  702|  3.66k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  3.66k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.66k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  3.66k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  250|       |
  251|  3.66k|    v->end = tmp + (v->end - v->stor_begin);
  252|  3.66k|    v->stor_begin = tmp;
  253|  3.66k|    v->stor_end = v->stor_begin + capacity;
  254|       |
  255|  3.66k|    return IGRAPH_SUCCESS;
  256|  3.66k|}
igraph_bitset_list_size:
  288|  3.76k|igraph_integer_t FUNCTION(size)(const TYPE *v) {
  289|  3.76k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  290|  3.76k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  291|  3.76k|    return v->end - v->stor_begin;
  292|  3.76k|}
igraph_bitset_list_resize:
  325|  3.76k|igraph_error_t FUNCTION(resize)(TYPE *v, igraph_integer_t new_size) {
  326|  3.76k|    igraph_integer_t old_size;
  327|       |
  328|  3.76k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  329|  3.76k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  330|       |
  331|  3.76k|    IGRAPH_CHECK(FUNCTION(reserve)(v, new_size));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  332|       |
  333|  3.76k|    old_size = FUNCTION(size)(v);
  ------------------
  |  |  170|  3.76k|    #define FUNCTION(c) CONCAT2x(igraph_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|  3.76k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
  334|       |
  335|  3.76k|    if (old_size < new_size) {
  ------------------
  |  Branch (335:9): [True: 3.76k, False: 2]
  ------------------
  336|  3.76k|        IGRAPH_CHECK(INTERNAL_FUNCTION(init_slice)(v, v->stor_begin + old_size, v->stor_begin + new_size));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  337|  3.76k|    } else if (old_size > new_size) {
  ------------------
  |  Branch (337:16): [True: 0, False: 2]
  ------------------
  338|      0|        INTERNAL_FUNCTION(destroy_slice)(v, v->stor_begin + new_size, v->stor_begin + old_size);
  ------------------
  |  |  171|      0|    #define INTERNAL_FUNCTION(c) CONCAT2x(igraph_i_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|      0|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
  339|      0|    }
  340|       |
  341|  3.76k|    v->end = v->stor_begin + new_size;
  342|       |
  343|  3.76k|    return IGRAPH_SUCCESS;
  344|  3.76k|}
igraph_bitset_list_clear:
  358|  3.76k|void FUNCTION(clear)(TYPE *v) {
  359|  3.76k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  360|  3.76k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  361|  3.76k|    INTERNAL_FUNCTION(destroy_slice)(v, v->stor_begin, v->end);
  ------------------
  |  |  171|  3.76k|    #define INTERNAL_FUNCTION(c) CONCAT2x(igraph_i_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|  3.76k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
  362|  3.76k|    v->end = v->stor_begin;
  363|  3.76k|}
igraph_bitset_list_get_ptr:
  378|  2.99M|ITEM_TYPE *FUNCTION(get_ptr)(const TYPE *v, igraph_integer_t pos) {
  379|  2.99M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  2.99M|    do { \
  |  |  917|  2.99M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  2.99M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.99M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  2.99M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  380|  2.99M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  2.99M|    do { \
  |  |  917|  2.99M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  2.99M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.99M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  2.99M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  381|  2.99M|    return v->stor_begin + pos;
  382|  2.99M|}
bitset_list.c:igraph_i_bitset_list_init_slice:
 1069|  7.53k|static igraph_error_t INTERNAL_FUNCTION(init_slice)(const TYPE *list, ITEM_TYPE *start, ITEM_TYPE *end) {
 1070|  7.53k|    ITEM_TYPE *current;
  ------------------
  |  |   62|  7.53k|    #define ITEM_TYPE BASE
  |  |  ------------------
  |  |  |  |  123|  7.53k|    #define BASE igraph_bitset_t
  |  |  ------------------
  ------------------
 1071|  7.53k|    igraph_error_t retval;
 1072|       |
 1073|   728k|    for (current = start; current < end; current++) {
  ------------------
  |  Branch (1073:27): [True: 721k, False: 7.53k]
  ------------------
 1074|   721k|        retval = INTERNAL_FUNCTION(init_item)(list, current);
  ------------------
  |  |  171|   721k|    #define INTERNAL_FUNCTION(c) CONCAT2x(igraph_i_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|   721k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
 1075|   721k|        if (retval) {
  ------------------
  |  Branch (1075:13): [True: 0, False: 721k]
  ------------------
 1076|      0|            INTERNAL_FUNCTION(destroy_slice)(list, start, current);
  ------------------
  |  |  171|      0|    #define INTERNAL_FUNCTION(c) CONCAT2x(igraph_i_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|      0|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
 1077|      0|            IGRAPH_CHECK(retval);
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1078|      0|        }
 1079|   721k|    }
 1080|       |
 1081|  7.53k|    return IGRAPH_SUCCESS;
 1082|  7.53k|}
bitset_list.c:igraph_i_bitset_list_destroy_slice:
 1084|  3.76k|static void INTERNAL_FUNCTION(destroy_slice)(const TYPE *list, ITEM_TYPE *start, ITEM_TYPE *end) {
 1085|  3.76k|    IGRAPH_UNUSED(list);
  ------------------
  |  |   32|  3.76k|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
 1086|   724k|    for (; start < end; start++) {
  ------------------
  |  Branch (1086:12): [True: 721k, False: 3.76k]
  ------------------
 1087|   721k|        INTERNAL_FUNCTION(destroy_item)(start);
  ------------------
  |  |  171|   721k|    #define INTERNAL_FUNCTION(c) CONCAT2x(igraph_i_bitset_list,c)
  |  |  ------------------
  |  |  |  |   24|   721k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  ------------------
  ------------------
 1088|   721k|    }
 1089|  3.76k|}

igraph_vector_int_pair_order:
  120|  24.6k|                                       igraph_vector_int_t* res, igraph_integer_t nodes) {
  121|  24.6k|    igraph_integer_t edges = igraph_vector_int_size(v);
  122|  24.6k|    igraph_vector_int_t ptr;
  123|  24.6k|    igraph_vector_int_t rad;
  124|  24.6k|    igraph_integer_t i, j;
  125|       |
  126|  24.6k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  24.6k|    do { \
  |  |  917|  24.6k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  24.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 24.6k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  24.6k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  127|  24.6k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  24.6k|    do { \
  |  |  917|  24.6k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  24.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 24.6k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  24.6k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  128|       |
  129|  24.6k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&ptr, nodes + 1);
  ------------------
  |  |  124|  24.6k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  24.6k|    do { \
  |  |  |  |  649|  24.6k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  24.6k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  24.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 24.6k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  24.6k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  24.6k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  24.6k|    do { \
  |  |  |  |  592|  24.6k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  24.6k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  24.6k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  24.6k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  24.6k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  24.6k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  130|  24.6k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&rad, edges);
  ------------------
  |  |  124|  24.6k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  24.6k|    do { \
  |  |  |  |  649|  24.6k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  24.6k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  24.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 24.6k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  24.6k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  24.6k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  24.6k|    do { \
  |  |  |  |  592|  24.6k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  24.6k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  24.6k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  24.6k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  24.6k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  24.6k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  131|  24.6k|    IGRAPH_CHECK(igraph_vector_int_resize(res, edges));
  ------------------
  |  |  648|  24.6k|    do { \
  |  |  649|  24.6k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  24.6k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  24.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 24.6k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  24.6k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  132|       |
  133|  2.58M|    for (i = 0; i < edges; i++) {
  ------------------
  |  Branch (133:17): [True: 2.55M, False: 24.6k]
  ------------------
  134|  2.55M|        igraph_integer_t radix = VECTOR(*v2)[i];
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  135|  2.55M|        if (VECTOR(ptr)[radix] != 0) {
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (135:13): [True: 2.27M, False: 288k]
  ------------------
  136|  2.27M|            VECTOR(rad)[i] = VECTOR(ptr)[radix];
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(rad)[i] = VECTOR(ptr)[radix];
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  137|  2.27M|        }
  138|  2.55M|        VECTOR(ptr)[radix] = i + 1;
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  139|  2.55M|    }
  140|       |
  141|  24.6k|    j = 0;
  142|  3.73M|    for (i = 0; i < nodes + 1; i++) {
  ------------------
  |  Branch (142:17): [True: 3.71M, False: 24.6k]
  ------------------
  143|  3.71M|        if (VECTOR(ptr)[i] != 0) {
  ------------------
  |  |   65|  3.71M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (143:13): [True: 288k, False: 3.42M]
  ------------------
  144|   288k|            igraph_integer_t next = VECTOR(ptr)[i] - 1;
  ------------------
  |  |   65|   288k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  145|   288k|            VECTOR(*res)[j++] = next;
  ------------------
  |  |   65|   288k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  146|  2.55M|            while (VECTOR(rad)[next] != 0) {
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (146:20): [True: 2.27M, False: 288k]
  ------------------
  147|  2.27M|                next = VECTOR(rad)[next] - 1;
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  148|  2.27M|                VECTOR(*res)[j++] = next;
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  149|  2.27M|            }
  150|   288k|        }
  151|  3.71M|    }
  152|       |
  153|  24.6k|    igraph_vector_int_null(&ptr);
  154|  24.6k|    igraph_vector_int_null(&rad);
  155|       |
  156|  2.58M|    for (i = 0; i < edges; i++) {
  ------------------
  |  Branch (156:17): [True: 2.55M, False: 24.6k]
  ------------------
  157|  2.55M|        igraph_integer_t edge = VECTOR(*res)[edges - i - 1];
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  158|  2.55M|        igraph_integer_t radix = VECTOR(*v)[edge];
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  159|  2.55M|        if (VECTOR(ptr)[radix] != 0) {
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (159:13): [True: 2.27M, False: 288k]
  ------------------
  160|  2.27M|            VECTOR(rad)[edge] = VECTOR(ptr)[radix];
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(rad)[edge] = VECTOR(ptr)[radix];
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  161|  2.27M|        }
  162|  2.55M|        VECTOR(ptr)[radix] = edge + 1;
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  163|  2.55M|    }
  164|       |
  165|  24.6k|    j = 0;
  166|  3.73M|    for (i = 0; i < nodes + 1; i++) {
  ------------------
  |  Branch (166:17): [True: 3.71M, False: 24.6k]
  ------------------
  167|  3.71M|        if (VECTOR(ptr)[i] != 0) {
  ------------------
  |  |   65|  3.71M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (167:13): [True: 288k, False: 3.42M]
  ------------------
  168|   288k|            igraph_integer_t next = VECTOR(ptr)[i] - 1;
  ------------------
  |  |   65|   288k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  169|   288k|            VECTOR(*res)[j++] = next;
  ------------------
  |  |   65|   288k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  170|  2.55M|            while (VECTOR(rad)[next] != 0) {
  ------------------
  |  |   65|  2.55M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (170:20): [True: 2.27M, False: 288k]
  ------------------
  171|  2.27M|                next = VECTOR(rad)[next] - 1;
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  172|  2.27M|                VECTOR(*res)[j++] = next;
  ------------------
  |  |   65|  2.27M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  173|  2.27M|            }
  174|   288k|        }
  175|  3.71M|    }
  176|       |
  177|  24.6k|    igraph_vector_int_destroy(&ptr);
  178|  24.6k|    igraph_vector_int_destroy(&rad);
  179|  24.6k|    IGRAPH_FINALLY_CLEAN(2);
  180|       |
  181|  24.6k|    return IGRAPH_SUCCESS;
  182|  24.6k|}
igraph_i_vector_int_order:
  198|  1.88k|        igraph_integer_t maxval) {
  199|       |
  200|  1.88k|    const igraph_integer_t size = igraph_vector_int_size(v);
  201|  1.88k|    igraph_vector_int_t ptr;
  202|  1.88k|    igraph_vector_int_t rad;
  203|  1.88k|    igraph_integer_t j;
  204|       |
  205|  1.88k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  1.88k|    do { \
  |  |  917|  1.88k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  206|  1.88k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  1.88k|    do { \
  |  |  917|  1.88k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  207|       |
  208|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&ptr, maxval + 1);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  209|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&rad, size);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  210|  1.88k|    IGRAPH_CHECK(igraph_vector_int_resize(res, size));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  211|       |
  212|   375k|    for (igraph_integer_t i = 0; i < size; i++) {
  ------------------
  |  Branch (212:34): [True: 373k, False: 1.88k]
  ------------------
  213|   373k|        igraph_integer_t radix = VECTOR(*v)[i];
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  214|   373k|        if (VECTOR(ptr)[radix] != 0) {
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (214:13): [True: 366k, False: 6.68k]
  ------------------
  215|   366k|            VECTOR(rad)[i] = VECTOR(ptr)[radix];
  ------------------
  |  |   65|   366k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(rad)[i] = VECTOR(ptr)[radix];
  ------------------
  |  |   65|   366k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  216|   366k|        }
  217|   373k|        VECTOR(ptr)[radix] = i + 1;
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  218|   373k|    }
  219|       |
  220|  1.88k|    j = 0;
  221|  19.4k|    for (igraph_integer_t i = 0; i < maxval + 1; i++) {
  ------------------
  |  Branch (221:34): [True: 17.5k, False: 1.88k]
  ------------------
  222|  17.5k|        if (VECTOR(ptr)[i] != 0) {
  ------------------
  |  |   65|  17.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (222:13): [True: 6.68k, False: 10.8k]
  ------------------
  223|  6.68k|            igraph_integer_t next = VECTOR(ptr)[i] - 1;
  ------------------
  |  |   65|  6.68k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  224|  6.68k|            VECTOR(*res)[j++] = next;
  ------------------
  |  |   65|  6.68k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  225|   373k|            while (VECTOR(rad)[next] != 0) {
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (225:20): [True: 366k, False: 6.68k]
  ------------------
  226|   366k|                next = VECTOR(rad)[next] - 1;
  ------------------
  |  |   65|   366k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  227|   366k|                VECTOR(*res)[j++] = next;
  ------------------
  |  |   65|   366k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  228|   366k|            }
  229|  6.68k|        }
  230|  17.5k|    }
  231|       |
  232|  1.88k|    igraph_vector_int_destroy(&ptr);
  233|  1.88k|    igraph_vector_int_destroy(&rad);
  234|  1.88k|    IGRAPH_FINALLY_CLEAN(2);
  235|       |
  236|  1.88k|    return IGRAPH_SUCCESS;
  237|  1.88k|}

igraph_vector_init:
  135|  7.53k|igraph_error_t FUNCTION(igraph_vector, init)(TYPE(igraph_vector) *v, igraph_integer_t size) {
  136|  7.53k|    igraph_integer_t alloc_size;
  137|  7.53k|    IGRAPH_ASSERT(size >= 0);
  ------------------
  |  |  916|  7.53k|    do { \
  |  |  917|  7.53k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  138|  7.53k|    alloc_size = size > 0 ? size : 1;
  ------------------
  |  Branch (138:18): [True: 0, False: 7.53k]
  ------------------
  139|       |
  140|       |    /* When this function fails, it should leave stor_begin set to NULL,
  141|       |     * so that vector_destroy() is still safe to call on the vector.
  142|       |     * This simplifies freeing partially initialized data structures,
  143|       |     * such as adjacency lists, when an error occurs mid-initialization. */
  144|  7.53k|    v->stor_begin = IGRAPH_CALLOC(alloc_size, BASE);
  ------------------
  |  |   38|  7.53k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  15.0k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 7.53k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 7.53k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 7.53k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  145|  7.53k|    if (v->stor_begin == NULL) {
  ------------------
  |  Branch (145:9): [True: 0, False: 7.53k]
  ------------------
  146|      0|        IGRAPH_ERROR("Cannot initialize vector.", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  147|      0|    }
  148|  7.53k|    v->stor_end = v->stor_begin + alloc_size;
  149|  7.53k|    v->end = v->stor_begin + size;
  150|       |
  151|  7.53k|    return IGRAPH_SUCCESS;
  152|  7.53k|}
igraph_vector_destroy:
  400|  7.53k|void FUNCTION(igraph_vector, destroy)(TYPE(igraph_vector) *v) {
  401|  7.53k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  7.53k|    do { \
  |  |  917|  7.53k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  402|       |    /* vector_init() will leave stor_begin set to NULL when it fails.
  403|       |     * We handle these cases gracefully. */
  404|  7.53k|    if (v->stor_begin != NULL) {
  ------------------
  |  Branch (404:9): [True: 7.53k, False: 0]
  ------------------
  405|  7.53k|        IGRAPH_FREE(v->stor_begin);
  ------------------
  |  |   41|  7.53k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  406|  7.53k|        v->stor_begin = NULL;
  407|  7.53k|    }
  408|  7.53k|}
igraph_vector_capacity:
  428|  7.53k|igraph_integer_t FUNCTION(igraph_vector, capacity)(const TYPE(igraph_vector) *v) {
  429|  7.53k|    return v->stor_end - v->stor_begin;
  430|  7.53k|}
igraph_vector_reserve:
  460|  7.53k|igraph_error_t FUNCTION(igraph_vector, reserve)(TYPE(igraph_vector) *v, igraph_integer_t capacity) {
  461|  7.53k|    igraph_integer_t current_capacity;
  462|  7.53k|    BASE *tmp;
  ------------------
  |  |   34|  7.53k|    #define BASE igraph_real_t
  ------------------
  463|       |
  464|  7.53k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  7.53k|    do { \
  |  |  917|  7.53k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  465|  7.53k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  7.53k|    do { \
  |  |  917|  7.53k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  466|  7.53k|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|  7.53k|    do { \
  |  |  917|  7.53k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  467|       |
  468|  7.53k|    current_capacity = FUNCTION(igraph_vector, capacity)(v);
  ------------------
  |  |  175|  7.53k|        #define FUNCTION(a,c) CONCAT2(a,c)
  |  |  ------------------
  |  |  |  |   25|  7.53k|#define CONCAT2(a,b) CONCAT2x(a,b)
  |  |  |  |  ------------------
  |  |  |  |  |  |   24|  7.53k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  469|       |
  470|  7.53k|    if (capacity <= current_capacity) {
  ------------------
  |  Branch (470:9): [True: 2.88k, False: 4.64k]
  ------------------
  471|  2.88k|        return IGRAPH_SUCCESS;
  472|  2.88k|    }
  473|       |
  474|  4.64k|    tmp = IGRAPH_REALLOC(v->stor_begin, capacity, BASE);
  ------------------
  |  |   40|  4.64k|#define IGRAPH_REALLOC(p,n,t) IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, realloc((void*)(p), sizeof(t) * ((n) > 0 ? (n) : 1)))
  |  |  ------------------
  |  |  |  |   36|  9.29k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 4.64k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 4.64k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 4.64k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  475|  4.64k|    IGRAPH_CHECK_OOM(tmp, "Cannot reserve space for vector.");
  ------------------
  |  |  701|  4.64k|    do { \
  |  |  702|  4.64k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  4.64k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.64k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  4.64k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  476|       |
  477|  4.64k|    v->end = tmp + (v->end - v->stor_begin);
  478|  4.64k|    v->stor_begin = tmp;
  479|  4.64k|    v->stor_end = v->stor_begin + capacity;
  480|       |
  481|  4.64k|    return IGRAPH_SUCCESS;
  482|  4.64k|}
igraph_vector_size:
  514|  15.0k|igraph_integer_t FUNCTION(igraph_vector, size)(const TYPE(igraph_vector) *v) {
  515|  15.0k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  15.0k|    do { \
  |  |  917|  15.0k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  15.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 15.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  15.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  516|  15.0k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  15.0k|    do { \
  |  |  917|  15.0k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  15.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 15.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  15.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  517|  15.0k|    return v->end - v->stor_begin;
  518|  15.0k|}
igraph_vector_null:
  717|  5.65k|void FUNCTION(igraph_vector, null)(TYPE(igraph_vector) *v) {
  718|  5.65k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  5.65k|    do { \
  |  |  917|  5.65k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.65k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  719|  5.65k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  5.65k|    do { \
  |  |  917|  5.65k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.65k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  720|  5.65k|    if (FUNCTION(igraph_vector, size)(v) > 0) {
  ------------------
  |  |  175|  5.65k|        #define FUNCTION(a,c) CONCAT2(a,c)
  |  |  ------------------
  |  |  |  |   25|  5.65k|#define CONCAT2(a,b) CONCAT2x(a,b)
  |  |  |  |  ------------------
  |  |  |  |  |  |   24|  5.65k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (720:9): [True: 5.65k, False: 0]
  ------------------
  721|  5.65k|        memset(v->stor_begin, 0, sizeof(BASE) * FUNCTION(igraph_vector, size)(v));
  ------------------
  |  |  175|  5.65k|        #define FUNCTION(a,c) CONCAT2(a,c)
  |  |  ------------------
  |  |  |  |   25|  5.65k|#define CONCAT2(a,b) CONCAT2x(a,b)
  |  |  |  |  ------------------
  |  |  |  |  |  |   24|  5.65k|#define CONCAT2x(a,b) a ## _ ## b
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  722|  5.65k|    }
  723|  5.65k|}
igraph_vector_resize:
 1241|  7.53k|igraph_error_t FUNCTION(igraph_vector, resize)(TYPE(igraph_vector)* v, igraph_integer_t new_size) {
 1242|  7.53k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  7.53k|    do { \
  |  |  917|  7.53k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1243|  7.53k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  7.53k|    do { \
  |  |  917|  7.53k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1244|  7.53k|    IGRAPH_CHECK(FUNCTION(igraph_vector, reserve)(v, new_size));
  ------------------
  |  |  648|  7.53k|    do { \
  |  |  649|  7.53k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  7.53k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  7.53k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 7.53k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  7.53k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1245|  7.53k|    v->end = v->stor_begin + new_size;
 1246|  7.53k|    return IGRAPH_SUCCESS;
 1247|  7.53k|}
igraph_vector_int_init:
  135|  8.31M|igraph_error_t FUNCTION(igraph_vector, init)(TYPE(igraph_vector) *v, igraph_integer_t size) {
  136|  8.31M|    igraph_integer_t alloc_size;
  137|  8.31M|    IGRAPH_ASSERT(size >= 0);
  ------------------
  |  |  916|  8.31M|    do { \
  |  |  917|  8.31M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  8.31M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.31M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  8.31M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  138|  8.31M|    alloc_size = size > 0 ? size : 1;
  ------------------
  |  Branch (138:18): [True: 1.85M, False: 6.46M]
  ------------------
  139|       |
  140|       |    /* When this function fails, it should leave stor_begin set to NULL,
  141|       |     * so that vector_destroy() is still safe to call on the vector.
  142|       |     * This simplifies freeing partially initialized data structures,
  143|       |     * such as adjacency lists, when an error occurs mid-initialization. */
  144|  8.31M|    v->stor_begin = IGRAPH_CALLOC(alloc_size, BASE);
  ------------------
  |  |   38|  8.31M|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  16.6M|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 8.31M, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 8.31M, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 8.31M, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  145|  8.31M|    if (v->stor_begin == NULL) {
  ------------------
  |  Branch (145:9): [True: 0, False: 8.31M]
  ------------------
  146|      0|        IGRAPH_ERROR("Cannot initialize vector.", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  147|      0|    }
  148|  8.31M|    v->stor_end = v->stor_begin + alloc_size;
  149|  8.31M|    v->end = v->stor_begin + size;
  150|       |
  151|  8.31M|    return IGRAPH_SUCCESS;
  152|  8.31M|}
igraph_vector_int_destroy:
  400|  8.31M|void FUNCTION(igraph_vector, destroy)(TYPE(igraph_vector) *v) {
  401|  8.31M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  8.31M|    do { \
  |  |  917|  8.31M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  8.31M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.31M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  8.31M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  402|       |    /* vector_init() will leave stor_begin set to NULL when it fails.
  403|       |     * We handle these cases gracefully. */
  404|  8.31M|    if (v->stor_begin != NULL) {
  ------------------
  |  Branch (404:9): [True: 8.31M, False: 0]
  ------------------
  405|  8.31M|        IGRAPH_FREE(v->stor_begin);
  ------------------
  |  |   41|  8.31M|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  406|  8.31M|        v->stor_begin = NULL;
  407|  8.31M|    }
  408|  8.31M|}
igraph_vector_int_capacity:
  428|  14.4M|igraph_integer_t FUNCTION(igraph_vector, capacity)(const TYPE(igraph_vector) *v) {
  429|  14.4M|    return v->stor_end - v->stor_begin;
  430|  14.4M|}
igraph_vector_int_reserve:
  460|  14.4M|igraph_error_t FUNCTION(igraph_vector, reserve)(TYPE(igraph_vector) *v, igraph_integer_t capacity) {
  461|  14.4M|    igraph_integer_t current_capacity;
  462|  14.4M|    BASE *tmp;
  ------------------
  |  |   71|  14.4M|    #define BASE igraph_integer_t
  ------------------
  463|       |
  464|  14.4M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  14.4M|    do { \
  |  |  917|  14.4M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.4M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.4M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.4M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  465|  14.4M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  14.4M|    do { \
  |  |  917|  14.4M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.4M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.4M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.4M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  466|  14.4M|    IGRAPH_ASSERT(capacity >= 0);
  ------------------
  |  |  916|  14.4M|    do { \
  |  |  917|  14.4M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.4M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.4M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.4M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  467|       |
  468|  14.4M|    current_capacity = FUNCTION(igraph_vector, capacity)(v);
  ------------------
  |  |  183|  14.4M|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  14.4M|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  14.4M|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  469|       |
  470|  14.4M|    if (capacity <= current_capacity) {
  ------------------
  |  Branch (470:9): [True: 14.0M, False: 392k]
  ------------------
  471|  14.0M|        return IGRAPH_SUCCESS;
  472|  14.0M|    }
  473|       |
  474|   392k|    tmp = IGRAPH_REALLOC(v->stor_begin, capacity, BASE);
  ------------------
  |  |   40|   392k|#define IGRAPH_REALLOC(p,n,t) IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, realloc((void*)(p), sizeof(t) * ((n) > 0 ? (n) : 1)))
  |  |  ------------------
  |  |  |  |   36|   784k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 392k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 392k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 392k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  475|   392k|    IGRAPH_CHECK_OOM(tmp, "Cannot reserve space for vector.");
  ------------------
  |  |  701|   392k|    do { \
  |  |  702|   392k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|   392k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 392k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|   392k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  476|       |
  477|   392k|    v->end = tmp + (v->end - v->stor_begin);
  478|   392k|    v->stor_begin = tmp;
  479|   392k|    v->stor_end = v->stor_begin + capacity;
  480|       |
  481|   392k|    return IGRAPH_SUCCESS;
  482|   392k|}
igraph_vector_int_empty:
  495|  5.22M|igraph_bool_t FUNCTION(igraph_vector, empty)(const TYPE(igraph_vector) *v) {
  496|  5.22M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  5.22M|    do { \
  |  |  917|  5.22M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.22M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.22M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.22M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  497|  5.22M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  5.22M|    do { \
  |  |  917|  5.22M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  5.22M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.22M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  5.22M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  498|  5.22M|    return v->stor_begin == v->end;
  499|  5.22M|}
igraph_vector_int_size:
  514|  79.3M|igraph_integer_t FUNCTION(igraph_vector, size)(const TYPE(igraph_vector) *v) {
  515|  79.3M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  79.3M|    do { \
  |  |  917|  79.3M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  79.3M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 79.3M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  79.3M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  516|  79.3M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  79.3M|    do { \
  |  |  917|  79.3M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  79.3M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 79.3M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  79.3M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  517|  79.3M|    return v->end - v->stor_begin;
  518|  79.3M|}
igraph_vector_int_clear:
  534|  3.29M|void FUNCTION(igraph_vector, clear)(TYPE(igraph_vector)* v) {
  535|  3.29M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  3.29M|    do { \
  |  |  917|  3.29M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.29M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.29M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.29M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  536|  3.29M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  3.29M|    do { \
  |  |  917|  3.29M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.29M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.29M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.29M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  537|  3.29M|    v->end = v->stor_begin;
  538|  3.29M|}
igraph_vector_int_push_back:
  565|  25.4M|igraph_error_t FUNCTION(igraph_vector, push_back)(TYPE(igraph_vector) *v, BASE e) {
  566|  25.4M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  25.4M|    do { \
  |  |  917|  25.4M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  25.4M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 25.4M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  25.4M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  567|  25.4M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  25.4M|    do { \
  |  |  917|  25.4M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  25.4M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 25.4M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  25.4M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  568|       |
  569|  25.4M|    if (v->stor_end == v->end) {
  ------------------
  |  Branch (569:9): [True: 283k, False: 25.1M]
  ------------------
  570|       |        /* full, allocate more storage */
  571|   283k|        igraph_integer_t old_size = FUNCTION(igraph_vector, size)(v);
  ------------------
  |  |  183|   283k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|   283k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   283k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  572|   283k|        igraph_integer_t new_size = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|   283k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
                      igraph_integer_t new_size = old_size < IGRAPH_INTEGER_MAX/2 ? old_size * 2 : IGRAPH_INTEGER_MAX;
  ------------------
  |  |   77|   283k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (572:37): [True: 283k, False: 0]
  ------------------
  573|   283k|        if (old_size == IGRAPH_INTEGER_MAX) {
  ------------------
  |  |   77|   283k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (573:13): [True: 0, False: 283k]
  ------------------
  574|      0|            IGRAPH_ERROR("Cannot push to vector, already at maximum size.", IGRAPH_EOVERFLOW);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  575|      0|        }
  576|   283k|        if (new_size == 0) {
  ------------------
  |  Branch (576:13): [True: 0, False: 283k]
  ------------------
  577|      0|            new_size = 1;
  578|      0|        }
  579|   283k|        IGRAPH_CHECK(FUNCTION(igraph_vector, reserve)(v, new_size));
  ------------------
  |  |  648|   283k|    do { \
  |  |  649|   283k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   283k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   283k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 283k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   283k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  580|   283k|    }
  581|       |
  582|  25.4M|    *(v->end) = e;
  583|  25.4M|    v->end += 1;
  584|       |
  585|  25.4M|    return IGRAPH_SUCCESS;
  586|  25.4M|}
igraph_vector_int_get_ptr:
  674|  2.04M|BASE* FUNCTION(igraph_vector, get_ptr)(const TYPE(igraph_vector) *v, igraph_integer_t pos) {
  675|  2.04M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  2.04M|    do { \
  |  |  917|  2.04M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  2.04M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.04M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  2.04M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  676|  2.04M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  2.04M|    do { \
  |  |  917|  2.04M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  2.04M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.04M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  2.04M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  677|  2.04M|    return v->stor_begin + pos;
  678|  2.04M|}
igraph_vector_int_null:
  717|  84.9k|void FUNCTION(igraph_vector, null)(TYPE(igraph_vector) *v) {
  718|  84.9k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  84.9k|    do { \
  |  |  917|  84.9k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  84.9k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 84.9k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  84.9k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  719|  84.9k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  84.9k|    do { \
  |  |  917|  84.9k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  84.9k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 84.9k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  84.9k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  720|  84.9k|    if (FUNCTION(igraph_vector, size)(v) > 0) {
  ------------------
  |  |  183|  84.9k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  84.9k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  84.9k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (720:9): [True: 83.0k, False: 1.84k]
  ------------------
  721|  83.0k|        memset(v->stor_begin, 0, sizeof(BASE) * FUNCTION(igraph_vector, size)(v));
  ------------------
  |  |  183|  83.0k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  83.0k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  83.0k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  722|  83.0k|    }
  723|  84.9k|}
igraph_vector_int_fill:
  737|  1.59k|void FUNCTION(igraph_vector, fill)(TYPE(igraph_vector) *v, BASE e) {
  738|  1.59k|    BASE *ptr;
  ------------------
  |  |   71|  1.59k|    #define BASE igraph_integer_t
  ------------------
  739|  1.59k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  1.59k|    do { \
  |  |  917|  1.59k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  740|  1.59k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  1.59k|    do { \
  |  |  917|  1.59k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  741|   343k|    for (ptr = v->stor_begin; ptr < v->end; ptr++) {
  ------------------
  |  Branch (741:31): [True: 341k, False: 1.59k]
  ------------------
  742|   341k|        *ptr = e;
  743|   341k|    }
  744|  1.59k|}
igraph_vector_int_tail:
  794|  4.79M|BASE FUNCTION(igraph_vector, tail)(const TYPE(igraph_vector) *v) {
  795|  4.79M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  4.79M|    do { \
  |  |  917|  4.79M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  4.79M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.79M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  4.79M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  796|  4.79M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  4.79M|    do { \
  |  |  917|  4.79M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  4.79M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.79M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  4.79M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  797|  4.79M|    return *((v->end) - 1);
  798|  4.79M|}
igraph_vector_int_pop_back:
  813|  14.8M|BASE FUNCTION(igraph_vector, pop_back)(TYPE(igraph_vector) *v) {
  814|  14.8M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  14.8M|    do { \
  |  |  917|  14.8M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.8M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.8M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  815|  14.8M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  14.8M|    do { \
  |  |  917|  14.8M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.8M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.8M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  816|  14.8M|    IGRAPH_ASSERT(v->end != NULL);
  ------------------
  |  |  916|  14.8M|    do { \
  |  |  917|  14.8M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.8M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.8M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  817|  14.8M|    IGRAPH_ASSERT(v->end != v->stor_begin);
  ------------------
  |  |  916|  14.8M|    do { \
  |  |  917|  14.8M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.8M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.8M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  818|       |
  819|  14.8M|    (v->end)--;
  820|       |
  821|  14.8M|    return *(v->end);
  822|  14.8M|}
igraph_vector_int_sort:
  933|   675k|void FUNCTION(igraph_vector, sort)(TYPE(igraph_vector) *v) {
  934|   675k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|   675k|    do { \
  |  |  917|   675k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   675k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 675k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   675k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  935|   675k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|   675k|    do { \
  |  |  917|   675k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   675k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 675k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   675k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  936|   675k|    igraph_qsort(v->stor_begin, FUNCTION(igraph_vector, size)(v),
  ------------------
  |  |  183|   675k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|   675k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   675k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  937|   675k|                 sizeof(BASE), FUNCTION(igraph_vector, sort_cmp));
  ------------------
  |  |  183|   675k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|   675k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   675k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  938|   675k|}
igraph_vector_int_lex_cmp:
 1072|  3.51M|) {
 1073|  3.51M|    igraph_integer_t i, sa, sb;
 1074|  3.51M|    const TYPE(igraph_vector) *a = lhs, *b = rhs;
 1075|       |
 1076|  3.51M|    sa = FUNCTION(igraph_vector, size)(a);
  ------------------
  |  |  183|  3.51M|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  3.51M|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  3.51M|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1077|  3.51M|    sb = FUNCTION(igraph_vector, size)(b);
  ------------------
  |  |  183|  3.51M|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  3.51M|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  3.51M|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1078|       |
 1079|  6.82M|    for (i = 0; i < sa; i++) {
  ------------------
  |  Branch (1079:17): [True: 6.18M, False: 632k]
  ------------------
 1080|  6.18M|        if (i >= sb) {
  ------------------
  |  Branch (1080:13): [True: 0, False: 6.18M]
  ------------------
 1081|       |            /* b is shorter, and equal to the first part of a */
 1082|      0|            return 1;
 1083|      0|        }
 1084|  6.18M|        if (VECTOR(*a)[i] < VECTOR(*b)[i]) {
  ------------------
  |  |   65|  6.18M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      if (VECTOR(*a)[i] < VECTOR(*b)[i]) {
  ------------------
  |  |   65|  6.18M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1084:13): [True: 1.45M, False: 4.73M]
  ------------------
 1085|  1.45M|            return -1;
 1086|  1.45M|        }
 1087|  4.73M|        if (VECTOR(*a)[i] > VECTOR(*b)[i]) {
  ------------------
  |  |   65|  4.73M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      if (VECTOR(*a)[i] > VECTOR(*b)[i]) {
  ------------------
  |  |   65|  4.73M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1087:13): [True: 1.42M, False: 3.31M]
  ------------------
 1088|  1.42M|            return 1;
 1089|  1.42M|        }
 1090|  4.73M|    }
 1091|   632k|    if (i == sb) {
  ------------------
  |  Branch (1091:9): [True: 632k, False: 0]
  ------------------
 1092|   632k|        return 0;
 1093|   632k|    }
 1094|       |    /* a is shorter, and equal to the first part of b */
 1095|      0|    return -1;
 1096|   632k|}
igraph_vector_int_resize:
 1241|  14.0M|igraph_error_t FUNCTION(igraph_vector, resize)(TYPE(igraph_vector)* v, igraph_integer_t new_size) {
 1242|  14.0M|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  14.0M|    do { \
  |  |  917|  14.0M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.0M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.0M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.0M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1243|  14.0M|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  14.0M|    do { \
  |  |  917|  14.0M|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  14.0M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.0M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  14.0M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1244|  14.0M|    IGRAPH_CHECK(FUNCTION(igraph_vector, reserve)(v, new_size));
  ------------------
  |  |  648|  14.0M|    do { \
  |  |  649|  14.0M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  14.0M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  14.0M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.0M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  14.0M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1245|  14.0M|    v->end = v->stor_begin + new_size;
 1246|  14.0M|    return IGRAPH_SUCCESS;
 1247|  14.0M|}
igraph_vector_int_max:
 1304|  10.1k|BASE FUNCTION(igraph_vector, max)(const TYPE(igraph_vector) *v) {
 1305|  10.1k|    BASE max;
  ------------------
  |  |   71|  10.1k|    #define BASE igraph_integer_t
  ------------------
 1306|  10.1k|    BASE *ptr;
  ------------------
  |  |   71|  10.1k|    #define BASE igraph_integer_t
  ------------------
 1307|  10.1k|    IGRAPH_ASSERT(!FUNCTION(igraph_vector, empty)(v));
  ------------------
  |  |  916|  10.1k|    do { \
  |  |  917|  10.1k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  10.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 10.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  10.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1308|  10.1k|    max = *(v->stor_begin);
 1309|       |#if defined(BASE_IGRAPH_REAL)
 1310|       |    if (isnan(max)) { return max; }; /* Result is NaN */
 1311|       |#endif
 1312|  10.1k|    ptr = v->stor_begin + 1;
 1313|  2.81M|    while (ptr < v->end) {
  ------------------
  |  Branch (1313:12): [True: 2.80M, False: 10.1k]
  ------------------
 1314|  2.80M|        if ((*ptr) > max) {
  ------------------
  |  Branch (1314:13): [True: 62.4k, False: 2.74M]
  ------------------
 1315|  62.4k|            max = *ptr;
 1316|  62.4k|        }
 1317|       |#if defined(BASE_IGRAPH_REAL)
 1318|       |        else if (isnan(*ptr))
 1319|       |            return *ptr; /* Result is NaN */
 1320|       |#endif
 1321|  2.80M|        ptr++;
 1322|  2.80M|    }
 1323|  10.1k|    return max;
 1324|  10.1k|}
igraph_vector_int_init_copy:
 1515|   162k|) {
 1516|   162k|    igraph_integer_t from_size;
 1517|       |
 1518|   162k|    IGRAPH_ASSERT(from != NULL);
  ------------------
  |  |  916|   162k|    do { \
  |  |  917|   162k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   162k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 162k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   162k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1519|   162k|    IGRAPH_ASSERT(from->stor_begin != NULL);
  ------------------
  |  |  916|   162k|    do { \
  |  |  917|   162k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   162k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 162k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   162k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1520|       |
 1521|   162k|    from_size = FUNCTION(igraph_vector, size)(from);
  ------------------
  |  |  183|   162k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|   162k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   162k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1522|   162k|    IGRAPH_CHECK(FUNCTION(igraph_vector, init)(to, from_size));
  ------------------
  |  |  648|   162k|    do { \
  |  |  649|   162k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   162k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   162k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 162k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   162k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1523|       |
 1524|   162k|    memcpy(to->stor_begin, from->stor_begin, from_size * sizeof(BASE));
 1525|       |
 1526|   162k|    return IGRAPH_SUCCESS;
 1527|   162k|}
igraph_vector_int_isininterval:
 1809|  27.0k|        BASE high) {
 1810|  27.0k|    BASE *ptr;
  ------------------
  |  |   71|  27.0k|    #define BASE igraph_integer_t
  ------------------
 1811|  27.0k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  27.0k|    do { \
  |  |  917|  27.0k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  27.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 27.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  27.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1812|  27.0k|    IGRAPH_ASSERT(v->stor_begin != NULL);
  ------------------
  |  |  916|  27.0k|    do { \
  |  |  917|  27.0k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  27.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 27.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  27.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1813|  5.51M|    for (ptr = v->stor_begin; ptr < v->end; ptr++) {
  ------------------
  |  Branch (1813:31): [True: 5.48M, False: 27.0k]
  ------------------
 1814|       |        /* Note that the following is not equivalent to *ptr < low || *ptr > high
 1815|       |         * when *ptr is NaN! */
 1816|  5.48M|        if (!(*ptr >= low && *ptr <= high)) {
  ------------------
  |  Branch (1816:15): [True: 5.48M, False: 0]
  |  Branch (1816:30): [True: 5.48M, False: 0]
  ------------------
 1817|      0|            return 0;
 1818|      0|        }
 1819|  5.48M|    }
 1820|  27.0k|    return 1;
 1821|  27.0k|}
igraph_vector_int_all_e:
 1869|   672k|                                  const TYPE(igraph_vector) *rhs) {
 1870|   672k|    igraph_integer_t i, s;
 1871|   672k|    IGRAPH_ASSERT(lhs != 0);
  ------------------
  |  |  916|   672k|    do { \
  |  |  917|   672k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   672k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 672k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   672k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1872|   672k|    IGRAPH_ASSERT(rhs != 0);
  ------------------
  |  |  916|   672k|    do { \
  |  |  917|   672k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   672k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 672k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   672k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1873|   672k|    IGRAPH_ASSERT(lhs->stor_begin != 0);
  ------------------
  |  |  916|   672k|    do { \
  |  |  917|   672k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   672k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 672k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   672k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1874|   672k|    IGRAPH_ASSERT(rhs->stor_begin != 0);
  ------------------
  |  |  916|   672k|    do { \
  |  |  917|   672k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   672k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 672k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|   672k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1875|       |
 1876|   672k|    s = FUNCTION(igraph_vector, size)(lhs);
  ------------------
  |  |  183|   672k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|   672k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   672k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1877|   672k|    if (s != FUNCTION(igraph_vector, size)(rhs)) {
  ------------------
  |  |  183|   672k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|   672k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   672k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (1877:9): [True: 4.40k, False: 668k]
  ------------------
 1878|  4.40k|        return false;
 1879|   668k|    } else {
 1880|  3.02M|        for (i = 0; i < s; i++) {
  ------------------
  |  Branch (1880:21): [True: 2.45M, False: 570k]
  ------------------
 1881|  2.45M|            BASE l = VECTOR(*lhs)[i];
  ------------------
  |  |   71|  2.45M|    #define BASE igraph_integer_t
  ------------------
                          BASE l = VECTOR(*lhs)[i];
  ------------------
  |  |   65|  2.45M|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1882|  2.45M|            BASE r = VECTOR(*rhs)[i];
  ------------------
  |  |   71|  2.45M|    #define BASE igraph_integer_t
  ------------------
                          BASE r = VECTOR(*rhs)[i];
  ------------------
  |  |   65|  2.45M|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1883|       |#ifdef EQ
 1884|       |            if (!EQ(l, r)) {
 1885|       |#else
 1886|  2.45M|            if (l != r) {
  ------------------
  |  Branch (1886:17): [True: 97.8k, False: 2.36M]
  ------------------
 1887|  97.8k|#endif
 1888|  97.8k|                return false;
 1889|  97.8k|            }
 1890|  2.45M|        }
 1891|   570k|        return true;
 1892|   668k|    }
 1893|   672k|}
igraph_vector_int_contains:
 2284|  40.1k|        BASE what) {
 2285|  40.1k|    const BASE *p = v->stor_begin;
 2286|  1.82M|    while (p < v->end) {
  ------------------
  |  Branch (2286:12): [True: 1.80M, False: 20.0k]
  ------------------
 2287|       |#ifdef EQ
 2288|       |        if (EQ(*p, what)) {
 2289|       |#else
 2290|  1.80M|        if (*p == what) {
  ------------------
  |  Branch (2290:13): [True: 20.0k, False: 1.78M]
  ------------------
 2291|  20.0k|#endif
 2292|  20.0k|            return true;
 2293|  20.0k|        }
 2294|  1.78M|        p++;
 2295|  1.78M|    }
 2296|  20.0k|    return false;
 2297|  40.1k|}
igraph_vector_int_update:
 2481|  32.7k|                                    const TYPE(igraph_vector) *from) {
 2482|  32.7k|    igraph_integer_t n = FUNCTION(igraph_vector, size)(from);
  ------------------
  |  |  183|  32.7k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  32.7k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  32.7k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2483|  32.7k|    IGRAPH_CHECK(FUNCTION(igraph_vector, resize)(to, n));
  ------------------
  |  |  648|  32.7k|    do { \
  |  |  649|  32.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  32.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 2484|  32.7k|    memcpy(to->stor_begin, from->stor_begin, sizeof(BASE)*n);
 2485|  32.7k|    return IGRAPH_SUCCESS;
 2486|  32.7k|}
igraph_vector_int_swap:
 2498|   312k|void FUNCTION(igraph_vector, swap)(TYPE(igraph_vector) *v1, TYPE(igraph_vector) *v2) {
 2499|       |
 2500|   312k|    TYPE(igraph_vector) tmp;
  ------------------
  |  |  184|   312k|        #define TYPE(a) CONCAT3(a,SHORT,t)
  |  |  ------------------
  |  |  |  |   27|   312k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|   312k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 2501|       |
 2502|   312k|    tmp = *v1;
 2503|   312k|    *v1 = *v2;
 2504|   312k|    *v2 = tmp;
 2505|   312k|}
igraph_vector_int_intersection_size_sorted:
 3133|  57.5k|        const TYPE(igraph_vector) *v2) {
 3134|       |
 3135|  57.5k|    igraph_integer_t size1, size2, count;
 3136|  57.5k|    igraph_real_t r;
 3137|       |
 3138|  57.5k|    size1 = FUNCTION(igraph_vector, size)(v1);
  ------------------
  |  |  183|  57.5k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  57.5k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  57.5k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3139|  57.5k|    size2 = FUNCTION(igraph_vector, size)(v2);
  ------------------
  |  |  183|  57.5k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  57.5k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  57.5k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3140|       |
 3141|  57.5k|    count = 0;
 3142|       |
 3143|  57.5k|    if (size1 == 0 || size2 == 0) {
  ------------------
  |  Branch (3143:9): [True: 0, False: 57.5k]
  |  Branch (3143:23): [True: 0, False: 57.5k]
  ------------------
 3144|      0|        return count;
 3145|      0|    }
 3146|       |
 3147|  57.5k|    r = size1 > size2 ? (igraph_real_t) size1 / size2 : (igraph_real_t) size2 / size1;
  ------------------
  |  Branch (3147:9): [True: 16.7k, False: 40.7k]
  ------------------
 3148|       |
 3149|       |    /* When the set size ratio is small, use a simple linear scan. The ideal ratio
 3150|       |     * seems to be affected by processor cache effects. It depends on the machine,
 3151|       |     * as well as on the input sizes. The threshold of 10 was determined empirically
 3152|       |     * by using the intersection.c (direct) and igraph_ecc.c (indirect) benchmarks.
 3153|       |     * See https://github.com/igraph/igraph/pull/2618 */
 3154|  57.5k|    if (r < 10) {
  ------------------
  |  Branch (3154:9): [True: 47.0k, False: 10.4k]
  ------------------
 3155|       |        /* This is a fast branchless implementation that uses arithmetic
 3156|       |         * instead of conditionals. */
 3157|  47.0k|        igraph_integer_t i1 = 0, i2 = 0;
 3158|   245k|        while (i1 < size1 && i2 < size2) {
  ------------------
  |  Branch (3158:16): [True: 220k, False: 24.9k]
  |  Branch (3158:30): [True: 198k, False: 22.1k]
  ------------------
 3159|   198k|            BASE e1 = VECTOR(*v1)[i1], e2 = VECTOR(*v2)[i2];
  ------------------
  |  |   71|   198k|    #define BASE igraph_integer_t
  ------------------
                          BASE e1 = VECTOR(*v1)[i1], e2 = VECTOR(*v2)[i2];
  ------------------
  |  |   65|   198k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          BASE e1 = VECTOR(*v1)[i1], e2 = VECTOR(*v2)[i2];
  ------------------
  |  |   65|   198k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 3160|   198k|            igraph_integer_t d1 = (e1 <= e2), d2 = (e1 >= e2);
 3161|   198k|            i1 += d1; i2 += d2;
 3162|   198k|            count += (d1 == d2);
 3163|   198k|        }
 3164|  47.0k|    } else {
 3165|  10.4k|        FUNCTION(igraph_i_vector, intersection_size_sorted)(
  ------------------
  |  |  183|  10.4k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  10.4k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  10.4k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3166|  10.4k|            v1, 0, size1, v2, 0, size2, &count);
 3167|  10.4k|    }
 3168|       |
 3169|  57.5k|    return count;
 3170|  57.5k|}
vector.c:igraph_vector_int_sort_cmp:
  899|  6.60M|static int FUNCTION(igraph_vector, sort_cmp)(const void *a, const void *b) {
  900|  6.60M|    const BASE *da = (const BASE *) a;
  901|  6.60M|    const BASE *db = (const BASE *) b;
  902|       |
  903|  6.60M|    return (*da > *db) - (*da < *db);
  904|  6.60M|}
vector.c:igraph_i_vector_int_binsearch_slice:
 2160|  12.3k|        BASE what, igraph_integer_t *pos, igraph_integer_t start, igraph_integer_t end) {
 2161|  12.3k|    igraph_integer_t left  = start;
 2162|  12.3k|    igraph_integer_t right = end - 1;
 2163|       |
 2164|  78.9k|    while (left <= right) {
  ------------------
  |  Branch (2164:12): [True: 67.6k, False: 11.3k]
  ------------------
 2165|       |        /* (right + left) / 2 could theoretically overflow for long vectors */
 2166|  67.6k|        igraph_integer_t middle = left + ((right - left) >> 1);
 2167|  67.6k|        if (VECTOR(*v)[middle] > what) {
  ------------------
  |  |   65|  67.6k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (2167:13): [True: 40.0k, False: 27.5k]
  ------------------
 2168|  40.0k|            right = middle - 1;
 2169|  40.0k|        } else if (VECTOR(*v)[middle] < what) {
  ------------------
  |  |   65|  27.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (2169:20): [True: 26.5k, False: 1.01k]
  ------------------
 2170|  26.5k|            left = middle + 1;
 2171|  26.5k|        } else {
 2172|  1.01k|            if (pos != 0) {
  ------------------
  |  Branch (2172:17): [True: 1.01k, False: 0]
  ------------------
 2173|  1.01k|                *pos = middle;
 2174|  1.01k|            }
 2175|  1.01k|            return true;
 2176|  1.01k|        }
 2177|  67.6k|    }
 2178|       |
 2179|       |    /* if we are here, the element was not found */
 2180|  11.3k|    if (pos != 0) {
  ------------------
  |  Branch (2180:9): [True: 11.3k, False: 0]
  ------------------
 2181|  11.3k|        *pos = left;
 2182|  11.3k|    }
 2183|       |
 2184|  11.3k|    return false;
 2185|  12.3k|}
vector.c:igraph_i_vector_int_intersection_size_sorted:
 3054|  35.1k|    igraph_integer_t *result) {
 3055|       |
 3056|  35.1k|    igraph_integer_t size1, size2, probe1, probe2;
 3057|       |
 3058|  35.1k|    if (begin1 == end1 || begin2 == end2) {
  ------------------
  |  Branch (3058:9): [True: 14.0k, False: 21.1k]
  |  Branch (3058:27): [True: 8.82k, False: 12.3k]
  ------------------
 3059|  22.8k|        return;
 3060|  22.8k|    }
 3061|       |
 3062|  12.3k|    size1 = end1 - begin1;
 3063|  12.3k|    size2 = end2 - begin2;
 3064|       |
 3065|  12.3k|    if (size1 < size2) {
  ------------------
  |  Branch (3065:9): [True: 5.96k, False: 6.39k]
  ------------------
 3066|  5.96k|        probe1 = begin1 + (size1 >> 1);      /* pick the median element */
 3067|  5.96k|        FUNCTION(igraph_i_vector, binsearch_slice)(v2, VECTOR(*v1)[probe1], &probe2, begin2, end2);
  ------------------
  |  |  183|  5.96k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  5.96k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  5.96k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      FUNCTION(igraph_i_vector, binsearch_slice)(v2, VECTOR(*v1)[probe1], &probe2, begin2, end2);
  ------------------
  |  |   65|  5.96k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 3068|  5.96k|        FUNCTION(igraph_i_vector, intersection_size_sorted)(
  ------------------
  |  |  183|  5.96k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  5.96k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  5.96k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3069|  5.96k|            v1, begin1, probe1, v2, begin2, probe2, result
 3070|  5.96k|        );
 3071|  5.96k|        if (!(probe2 == end2 || VECTOR(*v1)[probe1] < VECTOR(*v2)[probe2])) {
  ------------------
  |  |   65|  5.10k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      if (!(probe2 == end2 || VECTOR(*v1)[probe1] < VECTOR(*v2)[probe2])) {
  ------------------
  |  |   65|  5.10k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (3071:15): [True: 860, False: 5.10k]
  |  Branch (3071:33): [True: 4.70k, False: 405]
  ------------------
 3072|    405|            (*result)++;
 3073|    405|            probe2++;
 3074|    405|        }
 3075|  5.96k|        FUNCTION(igraph_i_vector, intersection_size_sorted)(
  ------------------
  |  |  183|  5.96k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  5.96k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  5.96k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3076|  5.96k|            v1, probe1 + 1, end1, v2, probe2, end2, result
 3077|  5.96k|        );
 3078|  6.39k|    } else {
 3079|  6.39k|        probe2 = begin2 + (size2 >> 1);      /* pick the median element */
 3080|  6.39k|        FUNCTION(igraph_i_vector, binsearch_slice)(v1, VECTOR(*v2)[probe2], &probe1, begin1, end1);
  ------------------
  |  |  183|  6.39k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  6.39k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  6.39k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
                      FUNCTION(igraph_i_vector, binsearch_slice)(v1, VECTOR(*v2)[probe2], &probe1, begin1, end1);
  ------------------
  |  |   65|  6.39k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 3081|  6.39k|        FUNCTION(igraph_i_vector, intersection_size_sorted)(
  ------------------
  |  |  183|  6.39k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  6.39k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  6.39k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3082|  6.39k|            v1, begin1, probe1, v2, begin2, probe2, result
 3083|  6.39k|        );
 3084|  6.39k|        if (!(probe1 == end1 || VECTOR(*v2)[probe2] < VECTOR(*v1)[probe1])) {
  ------------------
  |  |   65|  5.34k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      if (!(probe1 == end1 || VECTOR(*v2)[probe2] < VECTOR(*v1)[probe1])) {
  ------------------
  |  |   65|  5.34k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (3084:15): [True: 1.04k, False: 5.34k]
  |  Branch (3084:33): [True: 4.73k, False: 605]
  ------------------
 3085|    605|            (*result)++;
 3086|    605|            probe1++;
 3087|    605|        }
 3088|  6.39k|        FUNCTION(igraph_i_vector, intersection_size_sorted)(
  ------------------
  |  |  183|  6.39k|        #define FUNCTION(a,c) CONCAT3(a,SHORT,c)
  |  |  ------------------
  |  |  |  |   27|  6.39k|#define CONCAT3(a,b,c) CONCAT3x(a,b,c)
  |  |  |  |  ------------------
  |  |  |  |  |  |   26|  6.39k|#define CONCAT3x(a,b,c) a ## _ ## b ## _ ## c
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 3089|  6.39k|            v1, probe1, end1, v2, probe2 + 1, end2, result
 3090|  6.39k|        );
 3091|  6.39k|    }
 3092|  12.3k|}

igraph_vector_ptr_init:
   87|  3.76k|igraph_error_t igraph_vector_ptr_init(igraph_vector_ptr_t* v, igraph_integer_t size) {
   88|  3.76k|    igraph_integer_t alloc_size = size > 0 ? size : 1;
  ------------------
  |  Branch (88:35): [True: 3.76k, False: 0]
  ------------------
   89|  3.76k|    IGRAPH_ASSERT(v != NULL);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   90|  3.76k|    if (size < 0) {
  ------------------
  |  Branch (90:9): [True: 0, False: 3.76k]
  ------------------
   91|      0|        size = 0;
   92|      0|    }
   93|  3.76k|    v->stor_begin = IGRAPH_CALLOC(alloc_size, void*);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   94|  3.76k|    if (v->stor_begin == 0) {
  ------------------
  |  Branch (94:9): [True: 0, False: 3.76k]
  ------------------
   95|      0|        IGRAPH_ERROR("vector ptr init failed", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   96|      0|    }
   97|  3.76k|    v->stor_end = v->stor_begin + alloc_size;
   98|  3.76k|    v->end = v->stor_begin + size;
   99|  3.76k|    v->item_destructor = 0;
  100|       |
  101|  3.76k|    return IGRAPH_SUCCESS;
  102|  3.76k|}
igraph_vector_ptr_destroy:
  133|  3.76k|void igraph_vector_ptr_destroy(igraph_vector_ptr_t* v) {
  134|  3.76k|    IGRAPH_ASSERT(v != 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  135|  3.76k|    if (v->stor_begin != 0) {
  ------------------
  |  Branch (135:9): [True: 3.76k, False: 0]
  ------------------
  136|  3.76k|        IGRAPH_FREE(v->stor_begin);
  ------------------
  |  |   41|  3.76k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  137|  3.76k|        v->stor_begin = NULL;
  138|  3.76k|    }
  139|  3.76k|}
igraph_vector_ptr_free_all:
  171|  3.76k|void igraph_vector_ptr_free_all(igraph_vector_ptr_t* v) {
  172|  3.76k|    void **ptr;
  173|  3.76k|    IGRAPH_ASSERT(v != 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  174|  3.76k|    IGRAPH_ASSERT(v->stor_begin != 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  175|       |
  176|  3.76k|    igraph_i_vector_ptr_call_item_destructor_all(v);
  177|   750k|    for (ptr = v->stor_begin; ptr < v->end; ptr++) {
  ------------------
  |  Branch (177:31): [True: 746k, False: 3.76k]
  ------------------
  178|   746k|        IGRAPH_FREE(*ptr);
  ------------------
  |  |   41|   746k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  179|   746k|    }
  180|  3.76k|}
igraph_vector_ptr_destroy_all:
  200|  3.76k|void igraph_vector_ptr_destroy_all(igraph_vector_ptr_t* v) {
  201|  3.76k|    IGRAPH_ASSERT(v != 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  202|  3.76k|    IGRAPH_ASSERT(v->stor_begin != 0);
  ------------------
  |  |  916|  3.76k|    do { \
  |  |  917|  3.76k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  203|  3.76k|    igraph_vector_ptr_free_all(v);
  204|  3.76k|    igraph_vector_ptr_set_item_destructor(v, 0);
  205|  3.76k|    igraph_vector_ptr_destroy(v);
  206|  3.76k|}
igraph_vector_ptr_set_item_destructor:
  670|  7.53k|    igraph_vector_ptr_t *v, igraph_finally_func_t *func) {
  671|  7.53k|    igraph_finally_func_t* result = v->item_destructor;
  672|       |
  673|  7.53k|    v->item_destructor = func;
  674|       |
  675|  7.53k|    return result;
  676|  7.53k|}
vector_ptr.c:igraph_i_vector_ptr_call_item_destructor_all:
  141|  3.76k|static void igraph_i_vector_ptr_call_item_destructor_all(igraph_vector_ptr_t* v) {
  142|  3.76k|    void **ptr;
  143|       |
  144|  3.76k|    if (v->item_destructor != 0) {
  ------------------
  |  Branch (144:9): [True: 3.76k, False: 0]
  ------------------
  145|   750k|        for (ptr = v->stor_begin; ptr < v->end; ptr++) {
  ------------------
  |  Branch (145:35): [True: 746k, False: 3.76k]
  ------------------
  146|   746k|            if (*ptr != 0) {
  ------------------
  |  Branch (146:17): [True: 0, False: 746k]
  ------------------
  147|      0|                v->item_destructor(*ptr);
  148|      0|            }
  149|   746k|        }
  150|  3.76k|    }
  151|  3.76k|}

igraph_adjlist_init:
  158|  22.5k|                        igraph_multiple_t multiple) {
  159|  22.5k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  160|  22.5k|    igraph_vector_int_t degrees;
  161|       |
  162|  22.5k|    if (mode != IGRAPH_IN && mode != IGRAPH_OUT && mode != IGRAPH_ALL) {
  ------------------
  |  Branch (162:9): [True: 18.7k, False: 3.71k]
  |  Branch (162:30): [True: 7.53k, False: 11.2k]
  |  Branch (162:52): [True: 0, False: 7.53k]
  ------------------
  163|      0|        IGRAPH_ERROR("Cannot create adjacency list view.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  164|      0|    }
  165|       |
  166|  22.5k|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (166:9): [True: 3.76k, False: 18.7k]
  ------------------
  167|  3.76k|        mode = IGRAPH_ALL;
  168|  3.76k|    }
  169|       |
  170|  22.5k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&degrees, no_of_nodes);
  ------------------
  |  |  124|  22.5k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  22.5k|    do { \
  |  |  |  |  649|  22.5k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  22.5k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  22.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 22.5k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  22.5k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  22.5k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  22.5k|    do { \
  |  |  |  |  592|  22.5k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  22.5k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  22.5k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  22.5k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  22.5k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  22.5k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  171|       |    /* igraph_degree() is fast when loops=true */
  172|  22.5k|    IGRAPH_CHECK(igraph_degree(graph, &degrees, igraph_vss_all(), mode, /* loops= */ true));
  ------------------
  |  |  648|  22.5k|    do { \
  |  |  649|  22.5k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  22.5k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  22.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 22.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  22.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  173|       |
  174|  22.5k|    al->length = no_of_nodes;
  175|  22.5k|    al->adjs = IGRAPH_CALLOC(al->length, igraph_vector_int_t);
  ------------------
  |  |   38|  22.5k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  45.0k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 22.5k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 22.5k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 22.4k, False: 11]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  176|  22.5k|    IGRAPH_CHECK_OOM(al->adjs, "Insufficient memory for creating adjacency list view.");
  ------------------
  |  |  701|  22.5k|    do { \
  |  |  702|  22.5k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  22.5k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 22.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  22.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  177|  22.5k|    IGRAPH_FINALLY(igraph_adjlist_destroy, al);
  ------------------
  |  |  591|  22.5k|    do { \
  |  |  592|  22.5k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  22.5k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  22.5k|         * incorrect destructor function with the pointer */ \
  |  |  595|  22.5k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  22.5k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  22.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  178|       |
  179|       |    /* if we already know there are no multi-edges, they don't need to be removed */
  180|  22.5k|    if (igraph_i_property_cache_has(graph, IGRAPH_PROP_HAS_MULTI) &&
  ------------------
  |  Branch (180:9): [True: 13.0k, False: 9.42k]
  ------------------
  181|  22.5k|        !igraph_i_property_cache_get_bool(graph, IGRAPH_PROP_HAS_MULTI)) {
  ------------------
  |  Branch (181:9): [True: 5.62k, False: 7.46k]
  ------------------
  182|  5.62k|        multiple = IGRAPH_MULTIPLE;
  183|  5.62k|    }
  184|       |
  185|       |    /* if we already know there are no loops, they don't need to be removed */
  186|  22.5k|    if (igraph_i_property_cache_has(graph, IGRAPH_PROP_HAS_LOOP) &&
  ------------------
  |  Branch (186:9): [True: 13.0k, False: 9.42k]
  ------------------
  187|  22.5k|        !igraph_i_property_cache_get_bool(graph, IGRAPH_PROP_HAS_LOOP)) {
  ------------------
  |  Branch (187:9): [True: 7.70k, False: 5.38k]
  ------------------
  188|  7.70k|        if (mode == IGRAPH_ALL) {
  ------------------
  |  Branch (188:13): [True: 1.10k, False: 6.59k]
  ------------------
  189|  1.10k|            loops = IGRAPH_LOOPS_TWICE;
  190|  6.59k|        } else {
  191|  6.59k|            loops = IGRAPH_LOOPS_ONCE;
  192|  6.59k|        }
  193|  7.70k|    }
  194|       |
  195|  22.5k|    igraph_bool_t has_loops = false;
  196|  22.5k|    igraph_bool_t has_multiple = false;
  197|  4.50M|    for (igraph_integer_t i = 0; i < al->length; i++) {
  ------------------
  |  Branch (197:34): [True: 4.48M, False: 22.5k]
  ------------------
  198|  4.48M|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|  4.48M|    do { \
  |  |   48|  4.48M|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 4.48M]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|  4.48M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  199|       |
  200|  4.48M|        IGRAPH_CHECK(igraph_vector_int_init(&al->adjs[i], VECTOR(degrees)[i]));
  ------------------
  |  |  648|  4.48M|    do { \
  |  |  649|  4.48M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  4.48M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  4.48M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.48M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  4.48M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  201|  4.48M|        IGRAPH_CHECK(igraph_neighbors(graph, &al->adjs[i], i, mode));
  ------------------
  |  |  648|  4.48M|    do { \
  |  |  649|  4.48M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  4.48M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  4.48M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.48M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  4.48M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  202|       |
  203|       |        /* Attention: This function will only set values for has_loops and has_multiple
  204|       |         * if it finds loops/multi-edges. Otherwise they are left at their original value. */
  205|  4.48M|        IGRAPH_CHECK(igraph_i_simplify_sorted_int_adjacency_vector_in_place(
  ------------------
  |  |  648|  4.48M|    do { \
  |  |  649|  4.48M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  4.48M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  4.48M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.48M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  4.48M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  206|  4.48M|            &al->adjs[i], i, mode, loops, multiple, &has_loops, &has_multiple
  207|  4.48M|        ));
  208|  4.48M|    }
  209|  22.5k|    if (has_loops) {
  ------------------
  |  Branch (209:9): [True: 2.33k, False: 20.1k]
  ------------------
  210|       |        /* If we have found at least one loop above, set the cache to true */
  211|  2.33k|        igraph_i_property_cache_set_bool_checked(graph, IGRAPH_PROP_HAS_LOOP, true);
  212|  20.1k|    } else if (loops == IGRAPH_NO_LOOPS) {
  ------------------
  |  Branch (212:16): [True: 1.10k, False: 19.0k]
  ------------------
  213|       |        /* If we explicitly _checked_ for loops (to remove them) and haven't
  214|       |         * found one, set the cache to false. This is the only case when a
  215|       |         * definite "no" from has_loops really means that there are no loops at
  216|       |         * all */
  217|  1.10k|        igraph_i_property_cache_set_bool_checked(graph, IGRAPH_PROP_HAS_LOOP, false);
  218|  1.10k|    }
  219|  22.5k|    if (has_multiple) {
  ------------------
  |  Branch (219:9): [True: 2.15k, False: 20.3k]
  ------------------
  220|       |        /* If we have found at least one multiedge above, set the cache to true */
  221|  2.15k|        igraph_i_property_cache_set_bool_checked(graph, IGRAPH_PROP_HAS_MULTI, true);
  222|  20.3k|    } else if (multiple == IGRAPH_NO_MULTIPLE) {
  ------------------
  |  Branch (222:16): [True: 805, False: 19.5k]
  ------------------
  223|       |        /* If we explicitly _checked_ for multi-edges (to remove them) and
  224|       |         * haven't found one, set the cache to false. This is the only case
  225|       |         * when a definite "no" from has_multiple really means that there are
  226|       |         * no multi-edges at all all */
  227|    805|        igraph_i_property_cache_set_bool_checked(graph, IGRAPH_PROP_HAS_MULTI, false);
  228|    805|    }
  229|       |
  230|  22.5k|    igraph_vector_int_destroy(&degrees);
  231|  22.5k|    IGRAPH_FINALLY_CLEAN(2); /* + igraph_adjlist_destroy */
  232|       |
  233|  22.5k|    return IGRAPH_SUCCESS;
  234|  22.5k|}
igraph_adjlist_init_empty:
  250|  3.76k|igraph_error_t igraph_adjlist_init_empty(igraph_adjlist_t *al, igraph_integer_t no_of_nodes) {
  251|       |
  252|  3.76k|    al->length = no_of_nodes;
  253|  3.76k|    al->adjs = IGRAPH_CALLOC(al->length, igraph_vector_int_t);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 2]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  254|  3.76k|    IGRAPH_CHECK_OOM(al->adjs, "Insufficient memory for creating adjlist.");
  ------------------
  |  |  701|  3.76k|    do { \
  |  |  702|  3.76k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  255|  3.76k|    IGRAPH_FINALLY(igraph_adjlist_destroy, al);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  256|       |
  257|   724k|    for (igraph_integer_t i = 0; i < al->length; i++) {
  ------------------
  |  Branch (257:34): [True: 721k, False: 3.76k]
  ------------------
  258|   721k|        IGRAPH_CHECK(igraph_vector_int_init(&al->adjs[i], 0));
  ------------------
  |  |  648|   721k|    do { \
  |  |  649|   721k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   721k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   721k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 721k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   721k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  259|   721k|    }
  260|       |
  261|  3.76k|    IGRAPH_FINALLY_CLEAN(1);
  262|       |
  263|  3.76k|    return IGRAPH_SUCCESS;
  264|  3.76k|}
igraph_adjlist_destroy:
  429|  26.2k|void igraph_adjlist_destroy(igraph_adjlist_t *al) {
  430|  5.22M|    for (igraph_integer_t i = 0; i < al->length; i++) {
  ------------------
  |  Branch (430:34): [True: 5.20M, False: 26.2k]
  ------------------
  431|       |        /* This works if some igraph_vector_int_t's contain NULL,
  432|       |           because igraph_vector_int_destroy can handle this. */
  433|  5.20M|        igraph_vector_int_destroy(&al->adjs[i]);
  434|  5.20M|    }
  435|  26.2k|    IGRAPH_FREE(al->adjs);
  ------------------
  |  |   41|  26.2k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  436|  26.2k|}
igraph_inclist_init:
  770|  3.76k|                        igraph_loops_t loops) {
  771|  3.76k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  772|  3.76k|    igraph_vector_int_t degrees;
  773|       |
  774|  3.76k|    if (mode != IGRAPH_IN && mode != IGRAPH_OUT && mode != IGRAPH_ALL) {
  ------------------
  |  Branch (774:9): [True: 3.76k, False: 0]
  |  Branch (774:30): [True: 3.76k, False: 0]
  |  Branch (774:52): [True: 0, False: 3.76k]
  ------------------
  775|      0|        IGRAPH_ERROR("Cannot create incidence list view.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  776|      0|    }
  777|       |
  778|  3.76k|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (778:9): [True: 0, False: 3.76k]
  ------------------
  779|      0|        mode = IGRAPH_ALL;
  780|      0|    }
  781|       |
  782|  3.76k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&degrees, no_of_nodes);
  ------------------
  |  |  124|  3.76k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  3.76k|    do { \
  |  |  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  3.76k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  3.76k|    do { \
  |  |  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  783|       |    /* igraph_degrees() is fast when loops=true */
  784|  3.76k|    IGRAPH_CHECK(igraph_degree(graph, &degrees, igraph_vss_all(), mode, /* loops= */ 1));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  785|       |
  786|  3.76k|    il->length = no_of_nodes;
  787|  3.76k|    il->incs = IGRAPH_CALLOC(il->length, igraph_vector_int_t);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 2]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  788|  3.76k|    if (il->incs == 0) {
  ------------------
  |  Branch (788:9): [True: 0, False: 3.76k]
  ------------------
  789|      0|        IGRAPH_ERROR("Cannot create incidence list view.", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  790|      0|    }
  791|       |
  792|  3.76k|    IGRAPH_FINALLY(igraph_inclist_destroy, il);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  793|   750k|    for (igraph_integer_t i = 0; i < il->length; i++) {
  ------------------
  |  Branch (793:34): [True: 746k, False: 3.76k]
  ------------------
  794|   746k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|   746k|    do { \
  |  |   48|   746k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 746k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  795|       |
  796|   746k|        IGRAPH_CHECK(igraph_vector_int_init(&il->incs[i], VECTOR(degrees)[i]));
  ------------------
  |  |  648|   746k|    do { \
  |  |  649|   746k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   746k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   746k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 746k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  797|   746k|        IGRAPH_CHECK(igraph_incident(graph, &il->incs[i], i, mode));
  ------------------
  |  |  648|   746k|    do { \
  |  |  649|   746k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   746k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   746k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 746k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  798|       |
  799|   746k|        if (loops != IGRAPH_LOOPS_TWICE) {
  ------------------
  |  Branch (799:13): [True: 746k, False: 0]
  ------------------
  800|   746k|            IGRAPH_CHECK(
  ------------------
  |  |  648|   746k|    do { \
  |  |  649|   746k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   746k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   746k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 746k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  801|   746k|                igraph_i_remove_loops_from_incidence_vector_in_place(&il->incs[i], graph, loops)
  802|   746k|            );
  803|   746k|        }
  804|   746k|    }
  805|       |
  806|  3.76k|    igraph_vector_int_destroy(&degrees);
  807|  3.76k|    IGRAPH_FINALLY_CLEAN(2); /* + igraph_inclist_destroy */
  808|       |
  809|  3.76k|    return IGRAPH_SUCCESS;
  810|  3.76k|}
igraph_inclist_destroy:
  854|  3.76k|void igraph_inclist_destroy(igraph_inclist_t *il) {
  855|   750k|    for (igraph_integer_t i = 0; i < il->length; i++) {
  ------------------
  |  Branch (855:34): [True: 746k, False: 3.76k]
  ------------------
  856|       |        /* This works if some igraph_vector_int_t's contain NULL,
  857|       |           because igraph_vector_int_destroy can handle this. */
  858|   746k|        igraph_vector_int_destroy(&il->incs[i]);
  859|   746k|    }
  860|  3.76k|    IGRAPH_FREE(il->incs);
  ------------------
  |  |   41|  3.76k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  861|  3.76k|}
igraph_lazy_adjlist_init:
 1096|  1.86k|                             igraph_multiple_t multiple) {
 1097|  1.86k|    if (mode != IGRAPH_IN && mode != IGRAPH_OUT && mode != IGRAPH_ALL) {
  ------------------
  |  Branch (1097:9): [True: 1.86k, False: 0]
  |  Branch (1097:30): [True: 1.86k, False: 0]
  |  Branch (1097:52): [True: 0, False: 1.86k]
  ------------------
 1098|      0|        IGRAPH_ERROR("Cannot create lazy adjacency list view.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1099|      0|    }
 1100|       |
 1101|  1.86k|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (1101:9): [True: 0, False: 1.86k]
  ------------------
 1102|      0|        mode = IGRAPH_ALL;
 1103|      0|    }
 1104|       |
 1105|       |    /* if we already know there are no multi-edges, they don't need to be removed */
 1106|  1.86k|    if (igraph_i_property_cache_has(graph, IGRAPH_PROP_HAS_MULTI) &&
  ------------------
  |  Branch (1106:9): [True: 1.86k, False: 0]
  ------------------
 1107|  1.86k|        !igraph_i_property_cache_get_bool(graph, IGRAPH_PROP_HAS_MULTI)) {
  ------------------
  |  Branch (1107:9): [True: 802, False: 1.06k]
  ------------------
 1108|    802|        multiple = IGRAPH_MULTIPLE;
 1109|    802|    }
 1110|       |
 1111|       |    /* if we already know there are no loops, they don't need to be removed */
 1112|  1.86k|    if (igraph_i_property_cache_has(graph, IGRAPH_PROP_HAS_LOOP) &&
  ------------------
  |  Branch (1112:9): [True: 1.86k, False: 0]
  ------------------
 1113|  1.86k|        !igraph_i_property_cache_get_bool(graph, IGRAPH_PROP_HAS_LOOP)) {
  ------------------
  |  Branch (1113:9): [True: 1.10k, False: 759]
  ------------------
 1114|  1.10k|        if (mode == IGRAPH_ALL) {
  ------------------
  |  Branch (1114:13): [True: 1.10k, False: 0]
  ------------------
 1115|  1.10k|            loops = IGRAPH_LOOPS_TWICE;
 1116|  1.10k|        } else {
 1117|      0|            loops = IGRAPH_LOOPS_ONCE;
 1118|      0|        }
 1119|  1.10k|    }
 1120|       |
 1121|  1.86k|    al->mode = mode;
 1122|  1.86k|    al->loops = loops;
 1123|  1.86k|    al->multiple = multiple;
 1124|  1.86k|    al->graph = graph;
 1125|       |
 1126|  1.86k|    al->length = igraph_vcount(graph);
 1127|  1.86k|    al->adjs = IGRAPH_CALLOC(al->length, igraph_vector_int_t*);
  ------------------
  |  |   38|  1.86k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  3.72k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 1.86k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 1.86k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 1.86k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1128|  1.86k|    IGRAPH_CHECK_OOM(al->adjs, "Insufficient memory for creating lazy adjacency list view.");
  ------------------
  |  |  701|  1.86k|    do { \
  |  |  702|  1.86k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  1.86k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1129|       |
 1130|  1.86k|    return IGRAPH_SUCCESS;
 1131|  1.86k|}
igraph_lazy_adjlist_destroy:
 1143|  1.86k|void igraph_lazy_adjlist_destroy(igraph_lazy_adjlist_t *al) {
 1144|  1.86k|    igraph_lazy_adjlist_clear(al);
 1145|  1.86k|    IGRAPH_FREE(al->adjs);
  ------------------
  |  |   41|  1.86k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1146|  1.86k|}
igraph_lazy_adjlist_clear:
 1156|  1.86k|void igraph_lazy_adjlist_clear(igraph_lazy_adjlist_t *al) {
 1157|  1.86k|    igraph_integer_t i, n = al->length;
 1158|   375k|    for (i = 0; i < n; i++) {
  ------------------
  |  Branch (1158:17): [True: 373k, False: 1.86k]
  ------------------
 1159|   373k|        if (al->adjs[i] != 0) {
  ------------------
  |  Branch (1159:13): [True: 19.1k, False: 354k]
  ------------------
 1160|  19.1k|            igraph_vector_int_destroy(al->adjs[i]);
 1161|  19.1k|            IGRAPH_FREE(al->adjs[i]);
  ------------------
  |  |   41|  19.1k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1162|  19.1k|        }
 1163|   373k|    }
 1164|  1.86k|}
igraph_i_lazy_adjlist_get_real:
 1179|  19.1k|igraph_vector_int_t *igraph_i_lazy_adjlist_get_real(igraph_lazy_adjlist_t *al, igraph_integer_t no) {
 1180|  19.1k|    igraph_error_t ret;
 1181|       |
 1182|  19.1k|    if (al->adjs[no] == NULL) {
  ------------------
  |  Branch (1182:9): [True: 19.1k, False: 0]
  ------------------
 1183|  19.1k|        al->adjs[no] = IGRAPH_CALLOC(1, igraph_vector_int_t);
  ------------------
  |  |   38|  19.1k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  38.2k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1184|  19.1k|        if (al->adjs[no] == NULL) {
  ------------------
  |  Branch (1184:13): [True: 0, False: 19.1k]
  ------------------
 1185|      0|            return NULL;
 1186|      0|        }
 1187|       |
 1188|  19.1k|        ret = igraph_vector_int_init(al->adjs[no], 0);
 1189|  19.1k|        if (ret != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (1189:13): [True: 0, False: 19.1k]
  ------------------
 1190|      0|            IGRAPH_FREE(al->adjs[no]);
  ------------------
  |  |   41|      0|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1191|      0|            return NULL;
 1192|      0|        }
 1193|       |
 1194|  19.1k|        ret = igraph_neighbors(al->graph, al->adjs[no], no, al->mode);
 1195|  19.1k|        if (ret != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (1195:13): [True: 0, False: 19.1k]
  ------------------
 1196|      0|            igraph_vector_int_destroy(al->adjs[no]);
 1197|      0|            IGRAPH_FREE(al->adjs[no]);
  ------------------
  |  |   41|      0|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1198|      0|            return NULL;
 1199|      0|        }
 1200|       |
 1201|  19.1k|        ret = igraph_i_simplify_sorted_int_adjacency_vector_in_place(
 1202|  19.1k|            al->adjs[no], no, al->mode, al->loops, al->multiple, NULL,
 1203|  19.1k|            NULL
 1204|  19.1k|        );
 1205|  19.1k|        if (ret != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (1205:13): [True: 0, False: 19.1k]
  ------------------
 1206|      0|            igraph_vector_int_destroy(al->adjs[no]);
 1207|      0|            IGRAPH_FREE(al->adjs[no]);
  ------------------
  |  |   41|      0|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1208|      0|            return NULL;
 1209|      0|        }
 1210|  19.1k|    }
 1211|       |
 1212|  19.1k|    return al->adjs[no];
 1213|  19.1k|}
igraph_lazy_inclist_init:
 1258|  3.76k|                             igraph_loops_t loops) {
 1259|       |
 1260|  3.76k|    if (mode != IGRAPH_IN && mode != IGRAPH_OUT && mode != IGRAPH_ALL) {
  ------------------
  |  Branch (1260:9): [True: 3.76k, False: 0]
  |  Branch (1260:30): [True: 3.76k, False: 0]
  |  Branch (1260:52): [True: 0, False: 3.76k]
  ------------------
 1261|      0|        IGRAPH_ERROR("Cannot create lazy incidence list view", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1262|      0|    }
 1263|       |
 1264|  3.76k|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (1264:9): [True: 1.88k, False: 1.88k]
  ------------------
 1265|  1.88k|        mode = IGRAPH_ALL;
 1266|  1.88k|    }
 1267|       |
 1268|  3.76k|    il->graph = graph;
 1269|  3.76k|    il->loops = loops;
 1270|  3.76k|    il->mode = mode;
 1271|       |
 1272|  3.76k|    il->length = igraph_vcount(graph);
 1273|  3.76k|    il->incs = IGRAPH_CALLOC(il->length, igraph_vector_int_t*);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1274|  3.76k|    if (il->incs == 0) {
  ------------------
  |  Branch (1274:9): [True: 0, False: 3.76k]
  ------------------
 1275|      0|        IGRAPH_ERROR("Cannot create lazy incidence list view", IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1276|      0|    }
 1277|       |
 1278|  3.76k|    return IGRAPH_SUCCESS;
 1279|       |
 1280|  3.76k|}
igraph_lazy_inclist_destroy:
 1292|  3.76k|void igraph_lazy_inclist_destroy(igraph_lazy_inclist_t *il) {
 1293|  3.76k|    igraph_lazy_inclist_clear(il);
 1294|  3.76k|    IGRAPH_FREE(il->incs);
  ------------------
  |  |   41|  3.76k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1295|  3.76k|}
igraph_lazy_inclist_clear:
 1306|  3.76k|void igraph_lazy_inclist_clear(igraph_lazy_inclist_t *il) {
 1307|  3.76k|    igraph_integer_t i, n = il->length;
 1308|   750k|    for (i = 0; i < n; i++) {
  ------------------
  |  Branch (1308:17): [True: 746k, False: 3.76k]
  ------------------
 1309|   746k|        if (il->incs[i] != 0) {
  ------------------
  |  Branch (1309:13): [True: 24.1k, False: 722k]
  ------------------
 1310|  24.1k|            igraph_vector_int_destroy(il->incs[i]);
 1311|  24.1k|            IGRAPH_FREE(il->incs[i]);
  ------------------
  |  |   41|  24.1k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1312|  24.1k|        }
 1313|   746k|    }
 1314|  3.76k|}
igraph_i_lazy_inclist_get_real:
 1329|  24.1k|igraph_vector_int_t *igraph_i_lazy_inclist_get_real(igraph_lazy_inclist_t *il, igraph_integer_t no) {
 1330|  24.1k|    igraph_error_t ret;
 1331|       |
 1332|  24.1k|    if (il->incs[no] == NULL) {
  ------------------
  |  Branch (1332:9): [True: 24.1k, False: 0]
  ------------------
 1333|  24.1k|        il->incs[no] = IGRAPH_CALLOC(1, igraph_vector_int_t);
  ------------------
  |  |   38|  24.1k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  48.3k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
 1334|  24.1k|        if (il->incs[no] == NULL) {
  ------------------
  |  Branch (1334:13): [True: 0, False: 24.1k]
  ------------------
 1335|      0|            return NULL;
 1336|      0|        }
 1337|       |
 1338|  24.1k|        ret = igraph_vector_int_init(il->incs[no], 0);
 1339|  24.1k|        if (ret != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (1339:13): [True: 0, False: 24.1k]
  ------------------
 1340|      0|            IGRAPH_FREE(il->incs[no]);
  ------------------
  |  |   41|      0|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1341|      0|            return NULL;
 1342|      0|        }
 1343|       |
 1344|  24.1k|        ret = igraph_incident(il->graph, il->incs[no], no, il->mode);
 1345|  24.1k|        if (ret != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (1345:13): [True: 0, False: 24.1k]
  ------------------
 1346|      0|            igraph_vector_int_destroy(il->incs[no]);
 1347|      0|            IGRAPH_FREE(il->incs[no]);
  ------------------
  |  |   41|      0|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1348|      0|            return NULL;
 1349|      0|        }
 1350|       |
 1351|  24.1k|        if (il->loops != IGRAPH_LOOPS_TWICE) {
  ------------------
  |  Branch (1351:13): [True: 0, False: 24.1k]
  ------------------
 1352|      0|            ret = igraph_i_remove_loops_from_incidence_vector_in_place(il->incs[no], il->graph, il->loops);
 1353|      0|            if (ret != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (1353:17): [True: 0, False: 0]
  ------------------
 1354|      0|                igraph_vector_int_destroy(il->incs[no]);
 1355|      0|                IGRAPH_FREE(il->incs[no]);
  ------------------
  |  |   41|      0|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
 1356|      0|                return NULL;
 1357|      0|            }
 1358|      0|        }
 1359|  24.1k|    }
 1360|       |
 1361|  24.1k|    return il->incs[no];
 1362|  24.1k|}
adjlist.c:igraph_i_remove_loops_from_incidence_vector_in_place:
  636|   746k|) {
  637|   746k|    igraph_integer_t i, length, eid, write_ptr;
  638|   746k|    igraph_vector_int_t *seen_loops = 0;
  639|       |
  640|       |    /* In this function we make use of the fact that we are dealing with
  641|       |     * _incidence_ lists, and the only way for an edge ID to appear twice
  642|       |     * within an incidence list is if the edge is a loop edge; otherwise each
  643|       |     * element will be unique.
  644|       |     *
  645|       |     * Note that incidence vectors are not sorted by edge ID, so we need to
  646|       |     * look up the edges in the graph to decide whether they are loops or not.
  647|       |     *
  648|       |     * Also, it may be tempting to introduce a boolean in case of IGRAPH_LOOPS_ONCE,
  649|       |     * and flip it every time we see a loop to get rid of half of the occurrences,
  650|       |     * but the problem is that even if the same loop edge ID appears twice in
  651|       |     * the input list, they are not guaranteed to be next to each other; it
  652|       |     * may be the case that there are multiple loop edges, each edge appears
  653|       |     * twice, and we want to keep exactly one of them for each ID. That's why
  654|       |     * we have a "seen_loops" vector.
  655|       |     */
  656|       |
  657|   746k|    if (loops == IGRAPH_LOOPS_TWICE) {
  ------------------
  |  Branch (657:9): [True: 0, False: 746k]
  ------------------
  658|       |        /* Loop edges appear twice by default, nothing to do. */
  659|      0|        return IGRAPH_SUCCESS;
  660|      0|    }
  661|       |
  662|   746k|    length = igraph_vector_int_size(v);
  663|   746k|    if (length == 0) {
  ------------------
  |  Branch (663:9): [True: 669k, False: 77.1k]
  ------------------
  664|   669k|        return IGRAPH_SUCCESS;
  665|   669k|    }
  666|       |
  667|  77.1k|    if (loops == IGRAPH_LOOPS_ONCE) {
  ------------------
  |  Branch (667:9): [True: 77.1k, False: 0]
  ------------------
  668|       |        /* We need a helper vector */
  669|  77.1k|        seen_loops = IGRAPH_CALLOC(1, igraph_vector_int_t);
  ------------------
  |  |   38|  77.1k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|   154k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  670|  77.1k|        IGRAPH_FINALLY(igraph_free, seen_loops);
  ------------------
  |  |  591|  77.1k|    do { \
  |  |  592|  77.1k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  77.1k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  77.1k|         * incorrect destructor function with the pointer */ \
  |  |  595|  77.1k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  77.1k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  77.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  671|  77.1k|        IGRAPH_CHECK(igraph_vector_int_init(seen_loops, 0));
  ------------------
  |  |  648|  77.1k|    do { \
  |  |  649|  77.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  77.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  77.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 77.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  77.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  672|  77.1k|        IGRAPH_FINALLY(igraph_vector_int_destroy, seen_loops);
  ------------------
  |  |  591|  77.1k|    do { \
  |  |  592|  77.1k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  77.1k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  77.1k|         * incorrect destructor function with the pointer */ \
  |  |  595|  77.1k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  77.1k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  77.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  673|  77.1k|    } else if (loops != IGRAPH_NO_LOOPS) {
  ------------------
  |  Branch (673:16): [True: 0, False: 0]
  ------------------
  674|      0|        IGRAPH_ERROR("Invalid value for 'loops' argument", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  675|      0|    }
  676|       |
  677|   347k|    for (i = 0, write_ptr = 0; i < length; i++) {
  ------------------
  |  Branch (677:32): [True: 270k, False: 77.1k]
  ------------------
  678|   270k|        eid = VECTOR(*v)[i];
  ------------------
  |  |   65|   270k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  679|   270k|        if (IGRAPH_FROM(graph, eid) == IGRAPH_TO(graph, eid)) {
  ------------------
  |  |  113|   270k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|   270k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
                      if (IGRAPH_FROM(graph, eid) == IGRAPH_TO(graph, eid)) {
  ------------------
  |  |  126|   270k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|   270k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  |  Branch (679:13): [True: 40.1k, False: 230k]
  ------------------
  680|       |            /* Loop edge */
  681|  40.1k|            if (seen_loops && !igraph_vector_int_contains(seen_loops, eid)) {
  ------------------
  |  Branch (681:17): [True: 40.1k, False: 0]
  |  Branch (681:31): [True: 20.0k, False: 20.0k]
  ------------------
  682|  20.0k|                VECTOR(*v)[write_ptr++] = eid;
  ------------------
  |  |   65|  20.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  683|  20.0k|                IGRAPH_CHECK(igraph_vector_int_push_back(seen_loops, eid));
  ------------------
  |  |  648|  20.0k|    do { \
  |  |  649|  20.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  20.0k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  20.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 20.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  20.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  684|  20.0k|            }
  685|   230k|        } else {
  686|       |            /* Not a loop edge */
  687|   230k|            VECTOR(*v)[write_ptr++] = eid;
  ------------------
  |  |   65|   230k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  688|   230k|        }
  689|   270k|    }
  690|       |
  691|       |    /* Always succeeds since we never grow the vector */
  692|  77.1k|    igraph_vector_int_resize(v, write_ptr);
  693|       |
  694|       |    /* Destroy the helper vector */
  695|  77.1k|    if (seen_loops) {
  ------------------
  |  Branch (695:9): [True: 77.1k, False: 0]
  ------------------
  696|  77.1k|        igraph_vector_int_destroy(seen_loops);
  697|  77.1k|        IGRAPH_FREE(seen_loops);
  ------------------
  |  |   41|  77.1k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  698|  77.1k|        IGRAPH_FINALLY_CLEAN(2);
  699|  77.1k|    }
  700|       |
  701|  77.1k|    return IGRAPH_SUCCESS;
  702|  77.1k|}
adjlist.c:igraph_i_simplify_sorted_int_adjacency_vector_in_place:
  900|  4.49M|) {
  901|  4.49M|    igraph_bool_t dummy1 = true, dummy2 = true; /* set dummies to avoid uninitialized read */
  902|  4.49M|    if (has_loops == NULL) {
  ------------------
  |  Branch (902:9): [True: 19.1k, False: 4.48M]
  ------------------
  903|  19.1k|        has_loops = &dummy1;
  904|  19.1k|    }
  905|  4.49M|    if (has_multiple == NULL) {
  ------------------
  |  Branch (905:9): [True: 19.1k, False: 4.48M]
  ------------------
  906|  19.1k|        has_multiple = &dummy2;
  907|  19.1k|    }
  908|  4.49M|    igraph_integer_t i, p = 0;
  909|  4.49M|    igraph_integer_t n = igraph_vector_int_size(v);
  910|       |
  911|  4.49M|    if (
  912|  4.49M|        multiple == IGRAPH_MULTIPLE &&
  ------------------
  |  Branch (912:9): [True: 3.89M, False: 601k]
  ------------------
  913|  4.49M|        (
  914|  3.89M|            loops == IGRAPH_LOOPS_TWICE ||
  ------------------
  |  Branch (914:13): [True: 877k, False: 3.02M]
  ------------------
  915|  3.89M|            (loops == IGRAPH_LOOPS_ONCE && (mode == IGRAPH_IN || mode == IGRAPH_OUT))
  ------------------
  |  Branch (915:14): [True: 2.98M, False: 33.8k]
  |  Branch (915:45): [True: 746k, False: 2.24M]
  |  Branch (915:66): [True: 1.86M, False: 373k]
  ------------------
  916|  3.89M|        )
  917|  4.49M|    ) {
  918|       |        /* nothing to simplify */
  919|  3.49M|        return IGRAPH_SUCCESS;
  920|  3.49M|    }
  921|       |
  922|  1.00M|    if (loops == IGRAPH_NO_LOOPS) {
  ------------------
  |  Branch (922:9): [True: 536k, False: 472k]
  ------------------
  923|   536k|        if (multiple == IGRAPH_NO_MULTIPLE) {
  ------------------
  |  Branch (923:13): [True: 502k, False: 33.8k]
  ------------------
  924|       |            /* We need to get rid of loops and multiple edges completely */
  925|   760k|            for (i = 0; i < n; i++) {
  ------------------
  |  Branch (925:25): [True: 257k, False: 502k]
  ------------------
  926|   257k|                if (VECTOR(*v)[i] != index &&
  ------------------
  |  |   65|   257k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (926:21): [True: 206k, False: 51.1k]
  ------------------
  927|   257k|                    (i == n - 1 || VECTOR(*v)[i + 1] != VECTOR(*v)[i])) {
  ------------------
  |  |   65|   146k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  (i == n - 1 || VECTOR(*v)[i + 1] != VECTOR(*v)[i])) {
  ------------------
  |  |   65|   146k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (927:22): [True: 60.4k, False: 146k]
  |  Branch (927:36): [True: 82.2k, False: 63.9k]
  ------------------
  928|   142k|                    VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|   142k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|   142k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  929|   142k|                    p++;
  930|   142k|                } else {
  931|   115k|                    if (VECTOR(*v)[i] == index) {
  ------------------
  |  |   65|   115k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (931:25): [True: 51.1k, False: 63.9k]
  ------------------
  932|  51.1k|                        *has_loops = true;
  933|       |                        /* If we haven't found multi-edges yet, we also need to check
  934|       |                         * if this is a multi-loop, to set 'has_multiple' correctly. */
  935|  51.1k|                        if (! *has_multiple) {
  ------------------
  |  Branch (935:29): [True: 2.94k, False: 48.2k]
  ------------------
  936|  2.94k|                            if (mode == IGRAPH_ALL) {
  ------------------
  |  Branch (936:33): [True: 2.94k, False: 0]
  ------------------
  937|       |                                /* Undirected loops appear twice in the neighbour list,
  938|       |                                 * so we check two following items instead of one. */
  939|  2.94k|                                if (i < n - 2 &&
  ------------------
  |  Branch (939:37): [True: 1.55k, False: 1.38k]
  ------------------
  940|  2.94k|                                    VECTOR(*v)[i + 1] == VECTOR(*v)[i] &&
  ------------------
  |  |   65|  1.55k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                                  VECTOR(*v)[i + 1] == VECTOR(*v)[i] &&
  ------------------
  |  |   65|  1.55k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (940:37): [True: 1.21k, False: 340]
  ------------------
  941|  2.94k|                                    VECTOR(*v)[i + 2] == VECTOR(*v)[i]) {
  ------------------
  |  |   65|  1.21k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                                  VECTOR(*v)[i + 2] == VECTOR(*v)[i]) {
  ------------------
  |  |   65|  1.21k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (941:37): [True: 498, False: 719]
  ------------------
  942|    498|                                    *has_multiple = true;
  943|    498|                                }
  944|  2.94k|                            } else {
  945|      0|                                if (i != n - 1 && VECTOR(*v)[i + 1] == VECTOR(*v)[i]) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                              if (i != n - 1 && VECTOR(*v)[i + 1] == VECTOR(*v)[i]) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (945:37): [True: 0, False: 0]
  |  Branch (945:51): [True: 0, False: 0]
  ------------------
  946|      0|                                    *has_multiple = true;
  947|      0|                                }
  948|      0|                            }
  949|  2.94k|                        }
  950|  63.9k|                    } else if (i != n - 1 && VECTOR(*v)[i + 1] == VECTOR(*v)[i]) {
  ------------------
  |  |   65|  63.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  } else if (i != n - 1 && VECTOR(*v)[i + 1] == VECTOR(*v)[i]) {
  ------------------
  |  |   65|  63.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (950:32): [True: 63.9k, False: 0]
  |  Branch (950:46): [True: 63.9k, False: 0]
  ------------------
  951|  63.9k|                        *has_multiple = true;
  952|  63.9k|                    }
  953|   115k|                }
  954|   257k|            }
  955|   502k|        } else {
  956|       |            /* We need to get rid of loops but keep multiple edges */
  957|  45.0k|            for (i = 0; i < n; i++) {
  ------------------
  |  Branch (957:25): [True: 11.2k, False: 33.8k]
  ------------------
  958|  11.2k|                if (VECTOR(*v)[i] != index) {
  ------------------
  |  |   65|  11.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (958:21): [True: 9.65k, False: 1.56k]
  ------------------
  959|  9.65k|                    VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|  9.65k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|  9.65k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  960|  9.65k|                    p++;
  961|  9.65k|                } else {
  962|  1.56k|                    *has_loops = true;
  963|  1.56k|                }
  964|  11.2k|            }
  965|  33.8k|        }
  966|   536k|    } else if (loops == IGRAPH_LOOPS_ONCE) {
  ------------------
  |  Branch (966:16): [True: 373k, False: 98.7k]
  ------------------
  967|   373k|        if (multiple == IGRAPH_NO_MULTIPLE) {
  ------------------
  |  Branch (967:13): [True: 0, False: 373k]
  ------------------
  968|       |            /* We need to get rid of multiple edges completely (including
  969|       |             * multiple loop edges), but keep one edge from each loop edge */
  970|      0|            for (i = 0; i < n; i++) {
  ------------------
  |  Branch (970:25): [True: 0, False: 0]
  ------------------
  971|      0|                if (i == n - 1 || VECTOR(*v)[i + 1] != VECTOR(*v)[i]) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              if (i == n - 1 || VECTOR(*v)[i + 1] != VECTOR(*v)[i]) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (971:21): [True: 0, False: 0]
  |  Branch (971:35): [True: 0, False: 0]
  ------------------
  972|      0|                    VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  973|      0|                    p++;
  974|      0|                } else if (
  975|       |                        /* If this is not a loop then we have a multigraph.
  976|       |                           Else we have at least two loops.
  977|       |                           The v vector comes from a call to igraph_neighbors.
  978|       |                           This will count loops twice if mode == IGRAPH_ALL.
  979|       |                           So if mode != IGRAPH_ALL,
  980|       |                           then we have a multigraph.
  981|       |                           If mode == IGRAPH_ALL and we have three loops
  982|       |                           then we also have a multigraph
  983|       |                           */
  984|      0|                        (VECTOR(*v)[i] != index) ||
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (984:25): [True: 0, False: 0]
  ------------------
  985|      0|                       (mode != IGRAPH_ALL)  ||
  ------------------
  |  Branch (985:24): [True: 0, False: 0]
  ------------------
  986|      0|                       (mode == IGRAPH_ALL && i < n - 2 && VECTOR(*v)[i + 2] == VECTOR(*v)[i])
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                     (mode == IGRAPH_ALL && i < n - 2 && VECTOR(*v)[i + 2] == VECTOR(*v)[i])
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (986:25): [True: 0, False: 0]
  |  Branch (986:47): [True: 0, False: 0]
  |  Branch (986:60): [True: 0, False: 0]
  ------------------
  987|      0|                       ){
  988|      0|                    *has_multiple = true;
  989|      0|                }
  990|      0|            }
  991|   373k|        } else {
  992|       |            /* We need to keep one edge from each loop edge and we don't need to
  993|       |             * touch multiple edges. Note that we can get here only if
  994|       |             * mode == IGRAPH_ALL; if mode was IGRAPH_IN or IGRAPH_OUT, we would
  995|       |             * have bailed out earlier */
  996|   459k|            for (i = 0; i < n; i++) {
  ------------------
  |  Branch (996:25): [True: 86.0k, False: 373k]
  ------------------
  997|  86.0k|                VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|  86.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|  86.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  998|  86.0k|                if (VECTOR(*v)[i] == index) {
  ------------------
  |  |   65|  86.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (998:21): [True: 1.91k, False: 84.1k]
  ------------------
  999|  1.91k|                    *has_loops = true;
 1000|       |                    /* this was a loop edge so if the next element is the same, we
 1001|       |                    * need to skip that */
 1002|  1.91k|                    if (i < n-1 && VECTOR(*v)[i + 1] == index) {
  ------------------
  |  |   65|  1.91k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1002:25): [True: 1.91k, False: 0]
  |  Branch (1002:36): [True: 1.91k, False: 0]
  ------------------
 1003|  1.91k|                        i++;
 1004|  1.91k|                    }
 1005|  1.91k|                }
 1006|  86.0k|                p++;
 1007|  86.0k|            }
 1008|   373k|        }
 1009|   373k|    } else if (loops == IGRAPH_LOOPS_TWICE && multiple == IGRAPH_NO_MULTIPLE) {
  ------------------
  |  Branch (1009:16): [True: 98.7k, False: 0]
  |  Branch (1009:47): [True: 98.7k, False: 0]
  ------------------
 1010|       |        /* We need to get rid of multiple edges completely (including
 1011|       |         * multiple loop edges), but keep both edge from each loop edge */
 1012|   142k|        for (i = 0; i < n; i++) {
  ------------------
  |  Branch (1012:21): [True: 44.1k, False: 98.7k]
  ------------------
 1013|  44.1k|            if (i == n - 1 || VECTOR(*v)[i + 1] != VECTOR(*v)[i]) {
  ------------------
  |  |   65|  32.4k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          if (i == n - 1 || VECTOR(*v)[i + 1] != VECTOR(*v)[i]) {
  ------------------
  |  |   65|  32.4k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1013:17): [True: 11.6k, False: 32.4k]
  |  Branch (1013:31): [True: 15.3k, False: 17.1k]
  ------------------
 1014|  26.9k|                VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|  26.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|  26.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1015|  26.9k|                p++;
 1016|  26.9k|            } else {
 1017|  17.1k|                *has_multiple = true;
 1018|       |                /* Current item is the same as the next one, but if it is a
 1019|       |                 * loop edge, then the first one or two items are okay. We need
 1020|       |                 * to keep one if mode == IGRAPH_IN or mode == IGRAPH_OUT,
 1021|       |                 * otherwise we need to keep two */
 1022|  17.1k|                if (VECTOR(*v)[i] == index) {
  ------------------
  |  |   65|  17.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1022:21): [True: 0, False: 17.1k]
  ------------------
 1023|      0|                    VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1024|      0|                    p++;
 1025|      0|                    if (mode == IGRAPH_ALL) {
  ------------------
  |  Branch (1025:25): [True: 0, False: 0]
  ------------------
 1026|      0|                        VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                      VECTOR(*v)[p] = VECTOR(*v)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1027|      0|                        p++;
 1028|      0|                    }
 1029|       |                    /* skip over all the items corresponding to the loop edges */
 1030|      0|                    while (i < n && VECTOR(*v)[i] == index) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1030:28): [True: 0, False: 0]
  |  Branch (1030:37): [True: 0, False: 0]
  ------------------
 1031|      0|                        i++;
 1032|      0|                    }
 1033|      0|                    i--; /* because the for loop also increases i by 1 */
 1034|      0|                }
 1035|  17.1k|            }
 1036|  44.1k|        }
 1037|  98.7k|    } else {
 1038|       |        /* TODO; we don't use this combination yet */
 1039|      0|        return IGRAPH_UNIMPLEMENTED;
 1040|      0|    }
 1041|       |
 1042|       |    /* always succeeds since we are never growing the vector */
 1043|  1.00M|    igraph_vector_int_resize(v, p);
 1044|       |
 1045|  1.00M|    return IGRAPH_SUCCESS;
 1046|  1.00M|}

igraph_i_attribute_init:
  617|  9.12k|) {
  618|  9.12k|    graph->attr = NULL;
  619|  9.12k|    if (igraph_i_attribute_table) {
  ------------------
  |  Branch (619:9): [True: 0, False: 9.12k]
  ------------------
  620|      0|        IGRAPH_CHECK(igraph_i_attribute_table->init(graph, attr));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  621|      0|        if (graph->attr == NULL) {
  ------------------
  |  Branch (621:13): [True: 0, False: 0]
  ------------------
  622|      0|            IGRAPH_ERROR("Attribute handler did not initialize attr pointer", IGRAPH_FAILURE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  623|      0|        }
  624|      0|    }
  625|  9.12k|    return IGRAPH_SUCCESS;
  626|  9.12k|}
igraph_i_attribute_destroy:
  628|  23.1k|void igraph_i_attribute_destroy(igraph_t *graph) {
  629|  23.1k|    if (graph->attr && igraph_i_attribute_table) {
  ------------------
  |  Branch (629:9): [True: 0, False: 23.1k]
  |  Branch (629:24): [True: 0, False: 0]
  ------------------
  630|      0|        igraph_i_attribute_table->destroy(graph);
  631|      0|    }
  632|  23.1k|    graph->attr = NULL;
  633|  23.1k|}
igraph_i_attribute_copy:
  636|  9.70k|                            igraph_bool_t va, igraph_bool_t ea) {
  637|  9.70k|    igraph_i_attribute_destroy(to);
  638|  9.70k|    if (from->attr && igraph_i_attribute_table) {
  ------------------
  |  Branch (638:9): [True: 0, False: 9.70k]
  |  Branch (638:23): [True: 0, False: 0]
  ------------------
  639|      0|        IGRAPH_CHECK(igraph_i_attribute_table->copy(to, from, ga, va, ea));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  640|      0|        if (to->attr == NULL) {
  ------------------
  |  Branch (640:13): [True: 0, False: 0]
  ------------------
  641|      0|            IGRAPH_ERROR("Attribute handler did not initialize attr pointer", IGRAPH_FAILURE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  642|      0|        }
  643|      0|    }
  644|  9.70k|    return IGRAPH_SUCCESS;
  645|  9.70k|}
igraph_i_attribute_permute_vertices:
  659|  1.59k|                                        const igraph_vector_int_t *idx) {
  660|       |    /* graph and newgraph may be the same, in which case we need to support
  661|       |     * in-place operations. If they are _not_ the same, it is assumed that the
  662|       |     * new graph has no vertex attributes yet */
  663|  1.59k|    if (igraph_i_attribute_table) {
  ------------------
  |  Branch (663:9): [True: 0, False: 1.59k]
  ------------------
  664|      0|        return igraph_i_attribute_table->permute_vertices(graph, newgraph, idx);
  665|  1.59k|    } else {
  666|  1.59k|        return IGRAPH_SUCCESS;
  667|  1.59k|    }
  668|  1.59k|}
igraph_i_attribute_permute_edges:
  700|  1.59k|                                     const igraph_vector_int_t *idx) {
  701|       |    /* graph and newgraph may be the same, in which case we need to support
  702|       |     * in-place operations. If they are _not_ the same, it is assumed that the
  703|       |     * new graph has no edge attributes yet */
  704|  1.59k|    if (igraph_i_attribute_table) {
  ------------------
  |  Branch (704:9): [True: 0, False: 1.59k]
  ------------------
  705|      0|        return igraph_i_attribute_table->permute_edges(graph, newgraph, idx);
  706|  1.59k|    } else {
  707|  1.59k|        return IGRAPH_SUCCESS;
  708|  1.59k|    }
  709|  1.59k|}

igraph_i_property_cache_init:
   30|  11.3k|igraph_error_t igraph_i_property_cache_init(igraph_i_property_cache_t *cache) {
   31|  11.3k|    IGRAPH_STATIC_ASSERT(IGRAPH_PROP_I_SIZE <= 32);
  ------------------
  |  |   69|  11.3k|#define IGRAPH_STATIC_ASSERT(condition) ((void)sizeof(char[1 - 2*!(condition)]))
  ------------------
   32|       |
   33|  11.3k|    memset(cache->value, 0, sizeof(cache->value));
   34|  11.3k|    cache->known = 0;
   35|  11.3k|    return IGRAPH_SUCCESS;
   36|  11.3k|}
igraph_i_property_cache_copy:
   43|  2.17k|        const igraph_i_property_cache_t *other_cache) {
   44|  2.17k|    *cache = *other_cache;
   45|  2.17k|    return IGRAPH_SUCCESS;
   46|  2.17k|}
igraph_i_property_cache_destroy:
   51|  13.4k|void igraph_i_property_cache_destroy(igraph_i_property_cache_t *cache) {
   52|  13.4k|    IGRAPH_UNUSED(cache);
  ------------------
  |  |   32|  13.4k|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
   53|       |    /* Nothing to do */
   54|  13.4k|}
igraph_i_property_cache_get_bool:
   70|  39.3k|igraph_bool_t igraph_i_property_cache_get_bool(const igraph_t *graph, igraph_cached_property_t prop) {
   71|  39.3k|    IGRAPH_ASSERT(prop >= 0 && prop < IGRAPH_PROP_I_SIZE);
  ------------------
  |  |  916|  39.3k|    do { \
  |  |  917|  39.3k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  78.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 39.3k]
  |  |  |  |  |  Branch (604:50): [True: 39.3k, False: 0]
  |  |  |  |  |  Branch (604:50): [True: 39.3k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  39.3k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   72|  39.3k|    assert(graph->cache != NULL);
   73|  39.3k|    return graph->cache->value[prop];
   74|  39.3k|}
igraph_i_property_cache_has:
   82|  54.3k|igraph_bool_t igraph_i_property_cache_has(const igraph_t *graph, igraph_cached_property_t prop) {
   83|  54.3k|    IGRAPH_ASSERT(prop >= 0 && prop < IGRAPH_PROP_I_SIZE);
  ------------------
  |  |  916|  54.3k|    do { \
  |  |  917|  54.3k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|   108k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 54.3k]
  |  |  |  |  |  Branch (604:50): [True: 54.3k, False: 0]
  |  |  |  |  |  Branch (604:50): [True: 54.3k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  54.3k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   84|  54.3k|    assert(graph->cache != NULL);
   85|  54.3k|    return graph->cache->known & (1 << prop);
   86|  54.3k|}
igraph_i_property_cache_set_bool:
   95|  8.31k|void igraph_i_property_cache_set_bool(const igraph_t *graph, igraph_cached_property_t prop, igraph_bool_t value) {
   96|  8.31k|    IGRAPH_ASSERT(prop >= 0 && prop < IGRAPH_PROP_I_SIZE);
  ------------------
  |  |  916|  8.31k|    do { \
  |  |  917|  8.31k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  16.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.31k]
  |  |  |  |  |  Branch (604:50): [True: 8.31k, False: 0]
  |  |  |  |  |  Branch (604:50): [True: 8.31k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  8.31k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   97|  8.31k|    assert(graph->cache != NULL);
   98|       |    /* Even though graph is const, updating the cache is not considered modification.
   99|       |     * Functions that merely compute graph properties, and thus leave the graph structure
  100|       |     * intact, will often update the cache. */
  101|  8.31k|    graph->cache->value[prop] = value;
  102|  8.31k|    graph->cache->known |= (1 << prop);
  103|  8.31k|}
igraph_i_property_cache_set_bool_checked:
  121|  12.0k|void igraph_i_property_cache_set_bool_checked(const igraph_t *graph, igraph_cached_property_t prop, igraph_bool_t value) {
  122|  12.0k|    IGRAPH_ASSERT(prop >= 0 && prop < IGRAPH_PROP_I_SIZE);
  ------------------
  |  |  916|  12.0k|    do { \
  |  |  917|  12.0k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  24.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 12.0k]
  |  |  |  |  |  Branch (604:50): [True: 12.0k, False: 0]
  |  |  |  |  |  Branch (604:50): [True: 12.0k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  12.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  123|  12.0k|    assert(graph->cache != NULL);
  124|       |    /* Even though graph is const, updating the cache is not considered modification.
  125|       |     * Functions that merely compute graph properties, and thus leave the graph structure
  126|       |     * intact, will often update the cache. */
  127|  12.0k|    if (graph->cache->known & (1 << prop)) {
  ------------------
  |  Branch (127:9): [True: 3.74k, False: 8.31k]
  ------------------
  128|  3.74k|        IGRAPH_ASSERT(graph->cache->value[prop] == value);
  ------------------
  |  |  916|  3.74k|    do { \
  |  |  917|  3.74k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  3.74k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.74k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  3.74k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  129|  8.31k|    } else {
  130|  8.31k|        igraph_i_property_cache_set_bool(graph, prop, value);
  131|  8.31k|    }
  132|  12.0k|}
igraph_i_property_cache_invalidate_conditionally:
  180|  23.0k|) {
  181|  23.0k|    uint32_t invalidate = ~keep_always;
  182|  23.0k|    uint32_t mask;
  183|  23.0k|    uint32_t maybe_keep;
  184|  23.0k|    igraph_bool_t cached_value;
  185|       |
  186|  23.0k|    assert(graph->cache != NULL);
  187|       |
  188|       |    /* The bits of maybe_keep are set to 1 for those properties that are:
  189|       |     *
  190|       |     * - currently cached
  191|       |     * - should _probably_ be invalidated
  192|       |     * - _but_ the current cached value of the property may change the decision
  193|       |     */
  194|  23.0k|    maybe_keep = graph->cache->known & invalidate & (keep_when_false | keep_when_true);
  195|       |
  196|  23.0k|    if (maybe_keep) {
  ------------------
  |  Branch (196:9): [True: 1.88k, False: 21.1k]
  ------------------
  197|  15.0k|        for (igraph_cached_property_t prop = (igraph_cached_property_t ) 0; prop < IGRAPH_PROP_I_SIZE; ++prop) {
  ------------------
  |  Branch (197:77): [True: 13.1k, False: 1.88k]
  ------------------
  198|  13.1k|            mask = 1 << prop;
  199|  13.1k|            if (maybe_keep & mask) {
  ------------------
  |  Branch (199:17): [True: 7.53k, False: 5.64k]
  ------------------
  200|       |                /* if we get here, we know that the property is cached; we have
  201|       |                 * masked maybe_keep with graph->cache->known */
  202|  7.53k|                cached_value = igraph_i_property_cache_get_bool(graph, prop);
  203|  7.53k|                if (
  204|  7.53k|                    ((keep_when_false & mask) && !cached_value) ||
  ------------------
  |  Branch (204:22): [True: 7.53k, False: 0]
  |  Branch (204:50): [True: 5.56k, False: 1.97k]
  ------------------
  205|  7.53k|                    ((keep_when_true & mask) && cached_value)
  ------------------
  |  Branch (205:22): [True: 0, False: 1.97k]
  |  Branch (205:49): [True: 0, False: 0]
  ------------------
  206|  7.53k|                ) {
  207|  5.56k|                    invalidate &= ~mask;
  208|  5.56k|                }
  209|  7.53k|            }
  210|  13.1k|        }
  211|  1.88k|    }
  212|       |
  213|  23.0k|    graph->cache->known &= ~invalidate;
  214|  23.0k|}

igraph_vss_all:
  116|  30.0k|igraph_vs_t igraph_vss_all(void) {
  117|  30.0k|    igraph_vs_t allvs;
  118|  30.0k|    allvs.type = IGRAPH_VS_ALL;
  119|  30.0k|    return allvs;
  120|  30.0k|}
igraph_vss_1:
  276|  1.86k|igraph_vs_t igraph_vss_1(igraph_integer_t vid) {
  277|  1.86k|    igraph_vs_t onevs;
  278|  1.86k|    onevs.type = IGRAPH_VS_1;
  279|  1.86k|    onevs.data.vid = vid;
  280|  1.86k|    return onevs;
  281|  1.86k|}
igraph_vss_vector:
  328|  4.05k|igraph_vs_t igraph_vss_vector(const igraph_vector_int_t *v) {
  329|  4.05k|    igraph_vs_t vecvs;
  330|  4.05k|    vecvs.type = IGRAPH_VS_VECTORPTR;
  331|  4.05k|    vecvs.data.vecptr = v;
  332|  4.05k|    return vecvs;
  333|  4.05k|}
igraph_vs_is_all:
  528|  3.74k|igraph_bool_t igraph_vs_is_all(const igraph_vs_t *vs) {
  529|  3.74k|    return vs->type == IGRAPH_VS_ALL;
  530|  3.74k|}
igraph_vs_size:
  592|  1.88k|                   igraph_integer_t *result) {
  593|  1.88k|    igraph_vector_int_t vec;
  594|  1.88k|    igraph_bool_t *seen;
  595|  1.88k|    igraph_integer_t i;
  596|  1.88k|    igraph_integer_t vec_len;
  597|       |
  598|  1.88k|    switch (vs->type) {
  ------------------
  |  Branch (598:13): [True: 0, False: 1.88k]
  ------------------
  599|      0|    case IGRAPH_VS_NONE:
  ------------------
  |  Branch (599:5): [True: 0, False: 1.88k]
  ------------------
  600|      0|        *result = 0; return IGRAPH_SUCCESS;
  601|       |
  602|      0|    case IGRAPH_VS_1:
  ------------------
  |  Branch (602:5): [True: 0, False: 1.88k]
  ------------------
  603|      0|        *result = 0;
  604|      0|        if (vs->data.vid < igraph_vcount(graph) && vs->data.vid >= 0) {
  ------------------
  |  Branch (604:13): [True: 0, False: 0]
  |  Branch (604:52): [True: 0, False: 0]
  ------------------
  605|      0|            *result = 1;
  606|      0|        }
  607|      0|        return IGRAPH_SUCCESS;
  608|       |
  609|      0|    case IGRAPH_VS_RANGE:
  ------------------
  |  Branch (609:5): [True: 0, False: 1.88k]
  ------------------
  610|      0|        *result = vs->data.range.end - vs->data.range.start;
  611|      0|        return IGRAPH_SUCCESS;
  612|       |
  613|      0|    case IGRAPH_VS_ALL:
  ------------------
  |  Branch (613:5): [True: 0, False: 1.88k]
  ------------------
  614|      0|        *result = igraph_vcount(graph); return IGRAPH_SUCCESS;
  615|       |
  616|      0|    case IGRAPH_VS_ADJ:
  ------------------
  |  Branch (616:5): [True: 0, False: 1.88k]
  ------------------
  617|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&vec, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  618|      0|        IGRAPH_CHECK(igraph_neighbors(graph, &vec, vs->data.adj.vid, vs->data.adj.mode));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  619|      0|        *result = igraph_vector_int_size(&vec);
  620|      0|        igraph_vector_int_destroy(&vec);
  621|      0|        IGRAPH_FINALLY_CLEAN(1);
  622|      0|        return IGRAPH_SUCCESS;
  623|       |
  624|      0|    case IGRAPH_VS_NONADJ:
  ------------------
  |  Branch (624:5): [True: 0, False: 1.88k]
  ------------------
  625|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&vec, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  626|      0|        IGRAPH_CHECK(igraph_neighbors(graph, &vec, vs->data.adj.vid, vs->data.adj.mode));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  627|      0|        vec_len = igraph_vector_int_size(&vec);
  628|      0|        *result = igraph_vcount(graph);
  629|      0|        seen = IGRAPH_CALLOC(*result, igraph_bool_t);
  ------------------
  |  |   38|      0|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|      0|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 0, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 0, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  630|      0|        IGRAPH_CHECK_OOM(seen, "Cannot calculate vertex selector length.");
  ------------------
  |  |  701|      0|    do { \
  |  |  702|      0|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  631|      0|        IGRAPH_FINALLY(igraph_free, seen);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  632|      0|        for (i = 0; i < vec_len; i++) {
  ------------------
  |  Branch (632:21): [True: 0, False: 0]
  ------------------
  633|      0|            if (!seen[ VECTOR(vec)[i] ]) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (633:17): [True: 0, False: 0]
  ------------------
  634|      0|                (*result)--;
  635|      0|                seen[ VECTOR(vec)[i] ] = true;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  636|      0|            }
  637|      0|        }
  638|      0|        igraph_free(seen);
  639|      0|        igraph_vector_int_destroy(&vec);
  640|      0|        IGRAPH_FINALLY_CLEAN(2);
  641|      0|        return IGRAPH_SUCCESS;
  642|       |
  643|      0|    case IGRAPH_VS_VECTOR:
  ------------------
  |  Branch (643:5): [True: 0, False: 1.88k]
  ------------------
  644|  1.88k|    case IGRAPH_VS_VECTORPTR:
  ------------------
  |  Branch (644:5): [True: 1.88k, False: 0]
  ------------------
  645|  1.88k|        *result = igraph_vector_int_size(vs->data.vecptr);
  646|  1.88k|        return IGRAPH_SUCCESS;
  647|  1.88k|    }
  648|       |
  649|      0|    IGRAPH_ERROR("Cannot calculate selector length, invalid selector type",
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  650|      0|                 IGRAPH_EINVAL);
  651|      0|}
igraph_vit_create:
  687|  35.9k|igraph_error_t igraph_vit_create(const igraph_t *graph, igraph_vs_t vs, igraph_vit_t *vit) {
  688|  35.9k|    igraph_vector_int_t vec;
  689|  35.9k|    igraph_vector_int_t *vec_int;
  690|  35.9k|    igraph_bool_t *seen;
  691|  35.9k|    igraph_integer_t i, j, n;
  692|  35.9k|    igraph_integer_t vec_len;
  693|       |
  694|  35.9k|    switch (vs.type) {
  695|  30.0k|    case IGRAPH_VS_ALL:
  ------------------
  |  Branch (695:5): [True: 30.0k, False: 5.91k]
  ------------------
  696|  30.0k|        vit->type = IGRAPH_VIT_RANGE;
  697|  30.0k|        vit->pos = 0;
  698|  30.0k|        vit->start = 0;
  699|  30.0k|        vit->end = igraph_vcount(graph);
  700|  30.0k|        break;
  701|      0|    case IGRAPH_VS_ADJ:
  ------------------
  |  Branch (701:5): [True: 0, False: 35.9k]
  ------------------
  702|      0|        vec_int = IGRAPH_CALLOC(1, igraph_vector_int_t);
  ------------------
  |  |   38|      0|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|      0|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  703|      0|        IGRAPH_CHECK_OOM(vec_int, "Cannot create vertex iterator.");
  ------------------
  |  |  701|      0|    do { \
  |  |  702|      0|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  704|      0|        IGRAPH_FINALLY(igraph_free, vec_int);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  705|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(vec_int, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  706|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&vec, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  707|      0|        IGRAPH_CHECK(igraph_neighbors(graph, &vec, vs.data.adj.vid, vs.data.adj.mode));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  708|      0|        n = igraph_vector_int_size(&vec);
  709|      0|        IGRAPH_CHECK(igraph_vector_int_resize(vec_int, n));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  710|      0|        for (i = 0; i < n; i++) {
  ------------------
  |  Branch (710:21): [True: 0, False: 0]
  ------------------
  711|      0|            VECTOR(*vec_int)[i] = VECTOR(vec)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*vec_int)[i] = VECTOR(vec)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  712|      0|        }
  713|       |
  714|      0|        igraph_vector_int_destroy(&vec);
  715|      0|        IGRAPH_FINALLY_CLEAN(3);
  716|       |
  717|      0|        vit->type = IGRAPH_VIT_VECTOR;
  718|      0|        vit->pos = 0;
  719|      0|        vit->start = 0;
  720|      0|        vit->vec = vec_int;
  721|      0|        vit->end = n;
  722|       |
  723|      0|        break;
  724|      0|    case IGRAPH_VS_NONADJ:
  ------------------
  |  Branch (724:5): [True: 0, False: 35.9k]
  ------------------
  725|      0|        vec_int = IGRAPH_CALLOC(1, igraph_vector_int_t);
  ------------------
  |  |   38|      0|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|      0|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  726|      0|        IGRAPH_CHECK_OOM(vec_int, "Cannot create vertex iterator.");
  ------------------
  |  |  701|      0|    do { \
  |  |  702|      0|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  727|      0|        IGRAPH_FINALLY(igraph_free, vec_int);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  728|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(vec_int, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  729|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&vec, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  730|      0|        IGRAPH_CHECK(igraph_neighbors(graph, &vec, vs.data.adj.vid, vs.data.adj.mode));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  731|      0|        vec_len = igraph_vector_int_size(&vec);
  732|      0|        n = igraph_vcount(graph);
  733|      0|        seen = IGRAPH_CALLOC(n, igraph_bool_t);
  ------------------
  |  |   38|      0|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|      0|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 0, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 0, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  734|      0|        IGRAPH_CHECK_OOM(seen, "Cannot create vertex iterator.");
  ------------------
  |  |  701|      0|    do { \
  |  |  702|      0|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  735|      0|        IGRAPH_FINALLY(igraph_free, seen);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  736|      0|        for (i = 0; i < vec_len; i++) {
  ------------------
  |  Branch (736:21): [True: 0, False: 0]
  ------------------
  737|      0|            if (! seen [ VECTOR(vec)[i] ] ) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (737:17): [True: 0, False: 0]
  ------------------
  738|      0|                n--;
  739|      0|                seen[ VECTOR(vec)[i] ] = true;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  740|      0|            }
  741|      0|        }
  742|      0|        IGRAPH_CHECK(igraph_vector_int_resize(vec_int, n));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  743|      0|        for (i = 0, j = 0; j < n; i++) {
  ------------------
  |  Branch (743:28): [True: 0, False: 0]
  ------------------
  744|      0|            if (!seen[i]) {
  ------------------
  |  Branch (744:17): [True: 0, False: 0]
  ------------------
  745|      0|                VECTOR(*vec_int)[j++] = i;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  746|      0|            }
  747|      0|        }
  748|       |
  749|      0|        IGRAPH_FREE(seen);
  ------------------
  |  |   41|      0|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  750|      0|        igraph_vector_int_destroy(&vec);
  751|      0|        IGRAPH_FINALLY_CLEAN(4);
  752|       |
  753|      0|        vit->type = IGRAPH_VIT_VECTOR;
  754|      0|        vit->pos = 0;
  755|      0|        vit->start = 0;
  756|      0|        vit->vec = vec_int;
  757|      0|        vit->end = n;
  758|      0|        break;
  759|      0|    case IGRAPH_VS_NONE:
  ------------------
  |  Branch (759:5): [True: 0, False: 35.9k]
  ------------------
  760|      0|        vit->type = IGRAPH_VIT_RANGE;
  761|      0|        vit->pos = 0;
  762|      0|        vit->start = 0;
  763|      0|        vit->end = 0;
  764|      0|        break;
  765|  1.86k|    case IGRAPH_VS_1:
  ------------------
  |  Branch (765:5): [True: 1.86k, False: 34.0k]
  ------------------
  766|  1.86k|        vit->type = IGRAPH_VIT_RANGE;
  767|  1.86k|        vit->pos = vs.data.vid;
  768|  1.86k|        vit->start = vs.data.vid;
  769|  1.86k|        vit->end = vs.data.vid + 1;
  770|  1.86k|        if (vit->pos >= igraph_vcount(graph)) {
  ------------------
  |  Branch (770:13): [True: 0, False: 1.86k]
  ------------------
  771|      0|            IGRAPH_ERROR("Cannot create iterator, invalid vertex ID.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  772|      0|        }
  773|  1.86k|        break;
  774|  4.05k|    case IGRAPH_VS_VECTORPTR:
  ------------------
  |  Branch (774:5): [True: 4.05k, False: 31.9k]
  ------------------
  775|  4.05k|    case IGRAPH_VS_VECTOR:
  ------------------
  |  Branch (775:5): [True: 0, False: 35.9k]
  ------------------
  776|  4.05k|        vit->type = IGRAPH_VIT_VECTORPTR;
  777|  4.05k|        vit->pos = 0;
  778|  4.05k|        vit->start = 0;
  779|  4.05k|        vit->vec = vs.data.vecptr;
  780|  4.05k|        vit->end = igraph_vector_int_size(vit->vec);
  781|  4.05k|        if (!igraph_vector_int_isininterval(vit->vec, 0, igraph_vcount(graph) - 1)) {
  ------------------
  |  Branch (781:13): [True: 0, False: 4.05k]
  ------------------
  782|      0|            IGRAPH_ERROR("Cannot create iterator, invalid vertex ID.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  783|      0|        }
  784|  4.05k|        break;
  785|  4.05k|    case IGRAPH_VS_RANGE:
  ------------------
  |  Branch (785:5): [True: 0, False: 35.9k]
  ------------------
  786|      0|        {
  787|      0|            igraph_integer_t no_of_nodes = igraph_vcount(graph);
  788|      0|            if (vs.data.range.start < 0 ||
  ------------------
  |  Branch (788:17): [True: 0, False: 0]
  ------------------
  789|      0|                vs.data.range.start > no_of_nodes ||
  ------------------
  |  Branch (789:17): [True: 0, False: 0]
  ------------------
  790|      0|                (no_of_nodes > 0 && vs.data.range.start == no_of_nodes)) {
  ------------------
  |  Branch (790:18): [True: 0, False: 0]
  |  Branch (790:37): [True: 0, False: 0]
  ------------------
  791|      0|                IGRAPH_ERROR("Cannot create range iterator, starting vertex ID out of range.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  792|      0|            }
  793|      0|            if (vs.data.range.end < 0 || vs.data.range.end > no_of_nodes) {
  ------------------
  |  Branch (793:17): [True: 0, False: 0]
  |  Branch (793:42): [True: 0, False: 0]
  ------------------
  794|      0|                IGRAPH_ERROR("Cannot create range iterator, ending vertex ID out of range.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  795|      0|            }
  796|      0|        }
  797|      0|        vit->type = IGRAPH_VIT_RANGE;
  798|      0|        vit->pos = vs.data.range.start;
  799|      0|        vit->start = vs.data.range.start;
  800|      0|        vit->end = vs.data.range.end;
  801|      0|        break;
  802|      0|    default:
  ------------------
  |  Branch (802:5): [True: 0, False: 35.9k]
  ------------------
  803|      0|        IGRAPH_ERROR("Cannot create iterator, invalid selector.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  804|      0|        break;
  805|  35.9k|    }
  806|  35.9k|    return IGRAPH_SUCCESS;
  807|  35.9k|}
igraph_vit_destroy:
  822|  35.9k|void igraph_vit_destroy(const igraph_vit_t *vit) {
  823|  35.9k|    switch (vit->type) {
  824|  31.9k|    case IGRAPH_VIT_RANGE:
  ------------------
  |  Branch (824:5): [True: 31.9k, False: 4.05k]
  ------------------
  825|  35.9k|    case IGRAPH_VIT_VECTORPTR:
  ------------------
  |  Branch (825:5): [True: 4.05k, False: 31.9k]
  ------------------
  826|  35.9k|        break;
  827|      0|    case IGRAPH_VIT_VECTOR:
  ------------------
  |  Branch (827:5): [True: 0, False: 35.9k]
  ------------------
  828|      0|        igraph_vector_int_destroy((igraph_vector_int_t*) vit->vec);
  829|      0|        igraph_free((igraph_vector_int_t*) vit->vec);
  830|      0|        break;
  831|      0|    default:
  ------------------
  |  Branch (831:5): [True: 0, False: 35.9k]
  ------------------
  832|       |        /*     IGRAPH_ERROR("Cannot destroy iterator, unknown type", IGRAPH_EINVAL); */
  833|      0|        break;
  834|  35.9k|    }
  835|  35.9k|}
igraph_vit_as_vector:
  837|  1.59k|igraph_error_t igraph_vit_as_vector(const igraph_vit_t *vit, igraph_vector_int_t *v) {
  838|  1.59k|    igraph_integer_t i;
  839|       |
  840|  1.59k|    IGRAPH_CHECK(igraph_vector_int_resize(v, IGRAPH_VIT_SIZE(*vit)));
  ------------------
  |  |  648|  1.59k|    do { \
  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  841|       |
  842|  1.59k|    switch (vit->type) {
  843|      0|    case IGRAPH_VIT_RANGE:
  ------------------
  |  Branch (843:5): [True: 0, False: 1.59k]
  ------------------
  844|      0|        for (i = 0; i < IGRAPH_VIT_SIZE(*vit); i++) {
  ------------------
  |  |  191|      0|#define IGRAPH_VIT_SIZE(vit)  ((vit).end - (vit).start)
  ------------------
  |  Branch (844:21): [True: 0, False: 0]
  ------------------
  845|      0|            VECTOR(*v)[i] = vit->start + i;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  846|      0|        }
  847|      0|        break;
  848|      0|    case IGRAPH_VIT_VECTOR:
  ------------------
  |  Branch (848:5): [True: 0, False: 1.59k]
  ------------------
  849|  1.59k|    case IGRAPH_VIT_VECTORPTR:
  ------------------
  |  Branch (849:5): [True: 1.59k, False: 0]
  ------------------
  850|  33.8k|        for (i = 0; i < IGRAPH_VIT_SIZE(*vit); i++) {
  ------------------
  |  |  191|  33.8k|#define IGRAPH_VIT_SIZE(vit)  ((vit).end - (vit).start)
  ------------------
  |  Branch (850:21): [True: 32.2k, False: 1.59k]
  ------------------
  851|  32.2k|            VECTOR(*v)[i] = VECTOR(*vit->vec)[i];
  ------------------
  |  |   65|  32.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*v)[i] = VECTOR(*vit->vec)[i];
  ------------------
  |  |   65|  32.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  852|  32.2k|        }
  853|  1.59k|        break;
  854|      0|    default:
  ------------------
  |  Branch (854:5): [True: 0, False: 1.59k]
  ------------------
  855|      0|        IGRAPH_ERROR("Cannot convert to vector, unknown iterator type",
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  856|      0|                     IGRAPH_EINVAL);
  857|      0|        break;
  858|  1.59k|    }
  859|       |
  860|  1.59k|    return IGRAPH_SUCCESS;
  861|  1.59k|}
igraph_es_all:
  890|  3.76k|                  igraph_edgeorder_type_t order) {
  891|  3.76k|    switch (order) {
  892|  3.76k|    case IGRAPH_EDGEORDER_ID:
  ------------------
  |  Branch (892:5): [True: 3.76k, False: 0]
  ------------------
  893|  3.76k|        es->type = IGRAPH_ES_ALL;
  894|  3.76k|        break;
  895|      0|    case IGRAPH_EDGEORDER_FROM:
  ------------------
  |  Branch (895:5): [True: 0, False: 3.76k]
  ------------------
  896|      0|        es->type = IGRAPH_ES_ALLFROM;
  897|      0|        break;
  898|      0|    case IGRAPH_EDGEORDER_TO:
  ------------------
  |  Branch (898:5): [True: 0, False: 3.76k]
  ------------------
  899|      0|        es->type = IGRAPH_ES_ALLTO;
  900|      0|        break;
  901|      0|    default:
  ------------------
  |  Branch (901:5): [True: 0, False: 3.76k]
  ------------------
  902|      0|        IGRAPH_ERROR("Invalid edge order, cannot create selector.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  903|      0|        break;
  904|  3.76k|    }
  905|  3.76k|    return IGRAPH_SUCCESS;
  906|  3.76k|}
igraph_ess_all:
  922|  3.76k|igraph_es_t igraph_ess_all(igraph_edgeorder_type_t order) {
  923|  3.76k|    igraph_es_t es;
  924|  3.76k|    igraph_es_all(&es, order); /* cannot fail */
  925|  3.76k|    return es;
  926|  3.76k|}
igraph_ess_vector:
 1100|  5.64k|igraph_es_t igraph_ess_vector(const igraph_vector_int_t *v) {
 1101|  5.64k|    igraph_es_t es;
 1102|  5.64k|    es.type = IGRAPH_ES_VECTORPTR;
 1103|  5.64k|    es.data.vecptr = v;
 1104|  5.64k|    return es;
 1105|  5.64k|}
igraph_es_is_all:
 1406|  3.76k|igraph_bool_t igraph_es_is_all(const igraph_es_t *es) {
 1407|  3.76k|    return es->type == IGRAPH_ES_ALL;
 1408|  3.76k|}
igraph_eit_create:
 1872|  9.41k|igraph_error_t igraph_eit_create(const igraph_t *graph, igraph_es_t es, igraph_eit_t *eit) {
 1873|  9.41k|    switch (es.type) {
 1874|  3.76k|    case IGRAPH_ES_ALL:
  ------------------
  |  Branch (1874:5): [True: 3.76k, False: 5.64k]
  ------------------
 1875|  3.76k|        eit->type = IGRAPH_EIT_RANGE;
 1876|  3.76k|        eit->pos = 0;
 1877|  3.76k|        eit->start = 0;
 1878|  3.76k|        eit->end = igraph_ecount(graph);
 1879|  3.76k|        break;
 1880|      0|    case IGRAPH_ES_ALLFROM:
  ------------------
  |  Branch (1880:5): [True: 0, False: 9.41k]
  ------------------
 1881|      0|        IGRAPH_CHECK(igraph_i_eit_create_allfromto(graph, eit, IGRAPH_OUT));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1882|      0|        break;
 1883|      0|    case IGRAPH_ES_ALLTO:
  ------------------
  |  Branch (1883:5): [True: 0, False: 9.41k]
  ------------------
 1884|      0|        IGRAPH_CHECK(igraph_i_eit_create_allfromto(graph, eit, IGRAPH_IN));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1885|      0|        break;
 1886|      0|    case IGRAPH_ES_INCIDENT:
  ------------------
  |  Branch (1886:5): [True: 0, False: 9.41k]
  ------------------
 1887|      0|        IGRAPH_CHECK(igraph_i_eit_create_incident(graph, es, eit));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1888|      0|        break;
 1889|      0|    case IGRAPH_ES_NONE:
  ------------------
  |  Branch (1889:5): [True: 0, False: 9.41k]
  ------------------
 1890|      0|        eit->type = IGRAPH_EIT_RANGE;
 1891|      0|        eit->pos = 0;
 1892|      0|        eit->start = 0;
 1893|      0|        eit->end = 0;
 1894|      0|        break;
 1895|      0|    case IGRAPH_ES_1:
  ------------------
  |  Branch (1895:5): [True: 0, False: 9.41k]
  ------------------
 1896|      0|        eit->type = IGRAPH_EIT_RANGE;
 1897|      0|        eit->pos = es.data.eid;
 1898|      0|        eit->start = es.data.eid;
 1899|      0|        eit->end = es.data.eid + 1;
 1900|      0|        if (eit->pos >= igraph_ecount(graph)) {
  ------------------
  |  Branch (1900:13): [True: 0, False: 0]
  ------------------
 1901|      0|            IGRAPH_ERROR("Cannot create iterator.", IGRAPH_EINVEID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1902|      0|        }
 1903|      0|        break;
 1904|      0|    case IGRAPH_ES_VECTOR:
  ------------------
  |  Branch (1904:5): [True: 0, False: 9.41k]
  ------------------
 1905|  5.64k|    case IGRAPH_ES_VECTORPTR:
  ------------------
  |  Branch (1905:5): [True: 5.64k, False: 3.76k]
  ------------------
 1906|  5.64k|        eit->type = IGRAPH_EIT_VECTORPTR;
 1907|  5.64k|        eit->pos = 0;
 1908|  5.64k|        eit->start = 0;
 1909|  5.64k|        eit->vec = es.data.vecptr;
 1910|  5.64k|        eit->end = igraph_vector_int_size(eit->vec);
 1911|  5.64k|        if (!igraph_vector_int_isininterval(eit->vec, 0, igraph_ecount(graph) - 1)) {
  ------------------
  |  Branch (1911:13): [True: 0, False: 5.64k]
  ------------------
 1912|      0|            IGRAPH_ERROR("Cannot create iterator.", IGRAPH_EINVEID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1913|      0|        }
 1914|  5.64k|        break;
 1915|  5.64k|    case IGRAPH_ES_RANGE:
  ------------------
  |  Branch (1915:5): [True: 0, False: 9.41k]
  ------------------
 1916|      0|        {
 1917|      0|            igraph_integer_t no_of_edges = igraph_ecount(graph);
 1918|      0|            if (es.data.range.start < 0 ||
  ------------------
  |  Branch (1918:17): [True: 0, False: 0]
  ------------------
 1919|      0|                es.data.range.start > no_of_edges ||
  ------------------
  |  Branch (1919:17): [True: 0, False: 0]
  ------------------
 1920|      0|                (no_of_edges > 0 && es.data.range.start == no_of_edges)) {
  ------------------
  |  Branch (1920:18): [True: 0, False: 0]
  |  Branch (1920:37): [True: 0, False: 0]
  ------------------
 1921|      0|                IGRAPH_ERROR("Cannot create range iterator, starting edge ID out of range.", IGRAPH_EINVEID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1922|      0|            }
 1923|      0|            if (es.data.range.end < 0 || es.data.range.end > no_of_edges) {
  ------------------
  |  Branch (1923:17): [True: 0, False: 0]
  |  Branch (1923:42): [True: 0, False: 0]
  ------------------
 1924|      0|                IGRAPH_ERROR("Cannot create range iterator, ending edge ID out of range.", IGRAPH_EINVEID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1925|      0|            }
 1926|      0|        }
 1927|      0|        eit->type = IGRAPH_EIT_RANGE;
 1928|      0|        eit->pos = es.data.range.start;
 1929|      0|        eit->start = es.data.range.start;
 1930|      0|        eit->end = es.data.range.end;
 1931|      0|        break;
 1932|      0|    case IGRAPH_ES_PAIRS:
  ------------------
  |  Branch (1932:5): [True: 0, False: 9.41k]
  ------------------
 1933|      0|        IGRAPH_CHECK(igraph_i_eit_pairs(graph, es, eit));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1934|      0|        break;
 1935|      0|    case IGRAPH_ES_PATH:
  ------------------
  |  Branch (1935:5): [True: 0, False: 9.41k]
  ------------------
 1936|      0|        IGRAPH_CHECK(igraph_i_eit_path(graph, es, eit));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1937|      0|        break;
 1938|      0|    case IGRAPH_ES_ALL_BETWEEN:
  ------------------
  |  Branch (1938:5): [True: 0, False: 9.41k]
  ------------------
 1939|      0|        IGRAPH_CHECK(igraph_i_eit_all_between(graph, es, eit));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1940|      0|        break;
 1941|      0|    default:
  ------------------
  |  Branch (1941:5): [True: 0, False: 9.41k]
  ------------------
 1942|      0|        IGRAPH_ERROR("Cannot create iterator, invalid selector.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1943|      0|        break;
 1944|  9.41k|    }
 1945|  9.41k|    return IGRAPH_SUCCESS;
 1946|  9.41k|}
igraph_eit_destroy:
 1958|  9.41k|void igraph_eit_destroy(const igraph_eit_t *eit) {
 1959|  9.41k|    switch (eit->type) {
 1960|  3.76k|    case IGRAPH_EIT_RANGE:
  ------------------
  |  Branch (1960:5): [True: 3.76k, False: 5.64k]
  ------------------
 1961|  9.41k|    case IGRAPH_EIT_VECTORPTR:
  ------------------
  |  Branch (1961:5): [True: 5.64k, False: 3.76k]
  ------------------
 1962|  9.41k|        break;
 1963|      0|    case IGRAPH_EIT_VECTOR:
  ------------------
  |  Branch (1963:5): [True: 0, False: 9.41k]
  ------------------
 1964|      0|        igraph_vector_int_destroy((igraph_vector_int_t*)eit->vec);
 1965|      0|        igraph_free((igraph_vector_int_t*)eit->vec);
 1966|      0|        break;
 1967|      0|    default:
  ------------------
  |  Branch (1967:5): [True: 0, False: 9.41k]
  ------------------
 1968|       |        /*     IGRAPH_ERROR("Cannot destroy iterator, unknown type", IGRAPH_EINVAL); */
 1969|      0|        break;
 1970|  9.41k|    }
 1971|  9.41k|}

igraph_empty:
   65|  9.12k|igraph_error_t igraph_empty(igraph_t *graph, igraph_integer_t n, igraph_bool_t directed) {
   66|  9.12k|    return igraph_empty_attrs(graph, n, directed, 0);
   67|  9.12k|}
igraph_delete_vertices:
   92|  1.88k|igraph_error_t igraph_delete_vertices(igraph_t *graph, const igraph_vs_t vertices) {
   93|  1.88k|    return igraph_delete_vertices_map(graph, vertices, /* idx= */ 0, /* invidx= */ 0);
   94|  1.88k|}
igraph_edge:
  133|  67.5k|) {
  134|       |
  135|  67.5k|    if (eid < 0 || eid >= igraph_ecount(graph)) {
  ------------------
  |  Branch (135:9): [True: 0, False: 67.5k]
  |  Branch (135:20): [True: 0, False: 67.5k]
  ------------------
  136|      0|        IGRAPH_ERROR("Cannot retrieve edge endpoints.", IGRAPH_EINVEID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  137|      0|    }
  138|       |
  139|  67.5k|    if (igraph_is_directed(graph)) {
  ------------------
  |  Branch (139:9): [True: 67.5k, False: 0]
  ------------------
  140|  67.5k|        *from = IGRAPH_FROM(graph, eid);
  ------------------
  |  |  113|  67.5k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  141|  67.5k|        *to   = IGRAPH_TO(graph, eid);
  ------------------
  |  |  126|  67.5k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  142|  67.5k|    } else {
  143|      0|        *from = IGRAPH_TO(graph, eid);
  ------------------
  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  144|      0|        *to   = IGRAPH_FROM(graph, eid);
  ------------------
  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  145|      0|    }
  146|       |
  147|  67.5k|    return IGRAPH_SUCCESS;
  148|  67.5k|}

igraph_empty_attrs:
  101|  9.12k|) {
  102|       |
  103|  9.12k|    if (n < 0) {
  ------------------
  |  Branch (103:9): [True: 0, False: 9.12k]
  ------------------
  104|      0|        IGRAPH_ERROR("Number of vertices must not be negative.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  105|      0|    }
  106|       |
  107|  9.12k|    memset(graph, 0, sizeof(igraph_t));
  108|       |
  109|  9.12k|    graph->n = 0;
  110|  9.12k|    graph->directed = directed;
  111|  9.12k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&graph->from, 0);
  ------------------
  |  |  124|  9.12k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  9.12k|    do { \
  |  |  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  9.12k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  9.12k|    do { \
  |  |  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  112|  9.12k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&graph->to, 0);
  ------------------
  |  |  124|  9.12k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  9.12k|    do { \
  |  |  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  9.12k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  9.12k|    do { \
  |  |  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  113|  9.12k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&graph->oi, 0);
  ------------------
  |  |  124|  9.12k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  9.12k|    do { \
  |  |  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  9.12k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  9.12k|    do { \
  |  |  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  114|  9.12k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&graph->ii, 0);
  ------------------
  |  |  124|  9.12k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  9.12k|    do { \
  |  |  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  9.12k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  9.12k|    do { \
  |  |  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  115|  9.12k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&graph->os, 1);
  ------------------
  |  |  124|  9.12k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  9.12k|    do { \
  |  |  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  9.12k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  9.12k|    do { \
  |  |  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  116|  9.12k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&graph->is, 1);
  ------------------
  |  |  124|  9.12k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  9.12k|    do { \
  |  |  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  9.12k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  9.12k|    do { \
  |  |  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  9.12k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  117|       |
  118|       |    /* init cache */
  119|  9.12k|    graph->cache = IGRAPH_CALLOC(1, igraph_i_property_cache_t);
  ------------------
  |  |   38|  9.12k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  18.2k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  120|  9.12k|    IGRAPH_CHECK_OOM(graph->cache, "Cannot create graph.");
  ------------------
  |  |  701|  9.12k|    do { \
  |  |  702|  9.12k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  121|  9.12k|    IGRAPH_FINALLY(igraph_free, graph->cache);
  ------------------
  |  |  591|  9.12k|    do { \
  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  122|  9.12k|    IGRAPH_CHECK(igraph_i_property_cache_init(graph->cache));
  ------------------
  |  |  648|  9.12k|    do { \
  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  123|  9.12k|    IGRAPH_FINALLY(igraph_i_property_cache_destroy, graph->cache);
  ------------------
  |  |  591|  9.12k|    do { \
  |  |  592|  9.12k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  9.12k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  9.12k|         * incorrect destructor function with the pointer */ \
  |  |  595|  9.12k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  9.12k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  124|       |
  125|  9.12k|    VECTOR(graph->os)[0] = 0;
  ------------------
  |  |   65|  9.12k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  126|  9.12k|    VECTOR(graph->is)[0] = 0;
  ------------------
  |  |   65|  9.12k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  127|       |
  128|       |    /* init attributes */
  129|  9.12k|    IGRAPH_CHECK(igraph_i_attribute_init(graph, attr));
  ------------------
  |  |  648|  9.12k|    do { \
  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  130|       |
  131|       |    /* add the vertices */
  132|  9.12k|    IGRAPH_CHECK(igraph_add_vertices(graph, n, 0));
  ------------------
  |  |  648|  9.12k|    do { \
  |  |  649|  9.12k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  9.12k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  9.12k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 9.12k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  9.12k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  133|       |
  134|  9.12k|    IGRAPH_FINALLY_CLEAN(8);
  135|  9.12k|    return IGRAPH_SUCCESS;
  136|  9.12k|}
igraph_destroy:
  154|  13.4k|void igraph_destroy(igraph_t *graph) {
  155|  13.4k|    igraph_i_attribute_destroy(graph);
  156|       |
  157|  13.4k|    igraph_i_property_cache_destroy(graph->cache);
  158|  13.4k|    IGRAPH_FREE(graph->cache);
  ------------------
  |  |   41|  13.4k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  159|       |
  160|  13.4k|    igraph_vector_int_destroy(&graph->from);
  161|  13.4k|    igraph_vector_int_destroy(&graph->to);
  162|  13.4k|    igraph_vector_int_destroy(&graph->oi);
  163|  13.4k|    igraph_vector_int_destroy(&graph->ii);
  164|  13.4k|    igraph_vector_int_destroy(&graph->os);
  165|  13.4k|    igraph_vector_int_destroy(&graph->is);
  166|  13.4k|}
igraph_copy:
  194|  2.17k|igraph_error_t igraph_copy(igraph_t *to, const igraph_t *from) {
  195|  2.17k|    memset(to, 0, sizeof(igraph_t));
  196|       |
  197|  2.17k|    to->n = from->n;
  198|  2.17k|    to->directed = from->directed;
  199|  2.17k|    IGRAPH_CHECK(igraph_vector_int_init_copy(&to->from, &from->from));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  200|  2.17k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &to->from);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  201|  2.17k|    IGRAPH_CHECK(igraph_vector_int_init_copy(&to->to, &from->to));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  202|  2.17k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &to->to);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  203|  2.17k|    IGRAPH_CHECK(igraph_vector_int_init_copy(&to->oi, &from->oi));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  204|  2.17k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &to->oi);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  205|  2.17k|    IGRAPH_CHECK(igraph_vector_int_init_copy(&to->ii, &from->ii));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  206|  2.17k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &to->ii);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  207|  2.17k|    IGRAPH_CHECK(igraph_vector_int_init_copy(&to->os, &from->os));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  208|  2.17k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &to->os);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  209|  2.17k|    IGRAPH_CHECK(igraph_vector_int_init_copy(&to->is, &from->is));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  210|  2.17k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &to->is);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  211|       |
  212|  2.17k|    to->cache = IGRAPH_CALLOC(1, igraph_i_property_cache_t);
  ------------------
  |  |   38|  2.17k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  4.34k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  213|  2.17k|    IGRAPH_CHECK_OOM(to->cache, "Cannot copy graph.");
  ------------------
  |  |  701|  2.17k|    do { \
  |  |  702|  2.17k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  214|  2.17k|    IGRAPH_FINALLY(igraph_free, to->cache);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  215|  2.17k|    IGRAPH_CHECK(igraph_i_property_cache_copy(to->cache, from->cache));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  216|  2.17k|    IGRAPH_FINALLY(igraph_i_property_cache_destroy, to->cache);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  217|       |
  218|  2.17k|    IGRAPH_CHECK(igraph_i_attribute_copy(to, from, true, true, true));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  219|       |
  220|  2.17k|    IGRAPH_FINALLY_CLEAN(8);
  221|  2.17k|    return IGRAPH_SUCCESS;
  222|  2.17k|}
igraph_add_edges:
  256|  8.26k|) {
  257|  8.26k|    igraph_integer_t no_of_edges = igraph_vector_int_size(&graph->from);
  258|  8.26k|    igraph_integer_t edges_to_add = igraph_vector_int_size(edges) / 2;
  259|  8.26k|    igraph_integer_t new_no_of_edges;
  260|  8.26k|    igraph_integer_t i = 0;
  261|  8.26k|    igraph_vector_int_t newoi, newii;
  262|  8.26k|    igraph_bool_t directed = igraph_is_directed(graph);
  263|       |
  264|  8.26k|    if (igraph_vector_int_size(edges) % 2 != 0) {
  ------------------
  |  Branch (264:9): [True: 0, False: 8.26k]
  ------------------
  265|      0|        IGRAPH_ERROR("Invalid (odd) length of edges vector.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  266|      0|    }
  267|  8.26k|    if (!igraph_vector_int_isininterval(edges, 0, igraph_vcount(graph) - 1)) {
  ------------------
  |  Branch (267:9): [True: 0, False: 8.26k]
  ------------------
  268|      0|        IGRAPH_ERROR("Out-of-range vertex IDs when adding edges.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  269|      0|    }
  270|       |
  271|       |    /* from & to */
  272|  8.26k|    IGRAPH_SAFE_ADD(no_of_edges, edges_to_add, &new_no_of_edges);
  ------------------
  |  |   47|  8.26k|    do { \
  |  |   48|  8.26k|        igraph_integer_t _safe_a = (a), _safe_b = (b); \
  |  |   49|  8.26k|        igraph_integer_t _safe_sum; \
  |  |   50|  8.26k|        if (__builtin_add_overflow(_safe_a, _safe_b, &_safe_sum)) { \
  |  |  ------------------
  |  |  |  Branch (50:13): [True: 0, False: 8.26k]
  |  |  ------------------
  |  |   51|      0|            IGRAPH_ERRORF("Overflow when adding %" IGRAPH_PRId " and %" IGRAPH_PRId ".", IGRAPH_EOVERFLOW, _safe_a, _safe_b); \
  |  |  ------------------
  |  |  |  |  469|      0|    do { \
  |  |  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  |  |  472|      0|        return igraph_errno; \
  |  |  |  |  473|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   52|      0|        } \
  |  |   53|  8.26k|        *(res) = _safe_sum; \
  |  |   54|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (54:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  273|  8.26k|    if (new_no_of_edges > IGRAPH_ECOUNT_MAX) {
  ------------------
  |  |  121|  8.26k|#define IGRAPH_ECOUNT_MAX (IGRAPH_INTEGER_MAX/2)
  |  |  ------------------
  |  |  |  |   77|  8.26k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  |  |  ------------------
  ------------------
  |  Branch (273:9): [True: 0, False: 8.26k]
  ------------------
  274|      0|        IGRAPH_ERRORF("Maximum edge count (%" IGRAPH_PRId ") exceeded.", IGRAPH_ERANGE,
  ------------------
  |  |  469|      0|    do { \
  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  472|      0|        return igraph_errno; \
  |  |  473|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  275|      0|                      IGRAPH_ECOUNT_MAX);
  276|      0|    }
  277|  8.26k|    IGRAPH_CHECK(igraph_vector_int_reserve(&graph->from, no_of_edges + edges_to_add));
  ------------------
  |  |  648|  8.26k|    do { \
  |  |  649|  8.26k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  8.26k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  8.26k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.26k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  278|  8.26k|    IGRAPH_CHECK(igraph_vector_int_reserve(&graph->to, no_of_edges + edges_to_add));
  ------------------
  |  |  648|  8.26k|    do { \
  |  |  649|  8.26k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  8.26k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  8.26k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.26k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  279|       |
  280|  1.22M|    while (i < edges_to_add * 2) {
  ------------------
  |  Branch (280:12): [True: 1.22M, False: 8.26k]
  ------------------
  281|  1.22M|        if (directed || VECTOR(*edges)[i] > VECTOR(*edges)[i + 1]) {
  ------------------
  |  |   65|  43.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      if (directed || VECTOR(*edges)[i] > VECTOR(*edges)[i + 1]) {
  ------------------
  |  |   65|  43.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (281:13): [True: 1.17M, False: 43.9k]
  |  Branch (281:25): [True: 42.0k, False: 1.91k]
  ------------------
  282|  1.21M|            igraph_vector_int_push_back(&graph->from, VECTOR(*edges)[i++]); /* reserved */
  ------------------
  |  |   65|  1.21M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  283|  1.21M|            igraph_vector_int_push_back(&graph->to,   VECTOR(*edges)[i++]); /* reserved */
  ------------------
  |  |   65|  1.21M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  284|  1.21M|        } else {
  285|  1.91k|            igraph_vector_int_push_back(&graph->to,   VECTOR(*edges)[i++]); /* reserved */
  ------------------
  |  |   65|  1.91k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  286|  1.91k|            igraph_vector_int_push_back(&graph->from, VECTOR(*edges)[i++]); /* reserved */
  ------------------
  |  |   65|  1.91k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  287|  1.91k|        }
  288|  1.22M|    }
  289|       |
  290|       |    /* If an error occurs while the edges are being added, we make the necessary fixup
  291|       |     * to ensure that the graph is still in a consistent state when this function returns.
  292|       |     * The graph may already be on the finally stack when calling this function. We use
  293|       |     * a separate finally stack level to avoid its destructor from being called on error,
  294|       |     * so that the fixup can succeed.
  295|       |     */
  296|       |
  297|  8.26k|#define CHECK_ERR(expr) \
  298|  8.26k|    do { \
  299|  8.26k|        igraph_error_t err = (expr); \
  300|  8.26k|        if (err != IGRAPH_SUCCESS) { \
  301|  8.26k|            igraph_vector_int_resize(&graph->from, no_of_edges); /* gets smaller, error safe */ \
  302|  8.26k|            igraph_vector_int_resize(&graph->to, no_of_edges);   /* gets smaller, error safe */ \
  303|  8.26k|            IGRAPH_FINALLY_EXIT(); \
  304|  8.26k|            IGRAPH_ERROR("Cannot add edges.", err); \
  305|  8.26k|        } \
  306|  8.26k|    } while (0)
  307|       |
  308|       |    /* oi & ii */
  309|  8.26k|    IGRAPH_FINALLY_ENTER();
  310|  8.26k|    {
  311|  8.26k|        CHECK_ERR(igraph_vector_int_init(&newoi, no_of_edges));
  ------------------
  |  |  298|  8.26k|    do { \
  |  |  299|  8.26k|        igraph_error_t err = (expr); \
  |  |  300|  8.26k|        if (err != IGRAPH_SUCCESS) { \
  |  |  ------------------
  |  |  |  Branch (300:13): [True: 0, False: 8.26k]
  |  |  ------------------
  |  |  301|      0|            igraph_vector_int_resize(&graph->from, no_of_edges); /* gets smaller, error safe */ \
  |  |  302|      0|            igraph_vector_int_resize(&graph->to, no_of_edges);   /* gets smaller, error safe */ \
  |  |  303|      0|            IGRAPH_FINALLY_EXIT(); \
  |  |  304|      0|            IGRAPH_ERROR("Cannot add edges.", err); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  305|      0|        } \
  |  |  306|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (306:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  312|  8.26k|        IGRAPH_FINALLY(igraph_vector_int_destroy, &newoi);
  ------------------
  |  |  591|  8.26k|    do { \
  |  |  592|  8.26k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  8.26k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  8.26k|         * incorrect destructor function with the pointer */ \
  |  |  595|  8.26k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  8.26k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  313|  8.26k|        CHECK_ERR(igraph_vector_int_init(&newii, no_of_edges));
  ------------------
  |  |  298|  8.26k|    do { \
  |  |  299|  8.26k|        igraph_error_t err = (expr); \
  |  |  300|  8.26k|        if (err != IGRAPH_SUCCESS) { \
  |  |  ------------------
  |  |  |  Branch (300:13): [True: 0, False: 8.26k]
  |  |  ------------------
  |  |  301|      0|            igraph_vector_int_resize(&graph->from, no_of_edges); /* gets smaller, error safe */ \
  |  |  302|      0|            igraph_vector_int_resize(&graph->to, no_of_edges);   /* gets smaller, error safe */ \
  |  |  303|      0|            IGRAPH_FINALLY_EXIT(); \
  |  |  304|      0|            IGRAPH_ERROR("Cannot add edges.", err); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  305|      0|        } \
  |  |  306|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (306:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  314|  8.26k|        IGRAPH_FINALLY(igraph_vector_int_destroy, &newii);
  ------------------
  |  |  591|  8.26k|    do { \
  |  |  592|  8.26k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  8.26k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  8.26k|         * incorrect destructor function with the pointer */ \
  |  |  595|  8.26k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  8.26k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  315|  8.26k|        CHECK_ERR(igraph_vector_int_pair_order(&graph->from, &graph->to, &newoi, graph->n));
  ------------------
  |  |  298|  8.26k|    do { \
  |  |  299|  8.26k|        igraph_error_t err = (expr); \
  |  |  300|  8.26k|        if (err != IGRAPH_SUCCESS) { \
  |  |  ------------------
  |  |  |  Branch (300:13): [True: 0, False: 8.26k]
  |  |  ------------------
  |  |  301|      0|            igraph_vector_int_resize(&graph->from, no_of_edges); /* gets smaller, error safe */ \
  |  |  302|      0|            igraph_vector_int_resize(&graph->to, no_of_edges);   /* gets smaller, error safe */ \
  |  |  303|      0|            IGRAPH_FINALLY_EXIT(); \
  |  |  304|      0|            IGRAPH_ERROR("Cannot add edges.", err); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  305|      0|        } \
  |  |  306|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (306:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  316|  8.26k|        CHECK_ERR(igraph_vector_int_pair_order(&graph->to, &graph->from, &newii, graph->n));
  ------------------
  |  |  298|  8.26k|    do { \
  |  |  299|  8.26k|        igraph_error_t err = (expr); \
  |  |  300|  8.26k|        if (err != IGRAPH_SUCCESS) { \
  |  |  ------------------
  |  |  |  Branch (300:13): [True: 0, False: 8.26k]
  |  |  ------------------
  |  |  301|      0|            igraph_vector_int_resize(&graph->from, no_of_edges); /* gets smaller, error safe */ \
  |  |  302|      0|            igraph_vector_int_resize(&graph->to, no_of_edges);   /* gets smaller, error safe */ \
  |  |  303|      0|            IGRAPH_FINALLY_EXIT(); \
  |  |  304|      0|            IGRAPH_ERROR("Cannot add edges.", err); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  305|      0|        } \
  |  |  306|  8.26k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (306:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  317|       |
  318|       |        /* Attributes */
  319|  8.26k|        if (graph->attr) {
  ------------------
  |  Branch (319:13): [True: 0, False: 8.26k]
  ------------------
  320|       |            /* TODO: Does this keep the attribute table in a consistent state upon failure? */
  321|      0|            CHECK_ERR(igraph_i_attribute_add_edges(graph, edges, attr));
  ------------------
  |  |  298|      0|    do { \
  |  |  299|      0|        igraph_error_t err = (expr); \
  |  |  300|      0|        if (err != IGRAPH_SUCCESS) { \
  |  |  ------------------
  |  |  |  Branch (300:13): [True: 0, False: 0]
  |  |  ------------------
  |  |  301|      0|            igraph_vector_int_resize(&graph->from, no_of_edges); /* gets smaller, error safe */ \
  |  |  302|      0|            igraph_vector_int_resize(&graph->to, no_of_edges);   /* gets smaller, error safe */ \
  |  |  303|      0|            IGRAPH_FINALLY_EXIT(); \
  |  |  304|      0|            IGRAPH_ERROR("Cannot add edges.", err); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  305|      0|        } \
  |  |  306|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (306:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  322|      0|        }
  323|       |
  324|       |        /* os & is, its length does not change, error safe */
  325|  8.26k|        igraph_i_create_start_vectors(&graph->os, &graph->from, &newoi, graph->n);
  326|  8.26k|        igraph_i_create_start_vectors(&graph->is, &graph->to, &newii, graph->n);
  327|       |
  328|       |        /* everything went fine */
  329|  8.26k|        igraph_vector_int_destroy(&graph->oi);
  330|  8.26k|        igraph_vector_int_destroy(&graph->ii);
  331|  8.26k|        IGRAPH_FINALLY_CLEAN(2);
  332|       |
  333|  8.26k|        graph->oi = newoi;
  334|  8.26k|        graph->ii = newii;
  335|  8.26k|    }
  336|      0|    IGRAPH_FINALLY_EXIT();
  337|       |
  338|  8.26k|#undef CHECK_ERR
  339|       |
  340|       |    /* modification successful, clear the cached properties of the graph.
  341|       |     *
  342|       |     * Adding one or more edges cannot make a strongly or weakly connected
  343|       |     * graph disconnected, so we keep those flags if they are cached as true.
  344|       |     *
  345|       |     * Adding one or more edges may turn a DAG into a non-DAG or a forest into
  346|       |     * a non-forest, so we can keep those flags only if they are cached as
  347|       |     * false.
  348|       |     *
  349|       |     * Also, adding one or more edges does not change HAS_LOOP, HAS_MULTI and
  350|       |     * HAS_MUTUAL if they were already true.
  351|       |     */
  352|  8.26k|    igraph_i_property_cache_invalidate_conditionally(
  353|  8.26k|        graph,
  354|  8.26k|        /* keep_always = */ 0,
  355|       |        /* keep_when_false = */
  356|  8.26k|        (1 << IGRAPH_PROP_IS_DAG) | (1 << IGRAPH_PROP_IS_FOREST),
  357|       |        /* keep_when_true = */
  358|  8.26k|        (1 << IGRAPH_PROP_IS_WEAKLY_CONNECTED) |
  359|  8.26k|        (1 << IGRAPH_PROP_IS_STRONGLY_CONNECTED) |
  360|  8.26k|        (1 << IGRAPH_PROP_HAS_LOOP) |
  361|  8.26k|        (1 << IGRAPH_PROP_HAS_MULTI) |
  362|  8.26k|        (1 << IGRAPH_PROP_HAS_MUTUAL)
  363|  8.26k|    );
  364|       |
  365|  8.26k|    return IGRAPH_SUCCESS;
  366|  8.26k|}
igraph_add_vertices:
  390|  10.7k|) {
  391|  10.7k|    igraph_integer_t ec = igraph_ecount(graph);
  392|  10.7k|    igraph_integer_t vc = igraph_vcount(graph);
  393|  10.7k|    igraph_integer_t new_vc;
  394|  10.7k|    igraph_integer_t i;
  395|       |
  396|  10.7k|    if (nv < 0) {
  ------------------
  |  Branch (396:9): [True: 0, False: 10.7k]
  ------------------
  397|      0|        IGRAPH_ERROR("Cannot add negative number of vertices.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  398|      0|    }
  399|       |
  400|  10.7k|    IGRAPH_SAFE_ADD(graph->n, nv, &new_vc);
  ------------------
  |  |   47|  10.7k|    do { \
  |  |   48|  10.7k|        igraph_integer_t _safe_a = (a), _safe_b = (b); \
  |  |   49|  10.7k|        igraph_integer_t _safe_sum; \
  |  |   50|  10.7k|        if (__builtin_add_overflow(_safe_a, _safe_b, &_safe_sum)) { \
  |  |  ------------------
  |  |  |  Branch (50:13): [True: 0, False: 10.7k]
  |  |  ------------------
  |  |   51|      0|            IGRAPH_ERRORF("Overflow when adding %" IGRAPH_PRId " and %" IGRAPH_PRId ".", IGRAPH_EOVERFLOW, _safe_a, _safe_b); \
  |  |  ------------------
  |  |  |  |  469|      0|    do { \
  |  |  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  |  |  472|      0|        return igraph_errno; \
  |  |  |  |  473|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   52|      0|        } \
  |  |   53|  10.7k|        *(res) = _safe_sum; \
  |  |   54|  10.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (54:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  401|  10.7k|    if (new_vc > IGRAPH_VCOUNT_MAX) {
  ------------------
  |  |  105|  10.7k|#define IGRAPH_VCOUNT_MAX (IGRAPH_INTEGER_MAX-1)
  |  |  ------------------
  |  |  |  |   77|  10.7k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  |  |  ------------------
  ------------------
  |  Branch (401:9): [True: 0, False: 10.7k]
  ------------------
  402|      0|        IGRAPH_ERRORF("Maximum vertex count (%" IGRAPH_PRId ") exceeded.", IGRAPH_ERANGE,
  ------------------
  |  |  469|      0|    do { \
  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  472|      0|        return igraph_errno; \
  |  |  473|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  403|      0|                      IGRAPH_VCOUNT_MAX);
  404|      0|    }
  405|  10.7k|    IGRAPH_CHECK(igraph_vector_int_reserve(&graph->os, new_vc + 1));
  ------------------
  |  |  648|  10.7k|    do { \
  |  |  649|  10.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  10.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  10.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 10.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  10.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  406|  10.7k|    IGRAPH_CHECK(igraph_vector_int_reserve(&graph->is, new_vc + 1));
  ------------------
  |  |  648|  10.7k|    do { \
  |  |  649|  10.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  10.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  10.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 10.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  10.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  407|       |
  408|  10.7k|    igraph_vector_int_resize(&graph->os, new_vc + 1); /* reserved */
  409|  10.7k|    igraph_vector_int_resize(&graph->is, new_vc + 1); /* reserved */
  410|  1.51M|    for (i = graph->n + 1; i < new_vc + 1; i++) {
  ------------------
  |  Branch (410:28): [True: 1.50M, False: 10.7k]
  ------------------
  411|  1.50M|        VECTOR(graph->os)[i] = ec;
  ------------------
  |  |   65|  1.50M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  412|  1.50M|        VECTOR(graph->is)[i] = ec;
  ------------------
  |  |   65|  1.50M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  413|  1.50M|    }
  414|       |
  415|  10.7k|    graph->n += nv;
  416|       |
  417|       |    /* Add attributes if necessary. This section is protected with
  418|       |     * FINALLY_ENTER/EXIT so that the graph would not be accidentally
  419|       |     * free upon error until it could be restored to a consistant state. */
  420|       |
  421|  10.7k|    if (graph->attr) {
  ------------------
  |  Branch (421:9): [True: 0, False: 10.7k]
  ------------------
  422|      0|        igraph_error_t err;
  423|      0|        IGRAPH_FINALLY_ENTER();
  424|      0|        err = igraph_i_attribute_add_vertices(graph, nv, attr);
  425|      0|        if (err != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (425:13): [True: 0, False: 0]
  ------------------
  426|       |            /* Restore original vertex count on failure */
  427|      0|            graph->n = vc;
  428|      0|            igraph_vector_int_resize(&graph->os, vc + 1); /* shrinks */
  429|      0|            igraph_vector_int_resize(&graph->is, vc + 1); /* shrinks */
  430|      0|        }
  431|      0|        IGRAPH_FINALLY_EXIT();
  432|      0|        if (err != IGRAPH_SUCCESS) {
  ------------------
  |  Branch (432:13): [True: 0, False: 0]
  ------------------
  433|      0|            IGRAPH_ERROR("Cannot add vertices.", err);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  434|      0|        }
  435|      0|    }
  436|       |
  437|       |    /* modification successful, clear the cached properties of the graph.
  438|       |     *
  439|       |     * Adding one or more nodes does not change the following cached properties:
  440|       |     *
  441|       |     * - IGRAPH_PROP_HAS_LOOP
  442|       |     * - IGRAPH_PROP_HAS_MULTI
  443|       |     * - IGRAPH_PROP_HAS_MUTUAL
  444|       |     * - IGRAPH_PROP_IS_DAG (adding a node does not create/destroy cycles)
  445|       |     * - IGRAPH_PROP_IS_FOREST (same)
  446|       |     *
  447|       |     * Adding one or more nodes without any edges incident on them is sure to
  448|       |     * make the graph disconnected (weakly or strongly), so we can keep the
  449|       |     * connectivity-related properties if they are currently cached as false.
  450|       |     * (Actually, even if they weren't cached as false, we could still set them
  451|       |     * to false, but we don't have that functionality yet). The only exception
  452|       |     * is when the graph had zero vertices and gained only one vertex, because
  453|       |     * it then becomes connected. That's why we have the condition below in the
  454|       |     * keep_when_false section.
  455|       |     */
  456|  10.7k|    igraph_i_property_cache_invalidate_conditionally(
  457|  10.7k|        graph,
  458|       |        /* keep_always = */
  459|  10.7k|        (1 << IGRAPH_PROP_HAS_LOOP) |
  460|  10.7k|        (1 << IGRAPH_PROP_HAS_MULTI) |
  461|  10.7k|        (1 << IGRAPH_PROP_HAS_MUTUAL) |
  462|  10.7k|        (1 << IGRAPH_PROP_IS_DAG) |
  463|  10.7k|        (1 << IGRAPH_PROP_IS_FOREST),
  464|       |        /* keep_when_false = */
  465|  10.7k|        igraph_vcount(graph) >= 2 ? (
  ------------------
  |  Branch (465:9): [True: 9.72k, False: 1.02k]
  ------------------
  466|  9.72k|            (1 << IGRAPH_PROP_IS_STRONGLY_CONNECTED) |
  467|  9.72k|            (1 << IGRAPH_PROP_IS_WEAKLY_CONNECTED)
  468|  9.72k|        ) : 0,
  469|       |        /* keep_when_true = */
  470|  10.7k|        0
  471|  10.7k|    );
  472|       |
  473|  10.7k|    return IGRAPH_SUCCESS;
  474|  10.7k|}
igraph_delete_edges:
  499|  1.88k|igraph_error_t igraph_delete_edges(igraph_t *graph, igraph_es_t edges) {
  500|  1.88k|    igraph_integer_t no_of_edges = igraph_ecount(graph);
  501|  1.88k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  502|  1.88k|    igraph_integer_t edges_to_remove = 0;
  503|  1.88k|    igraph_integer_t remaining_edges;
  504|  1.88k|    igraph_eit_t eit;
  505|       |
  506|  1.88k|    igraph_vector_int_t newfrom, newto;
  507|  1.88k|    igraph_vector_int_t newoi, newii;
  508|       |
  509|  1.88k|    igraph_bool_t *mark;
  510|  1.88k|    igraph_integer_t i, j;
  511|       |
  512|  1.88k|    mark = IGRAPH_CALLOC(no_of_edges, igraph_bool_t);
  ------------------
  |  |   38|  1.88k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  3.76k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 1.88k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 1.88k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 1.80k, False: 82]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  513|  1.88k|    IGRAPH_CHECK_OOM(mark, "Cannot delete edges.");
  ------------------
  |  |  701|  1.88k|    do { \
  |  |  702|  1.88k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  514|  1.88k|    IGRAPH_FINALLY(igraph_free, mark);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  515|       |
  516|  1.88k|    IGRAPH_CHECK(igraph_eit_create(graph, edges, &eit));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  517|  1.88k|    IGRAPH_FINALLY(igraph_eit_destroy, &eit);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  518|       |
  519|  47.0k|    for (IGRAPH_EIT_RESET(eit); !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  392|  1.88k|#define IGRAPH_EIT_RESET(eit) ((eit).pos = (eit).start)
  ------------------
                  for (IGRAPH_EIT_RESET(eit); !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  370|  47.0k|#define IGRAPH_EIT_END(eit)   ((eit).pos >= (eit).end)
  ------------------
                  for (IGRAPH_EIT_RESET(eit); !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  358|  45.1k|#define IGRAPH_EIT_NEXT(eit) (++((eit).pos))
  ------------------
  |  Branch (519:33): [True: 45.1k, False: 1.88k]
  ------------------
  520|  45.1k|        igraph_integer_t e = IGRAPH_EIT_GET(eit);
  ------------------
  |  |  404|  45.1k|    (igraph_integer_t)((((eit).type == IGRAPH_EIT_RANGE) ? (eit).pos : \
  |  |  ------------------
  |  |  |  Branch (404:25): [True: 0, False: 45.1k]
  |  |  ------------------
  |  |  405|  45.1k|                        VECTOR(*(eit).vec)[(eit).pos]))
  |  |  ------------------
  |  |  |  |   65|  45.1k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  521|  45.1k|        if (! mark[e]) {
  ------------------
  |  Branch (521:13): [True: 45.1k, False: 0]
  ------------------
  522|  45.1k|            edges_to_remove++;
  523|  45.1k|            mark[e] = true;
  524|  45.1k|        }
  525|  45.1k|    }
  526|  1.88k|    remaining_edges = no_of_edges - edges_to_remove;
  527|       |
  528|       |    /* We don't need the iterator any more */
  529|  1.88k|    igraph_eit_destroy(&eit);
  530|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  531|       |
  532|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newfrom, remaining_edges);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  533|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newto, remaining_edges);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  534|       |
  535|       |    /* Actually remove the edges, move from pos i to pos j in newfrom/newto */
  536|  52.2k|    for (i = 0, j = 0; j < remaining_edges; i++) {
  ------------------
  |  Branch (536:24): [True: 50.3k, False: 1.88k]
  ------------------
  537|  50.3k|        if (! mark[i]) {
  ------------------
  |  Branch (537:13): [True: 22.3k, False: 27.9k]
  ------------------
  538|  22.3k|            VECTOR(newfrom)[j] = VECTOR(graph->from)[i];
  ------------------
  |  |   65|  22.3k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(newfrom)[j] = VECTOR(graph->from)[i];
  ------------------
  |  |   65|  22.3k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  539|  22.3k|            VECTOR(newto)[j] = VECTOR(graph->to)[i];
  ------------------
  |  |   65|  22.3k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(newto)[j] = VECTOR(graph->to)[i];
  ------------------
  |  |   65|  22.3k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  540|  22.3k|            j++;
  541|  22.3k|        }
  542|  50.3k|    }
  543|       |
  544|       |    /* Create index, this might require additional memory */
  545|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newoi, remaining_edges);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  546|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newii, remaining_edges);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  547|  1.88k|    IGRAPH_CHECK(igraph_vector_int_pair_order(&newfrom, &newto, &newoi, no_of_nodes));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  548|  1.88k|    IGRAPH_CHECK(igraph_vector_int_pair_order(&newto, &newfrom, &newii, no_of_nodes));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  549|       |
  550|       |    /* Edge attributes, we need an index that gives the IDs of the
  551|       |       original edges for every new edge.
  552|       |    */
  553|  1.88k|    if (graph->attr) {
  ------------------
  |  Branch (553:9): [True: 0, False: 1.88k]
  ------------------
  554|      0|        igraph_vector_int_t idx;
  555|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&idx, remaining_edges);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  556|      0|        for (i = 0, j = 0; i < no_of_edges; i++) {
  ------------------
  |  Branch (556:28): [True: 0, False: 0]
  ------------------
  557|      0|            if (! mark[i]) {
  ------------------
  |  Branch (557:17): [True: 0, False: 0]
  ------------------
  558|      0|                VECTOR(idx)[j++] = i;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  559|      0|            }
  560|      0|        }
  561|      0|        IGRAPH_CHECK(igraph_i_attribute_permute_edges(graph, graph, &idx));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  562|      0|        igraph_vector_int_destroy(&idx);
  563|      0|        IGRAPH_FINALLY_CLEAN(1);
  564|      0|    }
  565|       |
  566|       |    /* Ok, we've all memory needed, free the old structure  */
  567|  1.88k|    igraph_vector_int_destroy(&graph->from);
  568|  1.88k|    igraph_vector_int_destroy(&graph->to);
  569|  1.88k|    igraph_vector_int_destroy(&graph->oi);
  570|  1.88k|    igraph_vector_int_destroy(&graph->ii);
  571|  1.88k|    graph->from = newfrom;
  572|  1.88k|    graph->to = newto;
  573|  1.88k|    graph->oi = newoi;
  574|  1.88k|    graph->ii = newii;
  575|  1.88k|    IGRAPH_FINALLY_CLEAN(4);
  576|       |
  577|  1.88k|    IGRAPH_FREE(mark);
  ------------------
  |  |   41|  1.88k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  578|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  579|       |
  580|       |    /* Create start vectors, no memory is needed for this */
  581|  1.88k|    igraph_i_create_start_vectors(&graph->os, &graph->from, &graph->oi, no_of_nodes);
  582|  1.88k|    igraph_i_create_start_vectors(&graph->is, &graph->to,   &graph->ii, no_of_nodes);
  583|       |
  584|       |    /* modification successful, clear the cached properties of the graph.
  585|       |     *
  586|       |     * Deleting one or more edges cannot make a directed acyclic graph cyclic,
  587|       |     * or an undirected forest into a cyclic graph, so we keep those flags if
  588|       |     * they are cached as true.
  589|       |     *
  590|       |     * Similarly, deleting one or more edges cannot make a disconnected graph
  591|       |     * connected, so we keep the connectivity flags if they are cached as false.
  592|       |     *
  593|       |     * Also, if the graph had no loop edges before the deletion, it will have
  594|       |     * no loop edges after the deletion either. The same applies to reciprocal
  595|       |     * edges or multiple edges as well.
  596|       |     */
  597|  1.88k|    igraph_i_property_cache_invalidate_conditionally(
  598|  1.88k|        graph,
  599|  1.88k|        /* keep_always = */ 0,
  600|       |        /* keep_when_false = */
  601|  1.88k|        (1 << IGRAPH_PROP_HAS_LOOP) |
  602|  1.88k|        (1 << IGRAPH_PROP_HAS_MULTI) |
  603|  1.88k|        (1 << IGRAPH_PROP_HAS_MUTUAL) |
  604|  1.88k|        (1 << IGRAPH_PROP_IS_STRONGLY_CONNECTED) |
  605|  1.88k|        (1 << IGRAPH_PROP_IS_WEAKLY_CONNECTED),
  606|       |        /* keep_when_true = */
  607|  1.88k|        (1 << IGRAPH_PROP_IS_DAG) |
  608|  1.88k|        (1 << IGRAPH_PROP_IS_FOREST)
  609|  1.88k|    );
  610|       |
  611|       |    /* Nothing to deallocate... */
  612|  1.88k|    return IGRAPH_SUCCESS;
  613|  1.88k|}
igraph_delete_vertices_map:
  647|  2.17k|) {
  648|  2.17k|    igraph_integer_t no_of_edges = igraph_ecount(graph);
  649|  2.17k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  650|  2.17k|    igraph_vector_int_t edge_recoding, vertex_recoding;
  651|  2.17k|    igraph_vector_int_t *my_vertex_recoding = &vertex_recoding;
  652|  2.17k|    igraph_vit_t vit;
  653|  2.17k|    igraph_t newgraph;
  654|  2.17k|    igraph_integer_t i, j;
  655|  2.17k|    igraph_integer_t remaining_vertices, remaining_edges;
  656|       |
  657|  2.17k|    if (map) {
  ------------------
  |  Branch (657:9): [True: 0, False: 2.17k]
  ------------------
  658|      0|        my_vertex_recoding = map;
  659|      0|        IGRAPH_CHECK(igraph_vector_int_resize(map, no_of_nodes));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  660|      0|        igraph_vector_int_null(map);
  661|  2.17k|    } else {
  662|  2.17k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&vertex_recoding, no_of_nodes);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  663|  2.17k|    }
  664|       |
  665|  2.17k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&edge_recoding, no_of_edges);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  666|       |
  667|  2.17k|    IGRAPH_CHECK(igraph_vit_create(graph, vertices, &vit));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  668|  2.17k|    IGRAPH_FINALLY(igraph_vit_destroy, &vit);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  669|       |
  670|       |    /* mark the vertices to delete */
  671|   391k|    for (; !IGRAPH_VIT_END(vit); IGRAPH_VIT_NEXT(vit) ) {
  ------------------
  |  |  180|   391k|#define IGRAPH_VIT_END(vit)   ((vit).pos >= (vit).end)
  ------------------
                  for (; !IGRAPH_VIT_END(vit); IGRAPH_VIT_NEXT(vit) ) {
  ------------------
  |  |  168|   389k|#define IGRAPH_VIT_NEXT(vit)  (++((vit).pos))
  ------------------
  |  Branch (671:12): [True: 389k, False: 2.17k]
  ------------------
  672|   389k|        igraph_integer_t vertex = IGRAPH_VIT_GET(vit);
  ------------------
  |  |  215|   389k|    ((igraph_integer_t)(((vit).type == IGRAPH_VIT_RANGE) ? (vit).pos : \
  |  |  ------------------
  |  |  |  Branch (215:25): [True: 0, False: 389k]
  |  |  ------------------
  |  |  216|   389k|                        VECTOR(*(vit).vec)[(vit).pos]))
  |  |  ------------------
  |  |  |  |   65|   389k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  673|   389k|        if (vertex < 0 || vertex >= no_of_nodes) {
  ------------------
  |  Branch (673:13): [True: 0, False: 389k]
  |  Branch (673:27): [True: 0, False: 389k]
  ------------------
  674|      0|            IGRAPH_ERROR("Cannot delete vertices.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  675|      0|        }
  676|   389k|        VECTOR(*my_vertex_recoding)[vertex] = 1;
  ------------------
  |  |   65|   389k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  677|   389k|    }
  678|       |    /* create vertex recoding vector */
  679|   407k|    for (remaining_vertices = 0, i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (679:41): [True: 405k, False: 2.17k]
  ------------------
  680|   405k|        if (VECTOR(*my_vertex_recoding)[i] == 0) {
  ------------------
  |  |   65|   405k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (680:13): [True: 16.0k, False: 389k]
  ------------------
  681|  16.0k|            VECTOR(*my_vertex_recoding)[i] = remaining_vertices;
  ------------------
  |  |   65|  16.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  682|  16.0k|            remaining_vertices++;
  683|   389k|        } else {
  684|   389k|            VECTOR(*my_vertex_recoding)[i] = -1;
  ------------------
  |  |   65|   389k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  685|   389k|        }
  686|   405k|    }
  687|       |    /* create edge recoding vector */
  688|  49.3k|    for (remaining_edges = 0, i = 0; i < no_of_edges; i++) {
  ------------------
  |  Branch (688:38): [True: 47.1k, False: 2.17k]
  ------------------
  689|  47.1k|        igraph_integer_t from = VECTOR(graph->from)[i];
  ------------------
  |  |   65|  47.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  690|  47.1k|        igraph_integer_t to = VECTOR(graph->to)[i];
  ------------------
  |  |   65|  47.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  691|  47.1k|        if (VECTOR(*my_vertex_recoding)[from] >= 0 &&
  ------------------
  |  |   65|  47.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (691:13): [True: 37.5k, False: 9.58k]
  ------------------
  692|  47.1k|            VECTOR(*my_vertex_recoding)[to  ] >= 0) {
  ------------------
  |  |   65|  37.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (692:13): [True: 36.2k, False: 1.30k]
  ------------------
  693|  36.2k|            VECTOR(edge_recoding)[i] = remaining_edges + 1;
  ------------------
  |  |   65|  36.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  694|  36.2k|            remaining_edges++;
  695|  36.2k|        }
  696|  47.1k|    }
  697|       |
  698|       |    /* start creating the graph */
  699|  2.17k|    memset(&newgraph, 0, sizeof(igraph_t));
  700|  2.17k|    newgraph.n = remaining_vertices;
  701|  2.17k|    newgraph.directed = graph->directed;
  702|       |
  703|       |    /* allocate vectors */
  704|  2.17k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newgraph.from, remaining_edges);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  705|  2.17k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newgraph.to, remaining_edges);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  706|  2.17k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newgraph.oi, remaining_edges);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  707|  2.17k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newgraph.ii, remaining_edges);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  708|  2.17k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newgraph.os, remaining_vertices + 1);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  709|  2.17k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&newgraph.is, remaining_vertices + 1);
  ------------------
  |  |  124|  2.17k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  2.17k|    do { \
  |  |  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  2.17k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  2.17k|    do { \
  |  |  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  2.17k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  710|       |
  711|       |    /* Add the edges */
  712|  48.0k|    for (i = 0, j = 0; j < remaining_edges; i++) {
  ------------------
  |  Branch (712:24): [True: 45.8k, False: 2.17k]
  ------------------
  713|  45.8k|        if (VECTOR(edge_recoding)[i] > 0) {
  ------------------
  |  |   65|  45.8k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (713:13): [True: 36.2k, False: 9.63k]
  ------------------
  714|  36.2k|            igraph_integer_t from = VECTOR(graph->from)[i];
  ------------------
  |  |   65|  36.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  715|  36.2k|            igraph_integer_t to = VECTOR(graph->to  )[i];
  ------------------
  |  |   65|  36.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  716|  36.2k|            VECTOR(newgraph.from)[j] = VECTOR(*my_vertex_recoding)[from];
  ------------------
  |  |   65|  36.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(newgraph.from)[j] = VECTOR(*my_vertex_recoding)[from];
  ------------------
  |  |   65|  36.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  717|  36.2k|            VECTOR(newgraph.to  )[j] = VECTOR(*my_vertex_recoding)[to];
  ------------------
  |  |   65|  36.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(newgraph.to  )[j] = VECTOR(*my_vertex_recoding)[to];
  ------------------
  |  |   65|  36.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  718|  36.2k|            j++;
  719|  36.2k|        }
  720|  45.8k|    }
  721|       |
  722|       |    /* update oi & ii */
  723|  2.17k|    IGRAPH_CHECK(igraph_vector_int_pair_order(&newgraph.from, &newgraph.to, &newgraph.oi,
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  724|  2.17k|                                         remaining_vertices));
  725|  2.17k|    IGRAPH_CHECK(igraph_vector_int_pair_order(&newgraph.to, &newgraph.from, &newgraph.ii,
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  726|  2.17k|                                         remaining_vertices));
  727|       |
  728|  2.17k|    IGRAPH_CHECK(igraph_i_create_start_vectors(&newgraph.os, &newgraph.from,
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  729|  2.17k|                                       &newgraph.oi, remaining_vertices));
  730|  2.17k|    IGRAPH_CHECK(igraph_i_create_start_vectors(&newgraph.is, &newgraph.to,
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  731|  2.17k|                                       &newgraph.ii, remaining_vertices));
  732|       |
  733|  2.17k|    newgraph.cache = IGRAPH_CALLOC(1, igraph_i_property_cache_t);
  ------------------
  |  |   38|  2.17k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  4.34k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  734|  2.17k|    IGRAPH_CHECK_OOM(newgraph.cache, "Cannot delete vertices.");
  ------------------
  |  |  701|  2.17k|    do { \
  |  |  702|  2.17k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  735|  2.17k|    IGRAPH_FINALLY(igraph_free, newgraph.cache);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  736|  2.17k|    IGRAPH_CHECK(igraph_i_property_cache_init(newgraph.cache));
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  737|  2.17k|    IGRAPH_FINALLY(igraph_i_property_cache_destroy, newgraph.cache);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  738|       |
  739|       |    /* attributes */
  740|  2.17k|    IGRAPH_CHECK(igraph_i_attribute_copy(
  ------------------
  |  |  648|  2.17k|    do { \
  |  |  649|  2.17k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  2.17k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  2.17k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.17k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  741|  2.17k|        &newgraph, graph, /* graph= */ true, /* vertex= */ false, /* edge= */ false
  742|  2.17k|    ));
  743|       |
  744|       |    /* at this point igraph_destroy can take over the responsibility of
  745|       |     * deallocating the graph */
  746|  2.17k|    IGRAPH_FINALLY_CLEAN(8);    /* 2 for the property cache, 6 for the vectors */
  747|  2.17k|    IGRAPH_FINALLY(igraph_destroy, &newgraph);
  ------------------
  |  |  591|  2.17k|    do { \
  |  |  592|  2.17k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  2.17k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  2.17k|         * incorrect destructor function with the pointer */ \
  |  |  595|  2.17k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  2.17k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  2.17k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  748|       |
  749|  2.17k|    if (newgraph.attr) {
  ------------------
  |  Branch (749:9): [True: 0, False: 2.17k]
  ------------------
  750|      0|        igraph_vector_int_t iidx;
  751|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&iidx, remaining_vertices);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  752|      0|        for (i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (752:21): [True: 0, False: 0]
  ------------------
  753|      0|            igraph_integer_t jj = VECTOR(*my_vertex_recoding)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  754|      0|            if (jj >= 0) {
  ------------------
  |  Branch (754:17): [True: 0, False: 0]
  ------------------
  755|      0|                VECTOR(iidx)[ jj ] = i;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  756|      0|            }
  757|      0|        }
  758|      0|        IGRAPH_CHECK(igraph_i_attribute_permute_vertices(graph, &newgraph, &iidx));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  759|      0|        IGRAPH_CHECK(igraph_vector_int_resize(&iidx, remaining_edges));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  760|      0|        for (i = 0; i < no_of_edges; i++) {
  ------------------
  |  Branch (760:21): [True: 0, False: 0]
  ------------------
  761|      0|            igraph_integer_t jj = VECTOR(edge_recoding)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  762|      0|            if (jj != 0) {
  ------------------
  |  Branch (762:17): [True: 0, False: 0]
  ------------------
  763|      0|                VECTOR(iidx)[ jj - 1 ] = i;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  764|      0|            }
  765|      0|        }
  766|      0|        IGRAPH_CHECK(igraph_i_attribute_permute_edges(graph, &newgraph, &iidx));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  767|      0|        igraph_vector_int_destroy(&iidx);
  768|      0|        IGRAPH_FINALLY_CLEAN(1);
  769|      0|    }
  770|       |
  771|  2.17k|    igraph_vit_destroy(&vit);
  772|  2.17k|    igraph_vector_int_destroy(&edge_recoding);
  773|  2.17k|    igraph_destroy(graph);
  774|  2.17k|    *graph = newgraph;
  775|       |
  776|  2.17k|    IGRAPH_FINALLY_CLEAN(3);
  777|       |
  778|  2.17k|    if (invmap) {
  ------------------
  |  Branch (778:9): [True: 0, False: 2.17k]
  ------------------
  779|      0|        IGRAPH_CHECK(igraph_vector_int_resize(invmap, remaining_vertices));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  780|      0|        for (i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (780:21): [True: 0, False: 0]
  ------------------
  781|      0|            igraph_integer_t newid = VECTOR(*my_vertex_recoding)[i];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  782|      0|            if (newid >= 0) {
  ------------------
  |  Branch (782:17): [True: 0, False: 0]
  ------------------
  783|      0|                VECTOR(*invmap)[newid] = i;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  784|      0|            }
  785|      0|        }
  786|      0|    }
  787|       |
  788|  2.17k|    if (!map) {
  ------------------
  |  Branch (788:9): [True: 2.17k, False: 0]
  ------------------
  789|  2.17k|        igraph_vector_int_destroy(my_vertex_recoding);
  790|  2.17k|        IGRAPH_FINALLY_CLEAN(1);
  791|  2.17k|    }
  792|       |
  793|       |    /* modification successful, clear the cached properties of the graph.
  794|       |     *
  795|       |     * Deleting one or more vertices cannot make a directed acyclic graph cyclic,
  796|       |     * or an undirected forest into a cyclic graph, so we keep those flags if
  797|       |     * they are cached as true.
  798|       |     *
  799|       |     * Also, if the graph had no loop edges before the deletion, it will have
  800|       |     * no loop edges after the deletion either. The same applies to reciprocal
  801|       |     * edges or multiple edges as well.
  802|       |     */
  803|  2.17k|    igraph_i_property_cache_invalidate_conditionally(
  804|  2.17k|        graph,
  805|  2.17k|        /* keep_always = */ 0,
  806|       |        /* keep_when_false = */
  807|  2.17k|        (1 << IGRAPH_PROP_HAS_LOOP) |
  808|  2.17k|        (1 << IGRAPH_PROP_HAS_MULTI) |
  809|  2.17k|        (1 << IGRAPH_PROP_HAS_MUTUAL),
  810|       |        /* keep_when_true = */
  811|  2.17k|        (1 << IGRAPH_PROP_IS_DAG) |
  812|  2.17k|        (1 << IGRAPH_PROP_IS_FOREST)
  813|  2.17k|    );
  814|       |
  815|  2.17k|    return IGRAPH_SUCCESS;
  816|  2.17k|}
igraph_vcount:
  828|  6.91M|igraph_integer_t igraph_vcount(const igraph_t *graph) {
  829|  6.91M|    return graph->n;
  830|  6.91M|}
igraph_ecount:
  842|   110k|igraph_integer_t igraph_ecount(const igraph_t *graph) {
  843|   110k|    return igraph_vector_int_size(&graph->from);
  844|   110k|}
igraph_neighbors:
  880|  4.87M|        igraph_neimode_t mode) {
  881|  4.87M|    if (!igraph_is_directed(graph) || mode == IGRAPH_ALL) {
  ------------------
  |  Branch (881:9): [True: 746k, False: 4.12M]
  |  Branch (881:39): [True: 1.51M, False: 2.61M]
  ------------------
  882|  2.25M|        return igraph_i_neighbors(graph, neis, pnode, mode, IGRAPH_LOOPS_TWICE, IGRAPH_MULTIPLE);
  883|  2.61M|    } else {
  884|  2.61M|        return igraph_i_neighbors(graph, neis, pnode, mode, IGRAPH_LOOPS_ONCE, IGRAPH_MULTIPLE);
  885|  2.61M|    }
  886|  4.87M|}
igraph_i_neighbors:
  889|  4.87M|        igraph_neimode_t mode, igraph_loops_t loops, igraph_multiple_t multiple) {
  890|  4.87M|#define DEDUPLICATE_IF_NEEDED(vertex, n)                                                 \
  891|  4.87M|    if (should_filter_duplicates) {                                                        \
  892|  4.87M|        if (                                                                               \
  893|  4.87M|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  894|  4.87M|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  895|  4.87M|        ) {                                                                                \
  896|  4.87M|            length -= n;                                                                   \
  897|  4.87M|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  898|  4.87M|                last_added = -1;                                                           \
  899|  4.87M|            }                                                                              \
  900|  4.87M|            continue;                                                                      \
  901|  4.87M|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  902|  4.87M|            length -= n;                                                                   \
  903|  4.87M|            continue;                                                                      \
  904|  4.87M|        } else {                                                                           \
  905|  4.87M|            last_added = vertex;                                                           \
  906|  4.87M|        }                                                                                  \
  907|  4.87M|    }
  908|       |
  909|  4.87M|    igraph_integer_t length = 0, idx = 0;
  910|  4.87M|    igraph_integer_t i, j;
  911|       |
  912|  4.87M|    igraph_integer_t node = pnode;
  913|  4.87M|    igraph_integer_t last_added = -1;
  914|  4.87M|    igraph_bool_t should_filter_duplicates;
  915|       |
  916|  4.87M|    if (node < 0 || node > igraph_vcount(graph) - 1) {
  ------------------
  |  Branch (916:9): [True: 0, False: 4.87M]
  |  Branch (916:21): [True: 0, False: 4.87M]
  ------------------
  917|      0|        IGRAPH_ERROR("Given vertex is not in the graph.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  918|      0|    }
  919|  4.87M|    if (mode != IGRAPH_OUT && mode != IGRAPH_IN &&
  ------------------
  |  Branch (919:9): [True: 3.00M, False: 1.86M]
  |  Branch (919:31): [True: 2.25M, False: 746k]
  ------------------
  920|  4.87M|            mode != IGRAPH_ALL) {
  ------------------
  |  Branch (920:13): [True: 0, False: 2.25M]
  ------------------
  921|      0|        IGRAPH_ERROR("Mode should be either IGRAPH_OUT, IGRAPH_IN or IGRAPH_ALL.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  922|      0|    }
  923|       |
  924|  4.87M|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (924:9): [True: 746k, False: 4.12M]
  ------------------
  925|   746k|        mode = IGRAPH_ALL;
  926|   746k|    }
  927|       |
  928|  4.87M|    if (mode != IGRAPH_ALL && loops == IGRAPH_LOOPS_TWICE) {
  ------------------
  |  Branch (928:9): [True: 2.61M, False: 2.25M]
  |  Branch (928:31): [True: 0, False: 2.61M]
  ------------------
  929|      0|        IGRAPH_ERROR("For a directed graph (with directions not ignored), "
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  930|      0|                     "IGRAPH_LOOPS_TWICE does not make sense.", IGRAPH_EINVAL);
  931|      0|    }
  932|       |    /* Calculate needed space first & allocate it */
  933|       |    /* Note that 'mode' is treated as a bit field here; it's okay because
  934|       |     * IGRAPH_ALL = IGRAPH_IN | IGRAPH_OUT, bit-wise */
  935|  4.87M|    if (mode & IGRAPH_OUT) {
  ------------------
  |  Branch (935:9): [True: 4.12M, False: 746k]
  ------------------
  936|  4.12M|        length += (VECTOR(graph->os)[node + 1] - VECTOR(graph->os)[node]);
  ------------------
  |  |   65|  4.12M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      length += (VECTOR(graph->os)[node + 1] - VECTOR(graph->os)[node]);
  ------------------
  |  |   65|  4.12M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  937|  4.12M|    }
  938|  4.87M|    if (mode & IGRAPH_IN) {
  ------------------
  |  Branch (938:9): [True: 3.00M, False: 1.86M]
  ------------------
  939|  3.00M|        length += (VECTOR(graph->is)[node + 1] - VECTOR(graph->is)[node]);
  ------------------
  |  |   65|  3.00M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      length += (VECTOR(graph->is)[node + 1] - VECTOR(graph->is)[node]);
  ------------------
  |  |   65|  3.00M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  940|  3.00M|    }
  941|       |
  942|  4.87M|    IGRAPH_CHECK(igraph_vector_int_resize(neis, length));
  ------------------
  |  |  648|  4.87M|    do { \
  |  |  649|  4.87M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  4.87M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  4.87M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.87M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  4.87M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  943|       |
  944|       |    /* The loops below produce an ordering what is consistent with the
  945|       |     * ordering returned by igraph_neighbors(), and this should be preserved.
  946|       |     * We are dealing with two sorted lists; one for the successors and one
  947|       |     * for the predecessors. If we have requested only one of them, we have
  948|       |     * an easy job. If we have requested both, we need to merge the two lists
  949|       |     * to ensure that the output is sorted by the vertex IDs of the "other"
  950|       |     * endpoint of the affected edges. We don't need to merge if the graph
  951|       |     * is undirected, because in that case the data structure guarantees that
  952|       |     * the "out-edges" contain only (u, v) pairs where u <= v and the
  953|       |     * "in-edges" contains the rest, so the result is sorted even without
  954|       |     * merging. */
  955|  4.87M|    if (!igraph_is_directed(graph) || mode != IGRAPH_ALL) {
  ------------------
  |  Branch (955:9): [True: 746k, False: 4.12M]
  |  Branch (955:39): [True: 2.61M, False: 1.51M]
  ------------------
  956|       |        /* graph is undirected or we did not ask for both directions in a
  957|       |         * directed graph; this is the easy case */
  958|       |
  959|  3.36M|        should_filter_duplicates = !(multiple == IGRAPH_MULTIPLE &&
  ------------------
  |  Branch (959:38): [True: 3.36M, False: 0]
  ------------------
  960|  3.36M|                ((!igraph_is_directed(graph) && loops == IGRAPH_LOOPS_TWICE) ||
  ------------------
  |  Branch (960:19): [True: 746k, False: 2.61M]
  |  Branch (960:49): [True: 746k, False: 0]
  ------------------
  961|  3.36M|                 (igraph_is_directed(graph) && loops != IGRAPH_NO_LOOPS)));
  ------------------
  |  Branch (961:19): [True: 2.61M, False: 0]
  |  Branch (961:48): [True: 2.61M, False: 0]
  ------------------
  962|       |
  963|  3.36M|        if (mode & IGRAPH_OUT) {
  ------------------
  |  Branch (963:13): [True: 2.61M, False: 746k]
  ------------------
  964|  2.61M|            j = VECTOR(graph->os)[node + 1];
  ------------------
  |  |   65|  2.61M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  965|  3.03M|            for (i = VECTOR(graph->os)[node]; i < j; i++) {
  ------------------
  |  |   65|  2.61M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (965:47): [True: 424k, False: 2.61M]
  ------------------
  966|   424k|                igraph_integer_t to = VECTOR(graph->to)[ VECTOR(graph->oi)[i] ];
  ------------------
  |  |   65|   424k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              igraph_integer_t to = VECTOR(graph->to)[ VECTOR(graph->oi)[i] ];
  ------------------
  |  |   65|   424k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  967|   424k|                DEDUPLICATE_IF_NEEDED(to, 1);
  ------------------
  |  |  891|   424k|    if (should_filter_duplicates) {                                                        \
  |  |  ------------------
  |  |  |  Branch (891:9): [True: 0, False: 424k]
  |  |  ------------------
  |  |  892|      0|        if (                                                                               \
  |  |  893|      0|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  |  |  ------------------
  |  |  |  Branch (893:14): [True: 0, False: 0]
  |  |  |  Branch (893:42): [True: 0, False: 0]
  |  |  ------------------
  |  |  894|      0|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  |  |  ------------------
  |  |  |  Branch (894:14): [True: 0, False: 0]
  |  |  |  Branch (894:44): [True: 0, False: 0]
  |  |  |  Branch (894:63): [True: 0, False: 0]
  |  |  ------------------
  |  |  895|      0|        ) {                                                                                \
  |  |  896|      0|            length -= n;                                                                   \
  |  |  897|      0|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  |  |  ------------------
  |  |  |  Branch (897:17): [True: 0, False: 0]
  |  |  ------------------
  |  |  898|      0|                last_added = -1;                                                           \
  |  |  899|      0|            }                                                                              \
  |  |  900|      0|            continue;                                                                      \
  |  |  901|      0|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  |  |  ------------------
  |  |  |  Branch (901:20): [True: 0, False: 0]
  |  |  |  Branch (901:54): [True: 0, False: 0]
  |  |  ------------------
  |  |  902|      0|            length -= n;                                                                   \
  |  |  903|      0|            continue;                                                                      \
  |  |  904|      0|        } else {                                                                           \
  |  |  905|      0|            last_added = vertex;                                                           \
  |  |  906|      0|        }                                                                                  \
  |  |  907|      0|    }
  ------------------
  968|   424k|                VECTOR(*neis)[idx++] = to;
  ------------------
  |  |   65|   424k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  969|   424k|            }
  970|  2.61M|        }
  971|       |
  972|  3.36M|        if (mode & IGRAPH_IN) {
  ------------------
  |  Branch (972:13): [True: 1.49M, False: 1.86M]
  ------------------
  973|  1.49M|            j = VECTOR(graph->is)[node + 1];
  ------------------
  |  |   65|  1.49M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  974|  1.71M|            for (i = VECTOR(graph->is)[node]; i < j; i++) {
  ------------------
  |  |   65|  1.49M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (974:47): [True: 221k, False: 1.49M]
  ------------------
  975|   221k|                igraph_integer_t from = VECTOR(graph->from)[ VECTOR(graph->ii)[i] ];
  ------------------
  |  |   65|   221k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              igraph_integer_t from = VECTOR(graph->from)[ VECTOR(graph->ii)[i] ];
  ------------------
  |  |   65|   221k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  976|   221k|                DEDUPLICATE_IF_NEEDED(from, 1);
  ------------------
  |  |  891|   221k|    if (should_filter_duplicates) {                                                        \
  |  |  ------------------
  |  |  |  Branch (891:9): [True: 0, False: 221k]
  |  |  ------------------
  |  |  892|      0|        if (                                                                               \
  |  |  893|      0|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  |  |  ------------------
  |  |  |  Branch (893:14): [True: 0, False: 0]
  |  |  |  Branch (893:42): [True: 0, False: 0]
  |  |  ------------------
  |  |  894|      0|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  |  |  ------------------
  |  |  |  Branch (894:14): [True: 0, False: 0]
  |  |  |  Branch (894:44): [True: 0, False: 0]
  |  |  |  Branch (894:63): [True: 0, False: 0]
  |  |  ------------------
  |  |  895|      0|        ) {                                                                                \
  |  |  896|      0|            length -= n;                                                                   \
  |  |  897|      0|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  |  |  ------------------
  |  |  |  Branch (897:17): [True: 0, False: 0]
  |  |  ------------------
  |  |  898|      0|                last_added = -1;                                                           \
  |  |  899|      0|            }                                                                              \
  |  |  900|      0|            continue;                                                                      \
  |  |  901|      0|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  |  |  ------------------
  |  |  |  Branch (901:20): [True: 0, False: 0]
  |  |  |  Branch (901:54): [True: 0, False: 0]
  |  |  ------------------
  |  |  902|      0|            length -= n;                                                                   \
  |  |  903|      0|            continue;                                                                      \
  |  |  904|      0|        } else {                                                                           \
  |  |  905|      0|            last_added = vertex;                                                           \
  |  |  906|      0|        }                                                                                  \
  |  |  907|      0|    }
  ------------------
  977|   221k|                VECTOR(*neis)[idx++] = from;
  ------------------
  |  |   65|   221k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  978|   221k|            }
  979|  1.49M|        }
  980|  3.36M|    } else {
  981|       |        /* Both in- and out- neighbors in a directed graph,
  982|       |           we need to merge the two 'vectors' so the result is
  983|       |           correctly ordered. */
  984|  1.51M|        igraph_integer_t j1 = VECTOR(graph->os)[node + 1];
  ------------------
  |  |   65|  1.51M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  985|  1.51M|        igraph_integer_t j2 = VECTOR(graph->is)[node + 1];
  ------------------
  |  |   65|  1.51M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  986|  1.51M|        igraph_integer_t i1 = VECTOR(graph->os)[node];
  ------------------
  |  |   65|  1.51M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  987|  1.51M|        igraph_integer_t i2 = VECTOR(graph->is)[node];
  ------------------
  |  |   65|  1.51M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  988|  1.51M|        igraph_integer_t eid1, eid2;
  989|  1.51M|        igraph_integer_t n1, n2;
  990|       |
  991|  1.51M|        should_filter_duplicates = !(multiple == IGRAPH_MULTIPLE &&
  ------------------
  |  Branch (991:38): [True: 1.51M, False: 0]
  ------------------
  992|  1.51M|                loops == IGRAPH_LOOPS_TWICE);
  ------------------
  |  Branch (992:17): [True: 1.51M, False: 0]
  ------------------
  993|       |
  994|  1.78M|        while (i1 < j1 && i2 < j2) {
  ------------------
  |  Branch (994:16): [True: 355k, False: 1.42M]
  |  Branch (994:27): [True: 272k, False: 83.1k]
  ------------------
  995|   272k|            eid1 = VECTOR(graph->oi)[i1];
  ------------------
  |  |   65|   272k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  996|   272k|            eid2 = VECTOR(graph->ii)[i2];
  ------------------
  |  |   65|   272k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  997|   272k|            n1 = VECTOR(graph->to)[eid1];
  ------------------
  |  |   65|   272k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  998|   272k|            n2 = VECTOR(graph->from)[eid2];
  ------------------
  |  |   65|   272k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  999|   272k|            if (n1 < n2) {
  ------------------
  |  Branch (999:17): [True: 105k, False: 166k]
  ------------------
 1000|   105k|                i1++;
 1001|   105k|                DEDUPLICATE_IF_NEEDED(n1, 1);
  ------------------
  |  |  891|   105k|    if (should_filter_duplicates) {                                                        \
  |  |  ------------------
  |  |  |  Branch (891:9): [True: 0, False: 105k]
  |  |  ------------------
  |  |  892|      0|        if (                                                                               \
  |  |  893|      0|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  |  |  ------------------
  |  |  |  Branch (893:14): [True: 0, False: 0]
  |  |  |  Branch (893:42): [True: 0, False: 0]
  |  |  ------------------
  |  |  894|      0|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  |  |  ------------------
  |  |  |  Branch (894:14): [True: 0, False: 0]
  |  |  |  Branch (894:44): [True: 0, False: 0]
  |  |  |  Branch (894:63): [True: 0, False: 0]
  |  |  ------------------
  |  |  895|      0|        ) {                                                                                \
  |  |  896|      0|            length -= n;                                                                   \
  |  |  897|      0|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  |  |  ------------------
  |  |  |  Branch (897:17): [True: 0, False: 0]
  |  |  ------------------
  |  |  898|      0|                last_added = -1;                                                           \
  |  |  899|      0|            }                                                                              \
  |  |  900|      0|            continue;                                                                      \
  |  |  901|      0|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  |  |  ------------------
  |  |  |  Branch (901:20): [True: 0, False: 0]
  |  |  |  Branch (901:54): [True: 0, False: 0]
  |  |  ------------------
  |  |  902|      0|            length -= n;                                                                   \
  |  |  903|      0|            continue;                                                                      \
  |  |  904|      0|        } else {                                                                           \
  |  |  905|      0|            last_added = vertex;                                                           \
  |  |  906|      0|        }                                                                                  \
  |  |  907|      0|    }
  ------------------
 1002|   105k|                VECTOR(*neis)[idx++] = n1;
  ------------------
  |  |   65|   105k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1003|   166k|            } else if (n1 > n2) {
  ------------------
  |  Branch (1003:24): [True: 102k, False: 64.1k]
  ------------------
 1004|   102k|                i2++;
 1005|   102k|                DEDUPLICATE_IF_NEEDED(n2, 1);
  ------------------
  |  |  891|   102k|    if (should_filter_duplicates) {                                                        \
  |  |  ------------------
  |  |  |  Branch (891:9): [True: 0, False: 102k]
  |  |  ------------------
  |  |  892|      0|        if (                                                                               \
  |  |  893|      0|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  |  |  ------------------
  |  |  |  Branch (893:14): [True: 0, False: 0]
  |  |  |  Branch (893:42): [True: 0, False: 0]
  |  |  ------------------
  |  |  894|      0|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  |  |  ------------------
  |  |  |  Branch (894:14): [True: 0, False: 0]
  |  |  |  Branch (894:44): [True: 0, False: 0]
  |  |  |  Branch (894:63): [True: 0, False: 0]
  |  |  ------------------
  |  |  895|      0|        ) {                                                                                \
  |  |  896|      0|            length -= n;                                                                   \
  |  |  897|      0|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  |  |  ------------------
  |  |  |  Branch (897:17): [True: 0, False: 0]
  |  |  ------------------
  |  |  898|      0|                last_added = -1;                                                           \
  |  |  899|      0|            }                                                                              \
  |  |  900|      0|            continue;                                                                      \
  |  |  901|      0|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  |  |  ------------------
  |  |  |  Branch (901:20): [True: 0, False: 0]
  |  |  |  Branch (901:54): [True: 0, False: 0]
  |  |  ------------------
  |  |  902|      0|            length -= n;                                                                   \
  |  |  903|      0|            continue;                                                                      \
  |  |  904|      0|        } else {                                                                           \
  |  |  905|      0|            last_added = vertex;                                                           \
  |  |  906|      0|        }                                                                                  \
  |  |  907|      0|    }
  ------------------
 1006|   102k|                VECTOR(*neis)[idx++] = n2;
  ------------------
  |  |   65|   102k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1007|   102k|            } else {
 1008|  64.1k|                i1++;
 1009|  64.1k|                i2++;
 1010|  64.1k|                DEDUPLICATE_IF_NEEDED(n1, 2);
  ------------------
  |  |  891|  64.1k|    if (should_filter_duplicates) {                                                        \
  |  |  ------------------
  |  |  |  Branch (891:9): [True: 0, False: 64.1k]
  |  |  ------------------
  |  |  892|      0|        if (                                                                               \
  |  |  893|      0|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  |  |  ------------------
  |  |  |  Branch (893:14): [True: 0, False: 0]
  |  |  |  Branch (893:42): [True: 0, False: 0]
  |  |  ------------------
  |  |  894|      0|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  |  |  ------------------
  |  |  |  Branch (894:14): [True: 0, False: 0]
  |  |  |  Branch (894:44): [True: 0, False: 0]
  |  |  |  Branch (894:63): [True: 0, False: 0]
  |  |  ------------------
  |  |  895|      0|        ) {                                                                                \
  |  |  896|      0|            length -= n;                                                                   \
  |  |  897|      0|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  |  |  ------------------
  |  |  |  Branch (897:17): [True: 0, False: 0]
  |  |  ------------------
  |  |  898|      0|                last_added = -1;                                                           \
  |  |  899|      0|            }                                                                              \
  |  |  900|      0|            continue;                                                                      \
  |  |  901|      0|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  |  |  ------------------
  |  |  |  Branch (901:20): [True: 0, False: 0]
  |  |  |  Branch (901:54): [True: 0, False: 0]
  |  |  ------------------
  |  |  902|      0|            length -= n;                                                                   \
  |  |  903|      0|            continue;                                                                      \
  |  |  904|      0|        } else {                                                                           \
  |  |  905|      0|            last_added = vertex;                                                           \
  |  |  906|      0|        }                                                                                  \
  |  |  907|      0|    }
  ------------------
 1011|  64.1k|                VECTOR(*neis)[idx++] = n1;
  ------------------
  |  |   65|  64.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1012|  64.1k|                if (should_filter_duplicates && ((loops == IGRAPH_LOOPS_ONCE && n1 == pnode && last_added == pnode) ||
  ------------------
  |  Branch (1012:21): [True: 0, False: 64.1k]
  |  Branch (1012:51): [True: 0, False: 0]
  |  Branch (1012:81): [True: 0, False: 0]
  |  Branch (1012:96): [True: 0, False: 0]
  ------------------
 1013|      0|                        (multiple == IGRAPH_NO_MULTIPLE))) {
  ------------------
  |  Branch (1013:25): [True: 0, False: 0]
  ------------------
 1014|      0|                    length--;
 1015|      0|                    if (loops == IGRAPH_LOOPS_ONCE) {
  ------------------
  |  Branch (1015:25): [True: 0, False: 0]
  ------------------
 1016|      0|                        last_added = -1;
 1017|      0|                    }
 1018|      0|                    continue;
 1019|      0|                }
 1020|  64.1k|                VECTOR(*neis)[idx++] = n2;
  ------------------
  |  |   65|  64.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1021|  64.1k|            }
 1022|   272k|        }
 1023|       |
 1024|  1.65M|        while (i1 < j1) {
  ------------------
  |  Branch (1024:16): [True: 140k, False: 1.51M]
  ------------------
 1025|   140k|            eid1 = VECTOR(graph->oi)[i1++];
  ------------------
  |  |   65|   140k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1026|   140k|            igraph_integer_t to = VECTOR(graph->to)[eid1];
  ------------------
  |  |   65|   140k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1027|   140k|            DEDUPLICATE_IF_NEEDED(to, 1);
  ------------------
  |  |  891|   140k|    if (should_filter_duplicates) {                                                        \
  |  |  ------------------
  |  |  |  Branch (891:9): [True: 0, False: 140k]
  |  |  ------------------
  |  |  892|      0|        if (                                                                               \
  |  |  893|      0|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  |  |  ------------------
  |  |  |  Branch (893:14): [True: 0, False: 0]
  |  |  |  Branch (893:42): [True: 0, False: 0]
  |  |  ------------------
  |  |  894|      0|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  |  |  ------------------
  |  |  |  Branch (894:14): [True: 0, False: 0]
  |  |  |  Branch (894:44): [True: 0, False: 0]
  |  |  |  Branch (894:63): [True: 0, False: 0]
  |  |  ------------------
  |  |  895|      0|        ) {                                                                                \
  |  |  896|      0|            length -= n;                                                                   \
  |  |  897|      0|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  |  |  ------------------
  |  |  |  Branch (897:17): [True: 0, False: 0]
  |  |  ------------------
  |  |  898|      0|                last_added = -1;                                                           \
  |  |  899|      0|            }                                                                              \
  |  |  900|      0|            continue;                                                                      \
  |  |  901|      0|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  |  |  ------------------
  |  |  |  Branch (901:20): [True: 0, False: 0]
  |  |  |  Branch (901:54): [True: 0, False: 0]
  |  |  ------------------
  |  |  902|      0|            length -= n;                                                                   \
  |  |  903|      0|            continue;                                                                      \
  |  |  904|      0|        } else {                                                                           \
  |  |  905|      0|            last_added = vertex;                                                           \
  |  |  906|      0|        }                                                                                  \
  |  |  907|      0|    }
  ------------------
 1028|   140k|            VECTOR(*neis)[idx++] = to;
  ------------------
  |  |   65|   140k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1029|   140k|        }
 1030|       |
 1031|  1.65M|        while (i2 < j2) {
  ------------------
  |  Branch (1031:16): [True: 142k, False: 1.51M]
  ------------------
 1032|   142k|            eid2 = VECTOR(graph->ii)[i2++];
  ------------------
  |  |   65|   142k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1033|   142k|            igraph_integer_t from = VECTOR(graph->from)[eid2];
  ------------------
  |  |   65|   142k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1034|   142k|            DEDUPLICATE_IF_NEEDED(from, 1);
  ------------------
  |  |  891|   142k|    if (should_filter_duplicates) {                                                        \
  |  |  ------------------
  |  |  |  Branch (891:9): [True: 0, False: 142k]
  |  |  ------------------
  |  |  892|      0|        if (                                                                               \
  |  |  893|      0|            (loops == IGRAPH_NO_LOOPS && vertex == pnode) ||                               \
  |  |  ------------------
  |  |  |  Branch (893:14): [True: 0, False: 0]
  |  |  |  Branch (893:42): [True: 0, False: 0]
  |  |  ------------------
  |  |  894|      0|            (loops == IGRAPH_LOOPS_ONCE && vertex == pnode && last_added == pnode)         \
  |  |  ------------------
  |  |  |  Branch (894:14): [True: 0, False: 0]
  |  |  |  Branch (894:44): [True: 0, False: 0]
  |  |  |  Branch (894:63): [True: 0, False: 0]
  |  |  ------------------
  |  |  895|      0|        ) {                                                                                \
  |  |  896|      0|            length -= n;                                                                   \
  |  |  897|      0|            if (loops == IGRAPH_LOOPS_ONCE) {                                              \
  |  |  ------------------
  |  |  |  Branch (897:17): [True: 0, False: 0]
  |  |  ------------------
  |  |  898|      0|                last_added = -1;                                                           \
  |  |  899|      0|            }                                                                              \
  |  |  900|      0|            continue;                                                                      \
  |  |  901|      0|        } else if (multiple == IGRAPH_NO_MULTIPLE && vertex == last_added) {               \
  |  |  ------------------
  |  |  |  Branch (901:20): [True: 0, False: 0]
  |  |  |  Branch (901:54): [True: 0, False: 0]
  |  |  ------------------
  |  |  902|      0|            length -= n;                                                                   \
  |  |  903|      0|            continue;                                                                      \
  |  |  904|      0|        } else {                                                                           \
  |  |  905|      0|            last_added = vertex;                                                           \
  |  |  906|      0|        }                                                                                  \
  |  |  907|      0|    }
  ------------------
 1035|   142k|            VECTOR(*neis)[idx++] = from;
  ------------------
  |  |   65|   142k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1036|   142k|        }
 1037|       |
 1038|  1.51M|    }
 1039|  4.87M|    IGRAPH_CHECK(igraph_vector_int_resize(neis, length));
  ------------------
  |  |  648|  4.87M|    do { \
  |  |  649|  4.87M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  4.87M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  4.87M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 4.87M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  4.87M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1040|       |
 1041|  4.87M|    return IGRAPH_SUCCESS;
 1042|  4.87M|#undef DEDUPLICATE_IF_NEEDED
 1043|  4.87M|}
igraph_is_directed:
 1108|  23.8M|igraph_bool_t igraph_is_directed(const igraph_t *graph) {
 1109|  23.8M|    return graph->directed;
 1110|  23.8M|}
igraph_degree:
 1218|  30.0k|                  igraph_neimode_t mode, igraph_bool_t loops) {
 1219|       |
 1220|  30.0k|    igraph_integer_t nodes_to_calc;
 1221|  30.0k|    igraph_integer_t i, j;
 1222|  30.0k|    igraph_vit_t vit;
 1223|       |
 1224|  30.0k|    IGRAPH_CHECK(igraph_vit_create(graph, vids, &vit));
  ------------------
  |  |  648|  30.0k|    do { \
  |  |  649|  30.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  30.0k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  30.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 30.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  30.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1225|  30.0k|    IGRAPH_FINALLY(igraph_vit_destroy, &vit);
  ------------------
  |  |  591|  30.0k|    do { \
  |  |  592|  30.0k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  30.0k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  30.0k|         * incorrect destructor function with the pointer */ \
  |  |  595|  30.0k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  30.0k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  30.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1226|       |
 1227|  30.0k|    if (mode != IGRAPH_OUT && mode != IGRAPH_IN && mode != IGRAPH_ALL) {
  ------------------
  |  Branch (1227:9): [True: 20.6k, False: 9.37k]
  |  Branch (1227:31): [True: 16.9k, False: 3.71k]
  |  Branch (1227:52): [True: 0, False: 16.9k]
  ------------------
 1228|      0|        IGRAPH_ERROR("Invalid mode for degree calculation.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1229|      0|    }
 1230|       |
 1231|  30.0k|    if (! loops) {
  ------------------
  |  Branch (1231:9): [True: 0, False: 30.0k]
  ------------------
 1232|       |        /* If the graph is known not to have loops, we can use the faster
 1233|       |         * loops == true code path, which has O(1) complexity instead of of O(d). */
 1234|      0|        if (igraph_i_property_cache_has(graph, IGRAPH_PROP_HAS_LOOP) &&
  ------------------
  |  Branch (1234:13): [True: 0, False: 0]
  ------------------
 1235|      0|            !igraph_i_property_cache_get_bool(graph, IGRAPH_PROP_HAS_LOOP)) {
  ------------------
  |  Branch (1235:13): [True: 0, False: 0]
  ------------------
 1236|      0|            loops = true;
 1237|      0|        }
 1238|      0|    }
 1239|       |
 1240|  30.0k|    nodes_to_calc = IGRAPH_VIT_SIZE(vit);
  ------------------
  |  |  191|  30.0k|#define IGRAPH_VIT_SIZE(vit)  ((vit).end - (vit).start)
  ------------------
 1241|  30.0k|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (1241:9): [True: 3.76k, False: 26.2k]
  ------------------
 1242|  3.76k|        mode = IGRAPH_ALL;
 1243|  3.76k|    }
 1244|       |
 1245|  30.0k|    IGRAPH_CHECK(igraph_vector_int_resize(res, nodes_to_calc));
  ------------------
  |  |  648|  30.0k|    do { \
  |  |  649|  30.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  30.0k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  30.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 30.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  30.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1246|  30.0k|    igraph_vector_int_null(res);
 1247|       |
 1248|  30.0k|    if (loops) {
  ------------------
  |  Branch (1248:9): [True: 30.0k, False: 0]
  ------------------
 1249|  30.0k|        if (mode & IGRAPH_OUT) {
  ------------------
  |  Branch (1249:13): [True: 26.3k, False: 3.71k]
  ------------------
 1250|  26.3k|            for (IGRAPH_VIT_RESET(vit), i = 0;
  ------------------
  |  |  202|  26.3k|#define IGRAPH_VIT_RESET(vit) ((vit).pos = (vit).start)
  ------------------
 1251|  5.25M|                 !IGRAPH_VIT_END(vit);
  ------------------
  |  |  180|  5.25M|#define IGRAPH_VIT_END(vit)   ((vit).pos >= (vit).end)
  ------------------
  |  Branch (1251:18): [True: 5.22M, False: 26.3k]
  ------------------
 1252|  5.22M|                 IGRAPH_VIT_NEXT(vit), i++) {
  ------------------
  |  |  168|  5.22M|#define IGRAPH_VIT_NEXT(vit)  (++((vit).pos))
  ------------------
 1253|  5.22M|                igraph_integer_t vid = IGRAPH_VIT_GET(vit);
  ------------------
  |  |  215|  5.22M|    ((igraph_integer_t)(((vit).type == IGRAPH_VIT_RANGE) ? (vit).pos : \
  |  |  ------------------
  |  |  |  Branch (215:25): [True: 5.22M, False: 0]
  |  |  ------------------
  |  |  216|  5.22M|                        VECTOR(*(vit).vec)[(vit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1254|  5.22M|                VECTOR(*res)[i] += (VECTOR(graph->os)[vid + 1] - VECTOR(graph->os)[vid]);
  ------------------
  |  |   65|  5.22M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->os)[vid + 1] - VECTOR(graph->os)[vid]);
  ------------------
  |  |   65|  5.22M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->os)[vid + 1] - VECTOR(graph->os)[vid]);
  ------------------
  |  |   65|  5.22M|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1255|  5.22M|            }
 1256|  26.3k|        }
 1257|  30.0k|        if (mode & IGRAPH_IN) {
  ------------------
  |  Branch (1257:13): [True: 20.6k, False: 9.37k]
  ------------------
 1258|  20.6k|            for (IGRAPH_VIT_RESET(vit), i = 0;
  ------------------
  |  |  202|  20.6k|#define IGRAPH_VIT_RESET(vit) ((vit).pos = (vit).start)
  ------------------
 1259|  4.12M|                 !IGRAPH_VIT_END(vit);
  ------------------
  |  |  180|  4.12M|#define IGRAPH_VIT_END(vit)   ((vit).pos >= (vit).end)
  ------------------
  |  Branch (1259:18): [True: 4.10M, False: 20.6k]
  ------------------
 1260|  4.10M|                 IGRAPH_VIT_NEXT(vit), i++) {
  ------------------
  |  |  168|  4.10M|#define IGRAPH_VIT_NEXT(vit)  (++((vit).pos))
  ------------------
 1261|  4.10M|                igraph_integer_t vid = IGRAPH_VIT_GET(vit);
  ------------------
  |  |  215|  4.10M|    ((igraph_integer_t)(((vit).type == IGRAPH_VIT_RANGE) ? (vit).pos : \
  |  |  ------------------
  |  |  |  Branch (215:25): [True: 4.10M, False: 0]
  |  |  ------------------
  |  |  216|  4.10M|                        VECTOR(*(vit).vec)[(vit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1262|  4.10M|                VECTOR(*res)[i] += (VECTOR(graph->is)[vid + 1] - VECTOR(graph->is)[vid]);
  ------------------
  |  |   65|  4.10M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->is)[vid + 1] - VECTOR(graph->is)[vid]);
  ------------------
  |  |   65|  4.10M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->is)[vid + 1] - VECTOR(graph->is)[vid]);
  ------------------
  |  |   65|  4.10M|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1263|  4.10M|            }
 1264|  20.6k|        }
 1265|  30.0k|    } else if (igraph_vs_is_all(&vids)) { /* no loops, calculating degree for all vertices */
  ------------------
  |  Branch (1265:16): [True: 0, False: 0]
  ------------------
 1266|       |        // When calculating degree for all vertices, iterating over edges is faster
 1267|      0|        igraph_integer_t no_of_edges = igraph_ecount(graph);
 1268|       |
 1269|      0|        if (mode & IGRAPH_OUT) {
  ------------------
  |  Branch (1269:13): [True: 0, False: 0]
  ------------------
 1270|      0|            for (igraph_integer_t edge = 0; edge < no_of_edges; ++edge) {
  ------------------
  |  Branch (1270:45): [True: 0, False: 0]
  ------------------
 1271|      0|                igraph_integer_t from = IGRAPH_FROM(graph, edge);
  ------------------
  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1272|      0|                if (from != IGRAPH_TO(graph, edge)) {
  ------------------
  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  |  Branch (1272:21): [True: 0, False: 0]
  ------------------
 1273|      0|                    VECTOR(*res)[from]++;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1274|      0|                }
 1275|      0|            }
 1276|      0|        }
 1277|      0|        if (mode & IGRAPH_IN) {
  ------------------
  |  Branch (1277:13): [True: 0, False: 0]
  ------------------
 1278|      0|            for (igraph_integer_t edge = 0; edge < no_of_edges; ++edge) {
  ------------------
  |  Branch (1278:45): [True: 0, False: 0]
  ------------------
 1279|      0|                igraph_integer_t to = IGRAPH_TO(graph, edge);
  ------------------
  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1280|      0|                if (IGRAPH_FROM(graph, edge) != to) {
  ------------------
  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  |  Branch (1280:21): [True: 0, False: 0]
  ------------------
 1281|      0|                    VECTOR(*res)[to]++;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1282|      0|                }
 1283|      0|            }
 1284|      0|        }
 1285|      0|    } else { /* no loops */
 1286|      0|        if (mode & IGRAPH_OUT) {
  ------------------
  |  Branch (1286:13): [True: 0, False: 0]
  ------------------
 1287|      0|            for (IGRAPH_VIT_RESET(vit), i = 0;
  ------------------
  |  |  202|      0|#define IGRAPH_VIT_RESET(vit) ((vit).pos = (vit).start)
  ------------------
 1288|      0|                 !IGRAPH_VIT_END(vit);
  ------------------
  |  |  180|      0|#define IGRAPH_VIT_END(vit)   ((vit).pos >= (vit).end)
  ------------------
  |  Branch (1288:18): [True: 0, False: 0]
  ------------------
 1289|      0|                 IGRAPH_VIT_NEXT(vit), i++) {
  ------------------
  |  |  168|      0|#define IGRAPH_VIT_NEXT(vit)  (++((vit).pos))
  ------------------
 1290|      0|                igraph_integer_t vid = IGRAPH_VIT_GET(vit);
  ------------------
  |  |  215|      0|    ((igraph_integer_t)(((vit).type == IGRAPH_VIT_RANGE) ? (vit).pos : \
  |  |  ------------------
  |  |  |  Branch (215:25): [True: 0, False: 0]
  |  |  ------------------
  |  |  216|      0|                        VECTOR(*(vit).vec)[(vit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1291|      0|                VECTOR(*res)[i] += (VECTOR(graph->os)[vid + 1] - VECTOR(graph->os)[vid]);
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->os)[vid + 1] - VECTOR(graph->os)[vid]);
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->os)[vid + 1] - VECTOR(graph->os)[vid]);
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1292|      0|                for (j = VECTOR(graph->os)[vid];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1293|      0|                     j < VECTOR(graph->os)[vid + 1]; j++) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1293:22): [True: 0, False: 0]
  ------------------
 1294|      0|                    if (VECTOR(graph->to)[ VECTOR(graph->oi)[j] ] == vid) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  if (VECTOR(graph->to)[ VECTOR(graph->oi)[j] ] == vid) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1294:25): [True: 0, False: 0]
  ------------------
 1295|      0|                        VECTOR(*res)[i] -= 1;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1296|      0|                    }
 1297|      0|                }
 1298|      0|            }
 1299|      0|        }
 1300|      0|        if (mode & IGRAPH_IN) {
  ------------------
  |  Branch (1300:13): [True: 0, False: 0]
  ------------------
 1301|      0|            for (IGRAPH_VIT_RESET(vit), i = 0;
  ------------------
  |  |  202|      0|#define IGRAPH_VIT_RESET(vit) ((vit).pos = (vit).start)
  ------------------
 1302|      0|                 !IGRAPH_VIT_END(vit);
  ------------------
  |  |  180|      0|#define IGRAPH_VIT_END(vit)   ((vit).pos >= (vit).end)
  ------------------
  |  Branch (1302:18): [True: 0, False: 0]
  ------------------
 1303|      0|                 IGRAPH_VIT_NEXT(vit), i++) {
  ------------------
  |  |  168|      0|#define IGRAPH_VIT_NEXT(vit)  (++((vit).pos))
  ------------------
 1304|      0|                igraph_integer_t vid = IGRAPH_VIT_GET(vit);
  ------------------
  |  |  215|      0|    ((igraph_integer_t)(((vit).type == IGRAPH_VIT_RANGE) ? (vit).pos : \
  |  |  ------------------
  |  |  |  Branch (215:25): [True: 0, False: 0]
  |  |  ------------------
  |  |  216|      0|                        VECTOR(*(vit).vec)[(vit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1305|      0|                VECTOR(*res)[i] += (VECTOR(graph->is)[vid + 1] - VECTOR(graph->is)[vid]);
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->is)[vid + 1] - VECTOR(graph->is)[vid]);
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*res)[i] += (VECTOR(graph->is)[vid + 1] - VECTOR(graph->is)[vid]);
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1306|      0|                for (j = VECTOR(graph->is)[vid];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1307|      0|                     j < VECTOR(graph->is)[vid + 1]; j++) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1307:22): [True: 0, False: 0]
  ------------------
 1308|      0|                    if (VECTOR(graph->from)[ VECTOR(graph->ii)[j] ] == vid) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  if (VECTOR(graph->from)[ VECTOR(graph->ii)[j] ] == vid) {
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1308:25): [True: 0, False: 0]
  ------------------
 1309|      0|                        VECTOR(*res)[i] -= 1;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1310|      0|                    }
 1311|      0|                }
 1312|      0|            }
 1313|      0|        }
 1314|      0|    }  /* loops */
 1315|       |
 1316|  30.0k|    igraph_vit_destroy(&vit);
 1317|  30.0k|    IGRAPH_FINALLY_CLEAN(1);
 1318|       |
 1319|  30.0k|    return IGRAPH_SUCCESS;
 1320|  30.0k|}
igraph_incident:
 1667|  1.52M|        igraph_neimode_t mode) {
 1668|  1.52M|    if (!igraph_is_directed(graph) || mode == IGRAPH_ALL) {
  ------------------
  |  Branch (1668:9): [True: 11.8k, False: 1.51M]
  |  Branch (1668:39): [True: 759k, False: 755k]
  ------------------
 1669|   770k|        return igraph_i_incident(graph, eids, pnode, mode, IGRAPH_LOOPS_TWICE);
 1670|   770k|    } else {
 1671|   755k|        return igraph_i_incident(graph, eids, pnode, mode, IGRAPH_LOOPS_ONCE);
 1672|   755k|    }
 1673|  1.52M|}
igraph_i_incident:
 1676|  1.52M|        igraph_neimode_t mode, igraph_loops_t loops) {
 1677|  1.52M|    igraph_integer_t length = 0, idx = 0;
 1678|  1.52M|    igraph_integer_t i, j;
 1679|  1.52M|    igraph_integer_t node = pnode;
 1680|  1.52M|    igraph_bool_t directed = igraph_is_directed(graph);
 1681|       |
 1682|  1.52M|    if (node < 0 || node > igraph_vcount(graph) - 1) {
  ------------------
  |  Branch (1682:9): [True: 0, False: 1.52M]
  |  Branch (1682:21): [True: 0, False: 1.52M]
  ------------------
 1683|      0|        IGRAPH_ERROR("Given vertex is not in the graph.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1684|      0|    }
 1685|  1.52M|    if (mode != IGRAPH_OUT && mode != IGRAPH_IN &&
  ------------------
  |  Branch (1685:9): [True: 1.14M, False: 382k]
  |  Branch (1685:31): [True: 770k, False: 373k]
  ------------------
 1686|  1.52M|        mode != IGRAPH_ALL) {
  ------------------
  |  Branch (1686:9): [True: 0, False: 770k]
  ------------------
 1687|      0|        IGRAPH_ERROR("Mode should be either IGRAPH_OUT, IGRAPH_IN or IGRAPH_ALL.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1688|      0|    }
 1689|       |
 1690|  1.52M|    if (!directed) {
  ------------------
  |  Branch (1690:9): [True: 11.8k, False: 1.51M]
  ------------------
 1691|  11.8k|        mode = IGRAPH_ALL;
 1692|  11.8k|    }
 1693|       |
 1694|  1.52M|    if (mode != IGRAPH_ALL && loops == IGRAPH_LOOPS_TWICE) {
  ------------------
  |  Branch (1694:9): [True: 755k, False: 770k]
  |  Branch (1694:31): [True: 0, False: 755k]
  ------------------
 1695|      0|        IGRAPH_ERROR("For a directed graph (with directions not ignored), "
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1696|      0|                     "IGRAPH_LOOPS_TWICE does not make sense.", IGRAPH_EINVAL);
 1697|      0|    }
 1698|       |
 1699|       |    /* Calculate needed space first & allocate it */
 1700|       |    /* Note that 'mode' is treated as a bit field here; it's okay because
 1701|       |     * IGRAPH_ALL = IGRAPH_IN | IGRAPH_OUT, bit-wise */
 1702|  1.52M|    if (mode & IGRAPH_OUT) {
  ------------------
  |  Branch (1702:9): [True: 1.15M, False: 373k]
  ------------------
 1703|  1.15M|        length += (VECTOR(graph->os)[node + 1] - VECTOR(graph->os)[node]);
  ------------------
  |  |   65|  1.15M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      length += (VECTOR(graph->os)[node + 1] - VECTOR(graph->os)[node]);
  ------------------
  |  |   65|  1.15M|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1704|  1.15M|    }
 1705|  1.52M|    if (mode & IGRAPH_IN) {
  ------------------
  |  Branch (1705:9): [True: 1.14M, False: 382k]
  ------------------
 1706|  1.14M|        length += (VECTOR(graph->is)[node + 1] - VECTOR(graph->is)[node]);
  ------------------
  |  |   65|  1.14M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      length += (VECTOR(graph->is)[node + 1] - VECTOR(graph->is)[node]);
  ------------------
  |  |   65|  1.14M|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1707|  1.14M|    }
 1708|       |
 1709|  1.52M|    IGRAPH_CHECK(igraph_vector_int_resize(eids, length));
  ------------------
  |  |  648|  1.52M|    do { \
  |  |  649|  1.52M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.52M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.52M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.52M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.52M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1710|       |
 1711|       |    /* The loops below produce an ordering what is consistent with the
 1712|       |     * ordering returned by igraph_neighbors(), and this should be preserved.
 1713|       |     * We are dealing with two sorted lists; one for the successors and one
 1714|       |     * for the predecessors. If we have requested only one of them, we have
 1715|       |     * an easy job. If we have requested both, we need to merge the two lists
 1716|       |     * to ensure that the output is sorted by the vertex IDs of the "other"
 1717|       |     * endpoint of the affected edges */
 1718|  1.52M|    if (!directed || mode != IGRAPH_ALL) {
  ------------------
  |  Branch (1718:9): [True: 11.8k, False: 1.51M]
  |  Branch (1718:22): [True: 755k, False: 759k]
  ------------------
 1719|       |        /* We did not ask for both directions; this is the easy case */
 1720|       |
 1721|   767k|        if (mode & IGRAPH_OUT) {
  ------------------
  |  Branch (1721:13): [True: 394k, False: 373k]
  ------------------
 1722|   394k|            j = VECTOR(graph->os)[node + 1];
  ------------------
  |  |   65|   394k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1723|   496k|            for (i = VECTOR(graph->os)[node]; i < j; i++) {
  ------------------
  |  |   65|   394k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1723:47): [True: 102k, False: 394k]
  ------------------
 1724|   102k|                igraph_integer_t edge = VECTOR(graph->oi)[i];
  ------------------
  |  |   65|   102k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1725|   102k|                igraph_integer_t other = VECTOR(graph->to)[edge];
  ------------------
  |  |   65|   102k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1726|   102k|                if (loops == IGRAPH_NO_LOOPS && other == pnode) {
  ------------------
  |  Branch (1726:21): [True: 0, False: 102k]
  |  Branch (1726:49): [True: 0, False: 0]
  ------------------
 1727|      0|                    length--;
 1728|   102k|                } else {
 1729|   102k|                    VECTOR(*eids)[idx++] = edge;
  ------------------
  |  |   65|   102k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1730|   102k|                }
 1731|   102k|            }
 1732|   394k|        }
 1733|       |
 1734|   767k|        if (mode & IGRAPH_IN) {
  ------------------
  |  Branch (1734:13): [True: 385k, False: 382k]
  ------------------
 1735|   385k|            j = VECTOR(graph->is)[node + 1];
  ------------------
  |  |   65|   385k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1736|   472k|            for (i = VECTOR(graph->is)[node]; i < j; i++) {
  ------------------
  |  |   65|   385k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (1736:47): [True: 87.6k, False: 385k]
  ------------------
 1737|  87.6k|                igraph_integer_t edge = VECTOR(graph->ii)[i];
  ------------------
  |  |   65|  87.6k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1738|  87.6k|                igraph_integer_t other = VECTOR(graph->from)[edge];
  ------------------
  |  |   65|  87.6k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1739|  87.6k|                if ((loops == IGRAPH_NO_LOOPS || (loops == IGRAPH_LOOPS_ONCE && !directed)) && other == pnode) {
  ------------------
  |  Branch (1739:22): [True: 0, False: 87.6k]
  |  Branch (1739:51): [True: 67.5k, False: 20.0k]
  |  Branch (1739:81): [True: 0, False: 67.5k]
  |  Branch (1739:96): [True: 0, False: 0]
  ------------------
 1740|      0|                    length--;
 1741|  87.6k|                } else {
 1742|  87.6k|                    VECTOR(*eids)[idx++] = edge;
  ------------------
  |  |   65|  87.6k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1743|  87.6k|                }
 1744|  87.6k|            }
 1745|   385k|        }
 1746|   767k|    } else {
 1747|       |        /* both in- and out- neighbors in a directed graph,
 1748|       |           we need to merge the two 'vectors' */
 1749|   759k|        igraph_integer_t j1 = VECTOR(graph->os)[node + 1];
  ------------------
  |  |   65|   759k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1750|   759k|        igraph_integer_t j2 = VECTOR(graph->is)[node + 1];
  ------------------
  |  |   65|   759k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1751|   759k|        igraph_integer_t i1 = VECTOR(graph->os)[node];
  ------------------
  |  |   65|   759k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1752|   759k|        igraph_integer_t i2 = VECTOR(graph->is)[node];
  ------------------
  |  |   65|   759k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1753|   759k|        igraph_integer_t eid1, eid2;
 1754|   759k|        igraph_integer_t n1, n2;
 1755|   759k|        igraph_bool_t seen_loop_edge = false;
 1756|       |
 1757|   910k|        while (i1 < j1 && i2 < j2) {
  ------------------
  |  Branch (1757:16): [True: 194k, False: 716k]
  |  Branch (1757:27): [True: 151k, False: 42.7k]
  ------------------
 1758|   151k|            eid1 = VECTOR(graph->oi)[i1];
  ------------------
  |  |   65|   151k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1759|   151k|            eid2 = VECTOR(graph->ii)[i2];
  ------------------
  |  |   65|   151k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1760|   151k|            n1 = VECTOR(graph->to)[eid1];
  ------------------
  |  |   65|   151k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1761|   151k|            n2 = VECTOR(graph->from)[eid2];
  ------------------
  |  |   65|   151k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1762|   151k|            if (n1 < n2) {
  ------------------
  |  Branch (1762:17): [True: 57.6k, False: 93.5k]
  ------------------
 1763|  57.6k|                i1++;
 1764|  57.6k|                VECTOR(*eids)[idx++] = eid1;
  ------------------
  |  |   65|  57.6k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1765|  93.5k|            } else if (n1 > n2) {
  ------------------
  |  Branch (1765:24): [True: 56.4k, False: 37.1k]
  ------------------
 1766|  56.4k|                i2++;
 1767|  56.4k|                VECTOR(*eids)[idx++] = eid2;
  ------------------
  |  |   65|  56.4k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1768|  56.4k|            } else if (n1 != pnode) {
  ------------------
  |  Branch (1768:24): [True: 10.0k, False: 27.0k]
  ------------------
 1769|       |                /* multiple edge */
 1770|  10.0k|                i1++;
 1771|  10.0k|                i2++;
 1772|  10.0k|                VECTOR(*eids)[idx++] = eid1;
  ------------------
  |  |   65|  10.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1773|  10.0k|                VECTOR(*eids)[idx++] = eid2;
  ------------------
  |  |   65|  10.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1774|  27.0k|            } else {
 1775|       |                /* loop edge */
 1776|  27.0k|                i1++;
 1777|  27.0k|                i2++;
 1778|  27.0k|                if (loops == IGRAPH_NO_LOOPS) {
  ------------------
  |  Branch (1778:21): [True: 0, False: 27.0k]
  ------------------
 1779|      0|                    length -= 2;
 1780|  27.0k|                } else if (loops == IGRAPH_LOOPS_ONCE) {
  ------------------
  |  Branch (1780:28): [True: 0, False: 27.0k]
  ------------------
 1781|      0|                    length--;
 1782|      0|                    if (!seen_loop_edge) {
  ------------------
  |  Branch (1782:25): [True: 0, False: 0]
  ------------------
 1783|      0|                        VECTOR(*eids)[idx++] = eid1;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1784|      0|                    } else {
 1785|      0|                        VECTOR(*eids)[idx++] = eid2;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1786|      0|                    }
 1787|      0|                    seen_loop_edge = !seen_loop_edge;
 1788|  27.0k|                } else {
 1789|  27.0k|                    VECTOR(*eids)[idx++] = eid1;
  ------------------
  |  |   65|  27.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1790|  27.0k|                    VECTOR(*eids)[idx++] = eid2;
  ------------------
  |  |   65|  27.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1791|  27.0k|                }
 1792|  27.0k|            }
 1793|   151k|        }
 1794|       |
 1795|   832k|        while (i1 < j1) {
  ------------------
  |  Branch (1795:16): [True: 73.7k, False: 759k]
  ------------------
 1796|  73.7k|            eid1 = VECTOR(graph->oi)[i1++];
  ------------------
  |  |   65|  73.7k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1797|  73.7k|            VECTOR(*eids)[idx++] = eid1;
  ------------------
  |  |   65|  73.7k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1798|  73.7k|        }
 1799|       |
 1800|   834k|        while (i2 < j2) {
  ------------------
  |  Branch (1800:16): [True: 75.2k, False: 759k]
  ------------------
 1801|  75.2k|            eid2 = VECTOR(graph->ii)[i2++];
  ------------------
  |  |   65|  75.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1802|  75.2k|            VECTOR(*eids)[idx++] = eid2;
  ------------------
  |  |   65|  75.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1803|  75.2k|        }
 1804|   759k|    }
 1805|  1.52M|    IGRAPH_CHECK(igraph_vector_int_resize(eids, length));
  ------------------
  |  |  648|  1.52M|    do { \
  |  |  649|  1.52M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.52M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.52M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.52M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.52M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1806|  1.52M|    return IGRAPH_SUCCESS;
 1807|  1.52M|#undef DEDUPLICATE_IF_NEEDED
 1808|  1.52M|}
type_indexededgelist.c:igraph_i_create_start_vectors:
 1051|  24.6k|        igraph_vector_int_t *iindex, igraph_integer_t nodes) {
 1052|       |
 1053|  24.6k|# define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
 1054|       |
 1055|  24.6k|    igraph_integer_t no_of_nodes;
 1056|  24.6k|    igraph_integer_t no_of_edges;
 1057|  24.6k|    igraph_integer_t i, j, idx;
 1058|       |
 1059|  24.6k|    no_of_nodes = nodes;
 1060|  24.6k|    no_of_edges = igraph_vector_int_size(el);
 1061|       |
 1062|       |    /* result */
 1063|       |
 1064|  24.6k|    IGRAPH_CHECK(igraph_vector_int_resize(res, nodes + 1));
  ------------------
  |  |  648|  24.6k|    do { \
  |  |  649|  24.6k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  24.6k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  24.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 24.6k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  24.6k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
 1065|       |
 1066|       |    /* create the index */
 1067|       |
 1068|  24.6k|    if (no_of_edges == 0) {
  ------------------
  |  Branch (1068:9): [True: 1.82k, False: 22.8k]
  ------------------
 1069|       |        /* empty graph */
 1070|  1.82k|        igraph_vector_int_null(res);
 1071|  22.8k|    } else {
 1072|  22.8k|        idx = -1;
 1073|   344k|        for (i = 0; i <= EDGE(0); i++) {
  ------------------
  |  | 1053|   344k|# define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|   344k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               # define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|   344k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  |  Branch (1073:21): [True: 321k, False: 22.8k]
  ------------------
 1074|   321k|            idx++; VECTOR(*res)[idx] = 0;
  ------------------
  |  |   65|   321k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1075|   321k|        }
 1076|  2.55M|        for (i = 1; i < no_of_edges; i++) {
  ------------------
  |  Branch (1076:21): [True: 2.53M, False: 22.8k]
  ------------------
 1077|  2.53M|            igraph_integer_t n = EDGE(i) - EDGE(VECTOR(*res)[idx]);
  ------------------
  |  | 1053|  2.53M|# define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|  2.53M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               # define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|  2.53M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
                          igraph_integer_t n = EDGE(i) - EDGE(VECTOR(*res)[idx]);
  ------------------
  |  | 1053|  2.53M|# define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|  2.53M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               # define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|  2.53M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1078|  5.22M|            for (j = 0; j < n; j++) {
  ------------------
  |  Branch (1078:25): [True: 2.69M, False: 2.53M]
  ------------------
 1079|  2.69M|                idx++; VECTOR(*res)[idx] = i;
  ------------------
  |  |   65|  2.69M|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1080|  2.69M|            }
 1081|  2.53M|        }
 1082|  22.8k|        j = EDGE(VECTOR(*res)[idx]);
  ------------------
  |  | 1053|  22.8k|# define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|  22.8k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               # define EDGE(i) (VECTOR(*el)[ VECTOR(*iindex)[(i)] ])
  |  |  ------------------
  |  |  |  |   65|  22.8k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
 1083|   543k|        for (i = 0; i < no_of_nodes - j; i++) {
  ------------------
  |  Branch (1083:21): [True: 521k, False: 22.8k]
  ------------------
 1084|   521k|            idx++; VECTOR(*res)[idx] = no_of_edges;
  ------------------
  |  |   65|   521k|#define VECTOR(v) ((v).stor_begin)
  ------------------
 1085|   521k|        }
 1086|  22.8k|    }
 1087|       |
 1088|       |    /* clean */
 1089|       |
 1090|  24.6k|# undef EDGE
 1091|  24.6k|    return IGRAPH_SUCCESS;
 1092|  24.6k|}

igraph_qsort:
  264|   677k|{
  265|   677k|	local_qsort(a, n, es, cmp, NULL);
  266|   677k|}
qsort.c:local_qsort:
  121|   888k|{
  122|   888k|	char *pa, *pb, *pc, *pd, *pl, *pm, *pn;
  123|   888k|	size_t d1, d2;
  124|   888k|	int cmp_result;
  125|   888k|	int swap_cnt;
  126|       |
  127|       |    /* if there are less than 2 elements, then sorting is not needed */
  128|   888k|    if (IGRAPH_UNLIKELY(n < 2))
  ------------------
  |  |  604|   888k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  ------------------
  |  |  |  Branch (604:32): [True: 94.3k, False: 794k]
  |  |  ------------------
  ------------------
  129|  94.3k|        return;
  130|  1.04M|loop:
  131|  1.04M|	swap_cnt = 0;
  132|  1.04M|	if (n < 7) {
  ------------------
  |  Branch (132:6): [True: 762k, False: 280k]
  ------------------
  133|  2.44M|		for (pm = (char *)a + es; pm < (char *)a + n * es; pm += es)
  ------------------
  |  Branch (133:29): [True: 1.68M, False: 762k]
  ------------------
  134|  1.68M|			for (pl = pm;
  135|  3.21M|			     pl > (char *)a && CMP(thunk, pl - es, pl) > 0;
  ------------------
  |  |   95|  2.74M|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
  |  Branch (135:9): [True: 2.74M, False: 466k]
  |  Branch (135:27): [True: 1.52M, False: 1.21M]
  ------------------
  136|  1.68M|			     pl -= es)
  137|  1.52M|				swapfunc(pl, pl - es, es);
  138|   762k|		return;
  139|   762k|	}
  140|   280k|	pm = (char *)a + (n / 2) * es;
  141|   280k|	if (n > 7) {
  ------------------
  |  Branch (141:6): [True: 227k, False: 52.5k]
  ------------------
  142|   227k|		pl = a;
  143|   227k|		pn = (char *)a + (n - 1) * es;
  144|   227k|		if (n > 40) {
  ------------------
  |  Branch (144:7): [True: 19.8k, False: 207k]
  ------------------
  145|  19.8k|			size_t d = (n / 8) * es;
  146|       |
  147|  19.8k|			pl = med3(pl, pl + d, pl + 2 * d, cmp, thunk);
  148|  19.8k|			pm = med3(pm - d, pm, pm + d, cmp, thunk);
  149|  19.8k|			pn = med3(pn - 2 * d, pn - d, pn, cmp, thunk);
  150|  19.8k|		}
  151|   227k|		pm = med3(pl, pm, pn, cmp, thunk);
  152|   227k|	}
  153|   280k|	swapfunc(a, pm, es);
  154|   280k|	pa = pb = (char *)a + es;
  155|       |
  156|   280k|	pc = pd = (char *)a + (n - 1) * es;
  157|  1.64M|	for (;;) {
  158|  3.98M|		while (pb <= pc && (cmp_result = CMP(thunk, pb, a)) <= 0) {
  ------------------
  |  |   95|  3.84M|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
  |  Branch (158:10): [True: 3.84M, False: 136k]
  |  Branch (158:22): [True: 2.34M, False: 1.50M]
  ------------------
  159|  2.34M|			if (cmp_result == 0) {
  ------------------
  |  Branch (159:8): [True: 355k, False: 1.98M]
  ------------------
  160|   355k|				swap_cnt = 1;
  161|   355k|				swapfunc(pa, pb, es);
  162|   355k|				pa += es;
  163|   355k|			}
  164|  2.34M|			pb += es;
  165|  2.34M|		}
  166|  3.86M|		while (pb <= pc && (cmp_result = CMP(thunk, pc, a)) >= 0) {
  ------------------
  |  |   95|  3.58M|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
  |  Branch (166:10): [True: 3.58M, False: 280k]
  |  Branch (166:22): [True: 2.22M, False: 1.36M]
  ------------------
  167|  2.22M|			if (cmp_result == 0) {
  ------------------
  |  Branch (167:8): [True: 198k, False: 2.02M]
  ------------------
  168|   198k|				swap_cnt = 1;
  169|   198k|				swapfunc(pc, pd, es);
  170|   198k|				pd -= es;
  171|   198k|			}
  172|  2.22M|			pc -= es;
  173|  2.22M|		}
  174|  1.64M|		if (pb > pc)
  ------------------
  |  Branch (174:7): [True: 280k, False: 1.36M]
  ------------------
  175|   280k|			break;
  176|  1.36M|		swapfunc(pb, pc, es);
  177|  1.36M|		swap_cnt = 1;
  178|  1.36M|		pb += es;
  179|  1.36M|		pc -= es;
  180|  1.36M|	}
  181|   280k|	if (swap_cnt == 0) {  /* Switch to insertion sort */
  ------------------
  |  Branch (181:6): [True: 26.1k, False: 254k]
  ------------------
  182|   219k|		for (pm = (char *)a + es; pm < (char *)a + n * es; pm += es)
  ------------------
  |  Branch (182:29): [True: 193k, False: 26.1k]
  ------------------
  183|   193k|			for (pl = pm;
  184|   571k|			     pl > (char *)a && CMP(thunk, pl - es, pl) > 0;
  ------------------
  |  |   95|   524k|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
  |  Branch (184:9): [True: 524k, False: 47.7k]
  |  Branch (184:27): [True: 378k, False: 145k]
  ------------------
  185|   378k|			     pl -= es)
  186|   378k|				swapfunc(pl, pl - es, es);
  187|  26.1k|		return;
  188|  26.1k|	}
  189|       |
  190|   254k|	pn = (char *)a + n * es;
  191|   254k|	d1 = MIN(pa - (char *)a, pb - pa);
  ------------------
  |  |   69|   254k|#define	MIN(a, b)	((a) < (b) ? a : b)
  |  |  ------------------
  |  |  |  Branch (69:20): [True: 222k, False: 32.2k]
  |  |  ------------------
  ------------------
  192|   254k|	vecswap(a, pb - d1, d1);
  ------------------
  |  |   88|   254k|	if ((n) > 0) swapfunc(a, b, n)
  |  |  ------------------
  |  |  |  Branch (88:6): [True: 244k, False: 9.85k]
  |  |  ------------------
  ------------------
  193|       |	/*
  194|       |	 * Cast es to preserve signedness of right-hand side of MIN()
  195|       |	 * expression, to avoid sign ambiguity in the implied comparison.  es
  196|       |	 * is safely within [0, SSIZE_MAX].
  197|       |	 */
  198|   254k|	d1 = MIN(pd - pc, pn - pd - (ptrdiff_t)es);
  ------------------
  |  |   69|   254k|#define	MIN(a, b)	((a) < (b) ? a : b)
  |  |  ------------------
  |  |  |  Branch (69:20): [True: 2.09k, False: 252k]
  |  |  ------------------
  ------------------
  199|   254k|	vecswap(pb, pn - d1, d1);
  ------------------
  |  |   88|   254k|	if ((n) > 0) swapfunc(a, b, n)
  |  |  ------------------
  |  |  |  Branch (88:6): [True: 22.1k, False: 232k]
  |  |  ------------------
  ------------------
  200|       |
  201|   254k|	d1 = pb - pa;
  202|   254k|	d2 = pd - pc;
  203|   254k|	if (d1 <= d2) {
  ------------------
  |  Branch (203:6): [True: 147k, False: 107k]
  ------------------
  204|       |		/* Recurse on left partition, then iterate on right partition */
  205|   147k|		if (d1 > es) {
  ------------------
  |  Branch (205:7): [True: 119k, False: 27.6k]
  ------------------
  206|   119k|			local_qsort(a, d1 / es, es, cmp, thunk);
  207|   119k|		}
  208|   147k|		if (d2 > es) {
  ------------------
  |  Branch (208:7): [True: 141k, False: 5.17k]
  ------------------
  209|       |			/* Iterate rather than recurse to save stack space */
  210|       |			/* qsort(pn - d2, d2 / es, es, cmp); */
  211|   141k|			a = pn - d2;
  212|   141k|			n = d2 / es;
  213|   141k|			goto loop;
  214|   141k|		}
  215|   147k|	} else {
  216|       |		/* Recurse on right partition, then iterate on left partition */
  217|   107k|		if (d2 > es) {
  ------------------
  |  Branch (217:7): [True: 91.4k, False: 15.8k]
  ------------------
  218|  91.4k|			local_qsort(pn - d2, d2 / es, es, cmp, thunk);
  219|  91.4k|		}
  220|   107k|		if (d1 > es) {
  ------------------
  |  Branch (220:7): [True: 106k, False: 383]
  ------------------
  221|       |			/* Iterate rather than recurse to save stack space */
  222|       |			/* qsort(a, d1 / es, es, cmp); */
  223|   106k|			n = d1 / es;
  224|   106k|			goto loop;
  225|   106k|		}
  226|   107k|	}
  227|   254k|}
qsort.c:swapfunc:
   77|  4.36M|{
   78|  4.36M|	char t;
   79|       |
   80|  66.7M|	do {
   81|  66.7M|		t = *a;
   82|  66.7M|		*a++ = *b;
   83|  66.7M|		*b++ = t;
   84|  66.7M|	} while (--es > 0);
  ------------------
  |  Branch (84:11): [True: 62.4M, False: 4.36M]
  ------------------
   85|  4.36M|}
qsort.c:med3:
  104|   287k|{
  105|   287k|	return CMP(thunk, a, b) < 0 ?
  ------------------
  |  |   95|   287k|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
  |  Branch (105:9): [True: 137k, False: 150k]
  ------------------
  106|   137k|	       (CMP(thunk, b, c) < 0 ? b : (CMP(thunk, a, c) < 0 ? c : a ))
  ------------------
  |  |   95|   137k|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
              	       (CMP(thunk, b, c) < 0 ? b : (CMP(thunk, a, c) < 0 ? c : a ))
  ------------------
  |  |   95|  89.2k|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
  |  Branch (106:10): [True: 47.7k, False: 89.2k]
  |  Branch (106:38): [True: 46.5k, False: 42.7k]
  ------------------
  107|   287k|	      :(CMP(thunk, b, c) > 0 ? b : (CMP(thunk, a, c) < 0 ? a : c ));
  ------------------
  |  |   95|   150k|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
              	      :(CMP(thunk, b, c) > 0 ? b : (CMP(thunk, a, c) < 0 ? a : c ));
  ------------------
  |  |   95|   108k|#define	CMP(t, x, y) (cmp((x), (y)))
  ------------------
  |  Branch (107:10): [True: 42.3k, False: 108k]
  |  Branch (107:38): [True: 47.1k, False: 60.8k]
  ------------------
  108|   287k|}

igraph_get_edgelist:
  307|  1.88k|igraph_error_t igraph_get_edgelist(const igraph_t *graph, igraph_vector_int_t *res, igraph_bool_t bycol) {
  308|       |
  309|  1.88k|    igraph_eit_t edgeit;
  310|  1.88k|    igraph_integer_t no_of_edges = igraph_ecount(graph);
  311|  1.88k|    igraph_integer_t vptr = 0;
  312|  1.88k|    igraph_integer_t from, to;
  313|       |
  314|  1.88k|    IGRAPH_CHECK(igraph_vector_int_resize(res, no_of_edges * 2));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  315|  1.88k|    IGRAPH_CHECK(igraph_eit_create(graph, igraph_ess_all(IGRAPH_EDGEORDER_ID),
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  316|  1.88k|                                   &edgeit));
  317|  1.88k|    IGRAPH_FINALLY(igraph_eit_destroy, &edgeit);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  318|       |
  319|  1.88k|    if (bycol) {
  ------------------
  |  Branch (319:9): [True: 0, False: 1.88k]
  ------------------
  320|      0|        while (!IGRAPH_EIT_END(edgeit)) {
  ------------------
  |  |  370|      0|#define IGRAPH_EIT_END(eit)   ((eit).pos >= (eit).end)
  ------------------
  |  Branch (320:16): [True: 0, False: 0]
  ------------------
  321|      0|            igraph_edge(graph, IGRAPH_EIT_GET(edgeit), &from, &to);
  ------------------
  |  |  404|      0|    (igraph_integer_t)((((eit).type == IGRAPH_EIT_RANGE) ? (eit).pos : \
  |  |  ------------------
  |  |  |  Branch (404:25): [True: 0, False: 0]
  |  |  ------------------
  |  |  405|      0|                        VECTOR(*(eit).vec)[(eit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  322|      0|            VECTOR(*res)[vptr] = from;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  323|      0|            VECTOR(*res)[vptr + no_of_edges] = to;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  324|      0|            vptr++;
  325|      0|            IGRAPH_EIT_NEXT(edgeit);
  ------------------
  |  |  358|      0|#define IGRAPH_EIT_NEXT(eit) (++((eit).pos))
  ------------------
  326|      0|        }
  327|  1.88k|    } else {
  328|  69.4k|        while (!IGRAPH_EIT_END(edgeit)) {
  ------------------
  |  |  370|  69.4k|#define IGRAPH_EIT_END(eit)   ((eit).pos >= (eit).end)
  ------------------
  |  Branch (328:16): [True: 67.5k, False: 1.88k]
  ------------------
  329|  67.5k|            igraph_edge(graph, IGRAPH_EIT_GET(edgeit), &from, &to);
  ------------------
  |  |  404|  67.5k|    (igraph_integer_t)((((eit).type == IGRAPH_EIT_RANGE) ? (eit).pos : \
  |  |  ------------------
  |  |  |  Branch (404:25): [True: 67.5k, False: 0]
  |  |  ------------------
  |  |  405|  67.5k|                        VECTOR(*(eit).vec)[(eit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  330|  67.5k|            VECTOR(*res)[vptr++] = from;
  ------------------
  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  331|  67.5k|            VECTOR(*res)[vptr++] = to;
  ------------------
  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  332|  67.5k|            IGRAPH_EIT_NEXT(edgeit);
  ------------------
  |  |  358|  67.5k|#define IGRAPH_EIT_NEXT(eit) (++((eit).pos))
  ------------------
  333|  67.5k|        }
  334|  1.88k|    }
  335|       |
  336|  1.88k|    igraph_eit_destroy(&edgeit);
  337|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  338|  1.88k|    return IGRAPH_SUCCESS;
  339|  1.88k|}
igraph_to_undirected:
  512|  1.88k|                         const igraph_attribute_combination_t *edge_comb) {
  513|       |
  514|  1.88k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  515|  1.88k|    igraph_integer_t no_of_edges = igraph_ecount(graph);
  516|  1.88k|    igraph_vector_int_t edges;
  517|  1.88k|    igraph_t newgraph;
  518|  1.88k|    igraph_bool_t attr = edge_comb && igraph_has_attribute_table();
  ------------------
  |  Branch (518:26): [True: 0, False: 1.88k]
  |  Branch (518:39): [True: 0, False: 0]
  ------------------
  519|       |
  520|  1.88k|    if (mode != IGRAPH_TO_UNDIRECTED_EACH &&
  ------------------
  |  Branch (520:9): [True: 1.88k, False: 0]
  ------------------
  521|  1.88k|        mode != IGRAPH_TO_UNDIRECTED_COLLAPSE &&
  ------------------
  |  Branch (521:9): [True: 0, False: 1.88k]
  ------------------
  522|  1.88k|        mode != IGRAPH_TO_UNDIRECTED_MUTUAL) {
  ------------------
  |  Branch (522:9): [True: 0, False: 0]
  ------------------
  523|      0|        IGRAPH_ERROR("Cannot undirect graph, invalid mode", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  524|      0|    }
  525|       |
  526|  1.88k|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (526:9): [True: 0, False: 1.88k]
  ------------------
  527|      0|        return IGRAPH_SUCCESS;
  528|      0|    }
  529|       |
  530|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&edges, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  531|       |
  532|  1.88k|    if (mode == IGRAPH_TO_UNDIRECTED_EACH) {
  ------------------
  |  Branch (532:9): [True: 0, False: 1.88k]
  ------------------
  533|      0|        igraph_es_t es;
  534|      0|        igraph_eit_t eit;
  535|       |
  536|      0|        IGRAPH_CHECK(igraph_vector_int_reserve(&edges, no_of_edges * 2));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  537|      0|        IGRAPH_CHECK(igraph_es_all(&es, IGRAPH_EDGEORDER_ID));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  538|      0|        IGRAPH_FINALLY(igraph_es_destroy, &es);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  539|      0|        IGRAPH_CHECK(igraph_eit_create(graph, es, &eit));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  540|      0|        IGRAPH_FINALLY(igraph_eit_destroy, &eit);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  541|       |
  542|      0|        while (!IGRAPH_EIT_END(eit)) {
  ------------------
  |  |  370|      0|#define IGRAPH_EIT_END(eit)   ((eit).pos >= (eit).end)
  ------------------
  |  Branch (542:16): [True: 0, False: 0]
  ------------------
  543|      0|            igraph_integer_t edge = IGRAPH_EIT_GET(eit);
  ------------------
  |  |  404|      0|    (igraph_integer_t)((((eit).type == IGRAPH_EIT_RANGE) ? (eit).pos : \
  |  |  ------------------
  |  |  |  Branch (404:25): [True: 0, False: 0]
  |  |  ------------------
  |  |  405|      0|                        VECTOR(*(eit).vec)[(eit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  544|      0|            IGRAPH_CHECK(igraph_vector_int_push_back(&edges, IGRAPH_FROM(graph, edge)));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  545|      0|            IGRAPH_CHECK(igraph_vector_int_push_back(&edges, IGRAPH_TO(graph, edge)));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  546|      0|            IGRAPH_EIT_NEXT(eit);
  ------------------
  |  |  358|      0|#define IGRAPH_EIT_NEXT(eit) (++((eit).pos))
  ------------------
  547|      0|        }
  548|       |
  549|      0|        igraph_eit_destroy(&eit);
  550|      0|        igraph_es_destroy(&es);
  551|      0|        IGRAPH_FINALLY_CLEAN(2);
  552|       |
  553|      0|        IGRAPH_CHECK(igraph_create(&newgraph, &edges,
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  554|      0|                                   no_of_nodes,
  555|      0|                                   IGRAPH_UNDIRECTED));
  556|      0|        IGRAPH_FINALLY(igraph_destroy, &newgraph);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  557|      0|        igraph_vector_int_destroy(&edges);
  558|      0|        IGRAPH_CHECK(igraph_i_attribute_copy(&newgraph, graph, true, true, true));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  559|      0|        IGRAPH_FINALLY_CLEAN(2);
  560|      0|        igraph_destroy(graph);
  561|      0|        *graph = newgraph;
  562|       |
  563|  1.88k|    } else if (mode == IGRAPH_TO_UNDIRECTED_COLLAPSE) {
  ------------------
  |  Branch (563:16): [True: 1.88k, False: 0]
  ------------------
  564|  1.88k|        igraph_vector_int_t inadj, outadj;
  565|  1.88k|        igraph_vector_int_t mergeinto;
  566|  1.88k|        igraph_integer_t actedge = 0;
  567|       |
  568|  1.88k|        if (attr) {
  ------------------
  |  Branch (568:13): [True: 0, False: 1.88k]
  ------------------
  569|      0|            IGRAPH_VECTOR_INT_INIT_FINALLY(&mergeinto, no_of_edges);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  570|      0|        }
  571|       |
  572|  1.88k|        IGRAPH_CHECK(igraph_vector_int_reserve(&edges, no_of_edges * 2));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  573|  1.88k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&inadj, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  574|  1.88k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&outadj, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  575|       |
  576|   375k|        for (igraph_integer_t i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (576:38): [True: 373k, False: 1.88k]
  ------------------
  577|   373k|            igraph_integer_t n_out, n_in;
  578|   373k|            igraph_integer_t p1 = -1, p2 = -1;
  579|   373k|            igraph_integer_t e1 = 0, e2 = 0, n1 = 0, n2 = 0, last;
  580|   373k|            IGRAPH_CHECK(igraph_incident(graph, &outadj, i, IGRAPH_OUT));
  ------------------
  |  |  648|   373k|    do { \
  |  |  649|   373k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   373k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   373k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 373k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   373k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  581|   373k|            IGRAPH_CHECK(igraph_incident(graph, &inadj, i, IGRAPH_IN));
  ------------------
  |  |  648|   373k|    do { \
  |  |  649|   373k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   373k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   373k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 373k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   373k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  582|   373k|            n_out = igraph_vector_int_size(&outadj);
  583|   373k|            n_in = igraph_vector_int_size(&inadj);
  584|       |
  585|   373k|#define STEPOUT() if ( (++p1) < n_out) {    \
  586|   373k|        e1 = VECTOR(outadj)[p1]; \
  587|   373k|        n1 = IGRAPH_TO(graph, e1);      \
  588|   373k|    }
  589|   373k|#define STEPIN()  if ( (++p2) < n_in) {         \
  590|   373k|        e2 = VECTOR(inadj )[p2]; \
  591|   373k|        n2 = IGRAPH_FROM(graph, e2);        \
  592|   373k|    }
  593|   373k|#define ADD_NEW_EDGE() { \
  594|   373k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, i)); \
  595|   373k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, last)); \
  596|   373k|}
  597|   373k|#define MERGE_INTO_CURRENT_EDGE(which) { \
  598|   373k|    if (attr) { \
  599|   373k|        VECTOR(mergeinto)[which] = actedge; \
  600|   373k|    } \
  601|   373k|}
  602|       |
  603|   373k|            STEPOUT();
  ------------------
  |  |  585|   373k|#define STEPOUT() if ( (++p1) < n_out) {    \
  |  |  ------------------
  |  |  |  Branch (585:24): [True: 30.5k, False: 342k]
  |  |  ------------------
  |  |  586|  30.5k|        e1 = VECTOR(outadj)[p1]; \
  |  |  ------------------
  |  |  |  |   65|  30.5k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  587|  30.5k|        n1 = IGRAPH_TO(graph, e1);      \
  |  |  ------------------
  |  |  |  |  126|  30.5k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  30.5k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  588|  30.5k|    }
  ------------------
  604|   373k|            STEPIN();
  ------------------
  |  |  589|   373k|#define STEPIN()  if ( (++p2) < n_in) {         \
  |  |  ------------------
  |  |  |  Branch (589:24): [True: 29.9k, False: 343k]
  |  |  ------------------
  |  |  590|  29.9k|        e2 = VECTOR(inadj )[p2]; \
  |  |  ------------------
  |  |  |  |   65|  29.9k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  591|  29.9k|        n2 = IGRAPH_FROM(graph, e2);        \
  |  |  ------------------
  |  |  |  |  113|  29.9k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  29.9k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  592|  29.9k|    }
  ------------------
  605|       |
  606|   389k|            while (p1 < n_out && n1 <= i && p2 < n_in && n2 <= i) {
  ------------------
  |  Branch (606:20): [True: 41.7k, False: 347k]
  |  Branch (606:34): [True: 28.5k, False: 13.1k]
  |  Branch (606:45): [True: 19.9k, False: 8.61k]
  |  Branch (606:58): [True: 16.0k, False: 3.89k]
  ------------------
  607|  16.0k|                last = (n1 <= n2) ? n1 : n2;
  ------------------
  |  Branch (607:24): [True: 10.0k, False: 6.04k]
  ------------------
  608|  16.0k|                ADD_NEW_EDGE();
  ------------------
  |  |  593|  16.0k|#define ADD_NEW_EDGE() { \
  |  |  594|  16.0k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, i)); \
  |  |  ------------------
  |  |  |  |  648|  16.0k|    do { \
  |  |  |  |  649|  16.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  16.0k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  16.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 16.0k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  16.0k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  595|  16.0k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, last)); \
  |  |  ------------------
  |  |  |  |  648|  16.0k|    do { \
  |  |  |  |  649|  16.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  16.0k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  16.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 16.0k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  16.0k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  596|  16.0k|}
  ------------------
  609|  37.9k|                while (p1 < n_out && last == n1) {
  ------------------
  |  Branch (609:24): [True: 33.1k, False: 4.83k]
  |  Branch (609:38): [True: 21.9k, False: 11.2k]
  ------------------
  610|  21.9k|                    MERGE_INTO_CURRENT_EDGE(e1);
  ------------------
  |  |  597|  21.9k|#define MERGE_INTO_CURRENT_EDGE(which) { \
  |  |  598|  21.9k|    if (attr) { \
  |  |  ------------------
  |  |  |  Branch (598:9): [True: 0, False: 21.9k]
  |  |  ------------------
  |  |  599|      0|        VECTOR(mergeinto)[which] = actedge; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  600|      0|    } \
  |  |  601|  21.9k|}
  ------------------
  611|  21.9k|                    STEPOUT();
  ------------------
  |  |  585|  21.9k|#define STEPOUT() if ( (++p1) < n_out) {    \
  |  |  ------------------
  |  |  |  Branch (585:24): [True: 17.0k, False: 4.83k]
  |  |  ------------------
  |  |  586|  17.0k|        e1 = VECTOR(outadj)[p1]; \
  |  |  ------------------
  |  |  |  |   65|  17.0k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  587|  17.0k|        n1 = IGRAPH_TO(graph, e1);      \
  |  |  ------------------
  |  |  |  |  126|  17.0k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  17.0k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  588|  17.0k|    }
  ------------------
  612|  21.9k|                }
  613|  38.2k|                while (p2 < n_in && last == n2) {
  ------------------
  |  Branch (613:24): [True: 33.5k, False: 4.73k]
  |  Branch (613:37): [True: 22.2k, False: 11.3k]
  ------------------
  614|  22.2k|                    MERGE_INTO_CURRENT_EDGE(e2);
  ------------------
  |  |  597|  22.2k|#define MERGE_INTO_CURRENT_EDGE(which) { \
  |  |  598|  22.2k|    if (attr) { \
  |  |  ------------------
  |  |  |  Branch (598:9): [True: 0, False: 22.2k]
  |  |  ------------------
  |  |  599|      0|        VECTOR(mergeinto)[which] = actedge; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  600|      0|    } \
  |  |  601|  22.2k|}
  ------------------
  615|  22.2k|                    STEPIN();
  ------------------
  |  |  589|  22.2k|#define STEPIN()  if ( (++p2) < n_in) {         \
  |  |  ------------------
  |  |  |  Branch (589:24): [True: 17.4k, False: 4.73k]
  |  |  ------------------
  |  |  590|  17.4k|        e2 = VECTOR(inadj )[p2]; \
  |  |  ------------------
  |  |  |  |   65|  17.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  591|  17.4k|        n2 = IGRAPH_FROM(graph, e2);        \
  |  |  ------------------
  |  |  |  |  113|  17.4k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  17.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  592|  17.4k|    }
  ------------------
  616|  22.2k|                }
  617|  16.0k|                actedge++;
  618|  16.0k|            }
  619|       |
  620|   387k|            while (p1 < n_out && n1 <= i) {
  ------------------
  |  Branch (620:20): [True: 29.0k, False: 358k]
  |  Branch (620:34): [True: 14.1k, False: 14.8k]
  ------------------
  621|  14.1k|                last = n1;
  622|  14.1k|                ADD_NEW_EDGE();
  ------------------
  |  |  593|  14.1k|#define ADD_NEW_EDGE() { \
  |  |  594|  14.1k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, i)); \
  |  |  ------------------
  |  |  |  |  648|  14.1k|    do { \
  |  |  |  |  649|  14.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  14.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  14.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.1k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  14.1k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  595|  14.1k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, last)); \
  |  |  ------------------
  |  |  |  |  648|  14.1k|    do { \
  |  |  |  |  649|  14.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  14.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  14.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.1k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  14.1k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  596|  14.1k|}
  ------------------
  623|  31.0k|                while (p1 < n_out && last == n1) {
  ------------------
  |  Branch (623:24): [True: 20.2k, False: 10.8k]
  |  Branch (623:38): [True: 16.8k, False: 3.34k]
  ------------------
  624|  16.8k|                    MERGE_INTO_CURRENT_EDGE(e1);
  ------------------
  |  |  597|  16.8k|#define MERGE_INTO_CURRENT_EDGE(which) { \
  |  |  598|  16.8k|    if (attr) { \
  |  |  ------------------
  |  |  |  Branch (598:9): [True: 0, False: 16.8k]
  |  |  ------------------
  |  |  599|      0|        VECTOR(mergeinto)[which] = actedge; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  600|      0|    } \
  |  |  601|  16.8k|}
  ------------------
  625|  16.8k|                    STEPOUT();
  ------------------
  |  |  585|  16.8k|#define STEPOUT() if ( (++p1) < n_out) {    \
  |  |  ------------------
  |  |  |  Branch (585:24): [True: 6.05k, False: 10.8k]
  |  |  ------------------
  |  |  586|  6.05k|        e1 = VECTOR(outadj)[p1]; \
  |  |  ------------------
  |  |  |  |   65|  6.05k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  587|  6.05k|        n1 = IGRAPH_TO(graph, e1);      \
  |  |  ------------------
  |  |  |  |  126|  6.05k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  6.05k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  588|  6.05k|    }
  ------------------
  626|  16.8k|                }
  627|  14.1k|                actedge++;
  628|  14.1k|            }
  629|       |
  630|   387k|            while (p2 < n_in && n2 <= i) {
  ------------------
  |  Branch (630:20): [True: 28.6k, False: 358k]
  |  Branch (630:33): [True: 13.7k, False: 14.8k]
  ------------------
  631|  13.7k|                last = n2;
  632|  13.7k|                ADD_NEW_EDGE();
  ------------------
  |  |  593|  13.7k|#define ADD_NEW_EDGE() { \
  |  |  594|  13.7k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, i)); \
  |  |  ------------------
  |  |  |  |  648|  13.7k|    do { \
  |  |  |  |  649|  13.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  13.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  13.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.7k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  13.7k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  595|  13.7k|    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, last)); \
  |  |  ------------------
  |  |  |  |  648|  13.7k|    do { \
  |  |  |  |  649|  13.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  13.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  13.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 13.7k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  13.7k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  596|  13.7k|}
  ------------------
  633|  30.3k|                while (p2 < n_in && last == n2) {
  ------------------
  |  Branch (633:24): [True: 19.9k, False: 10.3k]
  |  Branch (633:37): [True: 16.6k, False: 3.35k]
  ------------------
  634|  16.6k|                    MERGE_INTO_CURRENT_EDGE(e2);
  ------------------
  |  |  597|  16.6k|#define MERGE_INTO_CURRENT_EDGE(which) { \
  |  |  598|  16.6k|    if (attr) { \
  |  |  ------------------
  |  |  |  Branch (598:9): [True: 0, False: 16.6k]
  |  |  ------------------
  |  |  599|      0|        VECTOR(mergeinto)[which] = actedge; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  600|      0|    } \
  |  |  601|  16.6k|}
  ------------------
  635|  16.6k|                    STEPIN();
  ------------------
  |  |  589|  16.6k|#define STEPIN()  if ( (++p2) < n_in) {         \
  |  |  ------------------
  |  |  |  Branch (589:24): [True: 6.23k, False: 10.3k]
  |  |  ------------------
  |  |  590|  6.23k|        e2 = VECTOR(inadj )[p2]; \
  |  |  ------------------
  |  |  |  |   65|  6.23k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  591|  6.23k|        n2 = IGRAPH_FROM(graph, e2);        \
  |  |  ------------------
  |  |  |  |  113|  6.23k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  6.23k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  592|  6.23k|    }
  ------------------
  636|  16.6k|                }
  637|  13.7k|                actedge++;
  638|  13.7k|            }
  639|   373k|        }
  640|       |
  641|  1.88k|#undef MERGE_INTO_CURRENT_EDGE
  642|  1.88k|#undef ADD_NEW_EDGE
  643|  1.88k|#undef STEPOUT
  644|  1.88k|#undef STEPIN
  645|       |
  646|  1.88k|        igraph_vector_int_destroy(&outadj);
  647|  1.88k|        igraph_vector_int_destroy(&inadj);
  648|  1.88k|        IGRAPH_FINALLY_CLEAN(2);
  649|       |
  650|  1.88k|        IGRAPH_CHECK(igraph_create(&newgraph, &edges,
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  651|  1.88k|                                   no_of_nodes,
  652|  1.88k|                                   IGRAPH_UNDIRECTED));
  653|  1.88k|        IGRAPH_FINALLY(igraph_destroy, &newgraph);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  654|  1.88k|        igraph_vector_int_destroy(&edges);
  655|  1.88k|        IGRAPH_CHECK(igraph_i_attribute_copy(&newgraph, graph, true, true, /* edges= */ false));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  656|       |
  657|  1.88k|        if (attr) {
  ------------------
  |  Branch (657:13): [True: 0, False: 1.88k]
  ------------------
  658|      0|            igraph_fixed_vectorlist_t vl;
  659|      0|            IGRAPH_CHECK(igraph_fixed_vectorlist_convert(&vl, &mergeinto, actedge));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  660|      0|            IGRAPH_FINALLY(igraph_fixed_vectorlist_destroy, &vl);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  661|       |
  662|      0|            IGRAPH_CHECK(igraph_i_attribute_combine_edges(graph, &newgraph, &vl.vecs, edge_comb));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  663|       |
  664|      0|            igraph_fixed_vectorlist_destroy(&vl);
  665|      0|            IGRAPH_FINALLY_CLEAN(1);
  666|      0|        }
  667|       |
  668|  1.88k|        IGRAPH_FINALLY_CLEAN(2);
  669|  1.88k|        igraph_destroy(graph);
  670|  1.88k|        *graph = newgraph;
  671|       |
  672|  1.88k|        if (attr) {
  ------------------
  |  Branch (672:13): [True: 0, False: 1.88k]
  ------------------
  673|      0|            igraph_vector_int_destroy(&mergeinto);
  674|      0|            IGRAPH_FINALLY_CLEAN(1);
  675|      0|        }
  676|  1.88k|    } else if (mode == IGRAPH_TO_UNDIRECTED_MUTUAL) {
  ------------------
  |  Branch (676:16): [True: 0, False: 0]
  ------------------
  677|      0|        igraph_vector_int_t inadj, outadj;
  678|      0|        igraph_vector_int_t mergeinto;
  679|      0|        igraph_integer_t actedge = 0;
  680|       |
  681|      0|        if (attr) {
  ------------------
  |  Branch (681:13): [True: 0, False: 0]
  ------------------
  682|      0|            IGRAPH_VECTOR_INT_INIT_FINALLY(&mergeinto, no_of_edges);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  683|      0|            igraph_vector_int_fill(&mergeinto, -1);
  684|      0|        }
  685|       |
  686|      0|        IGRAPH_CHECK(igraph_vector_int_reserve(&edges, no_of_edges * 2));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  687|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&inadj, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  688|      0|        IGRAPH_VECTOR_INT_INIT_FINALLY(&outadj, 0);
  ------------------
  |  |  124|      0|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|      0|    do { \
  |  |  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|      0|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|      0|    do { \
  |  |  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  689|       |
  690|      0|        for (igraph_integer_t i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (690:38): [True: 0, False: 0]
  ------------------
  691|      0|            igraph_integer_t n_out, n_in;
  692|      0|            igraph_integer_t p1 = -1, p2 = -1;
  693|      0|            igraph_integer_t e1 = 0, e2 = 0, n1 = 0, n2 = 0;
  694|      0|            IGRAPH_CHECK(igraph_incident(graph, &outadj, i,
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  695|      0|                                         IGRAPH_OUT));
  696|      0|            IGRAPH_CHECK(igraph_incident(graph, &inadj,  i,
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  697|      0|                                         IGRAPH_IN));
  698|      0|            n_out = igraph_vector_int_size(&outadj);
  699|      0|            n_in = igraph_vector_int_size(&inadj);
  700|       |
  701|      0|#define STEPOUT() if ( (++p1) < n_out) {    \
  702|      0|        e1 = VECTOR(outadj)[p1]; \
  703|      0|        n1 = IGRAPH_TO(graph, e1);      \
  704|      0|    }
  705|      0|#define STEPIN()  if ( (++p2) < n_in) {         \
  706|      0|        e2 = VECTOR(inadj )[p2]; \
  707|      0|        n2 = IGRAPH_FROM(graph, e2);        \
  708|      0|    }
  709|       |
  710|      0|            STEPOUT();
  ------------------
  |  |  701|      0|#define STEPOUT() if ( (++p1) < n_out) {    \
  |  |  ------------------
  |  |  |  Branch (701:24): [True: 0, False: 0]
  |  |  ------------------
  |  |  702|      0|        e1 = VECTOR(outadj)[p1]; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  703|      0|        n1 = IGRAPH_TO(graph, e1);      \
  |  |  ------------------
  |  |  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|    }
  ------------------
  711|      0|            STEPIN();
  ------------------
  |  |  705|      0|#define STEPIN()  if ( (++p2) < n_in) {         \
  |  |  ------------------
  |  |  |  Branch (705:24): [True: 0, False: 0]
  |  |  ------------------
  |  |  706|      0|        e2 = VECTOR(inadj )[p2]; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  707|      0|        n2 = IGRAPH_FROM(graph, e2);        \
  |  |  ------------------
  |  |  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  708|      0|    }
  ------------------
  712|       |
  713|      0|            while (p1 < n_out && n1 <= i && p2 < n_in && n2 <= i) {
  ------------------
  |  Branch (713:20): [True: 0, False: 0]
  |  Branch (713:34): [True: 0, False: 0]
  |  Branch (713:45): [True: 0, False: 0]
  |  Branch (713:58): [True: 0, False: 0]
  ------------------
  714|      0|                if (n1 == n2) {
  ------------------
  |  Branch (714:21): [True: 0, False: 0]
  ------------------
  715|      0|                    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, i));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  716|      0|                    IGRAPH_CHECK(igraph_vector_int_push_back(&edges, n1));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  717|      0|                    if (attr) {
  ------------------
  |  Branch (717:25): [True: 0, False: 0]
  ------------------
  718|      0|                        VECTOR(mergeinto)[e1] = actedge;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  719|      0|                        VECTOR(mergeinto)[e2] = actedge;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  720|      0|                        actedge++;
  721|      0|                    }
  722|      0|                    STEPOUT();
  ------------------
  |  |  701|      0|#define STEPOUT() if ( (++p1) < n_out) {    \
  |  |  ------------------
  |  |  |  Branch (701:24): [True: 0, False: 0]
  |  |  ------------------
  |  |  702|      0|        e1 = VECTOR(outadj)[p1]; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  703|      0|        n1 = IGRAPH_TO(graph, e1);      \
  |  |  ------------------
  |  |  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|    }
  ------------------
  723|      0|                    STEPIN();
  ------------------
  |  |  705|      0|#define STEPIN()  if ( (++p2) < n_in) {         \
  |  |  ------------------
  |  |  |  Branch (705:24): [True: 0, False: 0]
  |  |  ------------------
  |  |  706|      0|        e2 = VECTOR(inadj )[p2]; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  707|      0|        n2 = IGRAPH_FROM(graph, e2);        \
  |  |  ------------------
  |  |  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  708|      0|    }
  ------------------
  724|      0|                } else if (n1 < n2) {
  ------------------
  |  Branch (724:28): [True: 0, False: 0]
  ------------------
  725|      0|                    STEPOUT();
  ------------------
  |  |  701|      0|#define STEPOUT() if ( (++p1) < n_out) {    \
  |  |  ------------------
  |  |  |  Branch (701:24): [True: 0, False: 0]
  |  |  ------------------
  |  |  702|      0|        e1 = VECTOR(outadj)[p1]; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  703|      0|        n1 = IGRAPH_TO(graph, e1);      \
  |  |  ------------------
  |  |  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|    }
  ------------------
  726|      0|                } else { /* n2<n1 */
  727|      0|                    STEPIN();
  ------------------
  |  |  705|      0|#define STEPIN()  if ( (++p2) < n_in) {         \
  |  |  ------------------
  |  |  |  Branch (705:24): [True: 0, False: 0]
  |  |  ------------------
  |  |  706|      0|        e2 = VECTOR(inadj )[p2]; \
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  707|      0|        n2 = IGRAPH_FROM(graph, e2);        \
  |  |  ------------------
  |  |  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  708|      0|    }
  ------------------
  728|      0|                }
  729|      0|            }
  730|      0|        }
  731|       |
  732|      0|#undef STEPOUT
  733|      0|#undef STEPIN
  734|       |
  735|      0|        igraph_vector_int_destroy(&outadj);
  736|      0|        igraph_vector_int_destroy(&inadj);
  737|      0|        IGRAPH_FINALLY_CLEAN(2);
  738|       |
  739|      0|        IGRAPH_CHECK(igraph_create(&newgraph, &edges,
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  740|      0|                                   no_of_nodes,
  741|      0|                                   IGRAPH_UNDIRECTED));
  742|      0|        IGRAPH_FINALLY(igraph_destroy, &newgraph);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  743|      0|        igraph_vector_int_destroy(&edges);
  744|      0|        IGRAPH_CHECK(igraph_i_attribute_copy(&newgraph, graph, true, true, /* edges= */ false));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  745|       |
  746|      0|        if (attr) {
  ------------------
  |  Branch (746:13): [True: 0, False: 0]
  ------------------
  747|      0|            igraph_fixed_vectorlist_t vl;
  748|      0|            IGRAPH_CHECK(igraph_fixed_vectorlist_convert(&vl, &mergeinto, actedge));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  749|      0|            IGRAPH_FINALLY(igraph_fixed_vectorlist_destroy, &vl);
  ------------------
  |  |  591|      0|    do { \
  |  |  592|      0|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|      0|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|      0|         * incorrect destructor function with the pointer */ \
  |  |  595|      0|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|      0|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  750|       |
  751|      0|            IGRAPH_CHECK(igraph_i_attribute_combine_edges(graph, &newgraph, &vl.vecs, edge_comb));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  752|       |
  753|      0|            igraph_fixed_vectorlist_destroy(&vl);
  754|      0|            IGRAPH_FINALLY_CLEAN(1);
  755|      0|        }
  756|       |
  757|      0|        IGRAPH_FINALLY_CLEAN(2);
  758|      0|        igraph_destroy(graph);
  759|      0|        *graph = newgraph;
  760|       |
  761|      0|        if (attr) {
  ------------------
  |  Branch (761:13): [True: 0, False: 0]
  ------------------
  762|      0|            igraph_vector_int_destroy(&mergeinto);
  763|      0|            IGRAPH_FINALLY_CLEAN(1);
  764|      0|        }
  765|      0|    }
  766|       |
  767|  1.88k|    return IGRAPH_SUCCESS;
  768|  1.88k|}

igraph_fundamental_cycles:
  210|  1.88k|                                         const igraph_vector_t *weights) {
  211|       |
  212|  1.88k|    const igraph_integer_t no_of_nodes = igraph_vcount(graph);
  213|  1.88k|    const igraph_integer_t no_of_edges = igraph_ecount(graph);
  214|  1.88k|    igraph_integer_t estimated_rank;
  215|  1.88k|    igraph_integer_t i;
  216|  1.88k|    igraph_inclist_t inclist;
  217|  1.88k|    igraph_vector_int_t visited; /* see comments before igraph_i_fundamental_cycles_bfs() */
  218|       |
  219|  1.88k|    IGRAPH_UNUSED(weights);
  ------------------
  |  |   32|  1.88k|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
  220|       |
  221|  1.88k|    if (start_vid >= no_of_nodes) {
  ------------------
  |  Branch (221:9): [True: 0, False: 1.88k]
  ------------------
  222|      0|        IGRAPH_ERROR("Vertex id out of range.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  223|      0|    }
  224|       |
  225|  1.88k|    IGRAPH_CHECK(igraph_inclist_init(graph, &inclist, IGRAPH_ALL, IGRAPH_LOOPS_ONCE));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  226|  1.88k|    IGRAPH_FINALLY(igraph_inclist_destroy, &inclist);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  227|       |
  228|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&visited, no_of_nodes);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  229|       |
  230|       |    /* Compute cycle rank assuming that the graph is connected. */
  231|  1.88k|    estimated_rank = no_of_edges - no_of_nodes + 1;
  232|  1.88k|    estimated_rank = estimated_rank < 0 ? 0 : estimated_rank;
  ------------------
  |  Branch (232:22): [True: 1.74k, False: 136]
  ------------------
  233|       |
  234|  1.88k|    igraph_vector_int_list_clear(result);
  235|  1.88k|    IGRAPH_CHECK(igraph_vector_int_list_reserve(result, estimated_rank));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  236|       |
  237|  1.88k|    if (start_vid < 0) {
  ------------------
  |  Branch (237:9): [True: 1.88k, False: 0]
  ------------------
  238|   375k|        for (i=0; i < no_of_nodes; ++i) {
  ------------------
  |  Branch (238:19): [True: 373k, False: 1.88k]
  ------------------
  239|   373k|            if (! VECTOR(visited)[i]) {
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (239:17): [True: 338k, False: 34.7k]
  ------------------
  240|   338k|                IGRAPH_CHECK(igraph_i_fundamental_cycles_bfs(graph, result, i, bfs_cutoff, &inclist,
  ------------------
  |  |  648|   338k|    do { \
  |  |  649|   338k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   338k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   338k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 338k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   338k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  241|   338k|                                                             &visited, /* mark */ 0));
  242|   338k|            }
  243|   373k|        }
  244|  1.88k|    } else {
  245|      0|        IGRAPH_CHECK(igraph_i_fundamental_cycles_bfs(graph, result, start_vid, bfs_cutoff, &inclist,
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  246|      0|                                                     &visited, /* mark */ 0));
  247|      0|    }
  248|       |
  249|  1.88k|    igraph_vector_int_destroy(&visited);
  250|  1.88k|    igraph_inclist_destroy(&inclist);
  251|  1.88k|    IGRAPH_FINALLY_CLEAN(2);
  252|       |
  253|  1.88k|    return IGRAPH_SUCCESS;
  254|  1.88k|}
igraph_minimum_cycle_basis:
  422|  1.88k|                                          const igraph_vector_t *weights) {
  423|       |
  424|  1.88k|    const igraph_integer_t no_of_nodes = igraph_vcount(graph);
  425|  1.88k|    const igraph_integer_t no_of_edges = igraph_ecount(graph);
  426|  1.88k|    igraph_integer_t rank;
  427|  1.88k|    igraph_vector_int_list_t candidates;
  428|       |
  429|  1.88k|    IGRAPH_UNUSED(weights);
  ------------------
  |  |   32|  1.88k|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
  430|       |
  431|       |    /* Compute candidate elements for the minimum weight basis. */
  432|  1.88k|    {
  433|  1.88k|        igraph_inclist_t inclist;
  434|  1.88k|        igraph_vector_int_t visited; /* visited[v] % 3 is zero for unvisited vertices, see igraph_i_fundamental_cycles_bfs() */
  435|  1.88k|        igraph_vector_int_t degrees;
  436|  1.88k|        igraph_integer_t no_of_comps;
  437|  1.88k|        igraph_integer_t mark;
  438|       |
  439|       |        /* We use the degrees to avoid doing a BFS from vertices with d < 3, except in special cases.
  440|       |         * Degrees cannot be computed from the inclist because there we use IGRAPH_LOOPS_ONCE. */
  441|  1.88k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&degrees, no_of_nodes);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  442|  1.88k|        IGRAPH_CHECK(igraph_degree(graph, &degrees, igraph_vss_all(), IGRAPH_ALL, IGRAPH_LOOPS));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  443|       |
  444|  1.88k|        IGRAPH_CHECK(igraph_connected_components(graph, NULL, NULL, &no_of_comps, IGRAPH_WEAK));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  445|  1.88k|        rank = no_of_edges - no_of_nodes + no_of_comps;
  446|       |
  447|  1.88k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&visited, no_of_nodes);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  448|       |
  449|  1.88k|        IGRAPH_CHECK(igraph_inclist_init(graph, &inclist, IGRAPH_ALL, IGRAPH_LOOPS_ONCE));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  450|  1.88k|        IGRAPH_FINALLY(igraph_inclist_destroy, &inclist);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  451|       |
  452|       |         /* TODO: estimate space to reserve. 'rank' is a lower bound only. */
  453|  1.88k|        IGRAPH_VECTOR_INT_LIST_INIT_FINALLY(&candidates, 0);
  ------------------
  |  |   62|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_list_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   63|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_list_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (63:69): [Folded - Ignored]
  |  |  ------------------
  ------------------
  454|  1.88k|        IGRAPH_CHECK(igraph_vector_int_list_reserve(&candidates, rank));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  455|       |
  456|  1.88k|        mark = 0;
  457|   375k|        for (igraph_integer_t i=0; i < no_of_nodes; ++i) {
  ------------------
  |  Branch (457:36): [True: 373k, False: 1.88k]
  ------------------
  458|   373k|            igraph_integer_t degree = VECTOR(degrees)[i];
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  459|   373k|            igraph_bool_t vis = VECTOR(visited)[i] % 3 != 0; /* was vertex i visited already? */
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  460|       |
  461|       |            /* Generally, we only need to run a BFS from vertices of degree 3 or greater.
  462|       |             * The exception is a connected component which is itself a cycle, and therefore
  463|       |             * only contains vertices of degree 2. Thus from unvisited vertices we always run
  464|       |             * a full BFS while from already visited ones only if their degree is at least 3. */
  465|       |
  466|       |            /* TODO: mark entire component as visited, not just vertex. */
  467|   373k|            if (degree <= 1 || (vis && degree < 3)) {
  ------------------
  |  Branch (467:17): [True: 347k, False: 25.6k]
  |  Branch (467:33): [True: 23.2k, False: 2.42k]
  |  Branch (467:40): [True: 10.8k, False: 12.4k]
  ------------------
  468|   358k|                continue;
  469|   358k|            }
  470|       |
  471|       |            /* TODO: BFS is only necessary from a feedback vertex set, find fast FVS approximation algorithm. */
  472|       |
  473|  14.8k|            IGRAPH_CHECK(igraph_i_fundamental_cycles_bfs(
  ------------------
  |  |  648|  14.8k|    do { \
  |  |  649|  47.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  ------------------
  |  |  |  Branch (649:40): [True: 12.4k, False: 2.42k]
  |  |  |  Branch (649:40): [True: 0, False: 2.42k]
  |  |  ------------------
  |  |  650|  14.8k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  14.8k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 14.8k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  14.8k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  474|  14.8k|                    graph, &candidates, i, (vis || !complete) ? bfs_cutoff : -1, &inclist, &visited, mark));
  475|  14.8k|            mark += 3;
  476|  14.8k|        }
  477|       |
  478|  1.88k|        igraph_inclist_destroy(&inclist);
  479|  1.88k|        igraph_vector_int_destroy(&visited);
  480|  1.88k|        igraph_vector_int_destroy(&degrees);
  481|  1.88k|        IGRAPH_FINALLY_CLEAN(3);
  482|  1.88k|    }
  483|       |
  484|       |    /* Sort candidates by size (= weight) and remove duplicates. */
  485|      0|    {
  486|  1.88k|        igraph_integer_t cand_count = igraph_vector_int_list_size(&candidates);
  487|       |
  488|   675k|        for (igraph_integer_t i=0; i < cand_count; ++i) {
  ------------------
  |  Branch (488:36): [True: 674k, False: 1.88k]
  ------------------
  489|   674k|            igraph_vector_int_sort(igraph_vector_int_list_get_ptr(&candidates, i));
  490|   674k|        }
  491|  1.88k|        igraph_vector_int_list_sort(&candidates, &cycle_cmp);
  492|  1.88k|        igraph_vector_int_list_remove_consecutive_duplicates(&candidates, igraph_vector_int_all_e);
  493|  1.88k|    }
  494|       |
  495|  1.88k|    igraph_vector_int_list_clear(result);
  496|  1.88k|    IGRAPH_CHECK(igraph_vector_int_list_reserve(result, rank));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  497|       |
  498|       |    /* Find a complete basis, starting with smallest elements. */
  499|       |    /* This is typically the slowest part of the algorithm. */
  500|  1.88k|    {
  501|  1.88k|        igraph_integer_t cand_len = igraph_vector_int_list_size(&candidates);
  502|  1.88k|        igraph_vector_int_list_t reduced_matrix;
  503|  1.88k|        igraph_bool_t independent;
  504|       |
  505|  1.88k|        IGRAPH_VECTOR_INT_LIST_INIT_FINALLY(&reduced_matrix, 0);
  ------------------
  |  |   62|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_list_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   63|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_list_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (63:69): [Folded - Ignored]
  |  |  ------------------
  ------------------
  506|       |
  507|  69.2k|        for (igraph_integer_t i=0; i < cand_len; ++i) {
  ------------------
  |  Branch (507:36): [True: 68.9k, False: 363]
  ------------------
  508|  68.9k|            const igraph_vector_int_t *cycle = igraph_vector_int_list_get_ptr(&candidates, i);
  509|       |
  510|  68.9k|            IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|  68.9k|    do { \
  |  |   48|  68.9k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 68.9k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|  68.9k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  511|       |
  512|  68.9k|            IGRAPH_CHECK(gaussian_elimination(&reduced_matrix, cycle, &independent));
  ------------------
  |  |  648|  68.9k|    do { \
  |  |  649|  68.9k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  68.9k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  68.9k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 68.9k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  68.9k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  513|  68.9k|            if (independent) {
  ------------------
  |  Branch (513:17): [True: 32.7k, False: 36.1k]
  ------------------
  514|  32.7k|                IGRAPH_CHECK(igraph_vector_int_list_push_back_copy(result, cycle));
  ------------------
  |  |  648|  32.7k|    do { \
  |  |  649|  32.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  32.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  515|  32.7k|            }
  516|       |
  517|  68.9k|            if (igraph_vector_int_list_size(&reduced_matrix) == rank) {
  ------------------
  |  Branch (517:17): [True: 1.52k, False: 67.3k]
  ------------------
  518|       |                /* We have a complete basis. */
  519|  1.52k|                break;
  520|  1.52k|            }
  521|  68.9k|        }
  522|       |
  523|  1.88k|        igraph_vector_int_list_destroy(&reduced_matrix);
  524|  1.88k|        IGRAPH_FINALLY_CLEAN(1);
  525|  1.88k|    }
  526|       |
  527|      0|    igraph_vector_int_list_destroy(&candidates);
  528|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  529|       |
  530|  1.88k|    if (use_cycle_order) {
  ------------------
  |  Branch (530:9): [True: 1.88k, False: 0]
  ------------------
  531|  1.88k|        igraph_integer_t result_size = igraph_vector_int_list_size(result);
  532|  1.88k|        igraph_vector_int_t tmp;
  533|  1.88k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&tmp, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  534|  34.6k|        for (igraph_integer_t i=0; i < result_size; ++i) {
  ------------------
  |  Branch (534:36): [True: 32.7k, False: 1.88k]
  ------------------
  535|  32.7k|            igraph_vector_int_t *cycle = igraph_vector_int_list_get_ptr(result, i);
  536|  32.7k|            IGRAPH_CHECK(igraph_vector_int_update(&tmp, cycle));
  ------------------
  |  |  648|  32.7k|    do { \
  |  |  649|  32.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  32.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  537|  32.7k|            IGRAPH_CHECK(igraph_i_order_cycle(graph, &tmp, cycle));
  ------------------
  |  |  648|  32.7k|    do { \
  |  |  649|  32.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  32.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  538|  32.7k|        }
  539|  1.88k|        igraph_vector_int_destroy(&tmp);
  540|  1.88k|        IGRAPH_FINALLY_CLEAN(1);
  541|  1.88k|    }
  542|       |
  543|  1.88k|    return IGRAPH_SUCCESS;
  544|  1.88k|}
cycle_bases.c:igraph_i_fundamental_cycles_bfs:
   53|   353k|        igraph_integer_t mark /* mark used in 'visited' */) {
   54|       |
   55|   353k|    const igraph_integer_t no_of_nodes = igraph_vcount(graph);
   56|   353k|    igraph_dqueue_int_t q;
   57|   353k|    igraph_vector_int_t pred_edge;
   58|   353k|    igraph_vector_int_t u_back, v_back;
   59|       |
   60|   353k|    if (start_vid < 0 || start_vid >= no_of_nodes) {
  ------------------
  |  Branch (60:9): [True: 0, False: 353k]
  |  Branch (60:26): [True: 0, False: 353k]
  ------------------
   61|      0|        IGRAPH_ERROR("Invalid starting vertex id.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   62|      0|    }
   63|       |
   64|   353k|    if (mark > IGRAPH_INTEGER_MAX - 2) {
  ------------------
  |  |   77|   353k|#  define IGRAPH_INTEGER_MAX INT64_MAX
  ------------------
  |  Branch (64:9): [True: 0, False: 353k]
  ------------------
   65|      0|        IGRAPH_ERROR("Graph too large for cycle basis.", IGRAPH_EOVERFLOW);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   66|      0|    }
   67|       |
   68|   353k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&pred_edge, no_of_nodes);
  ------------------
  |  |  124|   353k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|   353k|    do { \
  |  |  |  |  649|   353k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|   353k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|   353k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 353k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|   353k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|   353k|    do { \
  |  |  |  |  592|   353k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|   353k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|   353k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|   353k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|   353k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
   69|   353k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&u_back, 0);
  ------------------
  |  |  124|   353k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|   353k|    do { \
  |  |  |  |  649|   353k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|   353k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|   353k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 353k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|   353k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|   353k|    do { \
  |  |  |  |  592|   353k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|   353k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|   353k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|   353k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|   353k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
   70|   353k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&v_back, 0);
  ------------------
  |  |  124|   353k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|   353k|    do { \
  |  |  |  |  649|   353k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|   353k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|   353k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 353k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|   353k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|   353k|    do { \
  |  |  |  |  592|   353k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|   353k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|   353k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|   353k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|   353k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
   71|       |
   72|   353k|    IGRAPH_DQUEUE_INT_INIT_FINALLY(&q, 0);
  ------------------
  |  |   66|   353k|    do { IGRAPH_CHECK(igraph_dqueue_int_init(q, capacity)); \
  |  |  ------------------
  |  |  |  |  648|   353k|    do { \
  |  |  |  |  649|   353k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|   353k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|   353k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 353k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   67|   353k|        IGRAPH_FINALLY(igraph_dqueue_int_destroy, q); } while (0)
  |  |  ------------------
  |  |  |  |  591|   353k|    do { \
  |  |  |  |  592|   353k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|   353k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|   353k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|   353k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|   353k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|   353k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (67:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
   73|       |
   74|   353k|    IGRAPH_CHECK(igraph_dqueue_int_push(&q, start_vid)); /* vertex id */
  ------------------
  |  |  648|   353k|    do { \
  |  |  649|   353k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   353k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   353k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 353k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   353k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   75|   353k|    IGRAPH_CHECK(igraph_dqueue_int_push(&q, 0)); /* distance from start_vid*/
  ------------------
  |  |  648|   353k|    do { \
  |  |  649|   353k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   353k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   353k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 353k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   353k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   76|   353k|    VECTOR(*visited)[start_vid] = mark + 1; /* mark as seen */
  ------------------
  |  |   65|   353k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   77|   353k|    VECTOR(pred_edge)[start_vid] = -1; /* non-valid predecessor edge id for root vertex */
  ------------------
  |  |   65|   353k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   78|       |
   79|  1.41M|    while (! igraph_dqueue_int_empty(&q)) {
  ------------------
  |  Branch (79:12): [True: 1.05M, False: 353k]
  ------------------
   80|  1.05M|        igraph_integer_t v = igraph_dqueue_int_pop(&q);
   81|  1.05M|        igraph_integer_t vdist = igraph_dqueue_int_pop(&q);
   82|       |
   83|  1.05M|        igraph_vector_int_t *incs = igraph_inclist_get(inclist, v);
  ------------------
  |  |  107|  1.05M|#define igraph_inclist_get(il,no) (&(il)->incs[(igraph_integer_t)(no)])
  ------------------
   84|  1.05M|        igraph_integer_t n = igraph_vector_int_size(incs);
   85|  1.05M|        igraph_integer_t i, j;
   86|       |
   87|  1.05M|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|  1.05M|    do { \
  |  |   48|  1.05M|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 1.05M]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|  1.05M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   88|       |
   89|  3.78M|        for (i=0; i < n; ++i) {
  ------------------
  |  Branch (89:19): [True: 2.72M, False: 1.05M]
  ------------------
   90|  2.72M|            igraph_integer_t e = VECTOR(*incs)[i];
  ------------------
  |  |   65|  2.72M|#define VECTOR(v) ((v).stor_begin)
  ------------------
   91|  2.72M|            igraph_integer_t u = IGRAPH_OTHER(graph, e, v);
  ------------------
  |  |  144|  2.72M|    ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|  2.72M|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  2.72M|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  113|  1.41M|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  1.41M|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|  1.30M|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  1.30M|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:25): [True: 1.41M, False: 1.30M]
  |  |  ------------------
  ------------------
   92|       |
   93|  2.72M|            if (e == VECTOR(pred_edge)[v]) {
  ------------------
  |  |   65|  2.72M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (93:17): [True: 706k, False: 2.01M]
  ------------------
   94|       |                /* do not follow the edge through which we came to v */
   95|   706k|                continue;
   96|   706k|            }
   97|       |
   98|  2.01M|            if (VECTOR(*visited)[u] == mark + 2) {
  ------------------
  |  |   65|  2.01M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (98:17): [True: 603k, False: 1.41M]
  ------------------
   99|       |                /* u has already been processed */
  100|   603k|                continue;
  101|  1.41M|            } else if (VECTOR(*visited)[u] == mark + 1) {
  ------------------
  |  |   65|  1.41M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (101:24): [True: 706k, False: 706k]
  ------------------
  102|       |                /* u has been seen but not yet processed */
  103|       |
  104|       |                /* Found cycle edge u-v. Now we walk back up the BFS tree
  105|       |                 * in order to find the common ancestor of u and v. We exploit
  106|       |                 * that the distance of u from the start vertex is either the
  107|       |                 * same as that of v, or one greater. */
  108|       |
  109|   706k|                igraph_integer_t up = u, vp = v;
  110|   706k|                igraph_integer_t u_back_len, v_back_len;
  111|   706k|                igraph_vector_int_t cycle;
  112|       |
  113|   706k|                IGRAPH_CHECK(igraph_vector_int_push_back(&v_back, e));
  ------------------
  |  |  648|   706k|    do { \
  |  |  649|   706k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   706k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   706k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 706k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   706k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  114|  1.62M|                for (;;) {
  115|  1.62M|                    igraph_integer_t upe, vpe;
  116|       |
  117|  1.62M|                    if (up == vp) {
  ------------------
  |  Branch (117:25): [True: 257k, False: 1.36M]
  ------------------
  118|   257k|                        break;
  119|   257k|                    }
  120|       |
  121|  1.36M|                    upe = VECTOR(pred_edge)[up];
  ------------------
  |  |   65|  1.36M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  122|  1.36M|                    IGRAPH_CHECK(igraph_vector_int_push_back(&u_back, upe));
  ------------------
  |  |  648|  1.36M|    do { \
  |  |  649|  1.36M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.36M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.36M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.36M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.36M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  123|  1.36M|                    up = IGRAPH_OTHER(graph, upe, up);
  ------------------
  |  |  144|  1.36M|    ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|  1.36M|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  1.36M|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  113|   723k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|   723k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|   644k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|   644k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:25): [True: 723k, False: 644k]
  |  |  ------------------
  ------------------
  124|       |
  125|  1.36M|                    if (up == vp) {
  ------------------
  |  Branch (125:25): [True: 449k, False: 918k]
  ------------------
  126|   449k|                        break;
  127|   449k|                    }
  128|       |
  129|   918k|                    vpe = VECTOR(pred_edge)[vp];
  ------------------
  |  |   65|   918k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  130|   918k|                    IGRAPH_CHECK(igraph_vector_int_push_back(&v_back, vpe));
  ------------------
  |  |  648|   918k|    do { \
  |  |  649|   918k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   918k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   918k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 918k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   918k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  131|   918k|                    vp = IGRAPH_OTHER(graph, vpe, vp);
  ------------------
  |  |  144|   918k|    ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|   918k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|   918k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  113|   471k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|   471k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|   447k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|   447k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:25): [True: 471k, False: 447k]
  |  |  ------------------
  ------------------
  132|   918k|                }
  133|       |
  134|   706k|                u_back_len = igraph_vector_int_size(&u_back);
  135|   706k|                v_back_len = igraph_vector_int_size(&v_back);
  136|   706k|                IGRAPH_VECTOR_INT_INIT_FINALLY(&cycle, u_back_len + v_back_len);
  ------------------
  |  |  124|   706k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|   706k|    do { \
  |  |  |  |  649|   706k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|   706k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|   706k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 706k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|   706k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|   706k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|   706k|    do { \
  |  |  |  |  592|   706k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|   706k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|   706k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|   706k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|   706k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|   706k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  137|       |
  138|  2.33M|                for (j=0; j < v_back_len; ++j) {
  ------------------
  |  Branch (138:27): [True: 1.62M, False: 706k]
  ------------------
  139|  1.62M|                    VECTOR(cycle)[j] = VECTOR(v_back)[j];
  ------------------
  |  |   65|  1.62M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(cycle)[j] = VECTOR(v_back)[j];
  ------------------
  |  |   65|  1.62M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  140|  1.62M|                }
  141|  2.07M|                for (j=0; j < u_back_len; ++j) {
  ------------------
  |  Branch (141:27): [True: 1.36M, False: 706k]
  ------------------
  142|  1.36M|                    VECTOR(cycle)[v_back_len + j] = VECTOR(u_back)[u_back_len - j - 1];
  ------------------
  |  |   65|  1.36M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(cycle)[v_back_len + j] = VECTOR(u_back)[u_back_len - j - 1];
  ------------------
  |  |   65|  1.36M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  143|  1.36M|                }
  144|       |
  145|   706k|                igraph_vector_int_clear(&v_back);
  146|   706k|                igraph_vector_int_clear(&u_back);
  147|       |
  148|   706k|                IGRAPH_CHECK(igraph_vector_int_list_push_back(result, &cycle));
  ------------------
  |  |  648|   706k|    do { \
  |  |  649|   706k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   706k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   706k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 706k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   706k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  149|   706k|                IGRAPH_FINALLY_CLEAN(1); /* pass ownership of 'cycle' to 'result' */
  150|   706k|            } else {
  151|       |                /* encountering u for the first time, queue it for processing */
  152|       |
  153|       |                /* Only queue vertices with distance at most 'bfs_cutoff' from the root. */
  154|       |                /* Negative 'bfs_cutoff' indicates no cutoff. */
  155|   706k|                if (bfs_cutoff < 0 || vdist < bfs_cutoff) {
  ------------------
  |  Branch (155:21): [True: 706k, False: 0]
  |  Branch (155:39): [True: 0, False: 0]
  ------------------
  156|   706k|                    IGRAPH_CHECK(igraph_dqueue_int_push(&q, u));
  ------------------
  |  |  648|   706k|    do { \
  |  |  649|   706k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   706k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   706k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 706k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   706k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  157|   706k|                    IGRAPH_CHECK(igraph_dqueue_int_push(&q, vdist + 1));
  ------------------
  |  |  648|   706k|    do { \
  |  |  649|   706k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   706k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   706k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 706k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   706k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  158|   706k|                    VECTOR(*visited)[u] = mark + 1;
  ------------------
  |  |   65|   706k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  159|   706k|                    VECTOR(pred_edge)[u] = e;
  ------------------
  |  |   65|   706k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  160|   706k|                }
  161|   706k|            }
  162|  2.01M|        }
  163|       |
  164|  1.05M|        VECTOR(*visited)[v] = mark + 2; /* mark v as processed */
  ------------------
  |  |   65|  1.05M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  165|  1.05M|    } /* ! igraph_dqueue_int_empty(&q) */
  166|       |
  167|   353k|    igraph_dqueue_int_destroy(&q);
  168|   353k|    igraph_vector_int_destroy(&v_back);
  169|   353k|    igraph_vector_int_destroy(&u_back);
  170|   353k|    igraph_vector_int_destroy(&pred_edge);
  171|   353k|    IGRAPH_FINALLY_CLEAN(4);
  172|       |
  173|   353k|    return IGRAPH_SUCCESS;
  174|   353k|}
cycle_bases.c:cycle_cmp:
  266|  4.86M|static int cycle_cmp(const igraph_vector_int_t *v1, const igraph_vector_int_t *v2) {
  267|  4.86M|    igraph_integer_t n1 = igraph_vector_int_size(v1), n2 = igraph_vector_int_size(v2);
  268|       |
  269|  4.86M|    if (n1 < n2) {
  ------------------
  |  Branch (269:9): [True: 646k, False: 4.21M]
  ------------------
  270|   646k|        return -1;
  271|  4.21M|    } else if (n1 > n2) {
  ------------------
  |  Branch (271:16): [True: 707k, False: 3.51M]
  ------------------
  272|   707k|        return 1;
  273|  3.51M|    } else {
  274|  3.51M|        return igraph_vector_int_lex_cmp(v1, v2);
  275|  3.51M|    }
  276|  4.86M|}
cycle_bases.c:gaussian_elimination:
  325|  68.9k|                                           igraph_bool_t *independent) {
  326|       |
  327|  68.9k|    const igraph_integer_t nrow = igraph_vector_int_list_size(reduced_matrix);
  328|  68.9k|    igraph_integer_t i;
  329|       |
  330|  68.9k|    igraph_vector_int_t work, tmp;
  331|       |
  332|  68.9k|    IGRAPH_CHECK(igraph_vector_int_init_copy(&work, cycle));
  ------------------
  |  |  648|  68.9k|    do { \
  |  |  649|  68.9k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  68.9k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  68.9k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 68.9k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  68.9k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  333|  68.9k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &work);
  ------------------
  |  |  591|  68.9k|    do { \
  |  |  592|  68.9k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  68.9k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  68.9k|         * incorrect destructor function with the pointer */ \
  |  |  595|  68.9k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  68.9k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  68.9k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  334|       |
  335|  68.9k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&tmp, 0);
  ------------------
  |  |  124|  68.9k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  68.9k|    do { \
  |  |  |  |  649|  68.9k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  68.9k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  68.9k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 68.9k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  68.9k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  68.9k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  68.9k|    do { \
  |  |  |  |  592|  68.9k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  68.9k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  68.9k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  68.9k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  68.9k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  68.9k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  336|       |
  337|  3.68M|    for (i=0; i < nrow; ++i) {
  ------------------
  |  Branch (337:15): [True: 3.66M, False: 17.8k]
  ------------------
  338|  3.66M|        igraph_vector_int_t *row = MATROW(*reduced_matrix, i);
  ------------------
  |  |  317|  3.66M|#define MATROW(m, i) (&VECTOR(m)[i])
  |  |  ------------------
  |  |  |  |   65|  3.66M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  339|       |
  340|  3.66M|        if ( VECTOR(*row)[0] < VECTOR(work)[0] ) {
  ------------------
  |  |   65|  3.66M|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      if ( VECTOR(*row)[0] < VECTOR(work)[0] ) {
  ------------------
  |  |   65|  3.66M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (340:14): [True: 3.30M, False: 363k]
  ------------------
  341|  3.30M|            continue;
  342|  3.30M|        } else if ( VECTOR(*row)[0] == VECTOR(work)[0] ) {
  ------------------
  |  |   65|   363k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      } else if ( VECTOR(*row)[0] == VECTOR(work)[0] ) {
  ------------------
  |  |   65|   363k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (342:21): [True: 348k, False: 14.9k]
  ------------------
  343|   348k|            IGRAPH_CHECK(cycle_add(row, &work, &tmp));
  ------------------
  |  |  648|   348k|    do { \
  |  |  649|   348k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   348k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   348k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 348k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   348k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  344|   348k|            if (igraph_vector_int_empty(&tmp)) {
  ------------------
  |  Branch (344:17): [True: 36.1k, False: 312k]
  ------------------
  345|  36.1k|                *independent = false;
  346|  36.1k|                igraph_vector_int_destroy(&work);
  347|  36.1k|                igraph_vector_int_destroy(&tmp);
  348|  36.1k|                IGRAPH_FINALLY_CLEAN(2);
  349|  36.1k|                return IGRAPH_SUCCESS;
  350|  36.1k|            }
  351|   312k|            igraph_vector_int_swap(&work, &tmp);
  352|   312k|        } else { /* VECTOR(*row)[0] > VECTOR(work)[0] */
  353|  14.9k|            break;
  354|  14.9k|        }
  355|  3.66M|    }
  356|       |
  357|       |    /* 'cycle' was linearly independent, insert new row into matrix */
  358|  32.7k|    *independent = true;
  359|  32.7k|    IGRAPH_CHECK(igraph_vector_int_list_insert(reduced_matrix, i, &work)); /* transfers ownership */
  ------------------
  |  |  648|  32.7k|    do { \
  |  |  649|  32.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  32.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  360|       |
  361|  32.7k|    igraph_vector_int_destroy(&tmp);
  362|  32.7k|    IGRAPH_FINALLY_CLEAN(2); /* +1, transferring ownership of 'work' to 'reduced_matrix' */
  363|       |
  364|  32.7k|    return IGRAPH_SUCCESS;
  365|  32.7k|}
cycle_bases.c:cycle_add:
  279|   348k|static igraph_error_t cycle_add(const igraph_vector_int_t *a, const igraph_vector_int_t *b, igraph_vector_int_t *res) {
  280|   348k|    igraph_integer_t na = igraph_vector_int_size(a), nb = igraph_vector_int_size(b);
  281|   348k|    const igraph_integer_t *pa = VECTOR(*a), *pb = VECTOR(*b);
  ------------------
  |  |   65|   348k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                  const igraph_integer_t *pa = VECTOR(*a), *pb = VECTOR(*b);
  ------------------
  |  |   65|   348k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  282|   348k|    const igraph_integer_t *pa_end = pa + na, *pb_end = pb + nb;
  283|       |
  284|   348k|    igraph_vector_int_clear(res);
  285|   864k|    for (;;) {
  286|  1.33M|        while (pa != pa_end && pb != pb_end && *pa < *pb) {
  ------------------
  |  Branch (286:16): [True: 1.10M, False: 229k]
  |  Branch (286:32): [True: 1.10M, False: 0]
  |  Branch (286:48): [True: 473k, False: 634k]
  ------------------
  287|   473k|            IGRAPH_CHECK(igraph_vector_int_push_back(res, *pa));
  ------------------
  |  |  648|   473k|    do { \
  |  |  649|   473k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   473k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   473k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 473k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   473k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  288|   473k|            pa++;
  289|   473k|        }
  290|  1.61M|        while (pa != pa_end && pb != pb_end && *pa == *pb) {
  ------------------
  |  Branch (290:16): [True: 1.30M, False: 312k]
  |  Branch (290:32): [True: 1.29M, False: 7.53k]
  |  Branch (290:48): [True: 748k, False: 544k]
  ------------------
  291|   748k|            pa++; pb++;
  292|   748k|        }
  293|  1.49M|        while (pa != pa_end && pb != pb_end && *pb < *pa) {
  ------------------
  |  Branch (293:16): [True: 1.18M, False: 312k]
  |  Branch (293:32): [True: 1.14M, False: 36.4k]
  |  Branch (293:48): [True: 631k, False: 515k]
  ------------------
  294|   631k|            IGRAPH_CHECK(igraph_vector_int_push_back(res, *pb));
  ------------------
  |  |  648|   631k|    do { \
  |  |  649|   631k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   631k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   631k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 631k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   631k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  295|   631k|            pb++;
  296|   631k|        }
  297|   864k|        if (pa == pa_end) {
  ------------------
  |  Branch (297:13): [True: 312k, False: 551k]
  ------------------
  298|   769k|            while (pb != pb_end) {
  ------------------
  |  Branch (298:20): [True: 457k, False: 312k]
  ------------------
  299|   457k|                IGRAPH_CHECK(igraph_vector_int_push_back(res, *pb));
  ------------------
  |  |  648|   457k|    do { \
  |  |  649|   457k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   457k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   457k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 457k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   457k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  300|   457k|                pb++;
  301|   457k|            }
  302|   312k|            break;
  303|   312k|        }
  304|   551k|        if (pb == pb_end) {
  ------------------
  |  Branch (304:13): [True: 36.4k, False: 515k]
  ------------------
  305|  84.4k|            while (pa != pa_end) {
  ------------------
  |  Branch (305:20): [True: 48.0k, False: 36.4k]
  ------------------
  306|  48.0k|                IGRAPH_CHECK(igraph_vector_int_push_back(res, *pa));
  ------------------
  |  |  648|  48.0k|    do { \
  |  |  649|  48.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  48.0k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  48.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 48.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  48.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  307|  48.0k|                pa++;
  308|  48.0k|            }
  309|  36.4k|            break;
  310|  36.4k|        }
  311|   551k|    }
  312|       |
  313|   348k|    return IGRAPH_SUCCESS;
  314|   348k|}

igraph_motifs_randesu:
  118|  3.76k|                          igraph_integer_t size, const igraph_vector_t *cut_prob) {
  119|  3.76k|    igraph_bool_t directed = igraph_is_directed(graph);
  120|  3.76k|    igraph_integer_t histlen;
  121|       |
  122|  3.76k|    if (directed) {
  ------------------
  |  Branch (122:9): [True: 1.88k, False: 1.88k]
  ------------------
  123|  1.88k|        switch (size) {
  124|  1.88k|        case 3:
  ------------------
  |  Branch (124:9): [True: 1.88k, False: 0]
  ------------------
  125|  1.88k|            histlen = 16;
  126|  1.88k|            break;
  127|      0|        case 4:
  ------------------
  |  Branch (127:9): [True: 0, False: 1.88k]
  ------------------
  128|      0|            histlen = 218;
  129|      0|            break;
  130|      0|        default:
  ------------------
  |  Branch (130:9): [True: 0, False: 1.88k]
  ------------------
  131|      0|            IGRAPH_ERROR("In directed graphs, only 3 and 4 vertex motifs are supported.",
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  132|  1.88k|                         IGRAPH_UNIMPLEMENTED);
  133|  1.88k|        }
  134|  1.88k|    } else {
  135|  1.88k|        switch (size) {
  136|      0|        case 3:
  ------------------
  |  Branch (136:9): [True: 0, False: 1.88k]
  ------------------
  137|      0|            histlen = 4;
  138|      0|            break;
  139|  1.88k|        case 4:
  ------------------
  |  Branch (139:9): [True: 1.88k, False: 0]
  ------------------
  140|  1.88k|            histlen = 11;
  141|  1.88k|            break;
  142|      0|        case 5:
  ------------------
  |  Branch (142:9): [True: 0, False: 1.88k]
  ------------------
  143|      0|            histlen = 34;
  144|      0|            break;
  145|      0|        case 6:
  ------------------
  |  Branch (145:9): [True: 0, False: 1.88k]
  ------------------
  146|      0|            histlen = 156;
  147|      0|            break;
  148|      0|        default:
  ------------------
  |  Branch (148:9): [True: 0, False: 1.88k]
  ------------------
  149|      0|            IGRAPH_ERROR("In undirected graphs, only 3 to 6 vertex motifs are supported.",
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  150|  1.88k|                         IGRAPH_UNIMPLEMENTED);
  151|  1.88k|        }
  152|  1.88k|    }
  153|       |
  154|  3.76k|    if (cut_prob != NULL && igraph_vector_size(cut_prob) != size) {
  ------------------
  |  Branch (154:9): [True: 1.88k, False: 1.88k]
  |  Branch (154:29): [True: 0, False: 1.88k]
  ------------------
  155|      0|        IGRAPH_ERRORF("Cut probability vector size (%" IGRAPH_PRId ") must agree with motif size (%" IGRAPH_PRId ").",
  ------------------
  |  |  469|      0|    do { \
  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  472|      0|        return igraph_errno; \
  |  |  473|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  156|      0|                      IGRAPH_EINVAL, igraph_vector_size(cut_prob), size);
  157|      0|    }
  158|       |
  159|  3.76k|    IGRAPH_CHECK(igraph_vector_resize(hist, histlen));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  160|  3.76k|    igraph_vector_null(hist);
  161|       |
  162|  3.76k|    IGRAPH_CHECK(igraph_motifs_randesu_callback(graph, size, cut_prob,
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  163|  3.76k|                 &igraph_i_motifs_randesu_update_hist, hist));
  164|       |
  165|  3.76k|    if (size == 3) {
  ------------------
  |  Branch (165:9): [True: 1.88k, False: 1.88k]
  ------------------
  166|  1.88k|        if (directed) {
  ------------------
  |  Branch (166:13): [True: 1.88k, False: 0]
  ------------------
  167|  1.88k|            VECTOR(*hist)[0] = VECTOR(*hist)[1] = VECTOR(*hist)[3] = IGRAPH_NAN;
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[0] = VECTOR(*hist)[1] = VECTOR(*hist)[3] = IGRAPH_NAN;
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[0] = VECTOR(*hist)[1] = VECTOR(*hist)[3] = IGRAPH_NAN;
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[0] = VECTOR(*hist)[1] = VECTOR(*hist)[3] = IGRAPH_NAN;
  ------------------
  |  |  143|  1.88k|#define IGRAPH_NAN ((double)NAN)
  ------------------
  168|  1.88k|        } else {
  169|      0|            VECTOR(*hist)[0] = VECTOR(*hist)[1] = IGRAPH_NAN;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[0] = VECTOR(*hist)[1] = IGRAPH_NAN;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[0] = VECTOR(*hist)[1] = IGRAPH_NAN;
  ------------------
  |  |  143|      0|#define IGRAPH_NAN ((double)NAN)
  ------------------
  170|      0|        }
  171|  1.88k|    } else if (size == 4) {
  ------------------
  |  Branch (171:16): [True: 1.88k, False: 0]
  ------------------
  172|  1.88k|        if (directed) {
  ------------------
  |  Branch (172:13): [True: 0, False: 1.88k]
  ------------------
  173|      0|            const int not_connected[] = { 0, 1, 2, 4, 5, 6, 9, 10, 11, 15, 22, 23, 27,
  174|      0|                                          28, 33, 34, 39, 62, 120 };
  175|      0|            size_t i, n = sizeof(not_connected) / sizeof(not_connected[0]);
  176|      0|            for (i = 0; i < n; i++) {
  ------------------
  |  Branch (176:25): [True: 0, False: 0]
  ------------------
  177|      0|                VECTOR(*hist)[not_connected[i]] = IGRAPH_NAN;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              VECTOR(*hist)[not_connected[i]] = IGRAPH_NAN;
  ------------------
  |  |  143|      0|#define IGRAPH_NAN ((double)NAN)
  ------------------
  178|      0|            }
  179|  1.88k|        } else {
  180|  1.88k|            VECTOR(*hist)[0] = VECTOR(*hist)[1] = VECTOR(*hist)[2] =
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[0] = VECTOR(*hist)[1] = VECTOR(*hist)[2] =
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[0] = VECTOR(*hist)[1] = VECTOR(*hist)[2] =
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  181|  1.88k|                    VECTOR(*hist)[3] = VECTOR(*hist)[5] = IGRAPH_NAN;
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(*hist)[3] = VECTOR(*hist)[5] = IGRAPH_NAN;
  ------------------
  |  |   65|  1.88k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(*hist)[3] = VECTOR(*hist)[5] = IGRAPH_NAN;
  ------------------
  |  |  143|  1.88k|#define IGRAPH_NAN ((double)NAN)
  ------------------
  182|  1.88k|        }
  183|  1.88k|    } else if (size == 5) {
  ------------------
  |  Branch (183:16): [True: 0, False: 0]
  ------------------
  184|       |        /* undirected only */
  185|      0|        const int not_connected[] = { 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 12, 19 };
  186|      0|        size_t i, n = sizeof(not_connected) / sizeof(int);
  187|      0|        for (i = 0; i < n; i++) {
  ------------------
  |  Branch (187:21): [True: 0, False: 0]
  ------------------
  188|      0|            VECTOR(*hist)[not_connected[i]] = IGRAPH_NAN;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[not_connected[i]] = IGRAPH_NAN;
  ------------------
  |  |  143|      0|#define IGRAPH_NAN ((double)NAN)
  ------------------
  189|      0|        }
  190|      0|    } else if (size == 6) {
  ------------------
  |  Branch (190:16): [True: 0, False: 0]
  ------------------
  191|       |        /* undirected only */
  192|      0|        const int not_connected[] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
  193|      0|                                     16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
  194|      0|                                     30, 31, 32, 33, 35, 38, 44, 50, 51, 54, 74, 77, 89, 120};
  195|      0|        size_t i, n = sizeof(not_connected) / sizeof(int);
  196|      0|        for (i = 0; i < n; i++) {
  ------------------
  |  Branch (196:21): [True: 0, False: 0]
  ------------------
  197|      0|            VECTOR(*hist)[not_connected[i]] = IGRAPH_NAN;
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          VECTOR(*hist)[not_connected[i]] = IGRAPH_NAN;
  ------------------
  |  |  143|      0|#define IGRAPH_NAN ((double)NAN)
  ------------------
  198|      0|        }
  199|      0|    }
  200|       |
  201|  3.76k|    return IGRAPH_SUCCESS;
  202|  3.76k|}
igraph_motifs_randesu_callback:
  242|  3.76k|                                   void* extra) {
  243|       |
  244|  3.76k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  245|  3.76k|    igraph_adjlist_t allneis, alloutneis;
  246|  3.76k|    igraph_vector_int_t *neis;
  247|  3.76k|    igraph_integer_t father;
  248|  3.76k|    igraph_integer_t i, j, s;
  249|  3.76k|    igraph_integer_t motifs = 0;
  250|  3.76k|    IGRAPH_UNUSED(motifs);    /* We mark it as unused to prevent warnings about unused-but-set-variables. */
  ------------------
  |  |   32|  3.76k|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
  251|       |
  252|  3.76k|    igraph_vector_int_t vids;     /* this is G */
  253|  3.76k|    igraph_vector_int_t adjverts; /* this is V_E */
  254|  3.76k|    igraph_stack_int_t stack;     /* this is S */
  255|  3.76k|    igraph_integer_t *added;
  256|  3.76k|    char *subg;
  257|       |
  258|  3.76k|    const unsigned int *arr_idx, *arr_code;
  259|  3.76k|    unsigned int code = 0;
  260|  3.76k|    unsigned int mul, idx;
  261|       |
  262|  3.76k|    igraph_bool_t terminate = false;
  263|       |
  264|  3.76k|    if (igraph_is_directed(graph)) {
  ------------------
  |  Branch (264:9): [True: 1.88k, False: 1.88k]
  ------------------
  265|  1.88k|        switch (size) {
  266|  1.88k|        case 3:
  ------------------
  |  Branch (266:9): [True: 1.88k, False: 0]
  ------------------
  267|  1.88k|            arr_idx = igraph_i_isoclass_3_idx;
  268|  1.88k|            arr_code = igraph_i_isoclass2_3;
  269|  1.88k|            mul = 3;
  270|  1.88k|            break;
  271|      0|        case 4:
  ------------------
  |  Branch (271:9): [True: 0, False: 1.88k]
  ------------------
  272|      0|            arr_idx = igraph_i_isoclass_4_idx;
  273|      0|            arr_code = igraph_i_isoclass2_4;
  274|      0|            mul = 4;
  275|      0|            break;
  276|      0|        default:
  ------------------
  |  Branch (276:9): [True: 0, False: 1.88k]
  ------------------
  277|      0|            IGRAPH_ERROR("In directed graphs, only 3 and 4 vertex motifs are supported.",
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  278|  1.88k|                         IGRAPH_UNIMPLEMENTED);
  279|  1.88k|        }
  280|  1.88k|    } else {
  281|  1.88k|        switch (size) {
  282|      0|        case 3:
  ------------------
  |  Branch (282:9): [True: 0, False: 1.88k]
  ------------------
  283|      0|            arr_idx = igraph_i_isoclass_3u_idx;
  284|      0|            arr_code = igraph_i_isoclass2_3u;
  285|      0|            mul = 3;
  286|      0|            break;
  287|  1.88k|        case 4:
  ------------------
  |  Branch (287:9): [True: 1.88k, False: 0]
  ------------------
  288|  1.88k|            arr_idx = igraph_i_isoclass_4u_idx;
  289|  1.88k|            arr_code = igraph_i_isoclass2_4u;
  290|  1.88k|            mul = 4;
  291|  1.88k|            break;
  292|      0|        case 5:
  ------------------
  |  Branch (292:9): [True: 0, False: 1.88k]
  ------------------
  293|      0|            arr_idx = igraph_i_isoclass_5u_idx;
  294|      0|            arr_code = igraph_i_isoclass2_5u;
  295|      0|            mul = 5;
  296|      0|            break;
  297|      0|        case 6:
  ------------------
  |  Branch (297:9): [True: 0, False: 1.88k]
  ------------------
  298|      0|            arr_idx = igraph_i_isoclass_6u_idx;
  299|      0|            arr_code = igraph_i_isoclass2_6u;
  300|      0|            mul = 6;
  301|      0|            break;
  302|      0|        default:
  ------------------
  |  Branch (302:9): [True: 0, False: 1.88k]
  ------------------
  303|      0|            IGRAPH_ERROR("In undirected graphs, only 3 to 6 vertex motifs are supported.",
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  304|  1.88k|                         IGRAPH_UNIMPLEMENTED);
  305|  1.88k|        }
  306|  1.88k|    }
  307|       |
  308|  3.76k|    if (cut_prob != NULL && igraph_vector_size(cut_prob) != size) {
  ------------------
  |  Branch (308:9): [True: 1.88k, False: 1.88k]
  |  Branch (308:29): [True: 0, False: 1.88k]
  ------------------
  309|      0|        IGRAPH_ERRORF("Cut probability vector size (%" IGRAPH_PRId ") must agree with motif size (%" IGRAPH_PRId ").",
  ------------------
  |  |  469|      0|    do { \
  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  472|      0|        return igraph_errno; \
  |  |  473|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  310|      0|                      IGRAPH_EINVAL, igraph_vector_size(cut_prob), size);
  311|      0|    }
  312|       |
  313|  3.76k|    added = IGRAPH_CALLOC(no_of_nodes, igraph_integer_t);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 2]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  314|  3.76k|    IGRAPH_CHECK_OOM(added, "Insufficient memory to find motifs.");
  ------------------
  |  |  701|  3.76k|    do { \
  |  |  702|  3.76k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  315|  3.76k|    IGRAPH_FINALLY(igraph_free, added);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  316|       |
  317|  3.76k|    subg = IGRAPH_CALLOC(no_of_nodes, char);
  ------------------
  |  |   38|  3.76k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|  7.53k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:24): [True: 3.76k, False: 0]
  |  |  |  |  |  Branch (36:66): [True: 3.76k, False: 2]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  318|  3.76k|    IGRAPH_CHECK_OOM(subg, "Insufficient memory to find motifs.");
  ------------------
  |  |  701|  3.76k|    do { \
  |  |  702|  3.76k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  319|  3.76k|    IGRAPH_FINALLY(igraph_free, subg);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  320|       |
  321|  3.76k|    IGRAPH_CHECK(igraph_adjlist_init(graph, &allneis, IGRAPH_ALL, IGRAPH_LOOPS_TWICE, IGRAPH_MULTIPLE));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  322|  3.76k|    IGRAPH_FINALLY(igraph_adjlist_destroy, &allneis);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  323|  3.76k|    IGRAPH_CHECK(igraph_adjlist_init(graph, &alloutneis, IGRAPH_OUT, IGRAPH_LOOPS_ONCE, IGRAPH_MULTIPLE));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  324|  3.76k|    IGRAPH_FINALLY(igraph_adjlist_destroy, &alloutneis);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  325|       |
  326|  3.76k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&vids, 0);
  ------------------
  |  |  124|  3.76k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  3.76k|    do { \
  |  |  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  3.76k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  3.76k|    do { \
  |  |  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  327|  3.76k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&adjverts, 0);
  ------------------
  |  |  124|  3.76k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  3.76k|    do { \
  |  |  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  3.76k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  3.76k|    do { \
  |  |  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  328|  3.76k|    IGRAPH_CHECK(igraph_stack_int_init(&stack, 0));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  329|  3.76k|    IGRAPH_FINALLY(igraph_stack_int_destroy, &stack);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  330|       |
  331|  3.76k|    RNG_BEGIN();
  ------------------
  |  |  170|  3.76k|    do { if (!igraph_rng_default()->is_seeded) { \
  |  |  ------------------
  |  |  |  Branch (170:14): [True: 0, False: 3.76k]
  |  |  ------------------
  |  |  171|      0|        igraph_rng_seed(igraph_rng_default(), time(0)); \
  |  |  172|      0|        igraph_rng_default()->is_seeded = true; \
  |  |  173|  3.76k|    } } while (0)
  |  |  ------------------
  |  |  |  Branch (173:16): [Folded - Ignored]
  |  |  ------------------
  ------------------
  332|       |
  333|   750k|    for (father = 0; father < no_of_nodes; father++) {
  ------------------
  |  Branch (333:22): [True: 746k, False: 3.76k]
  ------------------
  334|   746k|        igraph_integer_t level;
  335|       |
  336|   746k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|   746k|    do { \
  |  |   48|   746k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 746k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  337|       |
  338|   746k|        if (cut_prob) {
  ------------------
  |  Branch (338:13): [True: 373k, False: 373k]
  ------------------
  339|   373k|            if (VECTOR(*cut_prob)[0] == 1 || RNG_UNIF01() < VECTOR(*cut_prob)[0]) {
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          if (VECTOR(*cut_prob)[0] == 1 || RNG_UNIF01() < VECTOR(*cut_prob)[0]) {
  ------------------
  |  |  182|   373k|#define RNG_UNIF01()     (igraph_rng_get_unif01(igraph_rng_default()))
  ------------------
                          if (VECTOR(*cut_prob)[0] == 1 || RNG_UNIF01() < VECTOR(*cut_prob)[0]) {
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (339:17): [True: 0, False: 373k]
  |  Branch (339:46): [True: 0, False: 373k]
  ------------------
  340|      0|                continue;
  341|      0|            }
  342|   373k|        }
  343|       |
  344|       |        /* init G */
  345|   746k|        igraph_vector_int_clear(&vids); level = 0;
  346|   746k|        IGRAPH_CHECK(igraph_vector_int_push_back(&vids, father));
  ------------------
  |  |  648|   746k|    do { \
  |  |  649|   746k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   746k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   746k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 746k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   746k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  347|   746k|        subg[father] = 1; added[father] += 1; level += 1;
  348|       |
  349|       |        /* init V_E */
  350|   746k|        igraph_vector_int_clear(&adjverts);
  351|   746k|        neis = igraph_adjlist_get(&allneis, father);
  ------------------
  |  |   78|   746k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  352|   746k|        s = igraph_vector_int_size(neis);
  353|   969k|        for (i = 0; i < s; i++) {
  ------------------
  |  Branch (353:21): [True: 223k, False: 746k]
  ------------------
  354|   223k|            igraph_integer_t nei = VECTOR(*neis)[i];
  ------------------
  |  |   65|   223k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  355|   223k|            if (!added[nei] && nei > father) {
  ------------------
  |  Branch (355:17): [True: 168k, False: 54.8k]
  |  Branch (355:32): [True: 84.1k, False: 84.1k]
  ------------------
  356|  84.1k|                IGRAPH_CHECK(igraph_vector_int_push_back(&adjverts, nei));
  ------------------
  |  |  648|  84.1k|    do { \
  |  |  649|  84.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  84.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  84.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 84.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  84.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  357|  84.1k|                IGRAPH_CHECK(igraph_vector_int_push_back(&adjverts, father));
  ------------------
  |  |  648|  84.1k|    do { \
  |  |  649|  84.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  84.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  84.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 84.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  84.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  358|  84.1k|            }
  359|   223k|            added[nei] += 1;
  360|   223k|        }
  361|       |
  362|       |        /* init S */
  363|   746k|        igraph_stack_int_clear(&stack);
  364|       |
  365|  1.64M|        while (level > 1 || !igraph_vector_int_empty(&adjverts)) {
  ------------------
  |  Branch (365:16): [True: 812k, False: 830k]
  |  Branch (365:29): [True: 84.1k, False: 746k]
  ------------------
  366|   896k|            igraph_real_t cp = cut_prob ? VECTOR(*cut_prob)[level] : 0;
  ------------------
  |  |   65|   812k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (366:32): [True: 812k, False: 84.1k]
  ------------------
  367|       |
  368|   896k|            if (level == size - 1) {
  ------------------
  |  Branch (368:17): [True: 406k, False: 490k]
  ------------------
  369|   406k|                s = igraph_vector_int_size(&adjverts) / 2;
  370|  10.5M|                for (i = 0; i < s; i++) {
  ------------------
  |  Branch (370:29): [True: 10.1M, False: 406k]
  ------------------
  371|  10.1M|                    igraph_integer_t k, s2;
  372|  10.1M|                    igraph_integer_t last;
  373|  10.1M|                    igraph_error_t ret;
  374|       |
  375|  10.1M|                    if (cp != 0 && RNG_UNIF01() < cp) {
  ------------------
  |  |  182|      0|#define RNG_UNIF01()     (igraph_rng_get_unif01(igraph_rng_default()))
  ------------------
  |  Branch (375:25): [True: 0, False: 10.1M]
  |  Branch (375:36): [True: 0, False: 0]
  ------------------
  376|      0|                        continue;
  377|      0|                    }
  378|  10.1M|                    motifs += 1;
  379|       |
  380|  10.1M|                    last = VECTOR(adjverts)[2 * i];
  ------------------
  |  |   65|  10.1M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  381|  10.1M|                    IGRAPH_CHECK(igraph_vector_int_push_back(&vids, last));
  ------------------
  |  |  648|  10.1M|    do { \
  |  |  649|  10.1M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  10.1M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  10.1M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 10.1M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  10.1M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  382|  10.1M|                    subg[last] = (char) size;
  383|       |
  384|  10.1M|                    code = 0; idx = 0;
  385|  50.2M|                    for (k = 0; k < size; k++) {
  ------------------
  |  Branch (385:33): [True: 40.0M, False: 10.1M]
  ------------------
  386|  40.0M|                        igraph_integer_t from = VECTOR(vids)[k];
  ------------------
  |  |   65|  40.0M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  387|  40.0M|                        neis = igraph_adjlist_get(&alloutneis, from);
  ------------------
  |  |   78|  40.0M|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  388|  40.0M|                        s2 = igraph_vector_int_size(neis);
  389|  1.15G|                        for (j = 0; j < s2; j++) {
  ------------------
  |  Branch (389:37): [True: 1.11G, False: 40.0M]
  ------------------
  390|  1.11G|                            igraph_integer_t nei = VECTOR(*neis)[j];
  ------------------
  |  |   65|  1.11G|#define VECTOR(v) ((v).stor_begin)
  ------------------
  391|  1.11G|                            if (subg[nei] && k != subg[nei] - 1) {
  ------------------
  |  Branch (391:33): [True: 62.3M, False: 1.05G]
  |  Branch (391:46): [True: 59.4M, False: 2.90M]
  ------------------
  392|  59.4M|                                idx = (unsigned char) (mul * k + (subg[nei] - 1));
  393|  59.4M|                                code |= arr_idx[idx];
  394|  59.4M|                            }
  395|  1.11G|                        }
  396|  40.0M|                    }
  397|       |
  398|  10.1M|                    IGRAPH_CHECK_CALLBACK(
  ------------------
  |  |  681|  10.1M|    do { \
  |  |  682|  10.1M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  683|  10.1M|        *(code) = igraph_i_ret; \
  |  |  684|  10.1M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS && igraph_i_ret != IGRAPH_STOP)) { \
  |  |  ------------------
  |  |  |  |  604|  10.1M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 10.1M]
  |  |  |  |  |  Branch (604:50): [True: 0, False: 10.1M]
  |  |  |  |  |  Branch (604:50): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  685|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  686|      0|        } \
  |  |  687|  10.1M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (687:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  399|  10.1M|                        callback(graph, &vids, arr_code[code], extra),
  400|  10.1M|                        &ret
  401|  10.1M|                    );
  402|       |
  403|  10.1M|                    if (ret == IGRAPH_STOP) {
  ------------------
  |  Branch (403:25): [True: 0, False: 10.1M]
  ------------------
  404|      0|                        terminate = true;
  405|      0|                        break;
  406|      0|                    }
  407|       |
  408|  10.1M|                    igraph_vector_int_pop_back(&vids);
  409|  10.1M|                    subg[last] = 0;
  410|  10.1M|                }
  411|   406k|            }
  412|       |
  413|       |            /* did the callback function asked us to terminate the search? */
  414|   896k|            if (terminate) {
  ------------------
  |  Branch (414:17): [True: 0, False: 896k]
  ------------------
  415|      0|                break;
  416|      0|            }
  417|       |
  418|       |            /* can we step down? */
  419|   896k|            if (level < size - 1 &&
  ------------------
  |  Branch (419:17): [True: 490k, False: 406k]
  ------------------
  420|   896k|                !igraph_vector_int_empty(&adjverts)) {
  ------------------
  |  Branch (420:17): [True: 448k, False: 42.0k]
  ------------------
  421|       |                /* we might step down */
  422|   448k|                igraph_integer_t neifather = igraph_vector_int_pop_back(&adjverts);
  423|   448k|                igraph_integer_t nei = igraph_vector_int_pop_back(&adjverts);
  424|       |
  425|   448k|                if (cp == 0 || RNG_UNIF01() > cp) {
  ------------------
  |  |  182|      0|#define RNG_UNIF01()     (igraph_rng_get_unif01(igraph_rng_default()))
  ------------------
  |  Branch (425:21): [True: 448k, False: 0]
  |  Branch (425:32): [True: 0, False: 0]
  ------------------
  426|       |                    /* yes, step down */
  427|   448k|                    IGRAPH_CHECK(igraph_vector_int_push_back(&vids, nei));
  ------------------
  |  |  648|   448k|    do { \
  |  |  649|   448k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   448k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   448k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 448k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   448k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  428|   448k|                    subg[nei] = (char) level + 1; added[nei] += 1; level += 1;
  429|       |
  430|   448k|                    IGRAPH_CHECK(igraph_stack_int_push(&stack, neifather));
  ------------------
  |  |  648|   448k|    do { \
  |  |  649|   448k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   448k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   448k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 448k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   448k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  431|   448k|                    IGRAPH_CHECK(igraph_stack_int_push(&stack, nei));
  ------------------
  |  |  648|   448k|    do { \
  |  |  649|   448k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   448k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   448k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 448k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   448k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  432|   448k|                    IGRAPH_CHECK(igraph_stack_int_push(&stack, level));
  ------------------
  |  |  648|   448k|    do { \
  |  |  649|   448k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   448k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   448k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 448k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   448k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  433|       |
  434|   448k|                    neis = igraph_adjlist_get(&allneis, nei);
  ------------------
  |  |   78|   448k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  435|   448k|                    s = igraph_vector_int_size(neis);
  436|  1.62M|                    for (i = 0; i < s; i++) {
  ------------------
  |  Branch (436:33): [True: 1.17M, False: 448k]
  ------------------
  437|  1.17M|                        igraph_integer_t nei2 = VECTOR(*neis)[i];
  ------------------
  |  |   65|  1.17M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  438|  1.17M|                        if (!added[nei2] && nei2 > father) {
  ------------------
  |  Branch (438:29): [True: 479k, False: 695k]
  |  Branch (438:45): [True: 300k, False: 178k]
  ------------------
  439|   300k|                            IGRAPH_CHECK(igraph_vector_int_push_back(&adjverts, nei2));
  ------------------
  |  |  648|   300k|    do { \
  |  |  649|   300k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   300k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   300k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 300k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   300k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  440|   300k|                            IGRAPH_CHECK(igraph_vector_int_push_back(&adjverts, nei));
  ------------------
  |  |  648|   300k|    do { \
  |  |  649|   300k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   300k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   300k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 300k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   300k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  441|   300k|                        }
  442|  1.17M|                        added[nei2] += 1;
  443|  1.17M|                    }
  444|   448k|                }
  445|   448k|            } else {
  446|       |                /* no, step back */
  447|   448k|                igraph_integer_t nei, neifather;
  448|   812k|                while (!igraph_stack_int_empty(&stack) &&
  ------------------
  |  Branch (448:24): [True: 812k, False: 0]
  ------------------
  449|   812k|                       level == igraph_stack_int_top(&stack) - 1) {
  ------------------
  |  Branch (449:24): [True: 363k, False: 448k]
  ------------------
  450|   363k|                    igraph_stack_int_pop(&stack);
  451|   363k|                    nei = igraph_stack_int_pop(&stack);
  452|   363k|                    neifather = igraph_stack_int_pop(&stack);
  453|   363k|                    igraph_vector_int_push_back(&adjverts, nei);
  454|   363k|                    igraph_vector_int_push_back(&adjverts, neifather);
  455|   363k|                }
  456|       |
  457|   448k|                nei = igraph_vector_int_pop_back(&vids);
  458|   448k|                subg[nei] = 0; added[nei] -= 1; level -= 1;
  459|   448k|                neis = igraph_adjlist_get(&allneis, nei);
  ------------------
  |  |   78|   448k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  460|   448k|                s = igraph_vector_int_size(neis);
  461|  1.62M|                for (i = 0; i < s; i++) {
  ------------------
  |  Branch (461:29): [True: 1.17M, False: 448k]
  ------------------
  462|  1.17M|                    added[ VECTOR(*neis)[i] ] -= 1;
  ------------------
  |  |   65|  1.17M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  463|  1.17M|                }
  464|   748k|                while (!igraph_vector_int_empty(&adjverts) &&
  ------------------
  |  Branch (464:24): [True: 671k, False: 77.2k]
  ------------------
  465|   748k|                       igraph_vector_int_tail(&adjverts) == nei) {
  ------------------
  |  Branch (465:24): [True: 300k, False: 370k]
  ------------------
  466|   300k|                    igraph_vector_int_pop_back(&adjverts);
  467|   300k|                    igraph_vector_int_pop_back(&adjverts);
  468|   300k|                }
  469|   448k|            }
  470|       |
  471|   896k|        } /* while */
  472|       |
  473|       |        /* did the callback function asked us to terminate the search? */
  474|   746k|        if (terminate) {
  ------------------
  |  Branch (474:13): [True: 0, False: 746k]
  ------------------
  475|      0|            break;
  476|      0|        }
  477|       |
  478|       |        /* clear the added vector */
  479|   746k|        added[father] -= 1;
  480|   746k|        subg[father] = 0;
  481|   746k|        neis = igraph_adjlist_get(&allneis, father);
  ------------------
  |  |   78|   746k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
  482|   746k|        s = igraph_vector_int_size(neis);
  483|   969k|        for (i = 0; i < s; i++) {
  ------------------
  |  Branch (483:21): [True: 223k, False: 746k]
  ------------------
  484|   223k|            added[ VECTOR(*neis)[i] ] -= 1;
  ------------------
  |  |   65|   223k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  485|   223k|        }
  486|       |
  487|   746k|    } /* for father */
  488|       |
  489|  3.76k|    RNG_END();
  ------------------
  |  |  175|  3.76k|    do { /* nothing */ } while (0)
  |  |  ------------------
  |  |  |  Branch (175:33): [Folded - Ignored]
  |  |  ------------------
  ------------------
  490|       |
  491|  3.76k|    IGRAPH_FREE(added);
  ------------------
  |  |   41|  3.76k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  492|  3.76k|    IGRAPH_FREE(subg);
  ------------------
  |  |   41|  3.76k|#define IGRAPH_FREE(p)        (free( (void *)(p) ), (p) = NULL)
  ------------------
  493|  3.76k|    igraph_vector_int_destroy(&vids);
  494|  3.76k|    igraph_vector_int_destroy(&adjverts);
  495|  3.76k|    igraph_adjlist_destroy(&alloutneis);
  496|  3.76k|    igraph_adjlist_destroy(&allneis);
  497|  3.76k|    igraph_stack_int_destroy(&stack);
  498|  3.76k|    IGRAPH_FINALLY_CLEAN(7);
  499|       |
  500|  3.76k|    return IGRAPH_SUCCESS;
  501|  3.76k|}
motifs.c:igraph_i_motifs_randesu_update_hist:
   43|  10.1M|        igraph_vector_int_t *vids, igraph_integer_t isoclass, void* extra) {
   44|  10.1M|    igraph_vector_t *hist = (igraph_vector_t*)extra;
   45|  10.1M|    IGRAPH_UNUSED(graph); IGRAPH_UNUSED(vids);
  ------------------
  |  |   32|  10.1M|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
                  IGRAPH_UNUSED(graph); IGRAPH_UNUSED(vids);
  ------------------
  |  |   32|  10.1M|#define IGRAPH_UNUSED(x) (void)(x)
  ------------------
   46|  10.1M|    VECTOR(*hist)[isoclass]++;
  ------------------
  |  |   65|  10.1M|#define VECTOR(v) ((v).stor_begin)
  ------------------
   47|  10.1M|    return IGRAPH_SUCCESS;
   48|  10.1M|}

igraph_i_order_cycle:
   44|  32.7k|        igraph_vector_int_t *res) {
   45|       |
   46|  32.7k|    IGRAPH_HANDLE_EXCEPTIONS_BEGIN;
  ------------------
  |  |   21|  32.7k|    try {
  ------------------
   47|       |
   48|  32.7k|    igraph_integer_t n = igraph_vector_int_size(cycle);
   49|  32.7k|    IGRAPH_ASSERT(n > 0);
  ------------------
  |  |  916|  32.7k|    do { \
  |  |  917|  32.7k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   50|       |
   51|  32.7k|    std::map<igraph_integer_t, eid_pair_t> inclist;
   52|   113k|    for (igraph_integer_t i=0; i < n; ++i) {
  ------------------
  |  Branch (52:32): [True: 80.7k, False: 32.7k]
  ------------------
   53|  80.7k|        igraph_integer_t eid = VECTOR(*cycle)[i];
  ------------------
  |  |   65|  80.7k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   54|       |
   55|  80.7k|        {
   56|  80.7k|            igraph_integer_t from = IGRAPH_FROM(graph, eid);
  ------------------
  |  |  113|  80.7k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  80.7k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   57|  80.7k|            auto &p = inclist[from];
   58|  80.7k|            if (p.first < 0) {
  ------------------
  |  Branch (58:17): [True: 45.4k, False: 35.2k]
  ------------------
   59|  45.4k|                p.first = eid;
   60|  45.4k|            } else {
   61|  35.2k|                IGRAPH_ASSERT(p.second < 0);
  ------------------
  |  |  916|  35.2k|    do { \
  |  |  917|  35.2k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  35.2k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 35.2k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  35.2k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   62|  35.2k|                p.second = eid;
   63|  35.2k|            }
   64|  80.7k|        }
   65|       |
   66|  80.7k|        {
   67|  80.7k|            igraph_integer_t to = IGRAPH_TO(graph, eid);
  ------------------
  |  |  126|  80.7k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  80.7k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   68|  80.7k|            auto &p = inclist[to];
   69|  80.7k|            if (p.first < 0) {
  ------------------
  |  Branch (69:17): [True: 35.2k, False: 45.4k]
  ------------------
   70|  35.2k|                p.first = eid;
   71|  45.4k|            } else {
   72|  45.4k|                IGRAPH_ASSERT(p.second < 0);
  ------------------
  |  |  916|  45.4k|    do { \
  |  |  917|  45.4k|        if (IGRAPH_UNLIKELY(!(condition))) { \
  |  |  ------------------
  |  |  |  |  604|  45.4k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 45.4k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  918|      0|            igraph_fatal("Assertion failed: " #condition, IGRAPH_FILE_BASENAME, __LINE__); \
  |  |  919|      0|        } \
  |  |  920|  45.4k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (920:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   73|  45.4k|                p.second = eid;
   74|  45.4k|            }
   75|  80.7k|        }
   76|  80.7k|    }
   77|       |
   78|  32.7k|    igraph_vector_int_clear(res);
   79|  32.7k|    IGRAPH_CHECK(igraph_vector_int_reserve(res, igraph_vector_int_size(cycle)));
  ------------------
  |  |  648|  32.7k|    do { \
  |  |  649|  32.7k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  32.7k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  32.7k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 32.7k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  32.7k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   80|  32.7k|    igraph_integer_t current_e = VECTOR(*cycle)[0];
  ------------------
  |  |   65|  32.7k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   81|  32.7k|    igraph_integer_t current_v = IGRAPH_FROM(graph, current_e);
  ------------------
  |  |  113|  32.7k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  32.7k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   82|   113k|    for (igraph_integer_t i=0; i < n; ++i) {
  ------------------
  |  Branch (82:32): [True: 80.7k, False: 32.7k]
  ------------------
   83|  80.7k|        const auto &p = inclist.at(current_v);
   84|  80.7k|        igraph_vector_int_push_back(res, current_e); /* reserved */
   85|  80.7k|        igraph_integer_t next_e = p.first;
   86|  80.7k|        if (next_e == current_e) {
  ------------------
  |  Branch (86:13): [True: 45.3k, False: 35.3k]
  ------------------
   87|  45.3k|            next_e = p.second;
   88|  45.3k|        }
   89|  80.7k|        current_e = next_e;
   90|  80.7k|        igraph_integer_t next_v = IGRAPH_FROM(graph, current_e);
  ------------------
  |  |  113|  80.7k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  80.7k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   91|  80.7k|        if (next_v == current_v) {
  ------------------
  |  Branch (91:13): [True: 34.8k, False: 45.9k]
  ------------------
   92|  34.8k|            next_v = IGRAPH_TO(graph, current_e);
  ------------------
  |  |  126|  34.8k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  34.8k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   93|  34.8k|        }
   94|  80.7k|        current_v = next_v;
   95|  80.7k|    }
   96|       |
   97|  32.7k|    IGRAPH_HANDLE_EXCEPTIONS_END;
  ------------------
  |  |   23|  32.7k|    } \
  |  |   24|  32.7k|    catch (const std::bad_alloc &e) { IGRAPH_ERROR(e.what(), IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ } \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   25|  32.7k|    catch (const std::range_error &e) { IGRAPH_ERROR(e.what(), IGRAPH_EOVERFLOW); /* LCOV_EXCL_LINE */ } \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   26|  32.7k|    catch (const std::exception &e) { IGRAPH_ERROR(e.what(), IGRAPH_FAILURE); /* LCOV_EXCL_LINE */ } \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   27|  32.7k|    catch (...) { IGRAPH_ERROR("Unknown exception caught.", IGRAPH_FAILURE); /* LCOV_EXCL_LINE */ }
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   98|       |
   99|  32.7k|    return IGRAPH_SUCCESS;
  100|  32.7k|}
_ZN10eid_pair_tC2Ev:
   30|  80.7k|    eid_pair_t() : std::pair<igraph_integer_t, igraph_integer_t>(-1, -1) { }

igraph_reverse_edges:
   54|  1.88k|igraph_error_t igraph_reverse_edges(igraph_t *graph, const igraph_es_t eids) {
   55|  1.88k|    igraph_integer_t no_of_edges = igraph_ecount(graph);
   56|  1.88k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
   57|  1.88k|    igraph_vector_int_t edges;
   58|  1.88k|    igraph_eit_t eit;
   59|  1.88k|    igraph_t new_graph;
   60|       |
   61|       |    /* Nothing to do on undirected graph. */
   62|  1.88k|    if (! igraph_is_directed(graph)) {
  ------------------
  |  Branch (62:9): [True: 0, False: 1.88k]
  ------------------
   63|      0|        return IGRAPH_SUCCESS;
   64|      0|    }
   65|       |
   66|       |    /* Use fast method when all edges are to be reversed. */
   67|  1.88k|    if (igraph_es_is_all(&eids)) {
  ------------------
  |  Branch (67:9): [True: 0, False: 1.88k]
  ------------------
   68|      0|        return igraph_i_reverse(graph);
   69|      0|    }
   70|       |
   71|       |    /* Convert graph to edge list. */
   72|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&edges, 2*no_of_edges);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
   73|  1.88k|    IGRAPH_CHECK(igraph_get_edgelist(graph, &edges, /* bycol= */ false));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   74|       |
   75|       |    /* Reverse the edges. */
   76|       |
   77|  1.88k|    IGRAPH_CHECK(igraph_eit_create(graph, eids, &eit));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   78|  1.88k|    IGRAPH_FINALLY(igraph_eit_destroy, &eit);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   79|       |
   80|  57.3k|    for (; !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  370|  57.3k|#define IGRAPH_EIT_END(eit)   ((eit).pos >= (eit).end)
  ------------------
                  for (; !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  358|  55.4k|#define IGRAPH_EIT_NEXT(eit) (++((eit).pos))
  ------------------
  |  Branch (80:12): [True: 55.4k, False: 1.88k]
  ------------------
   81|  55.4k|        igraph_integer_t eid = IGRAPH_EIT_GET(eit);
  ------------------
  |  |  404|  55.4k|    (igraph_integer_t)((((eit).type == IGRAPH_EIT_RANGE) ? (eit).pos : \
  |  |  ------------------
  |  |  |  Branch (404:25): [True: 0, False: 55.4k]
  |  |  ------------------
  |  |  405|  55.4k|                        VECTOR(*(eit).vec)[(eit).pos]))
  |  |  ------------------
  |  |  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   82|  55.4k|        igraph_integer_t tmp = VECTOR(edges)[2*eid];
  ------------------
  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   83|  55.4k|        VECTOR(edges)[2*eid] = VECTOR(edges)[2*eid + 1];
  ------------------
  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                      VECTOR(edges)[2*eid] = VECTOR(edges)[2*eid + 1];
  ------------------
  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   84|  55.4k|        VECTOR(edges)[2*eid + 1] = tmp;
  ------------------
  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   85|  55.4k|    }
   86|       |
   87|       |    /* Re-create graph from edge list and transfer attributes. */
   88|  1.88k|    IGRAPH_CHECK(igraph_create(&new_graph, &edges, no_of_nodes, IGRAPH_DIRECTED));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   89|  1.88k|    IGRAPH_FINALLY(igraph_destroy, &new_graph);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   90|       |
   91|  1.88k|    IGRAPH_CHECK(igraph_i_attribute_copy(&new_graph, graph, true, true, true));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   92|       |
   93|  1.88k|    igraph_eit_destroy(&eit);
   94|  1.88k|    igraph_vector_int_destroy(&edges);
   95|  1.88k|    igraph_destroy(graph);
   96|  1.88k|    IGRAPH_FINALLY_CLEAN(3);
   97|       |
   98|  1.88k|    *graph = new_graph;
   99|       |
  100|  1.88k|    return IGRAPH_SUCCESS;
  101|  1.88k|}

igraph_induced_subgraph:
  321|  1.88k|                                       igraph_subgraph_implementation_t impl) {
  322|  1.88k|    return igraph_induced_subgraph_map(graph, res, vids, impl,
  323|       |                                       /* map= */ NULL, /* invmap= */ NULL);
  324|  1.88k|}
igraph_i_induced_subgraph_map:
  354|  1.88k|                                  igraph_bool_t map_is_prepared) {
  355|       |
  356|  1.88k|    if (impl == IGRAPH_SUBGRAPH_AUTO) {
  ------------------
  |  Branch (356:9): [True: 1.88k, False: 0]
  ------------------
  357|  1.88k|        IGRAPH_CHECK(igraph_i_induced_subgraph_suggest_implementation(graph, vids, &impl));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  358|  1.88k|    }
  359|       |
  360|  1.88k|    switch (impl) {
  361|    289|    case IGRAPH_SUBGRAPH_COPY_AND_DELETE:
  ------------------
  |  Branch (361:5): [True: 289, False: 1.59k]
  ------------------
  362|    289|        return igraph_i_induced_subgraph_copy_and_delete(graph, res, vids, map, invmap);
  363|       |
  364|  1.59k|    case IGRAPH_SUBGRAPH_CREATE_FROM_SCRATCH:
  ------------------
  |  Branch (364:5): [True: 1.59k, False: 289]
  ------------------
  365|  1.59k|        return igraph_i_induced_subgraph_create_from_scratch(graph, res, vids, map,
  366|  1.59k|                invmap, /* map_is_prepared = */ map_is_prepared);
  367|       |
  368|      0|    default:
  ------------------
  |  Branch (368:5): [True: 0, False: 1.88k]
  ------------------
  369|      0|        IGRAPH_ERROR("unknown subgraph implementation type", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  370|  1.88k|    }
  371|  1.88k|}
igraph_induced_subgraph_map:
  429|  1.88k|                                           igraph_vector_int_t *invmap) {
  430|  1.88k|    return igraph_i_induced_subgraph_map(graph, res, vids, impl,
  431|  1.88k|                                         map, invmap,
  432|       |                                         /* map_is_prepared = */ false);
  433|  1.88k|}
igraph_subgraph_from_edges:
  538|  1.88k|) {
  539|       |
  540|  1.88k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
  541|  1.88k|    igraph_integer_t no_of_edges = igraph_ecount(graph);
  542|  1.88k|    igraph_integer_t no_of_edges_to_delete_estimate;
  543|  1.88k|    igraph_vector_int_t delete = IGRAPH_VECTOR_NULL;
  ------------------
  |  |  104|  1.88k|    #define IGRAPH_VECTOR_NULL { 0,0,0 }
  ------------------
  544|  1.88k|    igraph_bitset_t vremain, eremain;
  545|  1.88k|    igraph_eit_t eit;
  546|       |
  547|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&delete, 0);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  548|  1.88k|    IGRAPH_BITSET_INIT_FINALLY(&vremain, no_of_nodes);
  ------------------
  |  |  261|  1.88k|#define IGRAPH_BITSET_INIT_FINALLY(bitset, size) \
  |  |  262|  1.88k|do { IGRAPH_CHECK(igraph_bitset_init(bitset, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  263|  1.88k|     IGRAPH_FINALLY(igraph_bitset_destroy, bitset); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (263:62): [Folded - Ignored]
  |  |  ------------------
  ------------------
  549|  1.88k|    IGRAPH_BITSET_INIT_FINALLY(&eremain, no_of_edges);
  ------------------
  |  |  261|  1.88k|#define IGRAPH_BITSET_INIT_FINALLY(bitset, size) \
  |  |  262|  1.88k|do { IGRAPH_CHECK(igraph_bitset_init(bitset, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  263|  1.88k|     IGRAPH_FINALLY(igraph_bitset_destroy, bitset); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (263:62): [Folded - Ignored]
  |  |  ------------------
  ------------------
  550|       |
  551|  1.88k|    IGRAPH_CHECK(igraph_eit_create(graph, eids, &eit));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  552|  1.88k|    IGRAPH_FINALLY(igraph_eit_destroy, &eit);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  553|       |
  554|       |    /* Calculate how many edges there will be in the new graph. The result is
  555|       |     * a lower bound only as 'eit' may contain the same edge more than once. */
  556|  1.88k|    no_of_edges_to_delete_estimate = no_of_edges - IGRAPH_EIT_SIZE(eit);
  ------------------
  |  |  381|  1.88k|#define IGRAPH_EIT_SIZE(eit)  ((eit).end - (eit).start)
  ------------------
  557|  1.88k|    if (no_of_edges_to_delete_estimate < 0) {
  ------------------
  |  Branch (557:9): [True: 0, False: 1.88k]
  ------------------
  558|      0|        no_of_edges_to_delete_estimate = 0;
  559|      0|    }
  560|       |
  561|  1.88k|    IGRAPH_CHECK(igraph_vector_int_reserve(&delete, no_of_edges_to_delete_estimate));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  562|       |
  563|       |    /* Collect the vertex and edge IDs that will remain */
  564|  57.3k|    for (IGRAPH_EIT_RESET(eit); !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  392|  1.88k|#define IGRAPH_EIT_RESET(eit) ((eit).pos = (eit).start)
  ------------------
                  for (IGRAPH_EIT_RESET(eit); !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  370|  57.3k|#define IGRAPH_EIT_END(eit)   ((eit).pos >= (eit).end)
  ------------------
                  for (IGRAPH_EIT_RESET(eit); !IGRAPH_EIT_END(eit); IGRAPH_EIT_NEXT(eit)) {
  ------------------
  |  |  358|  55.4k|#define IGRAPH_EIT_NEXT(eit) (++((eit).pos))
  ------------------
  |  Branch (564:33): [True: 55.4k, False: 1.88k]
  ------------------
  565|  55.4k|        igraph_integer_t eid = IGRAPH_EIT_GET(eit);
  ------------------
  |  |  404|  55.4k|    (igraph_integer_t)((((eit).type == IGRAPH_EIT_RANGE) ? (eit).pos : \
  |  |  ------------------
  |  |  |  Branch (404:25): [True: 0, False: 55.4k]
  |  |  ------------------
  |  |  405|  55.4k|                        VECTOR(*(eit).vec)[(eit).pos]))
  |  |  ------------------
  |  |  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  566|  55.4k|        igraph_integer_t from = IGRAPH_FROM(graph, eid), to = IGRAPH_TO(graph, eid);
  ------------------
  |  |  113|  55.4k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
                      igraph_integer_t from = IGRAPH_FROM(graph, eid), to = IGRAPH_TO(graph, eid);
  ------------------
  |  |  126|  55.4k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  567|  55.4k|        IGRAPH_BIT_SET(eremain, eid);
  ------------------
  |  |  105|  55.4k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  55.4k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  55.4k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  55.4k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  55.4k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  568|  55.4k|        IGRAPH_BIT_SET(vremain, from);
  ------------------
  |  |  105|  55.4k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  55.4k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  55.4k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  55.4k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  55.4k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  569|  55.4k|        IGRAPH_BIT_SET(vremain, to);
  ------------------
  |  |  105|  55.4k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  55.4k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  55.4k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  55.4k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  55.4k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  55.4k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  570|  55.4k|    }
  571|       |
  572|  1.88k|    igraph_eit_destroy(&eit);
  573|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  574|       |
  575|       |    /* Collect the edge IDs to be deleted */
  576|  69.4k|    for (igraph_integer_t i = 0; i < no_of_edges; i++) {
  ------------------
  |  Branch (576:34): [True: 67.5k, False: 1.88k]
  ------------------
  577|  67.5k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|  67.5k|    do { \
  |  |   48|  67.5k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 67.5k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|  67.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  578|  67.5k|        if (! IGRAPH_BIT_TEST(eremain, i)) {
  ------------------
  |  |  144|  67.5k|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  67.5k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  67.5k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  67.5k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  67.5k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (578:13): [True: 45.1k, False: 22.3k]
  ------------------
  579|  45.1k|            IGRAPH_CHECK(igraph_vector_int_push_back(&delete, i));
  ------------------
  |  |  648|  45.1k|    do { \
  |  |  649|  45.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  45.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  45.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 45.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  45.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  580|  45.1k|        }
  581|  67.5k|    }
  582|       |
  583|  1.88k|    igraph_bitset_destroy(&eremain);
  584|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  585|       |
  586|       |    /* Delete the unnecessary edges */
  587|  1.88k|    IGRAPH_CHECK(igraph_copy(res, graph));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  588|  1.88k|    IGRAPH_FINALLY(igraph_destroy, res);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  589|  1.88k|    IGRAPH_CHECK(igraph_delete_edges(res, igraph_ess_vector(&delete)));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  590|       |
  591|  1.88k|    if (delete_vertices) {
  ------------------
  |  Branch (591:9): [True: 1.88k, False: 0]
  ------------------
  592|       |        /* Collect the vertex IDs to be deleted */
  593|  1.88k|        igraph_vector_int_clear(&delete);
  594|   375k|        for (igraph_integer_t i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (594:38): [True: 373k, False: 1.88k]
  ------------------
  595|   373k|            IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|   373k|    do { \
  |  |   48|   373k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 373k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|   373k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  596|   373k|            if (! IGRAPH_BIT_TEST(vremain, i)) {
  ------------------
  |  |  144|   373k|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|   373k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|   373k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|   373k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (596:17): [True: 361k, False: 12.2k]
  ------------------
  597|   361k|                IGRAPH_CHECK(igraph_vector_int_push_back(&delete, i));
  ------------------
  |  |  648|   361k|    do { \
  |  |  649|   361k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|   361k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|   361k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 361k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|   361k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  598|   361k|            }
  599|   373k|        }
  600|  1.88k|    }
  601|       |
  602|  1.88k|    igraph_bitset_destroy(&vremain);
  603|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  604|       |
  605|       |    /* Delete the unnecessary vertices */
  606|  1.88k|    if (delete_vertices) {
  ------------------
  |  Branch (606:9): [True: 1.88k, False: 0]
  ------------------
  607|  1.88k|        IGRAPH_CHECK(igraph_delete_vertices(res, igraph_vss_vector(&delete)));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  608|  1.88k|    }
  609|       |
  610|  1.88k|    igraph_vector_int_destroy(&delete);
  611|  1.88k|    IGRAPH_FINALLY_CLEAN(2);
  612|       |
  613|  1.88k|    return IGRAPH_SUCCESS;
  614|  1.88k|}
subgraph.c:igraph_i_induced_subgraph_suggest_implementation:
  328|  1.88k|        igraph_subgraph_implementation_t *result) {
  329|  1.88k|    double ratio;
  330|  1.88k|    igraph_integer_t num_vs;
  331|       |
  332|  1.88k|    if (igraph_vs_is_all(&vids)) {
  ------------------
  |  Branch (332:9): [True: 0, False: 1.88k]
  ------------------
  333|      0|        ratio = 1.0;
  334|  1.88k|    } else {
  335|  1.88k|        IGRAPH_CHECK(igraph_vs_size(graph, &vids, &num_vs));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  336|  1.88k|        ratio = (igraph_real_t) num_vs / igraph_vcount(graph);
  337|  1.88k|    }
  338|       |
  339|       |    /* TODO: needs benchmarking; threshold was chosen totally arbitrarily */
  340|  1.88k|    if (ratio > 0.5) {
  ------------------
  |  Branch (340:9): [True: 289, False: 1.59k]
  ------------------
  341|    289|        *result = IGRAPH_SUBGRAPH_COPY_AND_DELETE;
  342|  1.59k|    } else {
  343|  1.59k|        *result = IGRAPH_SUBGRAPH_CREATE_FROM_SCRATCH;
  344|  1.59k|    }
  345|       |
  346|  1.88k|    return IGRAPH_SUCCESS;
  347|  1.88k|}
subgraph.c:igraph_i_induced_subgraph_copy_and_delete:
   37|    289|        igraph_vector_int_t *map, igraph_vector_int_t *invmap) {
   38|       |
   39|    289|    const igraph_integer_t no_of_nodes = igraph_vcount(graph);
   40|    289|    igraph_integer_t no_of_new_nodes_estimate;
   41|    289|    igraph_vector_int_t delete;
   42|    289|    igraph_bitset_t remain;
   43|    289|    igraph_vit_t vit;
   44|       |
   45|    289|    IGRAPH_CHECK(igraph_vit_create(graph, vids, &vit));
  ------------------
  |  |  648|    289|    do { \
  |  |  649|    289|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|    289|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|    289|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 289]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|    289|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   46|    289|    IGRAPH_FINALLY(igraph_vit_destroy, &vit);
  ------------------
  |  |  591|    289|    do { \
  |  |  592|    289|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|    289|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|    289|         * incorrect destructor function with the pointer */ \
  |  |  595|    289|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|    289|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|    289|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   47|       |
   48|    289|    IGRAPH_VECTOR_INT_INIT_FINALLY(&delete, 0);
  ------------------
  |  |  124|    289|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|    289|    do { \
  |  |  |  |  649|    289|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|    289|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|    289|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 289]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|    289|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|    289|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|    289|    do { \
  |  |  |  |  592|    289|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|    289|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|    289|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|    289|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|    289|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|    289|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
   49|    289|    IGRAPH_BITSET_INIT_FINALLY(&remain, no_of_nodes);
  ------------------
  |  |  261|    289|#define IGRAPH_BITSET_INIT_FINALLY(bitset, size) \
  |  |  262|    289|do { IGRAPH_CHECK(igraph_bitset_init(bitset, size)); \
  |  |  ------------------
  |  |  |  |  648|    289|    do { \
  |  |  |  |  649|    289|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|    289|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|    289|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 289]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|    289|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  263|    289|     IGRAPH_FINALLY(igraph_bitset_destroy, bitset); } while (0)
  |  |  ------------------
  |  |  |  |  591|    289|    do { \
  |  |  |  |  592|    289|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|    289|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|    289|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|    289|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|    289|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|    289|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (263:62): [Folded - Ignored]
  |  |  ------------------
  ------------------
   50|       |
   51|       |    /* Calculate how many nodes there will be in the new graph. The result is
   52|       |     * a lower bound only as 'vit' may contain the same vertex more than once. */
   53|    289|    no_of_new_nodes_estimate = no_of_nodes - IGRAPH_VIT_SIZE(vit);
  ------------------
  |  |  191|    289|#define IGRAPH_VIT_SIZE(vit)  ((vit).end - (vit).start)
  ------------------
   54|    289|    if (no_of_new_nodes_estimate < 0) {
  ------------------
  |  Branch (54:9): [True: 110, False: 179]
  ------------------
   55|    110|        no_of_new_nodes_estimate = 0;
   56|    110|    }
   57|       |
   58|    289|    IGRAPH_CHECK(igraph_vector_int_reserve(&delete, no_of_new_nodes_estimate));
  ------------------
  |  |  648|    289|    do { \
  |  |  649|    289|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|    289|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|    289|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 289]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|    289|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   59|       |
   60|  25.3k|    for (IGRAPH_VIT_RESET(vit); !IGRAPH_VIT_END(vit); IGRAPH_VIT_NEXT(vit)) {
  ------------------
  |  |  202|    289|#define IGRAPH_VIT_RESET(vit) ((vit).pos = (vit).start)
  ------------------
                  for (IGRAPH_VIT_RESET(vit); !IGRAPH_VIT_END(vit); IGRAPH_VIT_NEXT(vit)) {
  ------------------
  |  |  180|  25.3k|#define IGRAPH_VIT_END(vit)   ((vit).pos >= (vit).end)
  ------------------
                  for (IGRAPH_VIT_RESET(vit); !IGRAPH_VIT_END(vit); IGRAPH_VIT_NEXT(vit)) {
  ------------------
  |  |  168|  25.0k|#define IGRAPH_VIT_NEXT(vit)  (++((vit).pos))
  ------------------
  |  Branch (60:33): [True: 25.0k, False: 289]
  ------------------
   61|  25.0k|        IGRAPH_BIT_SET(remain, IGRAPH_VIT_GET(vit));
  ------------------
  |  |  105|  25.0k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  25.0k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  50.0k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  25.0k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (87:30): [True: 0, False: 25.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  50.0k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  25.0k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (68:53): [True: 0, False: 25.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   62|  25.0k|    }
   63|       |
   64|  32.1k|    for (igraph_integer_t i = 0; i < no_of_nodes; i++) {
  ------------------
  |  Branch (64:34): [True: 31.8k, False: 289]
  ------------------
   65|  31.8k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|  31.8k|    do { \
  |  |   48|  31.8k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 31.8k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|  31.8k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   66|       |
   67|  31.8k|        if (! IGRAPH_BIT_TEST(remain, i)) {
  ------------------
  |  |  144|  31.8k|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  31.8k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  31.8k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  31.8k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  31.8k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  31.8k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  |  Branch (67:13): [True: 28.0k, False: 3.81k]
  ------------------
   68|  28.0k|            IGRAPH_CHECK(igraph_vector_int_push_back(&delete, i));
  ------------------
  |  |  648|  28.0k|    do { \
  |  |  649|  28.0k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  28.0k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  28.0k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 28.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  28.0k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   69|  28.0k|        }
   70|  31.8k|    }
   71|       |
   72|    289|    igraph_bitset_destroy(&remain);
   73|    289|    IGRAPH_FINALLY_CLEAN(1);
   74|       |
   75|    289|    IGRAPH_CHECK(igraph_copy(res, graph));
  ------------------
  |  |  648|    289|    do { \
  |  |  649|    289|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|    289|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|    289|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 289]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|    289|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   76|    289|    IGRAPH_FINALLY(igraph_destroy, res);
  ------------------
  |  |  591|    289|    do { \
  |  |  592|    289|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|    289|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|    289|         * incorrect destructor function with the pointer */ \
  |  |  595|    289|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|    289|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|    289|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   77|    289|    IGRAPH_CHECK(igraph_delete_vertices_map(res, igraph_vss_vector(&delete),
  ------------------
  |  |  648|    289|    do { \
  |  |  649|    289|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|    289|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|    289|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 289]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|    289|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   78|    289|                                            map, invmap));
   79|       |
   80|    289|    igraph_vector_int_destroy(&delete);
   81|    289|    igraph_vit_destroy(&vit);
   82|    289|    IGRAPH_FINALLY_CLEAN(3);
   83|       |
   84|    289|    return IGRAPH_SUCCESS;
   85|    289|}
subgraph.c:igraph_i_induced_subgraph_create_from_scratch:
  100|  1.59k|        igraph_bool_t map_is_prepared) {
  101|       |
  102|  1.59k|    const igraph_bool_t directed = igraph_is_directed(graph);
  103|  1.59k|    const igraph_integer_t no_of_nodes = igraph_vcount(graph);
  104|  1.59k|    igraph_integer_t no_of_new_nodes = 0;
  105|  1.59k|    igraph_integer_t n;
  106|  1.59k|    igraph_integer_t to;
  107|  1.59k|    igraph_integer_t eid;
  108|  1.59k|    igraph_vector_int_t vids_old2new, vids_new2old;
  109|  1.59k|    igraph_vector_int_t eids_new2old;
  110|  1.59k|    igraph_vector_int_t vids_vec;
  111|  1.59k|    igraph_vector_int_t nei_edges;
  112|  1.59k|    igraph_vector_int_t new_edges;
  113|  1.59k|    igraph_vit_t vit;
  114|  1.59k|    igraph_vector_int_t *my_vids_old2new = &vids_old2new,
  115|  1.59k|                        *my_vids_new2old = &vids_new2old;
  116|       |
  117|       |    /* The order of initialization is important here, they will be destroyed in the
  118|       |     * opposite order */
  119|  1.59k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&eids_new2old, 0);
  ------------------
  |  |  124|  1.59k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.59k|    do { \
  |  |  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.59k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.59k|    do { \
  |  |  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  120|  1.59k|    if (invmap) {
  ------------------
  |  Branch (120:9): [True: 0, False: 1.59k]
  ------------------
  121|      0|        my_vids_new2old = invmap;
  122|      0|        igraph_vector_int_clear(my_vids_new2old);
  123|  1.59k|    } else {
  124|  1.59k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&vids_new2old, 0);
  ------------------
  |  |  124|  1.59k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.59k|    do { \
  |  |  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.59k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.59k|    do { \
  |  |  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  125|  1.59k|    }
  126|  1.59k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&new_edges, 0);
  ------------------
  |  |  124|  1.59k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.59k|    do { \
  |  |  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.59k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.59k|    do { \
  |  |  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  127|  1.59k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&nei_edges, 0);
  ------------------
  |  |  124|  1.59k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.59k|    do { \
  |  |  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.59k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.59k|    do { \
  |  |  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  128|  1.59k|    if (map) {
  ------------------
  |  Branch (128:9): [True: 0, False: 1.59k]
  ------------------
  129|      0|        my_vids_old2new = map;
  130|      0|        if (!map_is_prepared) {
  ------------------
  |  Branch (130:13): [True: 0, False: 0]
  ------------------
  131|      0|            IGRAPH_CHECK(igraph_vector_int_resize(map, no_of_nodes));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  132|      0|            igraph_vector_int_fill(map, -1);
  133|      0|        }
  134|  1.59k|    } else {
  135|  1.59k|        IGRAPH_VECTOR_INT_INIT_FINALLY(&vids_old2new, no_of_nodes);
  ------------------
  |  |  124|  1.59k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.59k|    do { \
  |  |  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.59k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.59k|    do { \
  |  |  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  136|  1.59k|        igraph_vector_int_fill(&vids_old2new, -1);
  137|  1.59k|    }
  138|  1.59k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&vids_vec, 0);
  ------------------
  |  |  124|  1.59k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.59k|    do { \
  |  |  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.59k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.59k|    do { \
  |  |  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.59k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  139|       |
  140|  1.59k|    IGRAPH_CHECK(igraph_vit_create(graph, vids, &vit));
  ------------------
  |  |  648|  1.59k|    do { \
  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  141|  1.59k|    IGRAPH_FINALLY(igraph_vit_destroy, &vit);
  ------------------
  |  |  591|  1.59k|    do { \
  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  142|       |
  143|       |    /* Calculate the mapping from the old node IDs to the new ones. The other
  144|       |     * igraph_simplify implementation in igraph_i_simplify_copy_and_delete
  145|       |     * ensures that the order of vertex IDs is kept during remapping (i.e.
  146|       |     * if the old ID of vertex A is less than the old ID of vertex B, then
  147|       |     * the same will also be true for the new IDs). To ensure compatibility
  148|       |     * with the other implementation, we have to fetch the vertex IDs into
  149|       |     * a vector first and then sort it.
  150|       |     */
  151|  1.59k|    IGRAPH_CHECK(igraph_vit_as_vector(&vit, &vids_vec));
  ------------------
  |  |  648|  1.59k|    do { \
  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  152|  1.59k|    igraph_vit_destroy(&vit);
  153|  1.59k|    IGRAPH_FINALLY_CLEAN(1);
  154|       |
  155|  1.59k|    igraph_vector_int_sort(&vids_vec);
  156|  1.59k|    n = igraph_vector_int_size(&vids_vec);
  157|  33.8k|    for (igraph_integer_t i = 0; i < n; i++) {
  ------------------
  |  Branch (157:34): [True: 32.2k, False: 1.59k]
  ------------------
  158|  32.2k|        igraph_integer_t vid = VECTOR(vids_vec)[i];
  ------------------
  |  |   65|  32.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  159|       |
  160|       |        /* Cater for duplicate vertex IDs in the input vertex selector; we use
  161|       |         * the first occurrence of each vertex ID and ignore the rest */
  162|  32.2k|        if (VECTOR(*my_vids_old2new)[vid] < 0) {
  ------------------
  |  |   65|  32.2k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (162:13): [True: 8.85k, False: 23.4k]
  ------------------
  163|  8.85k|            IGRAPH_CHECK(igraph_vector_int_push_back(my_vids_new2old, vid));
  ------------------
  |  |  648|  8.85k|    do { \
  |  |  649|  8.85k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  8.85k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  8.85k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.85k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  8.85k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  164|  8.85k|            VECTOR(*my_vids_old2new)[vid] = no_of_new_nodes;
  ------------------
  |  |   65|  8.85k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  165|  8.85k|            no_of_new_nodes++;
  166|  8.85k|        }
  167|  32.2k|    }
  168|  1.59k|    igraph_vector_int_destroy(&vids_vec);
  169|  1.59k|    IGRAPH_FINALLY_CLEAN(1);
  170|       |
  171|       |    /* Create the new edge list */
  172|  10.4k|    for (igraph_integer_t i = 0; i < no_of_new_nodes; i++) {
  ------------------
  |  Branch (172:34): [True: 8.85k, False: 1.59k]
  ------------------
  173|  8.85k|        igraph_integer_t old_vid = VECTOR(*my_vids_new2old)[i];
  ------------------
  |  |   65|  8.85k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  174|  8.85k|        igraph_integer_t new_vid = i;
  175|  8.85k|        igraph_bool_t skip_loop_edge;
  176|       |
  177|  8.85k|        IGRAPH_CHECK(igraph_incident(graph, &nei_edges, old_vid, IGRAPH_OUT));
  ------------------
  |  |  648|  8.85k|    do { \
  |  |  649|  8.85k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  8.85k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  8.85k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 8.85k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  8.85k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  178|  8.85k|        n = igraph_vector_int_size(&nei_edges);
  179|       |
  180|  8.85k|        if (directed) {
  ------------------
  |  Branch (180:13): [True: 8.85k, False: 0]
  ------------------
  181|       |            /* directed graph; this is easier */
  182|  27.4k|            for (igraph_integer_t j = 0; j < n; j++) {
  ------------------
  |  Branch (182:42): [True: 18.6k, False: 8.85k]
  ------------------
  183|  18.6k|                eid = VECTOR(nei_edges)[j];
  ------------------
  |  |   65|  18.6k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  184|       |
  185|  18.6k|                to = VECTOR(*my_vids_old2new)[ IGRAPH_TO(graph, eid) ];
  ------------------
  |  |   65|  18.6k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              to = VECTOR(*my_vids_old2new)[ IGRAPH_TO(graph, eid) ];
  ------------------
  |  |  126|  18.6k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  18.6k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  186|  18.6k|                if (to < 0) {
  ------------------
  |  Branch (186:21): [True: 2.50k, False: 16.1k]
  ------------------
  187|  2.50k|                    continue;
  188|  2.50k|                }
  189|       |
  190|  16.1k|                IGRAPH_CHECK(igraph_vector_int_push_back(&new_edges, new_vid));
  ------------------
  |  |  648|  16.1k|    do { \
  |  |  649|  16.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  16.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  16.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 16.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  16.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  191|  16.1k|                IGRAPH_CHECK(igraph_vector_int_push_back(&new_edges, to));
  ------------------
  |  |  648|  16.1k|    do { \
  |  |  649|  16.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  16.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  16.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 16.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  16.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  192|  16.1k|                IGRAPH_CHECK(igraph_vector_int_push_back(&eids_new2old, eid));
  ------------------
  |  |  648|  16.1k|    do { \
  |  |  649|  16.1k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  16.1k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  16.1k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 16.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  16.1k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  193|  16.1k|            }
  194|  8.85k|        } else {
  195|       |            /* undirected graph. We need to be careful with loop edges as each
  196|       |             * loop edge will appear twice. We use a boolean flag to skip every
  197|       |             * second loop edge */
  198|      0|            skip_loop_edge = 0;
  199|      0|            for (igraph_integer_t j = 0; j < n; j++) {
  ------------------
  |  Branch (199:42): [True: 0, False: 0]
  ------------------
  200|      0|                eid = VECTOR(nei_edges)[j];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  201|       |
  202|      0|                if (IGRAPH_FROM(graph, eid) != old_vid) {
  ------------------
  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  |  Branch (202:21): [True: 0, False: 0]
  ------------------
  203|       |                    /* avoid processing edges twice */
  204|      0|                    continue;
  205|      0|                }
  206|       |
  207|      0|                to = VECTOR(*my_vids_old2new)[ IGRAPH_TO(graph, eid) ];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                              to = VECTOR(*my_vids_old2new)[ IGRAPH_TO(graph, eid) ];
  ------------------
  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  208|      0|                if (to < 0) {
  ------------------
  |  Branch (208:21): [True: 0, False: 0]
  ------------------
  209|      0|                    continue;
  210|      0|                }
  211|       |
  212|      0|                if (new_vid == to) {
  ------------------
  |  Branch (212:21): [True: 0, False: 0]
  ------------------
  213|       |                    /* this is a loop edge; check whether we need to skip it */
  214|      0|                    skip_loop_edge = !skip_loop_edge;
  215|      0|                    if (skip_loop_edge) {
  ------------------
  |  Branch (215:25): [True: 0, False: 0]
  ------------------
  216|      0|                        continue;
  217|      0|                    }
  218|      0|                }
  219|       |
  220|      0|                IGRAPH_CHECK(igraph_vector_int_push_back(&new_edges, new_vid));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  221|      0|                IGRAPH_CHECK(igraph_vector_int_push_back(&new_edges, to));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  222|      0|                IGRAPH_CHECK(igraph_vector_int_push_back(&eids_new2old, eid));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  223|      0|            }
  224|      0|        }
  225|  8.85k|    }
  226|       |
  227|       |    /* Get rid of some vectors that are not needed anymore */
  228|  1.59k|    if (!map) {
  ------------------
  |  Branch (228:9): [True: 1.59k, False: 0]
  ------------------
  229|  1.59k|        igraph_vector_int_destroy(&vids_old2new);
  230|  1.59k|        IGRAPH_FINALLY_CLEAN(1);
  231|  1.59k|    }
  232|  1.59k|    igraph_vector_int_destroy(&nei_edges);
  233|  1.59k|    IGRAPH_FINALLY_CLEAN(1);
  234|       |
  235|       |    /* Create the new graph */
  236|  1.59k|    IGRAPH_CHECK(igraph_create(res, &new_edges, no_of_new_nodes, directed));
  ------------------
  |  |  648|  1.59k|    do { \
  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  237|       |
  238|       |    /* Now we can also get rid of the new_edges vector */
  239|  1.59k|    igraph_vector_int_destroy(&new_edges);
  240|  1.59k|    IGRAPH_FINALLY_CLEAN(1);
  241|       |
  242|       |    /* Make sure that the newly created graph is destroyed if something happens from
  243|       |     * now on */
  244|  1.59k|    IGRAPH_FINALLY(igraph_destroy, res);
  ------------------
  |  |  591|  1.59k|    do { \
  |  |  592|  1.59k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.59k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.59k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.59k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.59k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  245|       |
  246|       |    /* Copy the graph attributes */
  247|  1.59k|    IGRAPH_CHECK(igraph_i_attribute_copy(res, graph, true, /* vertex= */ false, /* edge= */ false));
  ------------------
  |  |  648|  1.59k|    do { \
  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  248|       |
  249|       |    /* Copy the vertex attributes */
  250|  1.59k|    IGRAPH_CHECK(igraph_i_attribute_permute_vertices(graph, res, my_vids_new2old));
  ------------------
  |  |  648|  1.59k|    do { \
  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  251|       |
  252|       |    /* Copy the edge attributes */
  253|  1.59k|    IGRAPH_CHECK(igraph_i_attribute_permute_edges(graph, res, &eids_new2old));
  ------------------
  |  |  648|  1.59k|    do { \
  |  |  649|  1.59k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.59k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.59k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.59k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.59k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  254|       |
  255|       |    /* Get rid of the remaining stuff */
  256|  1.59k|    if (!invmap) {
  ------------------
  |  Branch (256:9): [True: 1.59k, False: 0]
  ------------------
  257|  1.59k|        igraph_vector_int_destroy(my_vids_new2old);
  258|  1.59k|        IGRAPH_FINALLY_CLEAN(1);
  259|  1.59k|    }
  260|  1.59k|    igraph_vector_int_destroy(&eids_new2old);
  261|  1.59k|    IGRAPH_FINALLY_CLEAN(2);   /* 1 + 1 since we don't need to destroy res */
  262|       |
  263|  1.59k|    return IGRAPH_SUCCESS;
  264|  1.59k|}

igraph_random_walk:
  304|  3.76k|                       igraph_random_walk_stuck_t stuck) {
  305|       |
  306|  3.76k|    igraph_integer_t vc = igraph_vcount(graph);
  307|  3.76k|    igraph_integer_t ec = igraph_ecount(graph);
  308|       |
  309|  3.76k|    if (!(mode == IGRAPH_ALL || mode == IGRAPH_IN || mode == IGRAPH_OUT)) {
  ------------------
  |  Branch (309:11): [True: 3.76k, False: 0]
  |  Branch (309:33): [True: 0, False: 0]
  |  Branch (309:54): [True: 0, False: 0]
  ------------------
  310|      0|        IGRAPH_ERROR("Invalid mode parameter.", IGRAPH_EINVMODE);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  311|      0|    }
  312|       |
  313|  3.76k|    if (start < 0 || start >= vc) {
  ------------------
  |  Branch (313:9): [True: 0, False: 3.76k]
  |  Branch (313:22): [True: 0, False: 3.76k]
  ------------------
  314|      0|        IGRAPH_ERRORF("Starting vertex must be between 0 and the "
  ------------------
  |  |  469|      0|    do { \
  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  472|      0|        return igraph_errno; \
  |  |  473|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  315|      0|                      "number of vertices in the graph (%" IGRAPH_PRId
  316|      0|                      "), got %" IGRAPH_PRId ".", IGRAPH_EINVAL,
  317|      0|                      vc, start);
  318|      0|    }
  319|  3.76k|    if (steps < 0) {
  ------------------
  |  Branch (319:9): [True: 0, False: 3.76k]
  ------------------
  320|      0|        IGRAPH_ERRORF("Number of steps should be non-negative, got %"
  ------------------
  |  |  469|      0|    do { \
  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  472|      0|        return igraph_errno; \
  |  |  473|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  321|      0|                      IGRAPH_PRId ".", IGRAPH_EINVAL, steps);
  322|      0|    }
  323|       |
  324|  3.76k|    if (weights) {
  ------------------
  |  Branch (324:9): [True: 0, False: 3.76k]
  ------------------
  325|      0|        if (igraph_vector_size(weights) != ec) {
  ------------------
  |  Branch (325:13): [True: 0, False: 0]
  ------------------
  326|      0|            IGRAPH_ERROR("Invalid weight vector length.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  327|      0|        }
  328|      0|        if (ec > 0) {
  ------------------
  |  Branch (328:13): [True: 0, False: 0]
  ------------------
  329|      0|            igraph_real_t min = igraph_vector_min(weights);
  330|      0|            if (min < 0) {
  ------------------
  |  Branch (330:17): [True: 0, False: 0]
  ------------------
  331|      0|                IGRAPH_ERROR("Weights must be non-negative.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  332|      0|            } else if (isnan(min)) {
  333|      0|                IGRAPH_ERROR("Weights must not contain NaN values.", IGRAPH_EINVAL);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  334|      0|            }
  335|      0|        }
  336|      0|    }
  337|       |
  338|  3.76k|    if (!igraph_is_directed(graph)) {
  ------------------
  |  Branch (338:9): [True: 1.88k, False: 1.88k]
  ------------------
  339|  1.88k|        mode = IGRAPH_ALL;
  340|  1.88k|    }
  341|       |
  342|  3.76k|    if (edges || weights) {
  ------------------
  |  Branch (342:9): [True: 3.76k, False: 0]
  |  Branch (342:18): [True: 0, False: 0]
  ------------------
  343|  3.76k|        return igraph_i_random_walk_inclist(graph, weights, vertices, edges,
  344|  3.76k|                                            start, mode, steps, stuck);
  345|  3.76k|    } else {
  346|      0|        return igraph_i_random_walk_adjlist(graph, vertices,
  347|      0|                                            start, mode, steps, stuck);
  348|      0|    }
  349|  3.76k|}
random_walk.c:igraph_i_random_walk_inclist:
  128|  3.76k|        igraph_random_walk_stuck_t stuck) {
  129|       |
  130|  3.76k|    igraph_integer_t vc = igraph_vcount(graph);
  131|  3.76k|    igraph_integer_t i, next;
  132|  3.76k|    igraph_vector_t weight_temp;
  133|  3.76k|    igraph_lazy_inclist_t il;
  134|  3.76k|    igraph_vector_ptr_t cdfs; /* cumulative distribution vectors for each node, used for weighted choice */
  135|       |
  136|  3.76k|    if (vertices) {
  ------------------
  |  Branch (136:9): [True: 3.76k, False: 0]
  ------------------
  137|  3.76k|        IGRAPH_CHECK(igraph_vector_int_resize(vertices, steps + 1)); /* size: steps + 1 because vertices includes start vertex */
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  138|  3.76k|    }
  139|  3.76k|    if (edges) {
  ------------------
  |  Branch (139:9): [True: 3.76k, False: 0]
  ------------------
  140|  3.76k|        IGRAPH_CHECK(igraph_vector_int_resize(edges, steps));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  141|  3.76k|    }
  142|       |
  143|  3.76k|    IGRAPH_CHECK(igraph_lazy_inclist_init(graph, &il, mode, IGRAPH_LOOPS));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  144|  3.76k|    IGRAPH_FINALLY(igraph_lazy_inclist_destroy, &il);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  145|       |
  146|  3.76k|    IGRAPH_VECTOR_INIT_FINALLY(&weight_temp, 0);
  ------------------
  |  |  109|  3.76k|    do { IGRAPH_CHECK(igraph_vector_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  3.76k|    do { \
  |  |  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  110|  3.76k|        IGRAPH_FINALLY(igraph_vector_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  3.76k|    do { \
  |  |  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  3.76k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (110:60): [Folded - Ignored]
  |  |  ------------------
  ------------------
  147|       |
  148|       |    /* cdf vectors will be computed lazily; that's why we are still using
  149|       |     * igraph_vector_ptr_t as it does not require us to pre-initialize all
  150|       |     * the vectors in the vector list */
  151|  3.76k|    IGRAPH_CHECK(igraph_vector_ptr_init(&cdfs, vc));
  ------------------
  |  |  648|  3.76k|    do { \
  |  |  649|  3.76k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  3.76k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  3.76k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 3.76k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  152|  3.76k|    IGRAPH_FINALLY(igraph_vector_ptr_destroy_all, &cdfs);
  ------------------
  |  |  591|  3.76k|    do { \
  |  |  592|  3.76k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  3.76k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  3.76k|         * incorrect destructor function with the pointer */ \
  |  |  595|  3.76k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  3.76k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  3.76k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  153|  3.76k|    IGRAPH_VECTOR_PTR_SET_ITEM_DESTRUCTOR(&cdfs, vec_destr);
  ------------------
  |  |  100|  3.76k|    igraph_vector_ptr_set_item_destructor((v), (igraph_finally_func_t*)(func))
  ------------------
  154|   750k|    for (i = 0; i < vc; ++i) {
  ------------------
  |  Branch (154:17): [True: 746k, False: 3.76k]
  ------------------
  155|   746k|        VECTOR(cdfs)[i] = NULL;
  ------------------
  |  |   65|   746k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  156|   746k|    }
  157|       |
  158|  3.76k|    RNG_BEGIN();
  ------------------
  |  |  170|  3.76k|    do { if (!igraph_rng_default()->is_seeded) { \
  |  |  ------------------
  |  |  |  Branch (170:14): [True: 0, False: 3.76k]
  |  |  ------------------
  |  |  171|      0|        igraph_rng_seed(igraph_rng_default(), time(0)); \
  |  |  172|      0|        igraph_rng_default()->is_seeded = true; \
  |  |  173|  3.76k|    } } while (0)
  |  |  ------------------
  |  |  |  Branch (173:16): [Folded - Ignored]
  |  |  ------------------
  ------------------
  159|       |
  160|  3.76k|    if (vertices) {
  ------------------
  |  Branch (160:9): [True: 3.76k, False: 0]
  ------------------
  161|  3.76k|        VECTOR(*vertices)[0] = start;
  ------------------
  |  |   65|  3.76k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  162|  3.76k|    }
  163|  95.6k|    for (i = 0; i < steps; ++i) {
  ------------------
  |  Branch (163:17): [True: 92.6k, False: 3.01k]
  ------------------
  164|  92.6k|        igraph_integer_t degree, edge, idx;
  165|  92.6k|        igraph_vector_int_t *inc_edges = igraph_lazy_inclist_get(&il, start);
  ------------------
  |  |  219|  92.6k|    (igraph_lazy_inclist_has(il,no) ? ((il)->incs[(igraph_integer_t)(no)]) \
  |  |  ------------------
  |  |  |  |  194|  92.6k|#define igraph_lazy_inclist_has(il,no) ((il)->incs[(igraph_integer_t)(no)] != NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (194:40): [True: 68.4k, False: 24.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  220|  92.6k|                                    : (igraph_i_lazy_inclist_get_real(il,no)))
  ------------------
  166|       |
  167|  92.6k|        IGRAPH_CHECK_OOM(inc_edges, "Failed to query incident edges.");
  ------------------
  |  |  701|  92.6k|    do { \
  |  |  702|  92.6k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  92.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 92.6k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  92.6k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  168|  92.6k|        degree = igraph_vector_int_size(inc_edges);
  169|       |
  170|       |        /* are we stuck? */
  171|  92.6k|        if (IGRAPH_UNLIKELY(degree == 0)) {
  ------------------
  |  |  604|  92.6k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  ------------------
  |  |  |  Branch (604:32): [True: 748, False: 91.9k]
  |  |  ------------------
  ------------------
  172|       |            /* can't fail since size is reduced, skip IGRAPH_CHECK */
  173|    748|            if (vertices) {
  ------------------
  |  Branch (173:17): [True: 748, False: 0]
  ------------------
  174|    748|                igraph_vector_int_resize(vertices, i + 1); /* size: i + 1 because vertices includes start vertex */
  175|    748|            }
  176|    748|            if (edges) {
  ------------------
  |  Branch (176:17): [True: 748, False: 0]
  ------------------
  177|    748|                igraph_vector_int_resize(edges, i);
  178|    748|            }
  179|    748|            if (stuck == IGRAPH_RANDOM_WALK_STUCK_RETURN) {
  ------------------
  |  Branch (179:17): [True: 748, False: 0]
  ------------------
  180|    748|                break;
  181|    748|            } else {
  182|      0|                IGRAPH_ERROR("Random walk got stuck.", IGRAPH_ERWSTUCK);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  183|      0|            }
  184|    748|        }
  185|       |
  186|  91.9k|        if (weights) { /* weighted: choose an out-edge with probability proportional to its weight */
  ------------------
  |  Branch (186:13): [True: 0, False: 91.9k]
  ------------------
  187|      0|            igraph_real_t r;
  188|      0|            igraph_vector_t **cd = (igraph_vector_t**) &(VECTOR(cdfs)[start]);
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  189|       |
  190|       |            /* compute out-edge cdf for this node if not already done */
  191|      0|            if (IGRAPH_UNLIKELY(! *cd)) {
  ------------------
  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  ------------------
  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  ------------------
  ------------------
  192|      0|                igraph_integer_t j;
  193|       |
  194|      0|                *cd = IGRAPH_CALLOC(1, igraph_vector_t);
  ------------------
  |  |   38|      0|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  ------------------
  |  |  |  |   36|      0|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (36:12): [Folded - Ignored]
  |  |  |  |  |  Branch (36:24): [Folded - Ignored]
  |  |  |  |  |  Branch (36:66): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  195|      0|                IGRAPH_CHECK_OOM(*cd, "Insufficient memory for random walk.");
  ------------------
  |  |  701|      0|    do { \
  |  |  702|      0|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  196|      0|                IGRAPH_CHECK(igraph_vector_init(*cd, degree));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  197|       |
  198|      0|                IGRAPH_CHECK(igraph_vector_resize(&weight_temp, degree));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  199|      0|                for (j = 0; j < degree; ++j) {
  ------------------
  |  Branch (199:29): [True: 0, False: 0]
  ------------------
  200|      0|                    VECTOR(weight_temp)[j] = VECTOR(*weights)[VECTOR(*inc_edges)[j]];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(weight_temp)[j] = VECTOR(*weights)[VECTOR(*inc_edges)[j]];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
                                  VECTOR(weight_temp)[j] = VECTOR(*weights)[VECTOR(*inc_edges)[j]];
  ------------------
  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  ------------------
  201|      0|                }
  202|       |
  203|      0|                IGRAPH_CHECK(igraph_vector_cumsum(*cd, &weight_temp));
  ------------------
  |  |  648|      0|    do { \
  |  |  649|      0|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|      0|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|      0|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  204|      0|            }
  205|       |
  206|      0|            r = RNG_UNIF(0, VECTOR(**cd)[degree - 1]);
  ------------------
  |  |  181|      0|#define RNG_UNIF(l,h)    (igraph_rng_get_unif(igraph_rng_default(),(l),(h)))
  ------------------
  207|      0|            igraph_vector_binsearch(*cd, r, &idx);
  208|      0|        }
  209|  91.9k|        else {
  210|  91.9k|            idx = RNG_INTEGER(0, degree - 1);
  ------------------
  |  |  179|  91.9k|#define RNG_INTEGER(l,h) (igraph_rng_get_integer(igraph_rng_default(),(l),(h)))
  ------------------
  211|  91.9k|        }
  212|       |
  213|  91.9k|        edge = VECTOR(*inc_edges)[idx];
  ------------------
  |  |   65|  91.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  214|  91.9k|        if (edges) {
  ------------------
  |  Branch (214:13): [True: 91.9k, False: 0]
  ------------------
  215|  91.9k|            VECTOR(*edges)[i] = edge;
  ------------------
  |  |   65|  91.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  216|  91.9k|        }
  217|       |
  218|       |        /* travel along edge in a direction specified by 'mode' */
  219|       |        /* note: 'mode' is always set to IGRAPH_ALL for undirected graphs */
  220|  91.9k|        switch (mode) {
  ------------------
  |  Branch (220:17): [True: 0, False: 91.9k]
  ------------------
  221|      0|        case IGRAPH_OUT:
  ------------------
  |  Branch (221:9): [True: 0, False: 91.9k]
  ------------------
  222|      0|            next = IGRAPH_TO(graph, edge);
  ------------------
  |  |  126|      0|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  223|      0|            break;
  224|      0|        case IGRAPH_IN:
  ------------------
  |  Branch (224:9): [True: 0, False: 91.9k]
  ------------------
  225|      0|            next = IGRAPH_FROM(graph, edge);
  ------------------
  |  |  113|      0|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
  226|      0|            break;
  227|  91.9k|        case IGRAPH_ALL:
  ------------------
  |  Branch (227:9): [True: 91.9k, False: 0]
  ------------------
  228|  91.9k|            next = IGRAPH_OTHER(graph, edge, start);
  ------------------
  |  |  144|  91.9k|    ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|  91.9k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  91.9k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  113|  52.8k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  52.8k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |                   ((igraph_integer_t)(IGRAPH_TO(graph,(eid))==(vid) ? IGRAPH_FROM((graph),(eid)) : IGRAPH_TO((graph),(eid))))
  |  |  ------------------
  |  |  |  |  126|  39.0k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  39.0k|#define VECTOR(v) ((v).stor_begin)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:25): [True: 52.8k, False: 39.0k]
  |  |  ------------------
  ------------------
  229|  91.9k|            break;
  230|  91.9k|        }
  231|       |
  232|  91.9k|        if (vertices) {
  ------------------
  |  Branch (232:13): [True: 91.9k, False: 0]
  ------------------
  233|  91.9k|            VECTOR(*vertices)[i + 1] = next; /* index i + 1 because vertices includes start vertex at position 0 */
  ------------------
  |  |   65|  91.9k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  234|  91.9k|        }
  235|  91.9k|        start = next;
  236|       |
  237|  91.9k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|  91.9k|    do { \
  |  |   48|  91.9k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 91.9k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|  91.9k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  238|  91.9k|    }
  239|       |
  240|  3.76k|    RNG_END();
  ------------------
  |  |  175|  3.76k|    do { /* nothing */ } while (0)
  |  |  ------------------
  |  |  |  Branch (175:33): [Folded - Ignored]
  |  |  ------------------
  ------------------
  241|       |
  242|  3.76k|    igraph_vector_ptr_destroy_all(&cdfs);
  243|  3.76k|    igraph_vector_destroy(&weight_temp);
  244|  3.76k|    igraph_lazy_inclist_destroy(&il);
  245|  3.76k|    IGRAPH_FINALLY_CLEAN(3);
  246|       |
  247|  3.76k|    return IGRAPH_SUCCESS;
  248|  3.76k|}

igraph_get_all_simple_paths:
   80|  1.86k|        igraph_neimode_t mode) {
   81|       |
   82|  1.86k|    const igraph_integer_t vcount = igraph_vcount(graph);
   83|  1.86k|    const igraph_bool_t toall = igraph_vs_is_all(&to);
   84|  1.86k|    igraph_vit_t vit;
   85|  1.86k|    igraph_lazy_adjlist_t adjlist;
   86|  1.86k|    igraph_vector_int_t stack, dist; /* used as a stack, but represented as a vector,
   87|       |                                        in order to be appendable the result vector list */
   88|  1.86k|    igraph_bitset_t markto, added;
   89|  1.86k|    igraph_vector_int_t nptr;
   90|  1.86k|    int iter = 0;
   91|       |
   92|  1.86k|    if (from < 0 || from >= vcount) {
  ------------------
  |  Branch (92:9): [True: 0, False: 1.86k]
  |  Branch (92:21): [True: 0, False: 1.86k]
  ------------------
   93|      0|        IGRAPH_ERROR("Index of source vertex is out of range.", IGRAPH_EINVVID);
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   94|      0|    }
   95|       |
   96|  1.86k|    if (!toall) {
  ------------------
  |  Branch (96:9): [True: 1.86k, False: 0]
  ------------------
   97|  1.86k|        IGRAPH_BITSET_INIT_FINALLY(&markto, vcount);
  ------------------
  |  |  261|  1.86k|#define IGRAPH_BITSET_INIT_FINALLY(bitset, size) \
  |  |  262|  1.86k|do { IGRAPH_CHECK(igraph_bitset_init(bitset, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.86k|    do { \
  |  |  |  |  649|  1.86k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.86k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  263|  1.86k|     IGRAPH_FINALLY(igraph_bitset_destroy, bitset); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.86k|    do { \
  |  |  |  |  592|  1.86k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.86k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.86k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.86k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.86k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (263:62): [Folded - Ignored]
  |  |  ------------------
  ------------------
   98|  1.86k|        IGRAPH_CHECK(igraph_vit_create(graph, to, &vit));
  ------------------
  |  |  648|  1.86k|    do { \
  |  |  649|  1.86k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.86k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.86k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   99|  1.86k|        IGRAPH_FINALLY(igraph_vit_destroy, &vit);
  ------------------
  |  |  591|  1.86k|    do { \
  |  |  592|  1.86k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.86k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.86k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.86k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.86k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.86k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  100|  3.72k|        for (; !IGRAPH_VIT_END(vit); IGRAPH_VIT_NEXT(vit)) {
  ------------------
  |  |  180|  3.72k|#define IGRAPH_VIT_END(vit)   ((vit).pos >= (vit).end)
  ------------------
                      for (; !IGRAPH_VIT_END(vit); IGRAPH_VIT_NEXT(vit)) {
  ------------------
  |  |  168|  1.86k|#define IGRAPH_VIT_NEXT(vit)  (++((vit).pos))
  ------------------
  |  Branch (100:16): [True: 1.86k, False: 1.86k]
  ------------------
  101|  1.86k|            IGRAPH_BIT_SET(markto, IGRAPH_VIT_GET(vit));
  ------------------
  |  |  105|  1.86k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  1.86k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  3.72k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.86k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (87:30): [True: 1.86k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  3.72k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.86k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (68:53): [True: 1.86k, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  102|  1.86k|        }
  103|  1.86k|        igraph_vit_destroy(&vit);
  104|  1.86k|        IGRAPH_FINALLY_CLEAN(1);
  105|  1.86k|    }
  106|       |
  107|  1.86k|    IGRAPH_BITSET_INIT_FINALLY(&added, vcount);
  ------------------
  |  |  261|  1.86k|#define IGRAPH_BITSET_INIT_FINALLY(bitset, size) \
  |  |  262|  1.86k|do { IGRAPH_CHECK(igraph_bitset_init(bitset, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.86k|    do { \
  |  |  |  |  649|  1.86k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.86k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  263|  1.86k|     IGRAPH_FINALLY(igraph_bitset_destroy, bitset); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.86k|    do { \
  |  |  |  |  592|  1.86k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.86k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.86k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.86k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.86k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (263:62): [Folded - Ignored]
  |  |  ------------------
  ------------------
  108|  1.86k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&stack, 100);
  ------------------
  |  |  124|  1.86k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.86k|    do { \
  |  |  |  |  649|  1.86k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.86k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.86k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.86k|    do { \
  |  |  |  |  592|  1.86k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.86k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.86k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.86k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.86k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  109|  1.86k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&dist, 100);
  ------------------
  |  |  124|  1.86k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.86k|    do { \
  |  |  |  |  649|  1.86k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.86k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.86k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.86k|    do { \
  |  |  |  |  592|  1.86k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.86k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.86k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.86k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.86k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  110|  1.86k|    IGRAPH_CHECK(igraph_lazy_adjlist_init(
  ------------------
  |  |  648|  1.86k|    do { \
  |  |  649|  1.86k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.86k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.86k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  111|  1.86k|        graph, &adjlist, mode, IGRAPH_NO_LOOPS, IGRAPH_NO_MULTIPLE
  112|  1.86k|    ));
  113|  1.86k|    IGRAPH_FINALLY(igraph_lazy_adjlist_destroy, &adjlist);
  ------------------
  |  |  591|  1.86k|    do { \
  |  |  592|  1.86k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.86k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.86k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.86k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.86k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.86k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  114|  1.86k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&nptr, vcount);
  ------------------
  |  |  124|  1.86k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.86k|    do { \
  |  |  |  |  649|  1.86k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.86k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.86k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.86k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.86k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.86k|    do { \
  |  |  |  |  592|  1.86k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.86k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.86k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.86k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.86k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.86k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
  115|       |
  116|  1.86k|    igraph_vector_int_list_clear(res);
  117|       |
  118|  1.86k|    igraph_vector_int_clear(&stack);
  119|  1.86k|    igraph_vector_int_clear(&dist);
  120|  1.86k|    igraph_vector_int_push_back(&stack, from);
  121|  1.86k|    igraph_vector_int_push_back(&dist, 0);
  122|  1.86k|    IGRAPH_BIT_SET(added, from);
  ------------------
  |  |  105|  1.86k|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  1.86k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  1.86k|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.86k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  1.86k|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.86k|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  123|  2.04M|    while (!igraph_vector_int_empty(&stack)) {
  ------------------
  |  Branch (123:12): [True: 2.04M, False: 1.86k]
  ------------------
  124|  2.04M|        const igraph_integer_t act = igraph_vector_int_tail(&stack);
  125|  2.04M|        const igraph_integer_t curdist = igraph_vector_int_tail(&dist);
  126|       |
  127|  2.04M|        const igraph_vector_int_t *neis = igraph_lazy_adjlist_get(&adjlist, act);
  ------------------
  |  |  163|  2.04M|    (igraph_lazy_adjlist_has(al,no) ? ((al)->adjs[(igraph_integer_t)(no)]) \
  |  |  ------------------
  |  |  |  |  138|  2.04M|#define igraph_lazy_adjlist_has(al,no) ((al)->adjs[(igraph_integer_t)(no)] != NULL)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (138:40): [True: 2.02M, False: 19.1k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  164|  2.04M|                                    : (igraph_i_lazy_adjlist_get_real(al, no)))
  ------------------
  128|  2.04M|        IGRAPH_CHECK_OOM(neis, "Failed to query neighbors.");
  ------------------
  |  |  701|  2.04M|    do { \
  |  |  702|  2.04M|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  ------------------
  |  |  |  |  604|  2.04M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 2.04M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  704|      0|        } \
  |  |  705|  2.04M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  129|       |
  130|  2.04M|        const igraph_integer_t n = igraph_vector_int_size(neis);
  131|  2.04M|        igraph_integer_t *ptr = igraph_vector_int_get_ptr(&nptr, act);
  132|  2.04M|        igraph_bool_t any;
  133|  2.04M|        igraph_bool_t within_dist;
  134|  2.04M|        igraph_integer_t nei;
  135|       |
  136|  2.04M|        within_dist = (curdist < maxlen || maxlen < 0);
  ------------------
  |  Branch (136:24): [True: 1.22M, False: 816k]
  |  Branch (136:44): [True: 0, False: 816k]
  ------------------
  137|  2.04M|        if (within_dist) {
  ------------------
  |  Branch (137:13): [True: 1.22M, False: 816k]
  ------------------
  138|       |            /* Search for a neighbor that was not yet visited */
  139|  1.22M|            any = false;
  140|  2.73M|            while (!any && (*ptr) < n) {
  ------------------
  |  Branch (140:20): [True: 1.71M, False: 1.01M]
  |  Branch (140:28): [True: 1.51M, False: 204k]
  ------------------
  141|  1.51M|                nei = VECTOR(*neis)[(*ptr)];
  ------------------
  |  |   65|  1.51M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  142|  1.51M|                any = !IGRAPH_BIT_TEST(added, nei);
  ------------------
  |  |  144|  1.51M|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  1.51M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  1.51M|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.51M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  1.51M|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.51M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  143|  1.51M|                (*ptr) ++;
  144|  1.51M|            }
  145|  1.22M|        }
  146|  2.04M|        if (within_dist && any) {
  ------------------
  |  Branch (146:13): [True: 1.22M, False: 816k]
  |  Branch (146:28): [True: 1.01M, False: 204k]
  ------------------
  147|       |            /* There is such a neighbor, add it */
  148|  1.01M|            IGRAPH_CHECK(igraph_vector_int_push_back(&stack, nei));
  ------------------
  |  |  648|  1.01M|    do { \
  |  |  649|  1.01M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.01M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.01M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.01M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.01M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  149|  1.01M|            IGRAPH_CHECK(igraph_vector_int_push_back(&dist, curdist + 1));
  ------------------
  |  |  648|  1.01M|    do { \
  |  |  649|  1.01M|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.01M|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.01M|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.01M]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.01M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  150|  1.01M|            IGRAPH_BIT_SET(added, nei);
  ------------------
  |  |  105|  1.01M|#define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  1.01M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  1.01M|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.01M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_SET(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] |= IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  1.01M|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.01M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  151|       |            /* Add to results */
  152|  1.01M|            if (toall || IGRAPH_BIT_TEST(markto, nei)) {
  ------------------
  |  |  144|  1.01M|#define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  1.01M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  1.01M|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.01M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_TEST(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] & IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  1.01M|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.01M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (144:36): [True: 47.3k, False: 971k]
  |  |  ------------------
  ------------------
  |  Branch (152:17): [True: 0, False: 1.01M]
  ------------------
  153|  47.3k|                if (curdist + 1 >= minlen) {
  ------------------
  |  Branch (153:21): [True: 47.3k, False: 0]
  ------------------
  154|  47.3k|                    IGRAPH_CHECK(igraph_vector_int_list_push_back_copy(res, &stack));
  ------------------
  |  |  648|  47.3k|    do { \
  |  |  649|  47.3k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  47.3k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  47.3k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 47.3k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  47.3k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  155|  47.3k|                }
  156|  47.3k|            }
  157|  1.02M|        } else {
  158|       |            /* There is no such neighbor, finished with the subtree */
  159|  1.02M|            igraph_integer_t up = igraph_vector_int_pop_back(&stack);
  160|  1.02M|            igraph_vector_int_pop_back(&dist);
  161|  1.02M|            IGRAPH_BIT_CLEAR(added, up);
  ------------------
  |  |  123|  1.02M|#define IGRAPH_BIT_CLEAR(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] &= ~IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   65|  1.02M|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |               #define IGRAPH_BIT_CLEAR(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] &= ~IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   87|  1.02M|#define IGRAPH_BIT_SLOT(i) ((i) / IGRAPH_INTEGER_SIZE)
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.02M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  |  |               #define IGRAPH_BIT_CLEAR(bitset, i) (VECTOR((bitset))[IGRAPH_BIT_SLOT(i)] &= ~IGRAPH_BIT_MASK(i))
  |  |  ------------------
  |  |  |  |   68|  1.02M|#define IGRAPH_BIT_MASK(i) ((igraph_uint_t)(1) << ((i) % IGRAPH_INTEGER_SIZE))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  1.02M|#define IGRAPH_INTEGER_SIZE 64
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  162|  1.02M|            VECTOR(nptr)[up] = 0;
  ------------------
  |  |   65|  1.02M|#define VECTOR(v) ((v).stor_begin)
  ------------------
  163|  1.02M|        }
  164|       |
  165|  2.04M|        IGRAPH_ALLOW_INTERRUPTION_LIMITED(iter, 1 << 13);
  ------------------
  |  |   72|  2.04M|    do { \
  |  |   73|  2.04M|        if (++iter >= skips) { \
  |  |  ------------------
  |  |  |  Branch (73:13): [True: 212, False: 2.03M]
  |  |  ------------------
  |  |   74|    212|            IGRAPH_ALLOW_INTERRUPTION(); \
  |  |  ------------------
  |  |  |  |   47|    212|    do { \
  |  |  |  |   48|    212|        if (igraph_i_interruption_handler) { \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (48:13): [True: 0, False: 212]
  |  |  |  |  ------------------
  |  |  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |  |  |   51|      0|            } \
  |  |  |  |   52|      0|        } \
  |  |  |  |   53|    212|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   75|    212|            iter = 0; \
  |  |   76|    212|        } \
  |  |   77|  2.04M|    } while (0)
  |  |  ------------------
  |  |  |  Branch (77:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  166|  2.04M|    }
  167|       |
  168|  1.86k|    igraph_vector_int_destroy(&nptr);
  169|  1.86k|    igraph_lazy_adjlist_destroy(&adjlist);
  170|  1.86k|    igraph_vector_int_destroy(&dist);
  171|  1.86k|    igraph_vector_int_destroy(&stack);
  172|  1.86k|    igraph_bitset_destroy(&added);
  173|  1.86k|    IGRAPH_FINALLY_CLEAN(5);
  174|       |
  175|  1.86k|    if (!toall) {
  ------------------
  |  Branch (175:9): [True: 1.86k, False: 0]
  ------------------
  176|  1.86k|        igraph_bitset_destroy(&markto);
  177|  1.86k|        IGRAPH_FINALLY_CLEAN(1);
  178|  1.86k|    }
  179|       |
  180|  1.86k|    return IGRAPH_SUCCESS;
  181|  1.86k|}

igraph_ecc:
  363|  1.88k|                          igraph_bool_t offset, igraph_bool_t normalize) {
  364|       |
  365|  1.88k|    if (k < 3) {
  ------------------
  |  Branch (365:9): [True: 0, False: 1.88k]
  ------------------
  366|      0|        IGRAPH_ERRORF("Cycle size for edge clustering coefficient must be at least 3, got %" IGRAPH_PRId ".",
  ------------------
  |  |  469|      0|    do { \
  |  |  470|      0|        igraph_errorf(reason, IGRAPH_FILE_BASENAME, __LINE__, \
  |  |  471|      0|                      igraph_errno, __VA_ARGS__) ; \
  |  |  472|      0|        return igraph_errno; \
  |  |  473|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (473:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  367|      0|                      IGRAPH_EINVAL, k);
  368|      0|    }
  369|       |
  370|  1.88k|    switch (k) {
  371|  1.88k|    case 3:
  ------------------
  |  Branch (371:5): [True: 1.88k, False: 0]
  ------------------
  372|  1.88k|        if (igraph_es_is_all(&eids)) {
  ------------------
  |  Branch (372:13): [True: 1.88k, False: 0]
  ------------------
  373|  1.88k|            return igraph_i_ecc3_1(graph, res, eids, offset, normalize);
  374|  1.88k|        } else {
  375|      0|            return igraph_i_ecc3_2(graph, res, eids, offset, normalize);
  376|      0|        }
  377|      0|    case 4:
  ------------------
  |  Branch (377:5): [True: 0, False: 1.88k]
  ------------------
  378|      0|        if (igraph_es_is_all(&eids)) {
  ------------------
  |  Branch (378:13): [True: 0, False: 0]
  ------------------
  379|      0|            return igraph_i_ecc4_1(graph, res, eids, offset, normalize);
  380|      0|        } else {
  381|      0|            return igraph_i_ecc4_2(graph, res, eids, offset, normalize);
  382|      0|        }
  383|      0|    default:
  ------------------
  |  Branch (383:5): [True: 0, False: 1.88k]
  ------------------
  384|      0|        IGRAPH_ERROR("Edge clustering coefficient calculation is only implemented for cycle sizes 3 and 4.",
  ------------------
  |  |  431|      0|    do { \
  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  433|      0|        return igraph_errno ; \
  |  |  434|      0|    } while (0)
  |  |  ------------------
  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  385|  1.88k|                     IGRAPH_UNIMPLEMENTED);
  386|  1.88k|    }
  387|  1.88k|}
ecc.c:igraph_i_ecc3_1:
   35|  1.88k|        igraph_bool_t offset, igraph_bool_t normalize) {
   36|       |
   37|  1.88k|    igraph_integer_t no_of_nodes = igraph_vcount(graph);
   38|  1.88k|    igraph_vector_int_t degree;
   39|  1.88k|    igraph_adjlist_t al;
   40|  1.88k|    igraph_eit_t eit;
   41|  1.88k|    const igraph_real_t c = offset ? 1.0 : 0.0;
  ------------------
  |  Branch (41:29): [True: 0, False: 1.88k]
  ------------------
   42|       |
   43|  1.88k|    IGRAPH_CHECK(igraph_adjlist_init(graph, &al, IGRAPH_ALL, IGRAPH_NO_LOOPS, IGRAPH_NO_MULTIPLE));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   44|  1.88k|    IGRAPH_FINALLY(igraph_adjlist_destroy, &al);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   45|       |
   46|  1.88k|    IGRAPH_VECTOR_INT_INIT_FINALLY(&degree, no_of_nodes);
  ------------------
  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  ------------------
  ------------------
   47|  1.88k|    IGRAPH_CHECK(igraph_degree(graph, &degree, igraph_vss_all(), IGRAPH_ALL, IGRAPH_LOOPS));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   48|       |
   49|  1.88k|    IGRAPH_CHECK(igraph_eit_create(graph, eids, &eit));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   50|  1.88k|    IGRAPH_FINALLY(igraph_eit_destroy, &eit);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   51|       |
   52|  1.88k|    IGRAPH_CHECK(igraph_vector_resize(res, IGRAPH_EIT_SIZE(eit)));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   53|       |
   54|  1.88k|    for (igraph_integer_t i=0;
   55|  69.4k|         ! IGRAPH_EIT_END(eit);
  ------------------
  |  |  370|  69.4k|#define IGRAPH_EIT_END(eit)   ((eit).pos >= (eit).end)
  ------------------
  |  Branch (55:10): [True: 67.5k, False: 1.88k]
  ------------------
   56|  67.5k|         IGRAPH_EIT_NEXT(eit), i++) {
  ------------------
  |  |  358|  67.5k|#define IGRAPH_EIT_NEXT(eit) (++((eit).pos))
  ------------------
   57|       |
   58|  67.5k|        igraph_integer_t edge = IGRAPH_EIT_GET(eit);
  ------------------
  |  |  404|  67.5k|    (igraph_integer_t)((((eit).type == IGRAPH_EIT_RANGE) ? (eit).pos : \
  |  |  ------------------
  |  |  |  Branch (404:25): [True: 67.5k, False: 0]
  |  |  ------------------
  |  |  405|  67.5k|                        VECTOR(*(eit).vec)[(eit).pos]))
  |  |  ------------------
  |  |  |  |   65|      0|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   59|  67.5k|        igraph_integer_t v1 = IGRAPH_FROM(graph, edge), v2 = IGRAPH_TO(graph, edge);
  ------------------
  |  |  113|  67.5k|#define IGRAPH_FROM(graph,eid) ((igraph_integer_t)(VECTOR((graph)->from)[(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
                      igraph_integer_t v1 = IGRAPH_FROM(graph, edge), v2 = IGRAPH_TO(graph, edge);
  ------------------
  |  |  126|  67.5k|#define IGRAPH_TO(graph,eid)   ((igraph_integer_t)(VECTOR((graph)->to)  [(igraph_integer_t)(eid)]))
  |  |  ------------------
  |  |  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  ------------------
   60|       |
   61|  67.5k|        igraph_real_t z; /* number of triangles the edge participates in */
   62|  67.5k|        igraph_real_t s; /* max number of triangles the edge could be part of */
   63|       |
   64|  67.5k|        IGRAPH_ALLOW_INTERRUPTION();
  ------------------
  |  |   47|  67.5k|    do { \
  |  |   48|  67.5k|        if (igraph_i_interruption_handler) { \
  |  |  ------------------
  |  |  |  Branch (48:13): [True: 0, False: 67.5k]
  |  |  ------------------
  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  ------------------
  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  ------------------
  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |   51|      0|            } \
  |  |   52|      0|        } \
  |  |   53|  67.5k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
   65|       |
   66|  67.5k|        if (v1 == v2) {
  ------------------
  |  Branch (66:13): [True: 10.0k, False: 57.5k]
  ------------------
   67|       |            /* A self-loop isn't, and cannot be part of any triangles. */
   68|  10.0k|            z = 0.0;
   69|  10.0k|            s = 0.0;
   70|  57.5k|        } else {
   71|  57.5k|            const igraph_vector_int_t *a1 = igraph_adjlist_get(&al, v1), *a2 = igraph_adjlist_get(&al, v2);
  ------------------
  |  |   78|  57.5k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
                          const igraph_vector_int_t *a1 = igraph_adjlist_get(&al, v1), *a2 = igraph_adjlist_get(&al, v2);
  ------------------
  |  |   78|  57.5k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  ------------------
   72|  57.5k|            igraph_integer_t d1 = VECTOR(degree)[v1], d2 = VECTOR(degree)[v2];
  ------------------
  |  |   65|  57.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          igraph_integer_t d1 = VECTOR(degree)[v1], d2 = VECTOR(degree)[v2];
  ------------------
  |  |   65|  57.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   73|       |
   74|  57.5k|            z = igraph_vector_int_intersection_size_sorted(a1, a2);
   75|  57.5k|            s = (d1 < d2 ? d1 : d2) - 1.0;
  ------------------
  |  Branch (75:18): [True: 17.8k, False: 39.7k]
  ------------------
   76|  57.5k|        }
   77|       |
   78|  67.5k|        VECTOR(*res)[i] = z + c;
  ------------------
  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
   79|  67.5k|        if (normalize) VECTOR(*res)[i] /= s;
  ------------------
  |  |   65|  67.5k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (79:13): [True: 67.5k, False: 0]
  ------------------
   80|  67.5k|    }
   81|       |
   82|  1.88k|    igraph_eit_destroy(&eit);
   83|  1.88k|    igraph_vector_int_destroy(&degree);
   84|  1.88k|    igraph_adjlist_destroy(&al);
   85|  1.88k|    IGRAPH_FINALLY_CLEAN(3);
   86|       |
   87|  1.88k|    return IGRAPH_SUCCESS;
   88|  1.88k|}

igraph_i_trans4_al_simplify:
  292|  1.88k|                                const igraph_vector_int_t *rank) {
  293|  1.88k|    igraph_integer_t i;
  294|  1.88k|    igraph_integer_t n = al->length;
  295|  1.88k|    igraph_vector_int_t mark;
  296|       |
  297|  1.88k|    IGRAPH_CHECK(igraph_vector_int_init(&mark, n));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  298|  1.88k|    IGRAPH_FINALLY(igraph_vector_int_destroy, &mark);
  ------------------
  |  |  591|  1.88k|    do { \
  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  ------------------
  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  ------------------
  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  597|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  299|       |
  300|   375k|    for (i = 0; i < n; i++) {
  ------------------
  |  Branch (300:17): [True: 373k, False: 1.88k]
  ------------------
  301|   373k|        igraph_vector_int_t *v = &al->adjs[i];
  302|   373k|        igraph_integer_t j, l = igraph_vector_int_size(v);
  303|   373k|        igraph_integer_t irank = VECTOR(*rank)[i];
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  304|   373k|        VECTOR(mark)[i] = i + 1;
  ------------------
  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  305|   457k|        for (j = 0; j < l; /* nothing */) {
  ------------------
  |  Branch (305:21): [True: 84.1k, False: 373k]
  ------------------
  306|  84.1k|            igraph_integer_t e = VECTOR(*v)[j];
  ------------------
  |  |   65|  84.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  307|  84.1k|            if (VECTOR(*rank)[e] > irank && VECTOR(mark)[e] != i + 1) {
  ------------------
  |  |   65|  84.1k|#define VECTOR(v) ((v).stor_begin)
  ------------------
                          if (VECTOR(*rank)[e] > irank && VECTOR(mark)[e] != i + 1) {
  ------------------
  |  |   65|  42.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  |  Branch (307:17): [True: 42.0k, False: 42.0k]
  |  Branch (307:45): [True: 42.0k, False: 0]
  ------------------
  308|  42.0k|                VECTOR(mark)[e] = i + 1;
  ------------------
  |  |   65|  42.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  309|  42.0k|                j++;
  310|  42.0k|            } else {
  311|  42.0k|                VECTOR(*v)[j] = igraph_vector_int_tail(v);
  ------------------
  |  |   65|  42.0k|#define VECTOR(v) ((v).stor_begin)
  ------------------
  312|  42.0k|                igraph_vector_int_pop_back(v);
  313|  42.0k|                l--;
  314|  42.0k|            }
  315|  84.1k|        }
  316|   373k|    }
  317|       |
  318|  1.88k|    igraph_vector_int_destroy(&mark);
  319|  1.88k|    IGRAPH_FINALLY_CLEAN(1);
  320|       |
  321|  1.88k|    return IGRAPH_SUCCESS;
  322|  1.88k|}
igraph_list_triangles:
  590|  1.88k|                          igraph_vector_int_t *res) {
  591|  1.88k|# define TRIANGLES
  592|  1.88k|# include "properties/triangles_template.h"
  ------------------
  |  |    1|       |/* -*- mode: C -*-  */
  |  |    2|       |/* vim:set ts=4 sw=4 sts=4 et: */
  |  |    3|       |/*
  |  |    4|       |   IGraph library.
  |  |    5|       |   Copyright (C) 2005-2012  Gabor Csardi <csardi.gabor@gmail.com>
  |  |    6|       |   334 Harvard street, Cambridge, MA 02139 USA
  |  |    7|       |
  |  |    8|       |   This program is free software; you can redistribute it and/or modify
  |  |    9|       |   it under the terms of the GNU General Public License as published by
  |  |   10|       |   the Free Software Foundation; either version 2 of the License, or
  |  |   11|       |   (at your option) any later version.
  |  |   12|       |
  |  |   13|       |   This program is distributed in the hope that it will be useful,
  |  |   14|       |   but WITHOUT ANY WARRANTY; without even the implied warranty of
  |  |   15|       |   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  |  |   16|       |   GNU General Public License for more details.
  |  |   17|       |
  |  |   18|       |   You should have received a copy of the GNU General Public License
  |  |   19|       |   along with this program; if not, write to the Free Software
  |  |   20|       |   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
  |  |   21|       |   02110-1301 USA
  |  |   22|       |
  |  |   23|       |*/
  |  |   24|       |
  |  |   25|       |#ifdef TRANSIT
  |  |   26|       |#define TRANSIT_TRIEDGES
  |  |   27|       |#endif
  |  |   28|       |
  |  |   29|  1.88k|igraph_integer_t no_of_nodes = igraph_vcount(graph);
  |  |   30|  1.88k|igraph_integer_t node, i, j, nn;
  |  |   31|  1.88k|igraph_adjlist_t allneis;
  |  |   32|  1.88k|igraph_vector_int_t *neis1, *neis2;
  |  |   33|  1.88k|igraph_integer_t neilen1, neilen2;
  |  |   34|  1.88k|igraph_integer_t *neis;
  |  |   35|  1.88k|igraph_integer_t maxdegree;
  |  |   36|       |
  |  |   37|       |#ifdef TRANSIT_TRIEDGES
  |  |   38|       |igraph_integer_t deg1;
  |  |   39|       |#endif
  |  |   40|       |
  |  |   41|  1.88k|igraph_vector_int_t order;
  |  |   42|  1.88k|igraph_vector_int_t rank;
  |  |   43|  1.88k|igraph_vector_int_t degree;
  |  |   44|       |
  |  |   45|  1.88k|if (no_of_nodes == 0) {
  |  |  ------------------
  |  |  |  Branch (45:5): [True: 1, False: 1.88k]
  |  |  ------------------
  |  |   46|       |#ifndef TRIANGLES
  |  |   47|       |    igraph_vector_clear(res);
  |  |   48|       |#else
  |  |   49|      1|    igraph_vector_int_clear(res);
  |  |   50|      1|#endif
  |  |   51|      1|    return IGRAPH_SUCCESS;
  |  |   52|      1|}
  |  |   53|       |
  |  |   54|  1.88k|IGRAPH_VECTOR_INT_INIT_FINALLY(&order, no_of_nodes);
  |  |  ------------------
  |  |  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  652|      0|        } \
  |  |  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   55|  1.88k|IGRAPH_VECTOR_INT_INIT_FINALLY(&degree, no_of_nodes);
  |  |  ------------------
  |  |  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  652|      0|        } \
  |  |  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   56|       |
  |  |   57|  1.88k|IGRAPH_CHECK(igraph_adjlist_init(graph, &allneis, IGRAPH_ALL, IGRAPH_NO_LOOPS, IGRAPH_NO_MULTIPLE));
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   58|  1.88k|IGRAPH_FINALLY(igraph_adjlist_destroy, &allneis);
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   59|       |
  |  |   60|   375k|for (i = 0; i < no_of_nodes; i++) {
  |  |  ------------------
  |  |  |  Branch (60:13): [True: 373k, False: 1.88k]
  |  |  ------------------
  |  |   61|   373k|    VECTOR(degree)[i] = igraph_vector_int_size(igraph_adjlist_get(&allneis, i));
  |  |  ------------------
  |  |  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |                   VECTOR(degree)[i] = igraph_vector_int_size(igraph_adjlist_get(&allneis, i));
  |  |  ------------------
  |  |  |  |   78|   373k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  |  |  ------------------
  |  |   62|   373k|}
  |  |   63|       |
  |  |   64|  1.88k|maxdegree = igraph_vector_int_max(&degree) + 1;
  |  |   65|  1.88k|IGRAPH_CHECK(igraph_i_vector_int_order(&degree, &order, maxdegree));
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   66|  1.88k|IGRAPH_VECTOR_INT_INIT_FINALLY(&rank, no_of_nodes);
  |  |  ------------------
  |  |  |  |  124|  1.88k|    do { IGRAPH_CHECK(igraph_vector_int_init(v, size)); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  652|      0|        } \
  |  |  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  125|  1.88k|        IGRAPH_FINALLY(igraph_vector_int_destroy, v); } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (125:64): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   67|   375k|for (i = 0; i < no_of_nodes; i++) {
  |  |  ------------------
  |  |  |  Branch (67:13): [True: 373k, False: 1.88k]
  |  |  ------------------
  |  |   68|   373k|    VECTOR(rank)[ VECTOR(order)[i] ] = no_of_nodes - i - 1;
  |  |  ------------------
  |  |  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |                   VECTOR(rank)[ VECTOR(order)[i] ] = no_of_nodes - i - 1;
  |  |  ------------------
  |  |  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |   69|   373k|}
  |  |   70|       |
  |  |   71|  1.88k|IGRAPH_CHECK(igraph_i_trans4_al_simplify(&allneis, &rank));
  |  |  ------------------
  |  |  |  |  648|  1.88k|    do { \
  |  |  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   72|       |
  |  |   73|  1.88k|neis = IGRAPH_CALLOC(no_of_nodes, igraph_integer_t);
  |  |  ------------------
  |  |  |  |   38|  1.88k|#define IGRAPH_CALLOC(n,t)    IGRAPH_I_ALLOC_CHECK_OVERFLOW(n, t, calloc(sizeof(t) * ((n) > 0 ? (n) : 1), 1))
  |  |  |  |  ------------------
  |  |  |  |  |  |   36|  3.76k|    (t*) ((0 <= (n) && ((size_t)(n)) <= SIZE_MAX / sizeof(t)) ? (expr) : NULL)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (36:12): [True: 1.88k, False: 0]
  |  |  |  |  |  |  |  Branch (36:24): [True: 1.88k, False: 0]
  |  |  |  |  |  |  |  Branch (36:66): [True: 1.88k, False: 0]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   74|  1.88k|IGRAPH_CHECK_OOM(neis, "Insufficient memory to count triangles.");
  |  |  ------------------
  |  |  |  |  701|  1.88k|    do { \
  |  |  |  |  702|  1.88k|        if (IGRAPH_UNLIKELY(!ptr)) { \
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  703|      0|            IGRAPH_ERROR(message, IGRAPH_ENOMEM); /* LCOV_EXCL_LINE */ \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  704|      0|        } \
  |  |  |  |  705|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (705:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   75|  1.88k|IGRAPH_FINALLY(igraph_free, neis);
  |  |  ------------------
  |  |  |  |  591|  1.88k|    do { \
  |  |  |  |  592|  1.88k|        /* the following branch makes the compiler check the compatibility of \
  |  |  |  |  593|  1.88k|         * func and ptr to detect cases when we are accidentally invoking an \
  |  |  |  |  594|  1.88k|         * incorrect destructor function with the pointer */ \
  |  |  |  |  595|  1.88k|        if (0) { func(ptr); } \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (595:13): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  |  |  596|  1.88k|        IGRAPH_FINALLY_REAL((igraph_finally_func_t*)(func), (ptr)); \
  |  |  |  |  597|  1.88k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (597:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   76|       |
  |  |   77|       |#ifndef TRIANGLES
  |  |   78|       |    IGRAPH_CHECK(igraph_vector_resize(res, no_of_nodes));
  |  |   79|       |    igraph_vector_null(res);
  |  |   80|       |#else
  |  |   81|  1.88k|    igraph_vector_int_clear(res);
  |  |   82|  1.88k|#endif
  |  |   83|       |
  |  |   84|   375k|for (nn = no_of_nodes - 1; nn >= 0; nn--) {
  |  |  ------------------
  |  |  |  Branch (84:28): [True: 373k, False: 1.88k]
  |  |  ------------------
  |  |   85|   373k|    node = VECTOR(order)[nn];
  |  |  ------------------
  |  |  |  |   65|   373k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |   86|       |
  |  |   87|   373k|    IGRAPH_ALLOW_INTERRUPTION();
  |  |  ------------------
  |  |  |  |   47|   373k|    do { \
  |  |  |  |   48|   373k|        if (igraph_i_interruption_handler) { \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (48:13): [True: 0, False: 373k]
  |  |  |  |  ------------------
  |  |  |  |   49|      0|            if (igraph_allow_interruption()) { \
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (49:17): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   50|      0|                return IGRAPH_INTERRUPTED; \
  |  |  |  |   51|      0|            } \
  |  |  |  |   52|      0|        } \
  |  |  |  |   53|   373k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (53:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   88|       |
  |  |   89|   373k|    neis1 = igraph_adjlist_get(&allneis, node);
  |  |  ------------------
  |  |  |  |   78|   373k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  |  |  ------------------
  |  |   90|   373k|    neilen1 = igraph_vector_int_size(neis1);
  |  |   91|       |
  |  |   92|       |#ifdef TRANSIT_TRIEDGES
  |  |   93|       |    deg1 = VECTOR(degree)[node];
  |  |   94|       |#endif
  |  |   95|       |
  |  |   96|       |    /* Mark the neighbors of the node */
  |  |   97|   415k|    for (i = 0; i < neilen1; i++) {
  |  |  ------------------
  |  |  |  Branch (97:17): [True: 42.0k, False: 373k]
  |  |  ------------------
  |  |   98|  42.0k|        neis[ VECTOR(*neis1)[i] ] = node + 1;
  |  |  ------------------
  |  |  |  |   65|  42.0k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |   99|  42.0k|    }
  |  |  100|       |
  |  |  101|   415k|    for (i = 0; i < neilen1; i++) {
  |  |  ------------------
  |  |  |  Branch (101:17): [True: 42.0k, False: 373k]
  |  |  ------------------
  |  |  102|  42.0k|        igraph_integer_t nei = VECTOR(*neis1)[i];
  |  |  ------------------
  |  |  |  |   65|  42.0k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  103|  42.0k|        neis2 = igraph_adjlist_get(&allneis, nei);
  |  |  ------------------
  |  |  |  |   78|  42.0k|#define igraph_adjlist_get(al,no) (&(al)->adjs[(igraph_integer_t)(no)])
  |  |  ------------------
  |  |  104|  42.0k|        neilen2 = igraph_vector_int_size(neis2);
  |  |  105|  64.1k|        for (j = 0; j < neilen2; j++) {
  |  |  ------------------
  |  |  |  Branch (105:21): [True: 22.0k, False: 42.0k]
  |  |  ------------------
  |  |  106|  22.0k|            igraph_integer_t nei2 = VECTOR(*neis2)[j];
  |  |  ------------------
  |  |  |  |   65|  22.0k|#define VECTOR(v) ((v).stor_begin)
  |  |  ------------------
  |  |  107|  22.0k|            if (neis[nei2] == node + 1) {
  |  |  ------------------
  |  |  |  Branch (107:17): [True: 5.65k, False: 16.4k]
  |  |  ------------------
  |  |  108|       |#ifndef TRIANGLES
  |  |  109|       |                VECTOR(*res)[nei2] += 1;
  |  |  110|       |                VECTOR(*res)[nei] += 1;
  |  |  111|       |                VECTOR(*res)[node] += 1;
  |  |  112|       |#else
  |  |  113|  5.65k|                IGRAPH_CHECK(igraph_vector_int_push_back(res, node));
  |  |  ------------------
  |  |  |  |  648|  5.65k|    do { \
  |  |  |  |  649|  5.65k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  5.65k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  5.65k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  114|  5.65k|                IGRAPH_CHECK(igraph_vector_int_push_back(res, nei));
  |  |  ------------------
  |  |  |  |  648|  5.65k|    do { \
  |  |  |  |  649|  5.65k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  5.65k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  5.65k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  115|  5.65k|                IGRAPH_CHECK(igraph_vector_int_push_back(res, nei2));
  |  |  ------------------
  |  |  |  |  648|  5.65k|    do { \
  |  |  |  |  649|  5.65k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  |  |  650|  5.65k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  |  |  ------------------
  |  |  |  |  |  |  604|  5.65k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (604:32): [True: 0, False: 5.65k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  |  |  ------------------
  |  |  |  |  |  |  431|      0|    do { \
  |  |  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  652|      0|        } \
  |  |  |  |  653|  5.65k|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  116|  5.65k|#endif
  |  |  117|  5.65k|            }
  |  |  118|  22.0k|        }
  |  |  119|  42.0k|    }
  |  |  120|       |
  |  |  121|       |#ifdef TRANSIT
  |  |  122|       |    if (mode == IGRAPH_TRANSITIVITY_ZERO && deg1 < 2) {
  |  |  123|       |        VECTOR(*res)[node] = 0.0;
  |  |  124|       |    } else {
  |  |  125|       |        VECTOR(*res)[node] = VECTOR(*res)[node] / deg1 / (deg1 - 1) * 2.0;
  |  |  126|       |    }
  |  |  127|       |#endif
  |  |  128|   373k|}
  |  |  129|       |
  |  |  130|  1.88k|igraph_free(neis);
  |  |  131|  1.88k|igraph_adjlist_destroy(&allneis);
  |  |  132|  1.88k|igraph_vector_int_destroy(&rank);
  |  |  133|  1.88k|igraph_vector_int_destroy(&degree);
  |  |  134|  1.88k|igraph_vector_int_destroy(&order);
  |  |  135|  1.88k|IGRAPH_FINALLY_CLEAN(5);
  |  |  136|       |
  |  |  137|       |#ifdef TRANSIT_TRIEDGES
  |  |  138|       |#undef TRANSIT_TRIEDGES
  |  |  139|       |#endif
  ------------------
  593|  1.88k|# undef TRIANGLES
  594|  1.88k|    return IGRAPH_SUCCESS;
  595|  15.0k|}

igraph_rng_default:
  189|   474k|igraph_rng_t *igraph_rng_default(void) {
  190|   474k|    return igraph_i_rng_default_ptr;
  191|   474k|}
igraph_rng_seed:
  261|  1.88k|igraph_error_t igraph_rng_seed(igraph_rng_t *rng, igraph_uint_t seed) {
  262|  1.88k|    const igraph_rng_type_t *type = rng->type;
  263|  1.88k|    IGRAPH_CHECK(type->seed(rng->state, seed));
  ------------------
  |  |  648|  1.88k|    do { \
  |  |  649|  1.88k|        igraph_error_t igraph_i_ret = (expr); \
  |  |  650|  1.88k|        if (IGRAPH_UNLIKELY(igraph_i_ret != IGRAPH_SUCCESS)) {\
  |  |  ------------------
  |  |  |  |  604|  1.88k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (604:32): [True: 0, False: 1.88k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  651|      0|            IGRAPH_ERROR("", igraph_i_ret); \
  |  |  ------------------
  |  |  |  |  431|      0|    do { \
  |  |  |  |  432|      0|        igraph_error (reason, IGRAPH_FILE_BASENAME, __LINE__, igraph_errno) ; \
  |  |  |  |  433|      0|        return igraph_errno ; \
  |  |  |  |  434|      0|    } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (434:14): [Folded - Ignored]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  652|      0|        } \
  |  |  653|  1.88k|    } while (0)
  |  |  ------------------
  |  |  |  Branch (653:14): [Folded - Ignored]
  |  |  ------------------
  ------------------
  264|  1.88k|    rng->is_seeded = true;
  265|  1.88k|    return IGRAPH_SUCCESS;
  266|  1.88k|}
igraph_rng_bits:
  278|   455k|igraph_integer_t igraph_rng_bits(const igraph_rng_t* rng) {
  279|   455k|    return rng->type->bits;
  280|   455k|}
igraph_rng_get_integer:
  594|  91.9k|) {
  595|  91.9k|    const igraph_rng_type_t *type = rng->type;
  596|  91.9k|    igraph_uint_t range;
  597|       |
  598|  91.9k|    assert(h >= l);
  599|       |
  600|  91.9k|    if (h == l) {
  ------------------
  |  Branch (600:9): [True: 9.67k, False: 82.2k]
  ------------------
  601|  9.67k|        return l;
  602|  9.67k|    }
  603|       |
  604|  82.2k|    if (type->get_int) {
  ------------------
  |  Branch (604:9): [True: 0, False: 82.2k]
  ------------------
  605|      0|        return type->get_int(rng->state, l, h);
  606|      0|    }
  607|       |
  608|  82.2k|    if (IGRAPH_UNLIKELY(l == IGRAPH_INTEGER_MIN && h == IGRAPH_INTEGER_MAX)) {
  ------------------
  |  |  604|  82.2k|    #define IGRAPH_UNLIKELY(a) __builtin_expect((a), 0)
  |  |  ------------------
  |  |  |  Branch (604:32): [True: 0, False: 82.2k]
  |  |  |  Branch (604:50): [True: 0, False: 82.2k]
  |  |  |  Branch (604:50): [True: 0, False: 0]
  |  |  ------------------
  ------------------
  609|       |        /* Full uint range is needed, we can just grab a random number from
  610|       |         * the uint range and cast it to a signed integer */
  611|      0|        return (igraph_integer_t) igraph_i_rng_get_uint(rng);
  612|  82.2k|    } else if (l >= 0 || h < 0) {
  ------------------
  |  Branch (612:16): [True: 82.2k, False: 0]
  |  Branch (612:26): [True: 0, False: 0]
  ------------------
  613|       |        /* this is okay, (h - l) will not overflow an igraph_integer_t */
  614|  82.2k|        range = (igraph_uint_t)(h - l) + 1;
  615|  82.2k|    } else {
  616|       |        /* (h - l) could potentially overflow so we need to play it safe. If we
  617|       |         * are here, l < 0 and h >= 0 so we can cast -l into an igraph_uint_t
  618|       |         * safely and do the subtraction that way */
  619|      0|        range = ((igraph_uint_t)(h)) + ((igraph_uint_t)(-l)) + 1;
  620|      0|    }
  621|       |
  622|  82.2k|    return l + igraph_i_rng_get_uint_bounded(rng, range);
  623|  82.2k|}
igraph_rng_get_unif01:
  699|   373k|igraph_real_t igraph_rng_get_unif01(igraph_rng_t *rng) {
  700|   373k|    const igraph_rng_type_t *type = rng->type;
  701|   373k|    if (type->get_real) {
  ------------------
  |  Branch (701:9): [True: 0, False: 373k]
  ------------------
  702|      0|        return type->get_real(rng->state);
  703|   373k|    } else {
  704|       |        /* We extract 52 random bits from a 64-bit uint and fill that directly
  705|       |         * into the mantissa of a double, bit-by-bit, clear the sign bit and
  706|       |         * set the exponent to 2^0. This way we get a 52-bit random double
  707|       |         * between 1 (inclusive) and 2 (exclusive), uniformly distributed.
  708|       |         * Then we subtract 1 to arrive at the [0; 1) interval. This is fast
  709|       |         * but we lose one bit of precision as there are 2^53 possible doubles
  710|       |         * between 0 and 1. */
  711|   373k|        union {
  712|   373k|            uint64_t as_uint64_t;
  713|   373k|            double as_double;
  714|   373k|        } value;
  715|   373k|        value.as_uint64_t =
  716|   373k|            (igraph_i_rng_get_random_bits_uint64(rng, 52) & 0xFFFFFFFFFFFFFull) | 0x3FF0000000000000ull;
  717|   373k|        return value.as_double - 1.0;
  718|   373k|    }
  719|   373k|}
random.c:igraph_i_rng_get_random_bits:
  337|  82.2k|static igraph_uint_t igraph_i_rng_get_random_bits(igraph_rng_t *rng, uint8_t bits) {
  338|  82.2k|    const igraph_rng_type_t *type = rng->type;
  339|  82.2k|    igraph_integer_t rng_bitwidth = igraph_rng_bits(rng);
  340|  82.2k|    igraph_uint_t result;
  341|       |
  342|  82.2k|    if (rng_bitwidth >= bits) {
  ------------------
  |  Branch (342:9): [True: 82.2k, False: 0]
  ------------------
  343|       |        /* keep the high bits as RNGs sometimes tend to have lower entropy in
  344|       |         * low bits than in high bits */
  345|  82.2k|        result = type->get(rng->state) >> (rng_bitwidth - bits);
  346|  82.2k|    } else {
  347|      0|        result = 0;
  348|      0|        do {
  349|      0|            result = (result << rng_bitwidth) + type->get(rng->state);
  350|      0|            bits -= rng_bitwidth;
  351|      0|        } while (bits > rng_bitwidth);
  ------------------
  |  Branch (351:18): [True: 0, False: 0]
  ------------------
  352|       |
  353|       |        /* and now the last piece */
  354|      0|        result = (result << bits) + (type->get(rng->state) >> (rng_bitwidth - bits));
  355|      0|    }
  356|       |
  357|  82.2k|    return result;
  358|  82.2k|}
random.c:igraph_i_rng_get_uint_bounded:
  533|  82.2k|static igraph_uint_t igraph_i_rng_get_uint_bounded(igraph_rng_t *rng, igraph_uint_t range) {
  534|       |    /* We must make this function behave the same way for range < 2^32 so igraph
  535|       |     * behaves the same way on 32-bit and 64-bit platforms as long as we stick
  536|       |     * to integers less than 2^32. This is to ensure that the unit tests are
  537|       |     * consistent */
  538|       |
  539|       |#if IGRAPH_INTEGER_SIZE == 32
  540|       |    return igraph_i_rng_get_uint32_bounded(rng, range);
  541|       |#else
  542|  82.2k|    if (range <= UINT32_MAX) {
  ------------------
  |  Branch (542:9): [True: 82.2k, False: 0]
  ------------------
  543|  82.2k|        return igraph_i_rng_get_uint32_bounded(rng, range);
  544|  82.2k|    } else {
  545|      0|        return igraph_i_rng_get_uint64_bounded(rng, range);
  546|      0|    }
  547|  82.2k|#endif
  548|  82.2k|}
random.c:igraph_i_rng_get_uint32_bounded:
  429|  82.2k|static uint32_t igraph_i_rng_get_uint32_bounded(igraph_rng_t *rng, uint32_t range) {
  430|       |    /* Debiased integer multiplication -- Lemire's method
  431|       |     * from https://www.pcg-random.org/posts/bounded-rands.html */
  432|  82.2k|    uint32_t x, l, t = (-range) % range;
  433|  82.2k|    uint64_t m;
  434|  82.2k|    do {
  435|  82.2k|        x = igraph_i_rng_get_uint32(rng);
  436|  82.2k|        m = (uint64_t)(x) * (uint64_t)(range);
  437|  82.2k|        l = (uint32_t)m;
  438|  82.2k|    } while (l < t);
  ------------------
  |  Branch (438:14): [True: 0, False: 82.2k]
  ------------------
  439|  82.2k|    return m >> 32;
  440|  82.2k|}
random.c:igraph_i_rng_get_uint32:
  417|  82.2k|static uint32_t igraph_i_rng_get_uint32(igraph_rng_t *rng) {
  418|  82.2k|    return igraph_i_rng_get_random_bits(rng, 32);
  419|  82.2k|}
random.c:igraph_i_rng_get_random_bits_uint64:
  376|   373k|static uint64_t igraph_i_rng_get_random_bits_uint64(igraph_rng_t *rng, uint8_t bits) {
  377|   373k|    const igraph_rng_type_t *type = rng->type;
  378|   373k|    igraph_integer_t rng_bitwidth = igraph_rng_bits(rng);
  379|   373k|    uint64_t result;
  380|       |
  381|   373k|    if (rng_bitwidth >= bits) {
  ------------------
  |  Branch (381:9): [True: 0, False: 373k]
  ------------------
  382|       |        /* keep the high bits as RNGs sometimes tend to have lower entropy in
  383|       |         * low bits than in high bits */
  384|      0|        result = type->get(rng->state) >> (rng_bitwidth - bits);
  385|   373k|    } else {
  386|   373k|        result = 0;
  387|   373k|        do {
  388|   373k|            result = (result << rng_bitwidth) + type->get(rng->state);
  389|   373k|            bits -= rng_bitwidth;
  390|   373k|        } while (bits > rng_bitwidth);
  ------------------
  |  Branch (390:18): [True: 0, False: 373k]
  ------------------
  391|       |
  392|       |        /* and now the last piece */
  393|   373k|        result = (result << bits) + (type->get(rng->state) >> (rng_bitwidth - bits));
  394|   373k|    }
  395|       |
  396|   373k|    return result;
  397|   373k|}

rng_pcg32.c:igraph_rng_pcg32_seed:
   43|  1.88k|static igraph_error_t igraph_rng_pcg32_seed(void *vstate, igraph_uint_t seed) {
   44|  1.88k|    pcg32_random_t *state = (pcg32_random_t*) vstate;
   45|       |
   46|       |    /* PCG32 is seeded by a 64-bit state and a 64-bit sequence number (well, only
   47|       |     * 63 bits are used from the sequence number, though). Since the unified
   48|       |     * igraph RNG seeding interface provides a single igraph_uint_t as the seed,
   49|       |     * we use the seed to fill in the sequence number and use the state from
   50|       |     * PCG32_INITIALIZER */
   51|  1.88k|    if (seed == 0) {
  ------------------
  |  Branch (51:9): [True: 0, False: 1.88k]
  ------------------
   52|       |        /* If you feel the temptation to unify the two branches by running
   53|       |         * seed = pcg32_initializer.inc >> 1, don't.
   54|       |         * seed is an igraph_uint_t, so it can be 32-bit or 64-bit.
   55|       |         * pcg32_initializer.inc is always 64-bit.
   56|       |         */
   57|      0|        pcg32_srandom_r(state, pcg32_initializer.state, pcg32_initializer.inc >> 1);
  ------------------
  |  | 2398|      0|#define pcg32_srandom_r                 pcg_setseq_64_srandom_r
  ------------------
   58|  1.88k|    } else {
   59|  1.88k|        pcg32_srandom_r(state, pcg32_initializer.state, seed);
  ------------------
  |  | 2398|  1.88k|#define pcg32_srandom_r                 pcg_setseq_64_srandom_r
  ------------------
   60|  1.88k|    }
   61|       |
   62|  1.88k|    return IGRAPH_SUCCESS;
   63|  1.88k|}
rng_pcg32.c:igraph_rng_pcg32_get:
   38|   829k|static igraph_uint_t igraph_rng_pcg32_get(void *vstate) {
   39|   829k|    pcg32_random_t *state = (pcg32_random_t*) vstate;
   40|   829k|    return pcg32_random_r(state);
  ------------------
  |  | 2388|   829k|#define pcg32_random_r                  pcg_setseq_64_xsh_rr_32_random_r
  ------------------
   41|   829k|}

