VEP_Parse:
  613|  1.61k|{
  614|  1.61k|	const char *e;
  615|  1.61k|	struct vep_match *vm;
  616|  1.61k|	int i;
  617|       |
  618|  1.61k|	CHECK_OBJ_NOTNULL(vep, VEP_MAGIC);
  ------------------
  |  |   66|  1.61k|	do {								\
  |  |   67|  1.61k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  1.61k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  619|  1.61k|	assert(l > 0);
  ------------------
  |  |   65|  1.61k|#define assert(e)							\
  |  |   66|  1.61k|do {									\
  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  620|       |
  621|  1.61k|	if (vep->startup) {
  ------------------
  |  Branch (621:6): [True: 1.61k, False: 0]
  ------------------
  622|       |		/*
  623|       |		 * We must force the GZIP header out as a SKIP string,
  624|       |		 * otherwise an object starting with <esi:include would
  625|       |		 * have its GZIP header appear after the included object
  626|       |		 * (e000026.vtc)
  627|       |		 */
  628|  1.61k|		vep->ver_p = "";
  629|  1.61k|		vep->last_mark = SKIP;
  630|  1.61k|		vep_mark_common(vep, vep->ver_p, VERBATIM);
  631|  1.61k|		vep->startup = 0;
  632|  1.61k|		AZ(vep->hack_p);
  ------------------
  |  |   83|  1.61k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  633|  1.61k|		vep->hack_p = p;
  634|  1.61k|	}
  635|       |
  636|  1.61k|	vep->ver_p = p;
  637|       |
  638|  1.61k|	e = p + l;
  639|       |
  640|   606k|	while (p < e) {
  ------------------
  |  Branch (640:9): [True: 604k, False: 1.61k]
  ------------------
  641|   604k|		AN(vep->state);
  ------------------
  |  |   84|   604k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|   604k|#define assert(e)							\
  |  |  |  |   66|   604k|do {									\
  |  |  |  |   67|   604k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 604k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|   604k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 604k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 604k]
  |  |  ------------------
  ------------------
  642|   604k|		Debug("EP %s %d (%.*s) [%.*s]\n",
  643|   604k|		    vep->state,
  644|   604k|		    vep->remove,
  645|   604k|		    vep->tag_i, vep->tag,
  646|   604k|		    (e - p) > 10 ? 10 : (int)(e-p), p);
  647|   604k|		assert(p >= vep->ver_p);
  ------------------
  |  |   65|   604k|#define assert(e)							\
  |  |   66|   604k|do {									\
  |  |   67|   604k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 604k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   604k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 604k]
  |  |  ------------------
  ------------------
  648|       |
  649|       |		/******************************************************
  650|       |		 * SECTION A
  651|       |		 */
  652|       |
  653|   604k|		if (vep->state == VEP_START) {
  ------------------
  |  Branch (653:7): [True: 3.49k, False: 601k]
  ------------------
  654|  3.49k|			if (vep->flags.esi_remove_bom &&
  ------------------
  |  Branch (654:8): [True: 3.37k, False: 112]
  ------------------
  655|  3.37k|			    *p == (char)0xeb) {
  ------------------
  |  Branch (655:8): [True: 1.91k, False: 1.46k]
  ------------------
  656|  1.91k|				vep->match = vep_match_bom;
  657|  1.91k|				vep->state = VEP_MATCH;
  658|  1.91k|			} else
  659|  1.58k|				vep->state = VEP_BOM;
  660|   601k|		} else if (vep->state == VEP_BOM) {
  ------------------
  |  Branch (660:14): [True: 1.59k, False: 599k]
  ------------------
  661|  1.59k|			vep_mark_skip(vep, p);
  662|  1.59k|			if (vep->flags.esi_disable_xml_check)
  ------------------
  |  Branch (662:8): [True: 1.51k, False: 82]
  ------------------
  663|  1.51k|				vep->state = VEP_NEXTTAG;
  664|     82|			else
  665|     82|				vep->state = VEP_TESTXML;
  666|   599k|		} else if (vep->state == VEP_TESTXML) {
  ------------------
  |  Branch (666:14): [True: 82, False: 599k]
  ------------------
  667|       |			/*
  668|       |			 * If the first non-whitespace char is different
  669|       |			 * from '<' we assume this is not XML.
  670|       |			 */
  671|    385|			while (p < e && vct_islws(*p))
  ------------------
  |  |   72|    376|#define vct_islws(x) vct_is(x, VCT_LWS)
  |  |  ------------------
  |  |  |  |   39|    376|#define VCT_LWS			(VCT_CRLF | VCT_OWS)
  |  |  |  |  ------------------
  |  |  |  |  |  |   38|    376|#define VCT_CRLF		(1<<1)
  |  |  |  |  ------------------
  |  |  |  |               #define VCT_LWS			(VCT_CRLF | VCT_OWS)
  |  |  |  |  ------------------
  |  |  |  |  |  |   37|    376|#define VCT_OWS			(1<<0)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (72:22): [True: 303, False: 73]
  |  |  ------------------
  ------------------
  |  Branch (671:11): [True: 376, False: 9]
  ------------------
  672|    303|				p++;
  673|     82|			vep_mark_verbatim(vep, p);
  674|     82|			if (p < e && *p == '<') {
  ------------------
  |  Branch (674:8): [True: 73, False: 9]
  |  Branch (674:17): [True: 10, False: 63]
  ------------------
  675|     10|				p++;
  676|     10|				vep->state = VEP_STARTTAG;
  677|     72|			} else if (p < e && *p == (char)0xeb) {
  ------------------
  |  Branch (677:15): [True: 63, False: 9]
  |  Branch (677:24): [True: 5, False: 58]
  ------------------
  678|      5|				VSLb(vep->vc->wrk->vsl, SLT_ESI_xmlerror,
  679|      5|				    "WARN: No ESI processing, "
  680|      5|				    "first char not '<' but BOM."
  681|      5|				    " (See feature esi_remove_bom)"
  682|      5|				);
  683|      5|				vep->state = VEP_NOTXML;
  684|     67|			} else if (p < e) {
  ------------------
  |  Branch (684:15): [True: 58, False: 9]
  ------------------
  685|     58|				VSLb(vep->vc->wrk->vsl, SLT_ESI_xmlerror,
  686|     58|				    "WARN: No ESI processing, "
  687|     58|				    "first char not '<'."
  688|     58|				    " (See feature esi_disable_xml_check)"
  689|     58|				);
  690|     58|				vep->state = VEP_NOTXML;
  691|     58|			}
  692|   599k|		} else if (vep->state == VEP_NOTXML) {
  ------------------
  |  Branch (692:14): [True: 63, False: 599k]
  ------------------
  693|       |			/*
  694|       |			 * This is not recognized as XML, just skip thru
  695|       |			 * vfp_esi_end() will handle the rest
  696|       |			 */
  697|     63|			p = e;
  698|     63|			vep_mark_verbatim(vep, p);
  699|       |
  700|       |		/******************************************************
  701|       |		 * SECTION B
  702|       |		 */
  703|       |
  704|   599k|		} else if (vep->state == VEP_NOTMYTAG) {
  ------------------
  |  Branch (704:14): [True: 19.7k, False: 579k]
  ------------------
  705|  19.7k|			if (vep->flags.esi_ignore_other_elements) {
  ------------------
  |  Branch (705:8): [True: 19.2k, False: 426]
  ------------------
  706|  19.2k|				p++;
  707|  19.2k|				vep->state = VEP_NEXTTAG;
  708|  19.2k|			} else {
  709|    426|				vep->tag_i = 0;
  710|  52.2k|				while (p < e) {
  ------------------
  |  Branch (710:12): [True: 52.2k, False: 15]
  ------------------
  711|  52.2k|					if (*p++ == '>') {
  ------------------
  |  Branch (711:10): [True: 411, False: 51.8k]
  ------------------
  712|    411|						vep->state = VEP_NEXTTAG;
  713|    411|						break;
  714|    411|					}
  715|  52.2k|				}
  716|    426|			}
  717|  19.7k|			if (p == e && !vep->remove)
  ------------------
  |  Branch (717:8): [True: 53, False: 19.6k]
  |  Branch (717:18): [True: 51, False: 2]
  ------------------
  718|     51|				vep_mark_verbatim(vep, p);
  719|   579k|		} else if (vep->state == VEP_NEXTTAG) {
  ------------------
  |  Branch (719:14): [True: 96.0k, False: 483k]
  ------------------
  720|       |			/*
  721|       |			 * Hunt for start of next tag and keep an eye
  722|       |			 * out for end of EsiCmt if armed.
  723|       |			 */
  724|  96.0k|			vep->emptytag = 0;
  725|  96.0k|			vep->attr = NULL;
  726|  96.0k|			vep->dostuff = NULL;
  727|  12.4M|			while (p < e && *p != '<') {
  ------------------
  |  Branch (727:11): [True: 12.4M, False: 322]
  |  Branch (727:20): [True: 12.3M, False: 95.7k]
  ------------------
  728|  12.3M|				if (vep->esicmt_p == NULL) {
  ------------------
  |  Branch (728:9): [True: 12.0M, False: 291k]
  ------------------
  729|  12.0M|					p++;
  730|  12.0M|					continue;
  731|  12.0M|				}
  732|   291k|				if (*p != *vep->esicmt_p) {
  ------------------
  |  Branch (732:9): [True: 173k, False: 118k]
  ------------------
  733|   173k|					p++;
  734|   173k|					vep->esicmt_p = vep->esicmt;
  735|   173k|					continue;
  736|   173k|				}
  737|   118k|				if (!vep->remove && vep->esicmt_p == vep->esicmt)
  ------------------
  |  Branch (737:9): [True: 117k, False: 1.15k]
  |  Branch (737:25): [True: 40.2k, False: 76.9k]
  ------------------
  738|  40.2k|					vep_mark_verbatim(vep, p);
  739|   118k|				p++;
  740|   118k|				if (*++vep->esicmt_p == '\0') {
  ------------------
  |  Branch (740:9): [True: 38.1k, False: 80.1k]
  ------------------
  741|  38.1k|					vep->esi_found = 1;
  742|  38.1k|					vep->esicmt = NULL;
  743|  38.1k|					vep->esicmt_p = NULL;
  744|       |					/*
  745|       |					 * The end of the esicmt
  746|       |					 * should not be emitted.
  747|       |					 * But the stuff before should
  748|       |					 */
  749|  38.1k|					vep_mark_skip(vep, p);
  750|  38.1k|				}
  751|   118k|			}
  752|  96.0k|			if (p < e) {
  ------------------
  |  Branch (752:8): [True: 95.7k, False: 322]
  ------------------
  753|  95.7k|				if (!vep->remove)
  ------------------
  |  Branch (753:9): [True: 89.9k, False: 5.81k]
  ------------------
  754|  89.9k|					vep_mark_verbatim(vep, p);
  755|  95.7k|				assert(*p == '<');
  ------------------
  |  |   65|  95.7k|#define assert(e)							\
  |  |   66|  95.7k|do {									\
  |  |   67|  95.7k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 95.7k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  95.7k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 95.7k]
  |  |  ------------------
  ------------------
  756|  95.7k|				p++;
  757|  95.7k|				vep->state = VEP_STARTTAG;
  758|  95.7k|			} else if (vep->esicmt_p == vep->esicmt && !vep->remove)
  ------------------
  |  Branch (758:15): [True: 247, False: 75]
  |  Branch (758:47): [True: 227, False: 20]
  ------------------
  759|    227|				vep_mark_verbatim(vep, p);
  760|       |
  761|       |		/******************************************************
  762|       |		 * SECTION C
  763|       |		 */
  764|       |
  765|   483k|		} else if (vep->state == VEP_STARTTAG) {
  ------------------
  |  Branch (765:14): [True: 95.6k, False: 387k]
  ------------------
  766|       |			/* Start of tag, set up match table */
  767|  95.6k|			vep->endtag = 0;
  768|  95.6k|			vep->match = vep_match_starttag;
  769|  95.6k|			vep->state = VEP_MATCH;
  770|   387k|		} else if (vep->state == VEP_COMMENT) {
  ------------------
  |  Branch (770:14): [True: 1.35k, False: 386k]
  ------------------
  771|  1.35k|			vep->esicmt_p = vep->esicmt = NULL;
  772|  1.35k|			vep->until_p = vep->until = "-->";
  773|  1.35k|			vep->until_s = VEP_NEXTTAG;
  774|  1.35k|			vep->state = VEP_UNTIL;
  775|   386k|		} else if (vep->state == VEP_COMMENTESI) {
  ------------------
  |  Branch (775:14): [True: 39.2k, False: 347k]
  ------------------
  776|  39.2k|			if (vep->remove)
  ------------------
  |  Branch (776:8): [True: 672, False: 38.5k]
  ------------------
  777|    672|				vep_error(vep,
  778|    672|				    "ESI 1.0 Nested <!--esi"
  779|    672|				    " element in <esi:remove>");
  780|  39.2k|			vep->esicmt_p = vep->esicmt = "-->";
  781|  39.2k|			vep->state = VEP_NEXTTAG;
  782|  39.2k|			vep_mark_skip(vep, p);
  783|   347k|		} else if (vep->state == VEP_CDATA) {
  ------------------
  |  Branch (783:14): [True: 3.57k, False: 343k]
  ------------------
  784|       |			/*
  785|       |			 * Easy: just look for the end of CDATA
  786|       |			 */
  787|  3.57k|			vep->until_p = vep->until = "]]>";
  788|  3.57k|			vep->until_s = VEP_NEXTTAG;
  789|  3.57k|			vep->state = VEP_UNTIL;
  790|   343k|		} else if (vep->state == VEP_ESIENDTAG) {
  ------------------
  |  Branch (790:14): [True: 2.04k, False: 341k]
  ------------------
  791|  2.04k|			vep->endtag = 1;
  792|  2.04k|			vep->state = VEP_ESITAG;
  793|   341k|		} else if (vep->state == VEP_ESITAG) {
  ------------------
  |  Branch (793:14): [True: 31.3k, False: 310k]
  ------------------
  794|  31.3k|			vep->in_esi_tag = 1;
  795|  31.3k|			vep->esi_found = 1;
  796|  31.3k|			vep_mark_skip(vep, p);
  797|  31.3k|			vep->match = vep_match_esi;
  798|  31.3k|			vep->state = VEP_MATCH;
  799|   310k|		} else if (vep->state == VEP_ESIINCLUDE) {
  ------------------
  |  Branch (799:14): [True: 17.4k, False: 292k]
  ------------------
  800|  17.4k|			if (vep->remove) {
  ------------------
  |  Branch (800:8): [True: 1.41k, False: 16.0k]
  ------------------
  801|  1.41k|				vep_error(vep,
  802|  1.41k|				    "ESI 1.0 <esi:include> element"
  803|  1.41k|				    " nested in <esi:remove>");
  804|  1.41k|				vep->state = VEP_TAGERROR;
  805|  16.0k|			} else if (vep->endtag) {
  ------------------
  |  Branch (805:15): [True: 204, False: 15.8k]
  ------------------
  806|    204|				vep_error(vep,
  807|    204|				    "ESI 1.0 </esi:include> illegal end-tag");
  808|    204|				vep->state = VEP_TAGERROR;
  809|  15.8k|			} else {
  810|  15.8k|				vep->dostuff = vep_do_include;
  811|  15.8k|				vep->state = VEP_INTAG;
  812|  15.8k|				vep->attr = vep_match_attr_include;
  813|  15.8k|			}
  814|   292k|		} else if (vep->state == VEP_ESIREMOVE) {
  ------------------
  |  Branch (814:14): [True: 6.15k, False: 286k]
  ------------------
  815|  6.15k|			vep->dostuff = vep_do_remove;
  816|  6.15k|			vep->state = VEP_INTAG;
  817|   286k|		} else if (vep->state == VEP_ESICOMMENT) {
  ------------------
  |  Branch (817:14): [True: 2.63k, False: 284k]
  ------------------
  818|  2.63k|			if (vep->remove) {
  ------------------
  |  Branch (818:8): [True: 423, False: 2.21k]
  ------------------
  819|    423|				vep_error(vep,
  820|    423|				    "ESI 1.0 <esi:comment> element"
  821|    423|				    " nested in <esi:remove>");
  822|    423|				vep->state = VEP_TAGERROR;
  823|  2.21k|			} else if (vep->endtag) {
  ------------------
  |  Branch (823:15): [True: 290, False: 1.92k]
  ------------------
  824|    290|				vep_error(vep,
  825|    290|				    "ESI 1.0 </esi:comment> illegal end-tag");
  826|    290|				vep->state = VEP_TAGERROR;
  827|  1.92k|			} else {
  828|  1.92k|				vep->dostuff = vep_do_comment;
  829|  1.92k|				vep->state = VEP_INTAG;
  830|  1.92k|			}
  831|   284k|		} else if (vep->state == VEP_ESIBOGON) {
  ------------------
  |  Branch (831:14): [True: 5.02k, False: 279k]
  ------------------
  832|  5.02k|			vep_error(vep,
  833|  5.02k|			    "ESI 1.0 <esi:bogus> element");
  834|  5.02k|			vep->state = VEP_TAGERROR;
  835|       |
  836|       |		/******************************************************
  837|       |		 * SECTION D
  838|       |		 */
  839|       |
  840|   279k|		} else if (vep->state == VEP_INTAG) {
  ------------------
  |  Branch (840:14): [True: 39.7k, False: 239k]
  ------------------
  841|  39.7k|			vep->tag_i = 0;
  842|  45.4k|			while (p < e && vct_islws(*p) && !vep->emptytag) {
  ------------------
  |  |   72|  90.8k|#define vct_islws(x) vct_is(x, VCT_LWS)
  |  |  ------------------
  |  |  |  |   39|  45.4k|#define VCT_LWS			(VCT_CRLF | VCT_OWS)
  |  |  |  |  ------------------
  |  |  |  |  |  |   38|  45.4k|#define VCT_CRLF		(1<<1)
  |  |  |  |  ------------------
  |  |  |  |               #define VCT_LWS			(VCT_CRLF | VCT_OWS)
  |  |  |  |  ------------------
  |  |  |  |  |  |   37|  45.4k|#define VCT_OWS			(1<<0)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (72:22): [True: 5.68k, False: 39.7k]
  |  |  ------------------
  ------------------
  |  Branch (842:11): [True: 45.4k, False: 18]
  |  Branch (842:37): [True: 5.68k, False: 0]
  ------------------
  843|  5.68k|				p++;
  844|  5.68k|				vep->canattr = 1;
  845|  5.68k|			}
  846|  39.7k|			if (p < e && *p == '/' && !vep->emptytag) {
  ------------------
  |  Branch (846:8): [True: 39.7k, False: 18]
  |  Branch (846:17): [True: 2.89k, False: 36.8k]
  |  Branch (846:30): [True: 2.89k, False: 0]
  ------------------
  847|  2.89k|				p++;
  848|  2.89k|				vep->emptytag = 1;
  849|  2.89k|				vep->canattr = 0;
  850|  2.89k|			}
  851|  39.7k|			if (p < e && *p == '>') {
  ------------------
  |  Branch (851:8): [True: 39.7k, False: 29]
  |  Branch (851:17): [True: 16.0k, False: 23.6k]
  ------------------
  852|  16.0k|				p++;
  853|  16.0k|				AN(vep->dostuff);
  ------------------
  |  |   84|  16.0k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  16.0k|#define assert(e)							\
  |  |  |  |   66|  16.0k|do {									\
  |  |  |  |   67|  16.0k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 16.0k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  16.0k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 16.0k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 16.0k]
  |  |  ------------------
  ------------------
  854|  16.0k|				vep_mark_skip(vep, p);
  855|  16.0k|				vep->dostuff(vep, DO_TAG);
  856|  16.0k|				vep->in_esi_tag = 0;
  857|  16.0k|				vep->state = VEP_NEXTTAG;
  858|  23.6k|			} else if (p < e && vep->emptytag) {
  ------------------
  |  Branch (858:15): [True: 23.6k, False: 29]
  |  Branch (858:24): [True: 361, False: 23.2k]
  ------------------
  859|    361|				vep_error(vep,
  860|    361|				    "XML 1.0 '>' does not follow '/' in tag");
  861|    361|				vep->state = VEP_TAGERROR;
  862|  23.3k|			} else if (p < e && vep->canattr &&
  ------------------
  |  Branch (862:15): [True: 23.2k, False: 29]
  |  Branch (862:24): [True: 21.1k, False: 2.14k]
  ------------------
  863|  21.1k|			    vct_isxmlnamestart(*p)) {
  ------------------
  |  |   85|  21.1k|#define vct_isxmlnamestart(x) vct_is(x, VCT_XMLNAMESTART)
  |  |  ------------------
  |  |  |  |   45|  21.1k|#define VCT_XMLNAMESTART	(1<<7)
  |  |  ------------------
  |  |  |  Branch (85:31): [True: 20.2k, False: 868]
  |  |  ------------------
  ------------------
  864|  20.2k|				vep->state = VEP_ATTR;
  865|  20.2k|			} else if (p < e) {
  ------------------
  |  Branch (865:15): [True: 3.00k, False: 29]
  ------------------
  866|  3.00k|				vep_error(vep,
  867|  3.00k|				    "XML 1.0 Illegal attribute start char");
  868|  3.00k|				vep->state = VEP_TAGERROR;
  869|  3.00k|			}
  870|   239k|		} else if (vep->state == VEP_TAGERROR) {
  ------------------
  |  Branch (870:14): [True: 15.0k, False: 224k]
  ------------------
  871|  4.25M|			while (p < e && *p != '>')
  ------------------
  |  Branch (871:11): [True: 4.25M, False: 135]
  |  Branch (871:20): [True: 4.24M, False: 14.8k]
  ------------------
  872|  4.24M|				p++;
  873|  15.0k|			if (p < e) {
  ------------------
  |  Branch (873:8): [True: 14.8k, False: 135]
  ------------------
  874|  14.8k|				p++;
  875|  14.8k|				vep_mark_skip(vep, p);
  876|  14.8k|				vep->in_esi_tag = 0;
  877|  14.8k|				vep->state = VEP_NEXTTAG;
  878|  14.8k|				if (vep->attr_vsb)
  ------------------
  |  Branch (878:9): [True: 757, False: 14.1k]
  ------------------
  879|    757|					VSB_destroy(&vep->attr_vsb);
  880|  14.8k|			}
  881|       |
  882|       |		/******************************************************
  883|       |		 * SECTION E
  884|       |		 */
  885|       |
  886|   224k|		} else if (vep->state == VEP_ATTR) {
  ------------------
  |  Branch (886:14): [True: 20.2k, False: 203k]
  ------------------
  887|  20.2k|			AZ(vep->attr_delim);
  ------------------
  |  |   83|  20.2k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  20.2k|#define assert(e)							\
  |  |  |  |   66|  20.2k|do {									\
  |  |  |  |   67|  20.2k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 20.2k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  20.2k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 20.2k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 20.2k]
  |  |  ------------------
  ------------------
  888|  20.2k|			if (vep->attr == NULL) {
  ------------------
  |  Branch (888:8): [True: 4.29k, False: 15.9k]
  ------------------
  889|  4.29k|				p++;
  890|  4.29k|				AZ(vep->attr_vsb);
  ------------------
  |  |   83|  4.29k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  4.29k|#define assert(e)							\
  |  |  |  |   66|  4.29k|do {									\
  |  |  |  |   67|  4.29k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 4.29k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  4.29k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 4.29k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 4.29k]
  |  |  ------------------
  ------------------
  891|  4.29k|				vep->state = VEP_SKIPATTR;
  892|  15.9k|			} else {
  893|  15.9k|				vep->match = vep->attr;
  894|  15.9k|				vep->state = VEP_MATCH;
  895|  15.9k|			}
  896|   203k|		} else if (vep->state == VEP_SKIPATTR) {
  ------------------
  |  Branch (896:14): [True: 7.05k, False: 196k]
  ------------------
  897|  21.8k|			while (p < e && vct_isxmlname(*p))
  ------------------
  |  |   86|  21.8k|#define vct_isxmlname(x) vct_is(x, VCT_XMLNAMESTART | VCT_XMLNAME)
  |  |  ------------------
  |  |  |  |   45|  21.8k|#define VCT_XMLNAMESTART	(1<<7)
  |  |  ------------------
  |  |               #define vct_isxmlname(x) vct_is(x, VCT_XMLNAMESTART | VCT_XMLNAME)
  |  |  ------------------
  |  |  |  |   46|  21.8k|#define VCT_XMLNAME		(1<<8)
  |  |  ------------------
  |  |  |  Branch (86:26): [True: 14.7k, False: 7.03k]
  |  |  ------------------
  ------------------
  |  Branch (897:11): [True: 21.8k, False: 17]
  ------------------
  898|  14.7k|				p++;
  899|  7.05k|			if (p < e && *p == '=') {
  ------------------
  |  Branch (899:8): [True: 7.03k, False: 17]
  |  Branch (899:17): [True: 4.22k, False: 2.80k]
  ------------------
  900|  4.22k|				p++;
  901|  4.22k|				vep->state = VEP_ATTRDELIM;
  902|  4.22k|			} else if (p < e && *p == '>') {
  ------------------
  |  Branch (902:15): [True: 2.80k, False: 17]
  |  Branch (902:24): [True: 579, False: 2.22k]
  ------------------
  903|    579|				vep->state = VEP_INTAG;
  904|  2.24k|			} else if (p < e && *p == '/') {
  ------------------
  |  Branch (904:15): [True: 2.22k, False: 17]
  |  Branch (904:24): [True: 359, False: 1.86k]
  ------------------
  905|    359|				vep->state = VEP_INTAG;
  906|  1.88k|			} else if (p < e && vct_issp(*p)) {
  ------------------
  |  |   70|  1.86k|#define vct_issp(x) vct_is(x, VCT_OWS)
  |  |  ------------------
  |  |  |  |   37|  1.86k|#define VCT_OWS			(1<<0)
  |  |  ------------------
  |  |  |  Branch (70:21): [True: 1.05k, False: 815]
  |  |  ------------------
  ------------------
  |  Branch (906:15): [True: 1.86k, False: 17]
  ------------------
  907|  1.05k|				vep->state = VEP_INTAG;
  908|  1.05k|			} else if (p < e) {
  ------------------
  |  Branch (908:15): [True: 815, False: 17]
  ------------------
  909|    815|				vep_error(vep,
  910|    815|				    "XML 1.0 Illegal attr char");
  911|    815|				vep->state = VEP_TAGERROR;
  912|    815|			}
  913|   196k|		} else if (vep->state == VEP_ATTRGETVAL) {
  ------------------
  |  Branch (913:14): [True: 13.2k, False: 183k]
  ------------------
  914|  13.2k|			AZ(vep->attr_vsb);
  ------------------
  |  |   83|  13.2k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  13.2k|#define assert(e)							\
  |  |  |  |   66|  13.2k|do {									\
  |  |  |  |   67|  13.2k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 13.2k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  13.2k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 13.2k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 13.2k]
  |  |  ------------------
  ------------------
  915|  13.2k|			vep->attr_vsb = VSB_new_auto();
  916|  13.2k|			vep->state = VEP_ATTRDELIM;
  917|   183k|		} else if (vep->state == VEP_ATTRDELIM) {
  ------------------
  |  Branch (917:14): [True: 17.4k, False: 166k]
  ------------------
  918|  17.4k|			AZ(vep->attr_delim);
  ------------------
  |  |   83|  17.4k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  17.4k|#define assert(e)							\
  |  |  |  |   66|  17.4k|do {									\
  |  |  |  |   67|  17.4k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 17.4k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  17.4k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 17.4k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 17.4k]
  |  |  ------------------
  ------------------
  919|  17.4k|			if (*p == '"' || *p == '\'') {
  ------------------
  |  Branch (919:8): [True: 542, False: 16.9k]
  |  Branch (919:21): [True: 638, False: 16.2k]
  ------------------
  920|  1.18k|				vep->attr_delim = *p++;
  921|  1.18k|				vep->state = VEP_ATTRVAL;
  922|  16.2k|			} else if (!vct_issp(*p)) {
  ------------------
  |  |   70|  16.2k|#define vct_issp(x) vct_is(x, VCT_OWS)
  |  |  ------------------
  |  |  |  |   37|  16.2k|#define VCT_OWS			(1<<0)
  |  |  ------------------
  ------------------
  |  Branch (922:15): [True: 15.3k, False: 954]
  ------------------
  923|  15.3k|				vep->attr_delim = ' ';
  924|  15.3k|				vep->state = VEP_ATTRVAL;
  925|  15.3k|			} else {
  926|    954|				vep_error(vep,
  927|    954|				    "XML 1.0 Illegal attribute delimiter");
  928|    954|				vep->state = VEP_TAGERROR;
  929|    954|			}
  930|       |
  931|   166k|		} else if (vep->state == VEP_ATTRVAL) {
  ------------------
  |  Branch (931:14): [True: 16.4k, False: 149k]
  ------------------
  932|  19.4M|			while (p < e && *p != '>' && *p != vep->attr_delim &&
  ------------------
  |  Branch (932:11): [True: 19.4M, False: 88]
  |  Branch (932:20): [True: 19.4M, False: 1.31k]
  |  Branch (932:33): [True: 19.4M, False: 14.6k]
  ------------------
  933|  19.4M|			   (vep->attr_delim != ' ' || !vct_issp(*p))) {
  ------------------
  |  |   70|  19.4M|#define vct_issp(x) vct_is(x, VCT_OWS)
  |  |  ------------------
  |  |  |  |   37|  19.4M|#define VCT_OWS			(1<<0)
  |  |  ------------------
  ------------------
  |  Branch (933:8): [True: 5.01k, False: 19.4M]
  |  Branch (933:34): [True: 19.4M, False: 438]
  ------------------
  934|  19.4M|				if (vep->attr_vsb != NULL)
  ------------------
  |  Branch (934:9): [True: 19.3M, False: 32.3k]
  ------------------
  935|  19.3M|					VSB_putc(vep->attr_vsb, *p);
  936|  19.4M|				p++;
  937|  19.4M|			}
  938|  16.4k|			if (p < e && *p == '>') {
  ------------------
  |  Branch (938:8): [True: 16.3k, False: 88]
  |  Branch (938:17): [True: 1.31k, False: 15.0k]
  ------------------
  939|  1.31k|				vep_error(vep,
  940|  1.31k|				    "XML 1.0 Missing end attribute delimiter");
  941|  1.31k|				vep->state = VEP_TAGERROR;
  942|  1.31k|				vep->attr_delim = 0;
  943|  1.31k|				if (vep->attr_vsb != NULL) {
  ------------------
  |  Branch (943:9): [True: 895, False: 423]
  ------------------
  944|    895|					AZ(VSB_finish(vep->attr_vsb));
  ------------------
  |  |   83|    895|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|    895|#define assert(e)							\
  |  |  |  |   66|    895|do {									\
  |  |  |  |   67|    895|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 895]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|    895|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 895]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 895]
  |  |  ------------------
  ------------------
  945|    895|					VSB_destroy(&vep->attr_vsb);
  946|    895|				}
  947|  15.1k|			} else if (p < e) {
  ------------------
  |  Branch (947:15): [True: 15.0k, False: 88]
  ------------------
  948|  15.0k|				vep->attr_delim = 0;
  949|  15.0k|				p++;
  950|  15.0k|				vep->state = VEP_INTAG;
  951|  15.0k|				if (vep->attr_vsb != NULL) {
  ------------------
  |  Branch (951:9): [True: 11.5k, False: 3.53k]
  ------------------
  952|  11.5k|					AZ(VSB_finish(vep->attr_vsb));
  ------------------
  |  |   83|  11.5k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  11.5k|#define assert(e)							\
  |  |  |  |   66|  11.5k|do {									\
  |  |  |  |   67|  11.5k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 11.5k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  11.5k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 11.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 11.5k]
  |  |  ------------------
  ------------------
  953|  11.5k|					AN(vep->dostuff);
  ------------------
  |  |   84|  11.5k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  11.5k|#define assert(e)							\
  |  |  |  |   66|  11.5k|do {									\
  |  |  |  |   67|  11.5k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 11.5k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  11.5k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 11.5k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 11.5k]
  |  |  ------------------
  ------------------
  954|  11.5k|					vep->dostuff(vep, DO_ATTR);
  955|  11.5k|					vep->attr_vsb = NULL;
  956|  11.5k|				}
  957|  15.0k|			}
  958|       |
  959|       |		/******************************************************
  960|       |		 * Utility Section
  961|       |		 */
  962|       |
  963|   149k|		} else if (vep->state == VEP_MATCH) {
  ------------------
  |  Branch (963:14): [True: 144k, False: 4.92k]
  ------------------
  964|       |			/*
  965|       |			 * Match against a table
  966|       |			 */
  967|   144k|			vm = vep_match(vep, p, e);
  968|   144k|			vep->match_hit = vm;
  969|   144k|			if (vm != NULL) {
  ------------------
  |  Branch (969:8): [True: 144k, False: 34]
  ------------------
  970|   144k|				if (vm->match != NULL)
  ------------------
  |  Branch (970:9): [True: 117k, False: 27.5k]
  ------------------
  971|   117k|					p += vstrlen(vm->match);
  ------------------
  |  |  342|   117k|#  define vstrlen(s) __builtin_strlen(s)
  ------------------
  972|   144k|				vep->state = *vm->state;
  973|   144k|				vep->match = NULL;
  974|   144k|				vep->tag_i = 0;
  975|   144k|			} else {
  976|     34|				assert(p + sizeof(vep->tag) >= e);
  ------------------
  |  |   65|     34|#define assert(e)							\
  |  |   66|     34|do {									\
  |  |   67|     34|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 34]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|     34|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 34]
  |  |  ------------------
  ------------------
  977|     34|				memcpy(vep->tag, p, e - p);
  978|     34|				vep->tag_i = e - p;
  979|     34|				vep->state = VEP_MATCHBUF;
  980|     34|				p = e;
  981|     34|			}
  982|   144k|		} else if (vep->state == VEP_MATCHBUF) {
  ------------------
  |  Branch (982:14): [True: 0, False: 4.92k]
  ------------------
  983|       |			/*
  984|       |			 * Match against a table while split over input
  985|       |			 * sections.
  986|       |			 */
  987|      0|			AN(vep->match);
  ------------------
  |  |   84|      0|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|      0|#define assert(e)							\
  |  |  |  |   66|      0|do {									\
  |  |  |  |   67|      0|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|      0|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 0]
  |  |  ------------------
  ------------------
  988|      0|			i = sizeof(vep->tag) - vep->tag_i;
  989|      0|			if (i > e - p)
  ------------------
  |  Branch (989:8): [True: 0, False: 0]
  ------------------
  990|      0|				i = e - p;
  991|      0|			memcpy(vep->tag + vep->tag_i, p, i);
  992|      0|			vm = vep_match(vep, vep->tag,
  993|      0|			    vep->tag + vep->tag_i + i);
  994|      0|			Debug("MB (%.*s) tag_i %d i %d = vm %p match %s\n",
  995|      0|			    vep->tag_i + i, vep->tag,
  996|      0|			    vep->tag_i,
  997|      0|			    i,
  998|      0|			    vm,
  999|      0|			    vm ? vm->match : "(nil)");
 1000|       |
 1001|      0|			if (vm == NULL) {
  ------------------
  |  Branch (1001:8): [True: 0, False: 0]
  ------------------
 1002|      0|				vep->tag_i += i;
 1003|      0|				p += i;
 1004|      0|				assert(p == e);
  ------------------
  |  |   65|      0|#define assert(e)							\
  |  |   66|      0|do {									\
  |  |   67|      0|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1005|      0|			} else {
 1006|      0|				vep->match_hit = vm;
 1007|      0|				vep->state = *vm->state;
 1008|      0|				if (vm->match != NULL) {
  ------------------
  |  Branch (1008:9): [True: 0, False: 0]
  ------------------
 1009|      0|					i = vstrlen(vm->match);
  ------------------
  |  |  342|      0|#  define vstrlen(s) __builtin_strlen(s)
  ------------------
 1010|      0|					if (i > vep->tag_i)
  ------------------
  |  Branch (1010:10): [True: 0, False: 0]
  ------------------
 1011|      0|						p += i - vep->tag_i;
 1012|      0|				}
 1013|      0|				vep->match = NULL;
 1014|      0|				vep->tag_i = 0;
 1015|      0|			}
 1016|  4.92k|		} else if (vep->state == VEP_UNTIL) {
  ------------------
  |  Branch (1016:14): [True: 4.92k, False: 0]
  ------------------
 1017|       |			/*
 1018|       |			 * Skip until we see magic string
 1019|       |			 */
 1020|  10.6M|			while (p < e) {
  ------------------
  |  Branch (1020:11): [True: 10.6M, False: 75]
  ------------------
 1021|  10.6M|				if (*p++ != *vep->until_p++) {
  ------------------
  |  Branch (1021:9): [True: 10.5M, False: 24.9k]
  ------------------
 1022|  10.5M|					vep->until_p = vep->until;
 1023|  10.5M|				} else if (*vep->until_p == '\0') {
  ------------------
  |  Branch (1023:16): [True: 4.84k, False: 20.0k]
  ------------------
 1024|  4.84k|					vep->state = vep->until_s;
 1025|  4.84k|					break;
 1026|  4.84k|				}
 1027|  10.6M|			}
 1028|  4.92k|			if (p == e && !vep->remove)
  ------------------
  |  Branch (1028:8): [True: 82, False: 4.84k]
  |  Branch (1028:18): [True: 76, False: 6]
  ------------------
 1029|     76|				vep_mark_verbatim(vep, p);
 1030|  4.92k|		} else {
 1031|      0|			Debug("*** Unknown state %s\n", vep->state);
 1032|      0|			WRONG("WRONG ESI PARSER STATE");
  ------------------
  |  |   88|      0|#define WRONG(expl)							\
  |  |   89|      0|do {									\
  |  |   90|      0|	VAS_Fail(__func__, __FILE__, __LINE__, expl, VAS_WRONG);	\
  |  |   91|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (91:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
 1033|      0|		}
 1034|   604k|	}
 1035|       |	/*
 1036|       |	 * We must always mark up the storage we got, try to do so
 1037|       |	 * in the most efficient way, in particular with respect to
 1038|       |	 * minimizing and limiting use of pending.
 1039|       |	 */
 1040|  1.61k|	if (p == vep->ver_p)
  ------------------
  |  Branch (1040:6): [True: 1.02k, False: 597]
  ------------------
 1041|  1.02k|		;
 1042|    597|	else if (vep->in_esi_tag)
  ------------------
  |  Branch (1042:11): [True: 348, False: 249]
  ------------------
 1043|    348|		vep_mark_skip(vep, p);
 1044|    249|	else if (vep->remove)
  ------------------
  |  Branch (1044:11): [True: 35, False: 214]
  ------------------
 1045|     35|		vep_mark_skip(vep, p);
 1046|    214|	else
 1047|    214|		vep_mark_pending(vep, p);
 1048|  1.61k|}
VEP_Init:
 1072|  1.61k|{
 1073|  1.61k|	struct vep_state *vep;
 1074|       |
 1075|  1.61k|	CHECK_OBJ_NOTNULL(vc, VFP_CTX_MAGIC);
  ------------------
  |  |   66|  1.61k|	do {								\
  |  |   67|  1.61k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  1.61k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
 1076|  1.61k|	CHECK_OBJ_NOTNULL(req, HTTP_MAGIC);
  ------------------
  |  |   66|  1.61k|	do {								\
  |  |   67|  1.61k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  1.61k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
 1077|  1.61k|	vep = WS_Alloc(vc->resp->ws, sizeof *vep);
 1078|  1.61k|	if (vep == NULL) {
  ------------------
  |  Branch (1078:6): [True: 0, False: 1.61k]
  ------------------
 1079|      0|		VSLb(vc->wrk->vsl, SLT_VCL_Error,
 1080|      0|		     "VEP_Init() workspace overflow");
 1081|      0|		return (NULL);
 1082|      0|	}
 1083|       |
 1084|  1.61k|	INIT_OBJ(vep, VEP_MAGIC);
  ------------------
  |  |   15|  1.61k|	do {								\
  |  |   16|  1.61k|		(void)memset(to, 0, sizeof *(to));			\
  |  |   17|  1.61k|		(to)->magic = (type_magic);				\
  |  |   18|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (18:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
 1085|  1.61k|	vep->flags = flags;
 1086|  1.61k|	vep->url = req->hd[HTTP_HDR_URL].b;
 1087|  1.61k|	vep->vc = vc;
 1088|  1.61k|	vep->vsb = VSB_new_auto();
 1089|  1.61k|	AN(vep->vsb);
  ------------------
  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
 1090|       |
 1091|  1.61k|	if (cb != NULL) {
  ------------------
  |  Branch (1091:6): [True: 0, False: 1.61k]
  ------------------
 1092|      0|		vep->dogzip = 1;
 1093|       |		/* XXX */
 1094|      0|		VSB_printf(vep->vsb, "%c", VEC_GZ);
  ------------------
  |  |   32|      0|#define	VEC_GZ	(0x21)
  ------------------
 1095|      0|		vep->cb = cb;
 1096|      0|		vep->cb_priv = cb_priv;
 1097|  1.61k|	} else {
 1098|  1.61k|		vep->cb = vep_default_cb;
 1099|  1.61k|		vep->cb_priv = &vep->cb_x;
 1100|  1.61k|	}
 1101|       |
 1102|  1.61k|	vep->state = VEP_START;
 1103|  1.61k|	vep->crc = crc32(0L, Z_NULL, 0);
  ------------------
  |  |   38|  1.61k|#  define crc32                 z_crc32
  ------------------
              	vep->crc = crc32(0L, Z_NULL, 0);
  ------------------
  |  |  217|  1.61k|#define Z_NULL  0  /* for initializing zalloc, zfree, opaque */
  ------------------
 1104|  1.61k|	vep->crcp = crc32(0L, Z_NULL, 0);
  ------------------
  |  |   38|  1.61k|#  define crc32                 z_crc32
  ------------------
              	vep->crcp = crc32(0L, Z_NULL, 0);
  ------------------
  |  |  217|  1.61k|#define Z_NULL  0  /* for initializing zalloc, zfree, opaque */
  ------------------
 1105|       |
 1106|  1.61k|	vep->startup = 1;
 1107|  1.61k|	return (vep);
 1108|  1.61k|}
VEP_Finish:
 1115|  1.61k|{
 1116|  1.61k|	ssize_t l, lcb;
 1117|       |
 1118|  1.61k|	CHECK_OBJ_NOTNULL(vep, VEP_MAGIC);
  ------------------
  |  |   66|  1.61k|	do {								\
  |  |   67|  1.61k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  1.61k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
 1119|       |
 1120|  1.61k|	if (vep->include_src)
  ------------------
  |  Branch (1120:6): [True: 44, False: 1.57k]
  ------------------
 1121|     44|		VSB_destroy(&vep->include_src);
 1122|  1.61k|	if (vep->attr_vsb)
  ------------------
  |  Branch (1122:6): [True: 38, False: 1.57k]
  ------------------
 1123|     38|		VSB_destroy(&vep->attr_vsb);
 1124|       |
 1125|  1.61k|	if (vep->state != VEP_START &&
  ------------------
  |  Branch (1125:6): [True: 1.60k, False: 12]
  ------------------
 1126|  1.60k|	    vep->state != VEP_BOM &&
  ------------------
  |  Branch (1126:6): [True: 1.60k, False: 0]
  ------------------
 1127|  1.60k|	    vep->state != VEP_TESTXML &&
  ------------------
  |  Branch (1127:6): [True: 1.59k, False: 9]
  ------------------
 1128|  1.59k|	    vep->state != VEP_NOTXML &&
  ------------------
  |  Branch (1128:6): [True: 1.53k, False: 63]
  ------------------
 1129|  1.53k|	    vep->state != VEP_NEXTTAG) {
  ------------------
  |  Branch (1129:6): [True: 578, False: 955]
  ------------------
 1130|    578|		vep_error(vep, "VEP ended inside a tag");
 1131|    578|	}
 1132|       |
 1133|  1.61k|	if (vep->o_pending)
  ------------------
  |  Branch (1133:6): [True: 214, False: 1.40k]
  ------------------
 1134|    214|		vep_mark_common(vep, vep->ver_p, vep->last_mark);
 1135|  1.61k|	if (vep->o_wait > 0) {
  ------------------
  |  Branch (1135:6): [True: 1.58k, False: 30]
  ------------------
 1136|  1.58k|		lcb = vep->cb(vep->vc, vep->cb_priv, 0, VGZ_ALIGN);
 1137|  1.58k|		vep_emit_common(vep, lcb - vep->o_last, vep->last_mark);
 1138|  1.58k|	}
 1139|       |	// NB: We don't account for PAD+SUM+LEN in gzipped objects
 1140|  1.61k|	(void)vep->cb(vep->vc, vep->cb_priv, 0, VGZ_FINISH);
 1141|       |
 1142|  1.61k|	AZ(VSB_finish(vep->vsb));
  ------------------
  |  |   83|  1.61k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
 1143|  1.61k|	l = VSB_len(vep->vsb);
 1144|  1.61k|	if (vep->esi_found && l > 0)
  ------------------
  |  Branch (1144:6): [True: 1.11k, False: 500]
  |  Branch (1144:24): [True: 1.11k, False: 0]
  ------------------
 1145|  1.11k|		return (vep->vsb);
 1146|    500|	VSB_destroy(&vep->vsb);
 1147|       |	return (NULL);
 1148|  1.61k|}
cache_esi_parse.c:vep_mark_common:
  320|   274k|{
  321|   274k|	ssize_t l, lcb;
  322|       |
  323|   274k|	assert(mark == SKIP || mark == VERBATIM);
  ------------------
  |  |   65|   274k|#define assert(e)							\
  |  |   66|   274k|do {									\
  |  |   67|   406k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:8): [True: 141k, False: 132k]
  |  |  |  Branch (67:8): [True: 132k, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   274k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 274k]
  |  |  ------------------
  ------------------
  324|       |
  325|       |	/* The NO-OP case, no data, no pending data & no change of mode */
  326|   274k|	if (vep->last_mark == mark && p == vep->ver_p && vep->o_pending == 0)
  ------------------
  |  Branch (326:6): [True: 62.2k, False: 211k]
  |  Branch (326:32): [True: 214, False: 61.9k]
  |  Branch (326:51): [True: 0, False: 214]
  ------------------
  327|      0|		return;
  328|       |
  329|       |	/*
  330|       |	 * If we changed mode, emit whatever the opposite mode
  331|       |	 * assembled before the pending bytes.
  332|       |	 */
  333|       |
  334|   274k|	if (vep->last_mark != mark && (vep->o_wait > 0 || vep->startup)) {
  ------------------
  |  Branch (334:6): [True: 211k, False: 62.2k]
  |  Branch (334:33): [True: 183k, False: 28.9k]
  |  Branch (334:52): [True: 1.61k, False: 27.2k]
  ------------------
  335|   184k|		lcb = vep->cb(vep->vc, vep->cb_priv, 0,
  336|   184k|		    mark == VERBATIM ? VGZ_RESET : VGZ_ALIGN);
  ------------------
  |  Branch (336:7): [True: 104k, False: 79.9k]
  ------------------
  337|   184k|		vep_emit_common(vep, lcb - vep->o_last, vep->last_mark);
  338|   184k|		vep->o_last = lcb;
  339|   184k|		vep->o_wait = 0;
  340|   184k|	}
  341|       |
  342|       |	/* Transfer pending bytes CRC into active mode CRC */
  343|   274k|	if (vep->o_pending) {
  ------------------
  |  Branch (343:6): [True: 214, False: 273k]
  ------------------
  344|    214|		(void)vep->cb(vep->vc, vep->cb_priv, vep->o_pending,
  345|    214|		     VGZ_NORMAL);
  346|    214|		if (vep->o_crc == 0) {
  ------------------
  |  Branch (346:7): [True: 63, False: 151]
  ------------------
  347|     63|			vep->crc = vep->crcp;
  348|     63|			vep->o_crc = vep->o_pending;
  349|    151|		} else {
  350|    151|			vep->crc = crc32_combine(vep->crc,
  ------------------
  |  |   39|    151|#  define crc32_combine         z_crc32_combine
  ------------------
  351|    151|			    vep->crcp, vep->o_pending);
  352|    151|			vep->o_crc += vep->o_pending;
  353|    151|		}
  354|    214|		vep->crcp = crc32(0L, Z_NULL, 0);
  ------------------
  |  |   38|    214|#  define crc32                 z_crc32
  ------------------
              		vep->crcp = crc32(0L, Z_NULL, 0);
  ------------------
  |  |  217|    214|#define Z_NULL  0  /* for initializing zalloc, zfree, opaque */
  ------------------
  355|    214|		vep->o_wait += vep->o_pending;
  356|    214|		vep->o_pending = 0;
  357|    214|	}
  358|       |
  359|       |	/* * Process this bit of input */
  360|   274k|	AN(vep->ver_p);
  ------------------
  |  |   84|   274k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|   274k|#define assert(e)							\
  |  |  |  |   66|   274k|do {									\
  |  |  |  |   67|   274k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 274k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|   274k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 274k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 274k]
  |  |  ------------------
  ------------------
  361|   274k|	l = p - vep->ver_p;
  362|   274k|	assert(l >= 0);
  ------------------
  |  |   65|   274k|#define assert(e)							\
  |  |   66|   274k|do {									\
  |  |   67|   274k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 274k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   274k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 274k]
  |  |  ------------------
  ------------------
  363|   274k|	vep->crc = crc32(vep->crc, (const void*)vep->ver_p, l);
  ------------------
  |  |   38|   274k|#  define crc32                 z_crc32
  ------------------
  364|   274k|	vep->o_crc += l;
  365|   274k|	vep->ver_p = p;
  366|       |
  367|   274k|	vep->o_wait += l;
  368|   274k|	vep->last_mark = mark;
  369|   274k|	(void)vep->cb(vep->vc, vep->cb_priv, l, VGZ_NORMAL);
  370|   274k|}
cache_esi_parse.c:vep_mark_skip:
  382|   141k|{
  383|       |
  384|   141k|	vep_mark_common(vep, p, SKIP);
  385|   141k|	vep->nm_skip++;
  386|   141k|}
cache_esi_parse.c:vep_mark_verbatim:
  374|   130k|{
  375|       |
  376|   130k|	vep_mark_common(vep, p, VERBATIM);
  377|   130k|	vep->nm_verbatim++;
  378|   130k|}
cache_esi_parse.c:vep_error:
  205|  22.1k|{
  206|  22.1k|	VSC_C_main->esi_errors++;
  207|  22.1k|	VSLb(vep->vc->wrk->vsl, SLT_ESI_xmlerror, "ERR: after %zd %s",
  208|  22.1k|	     vep->o_last, p);
  209|  22.1k|}
cache_esi_parse.c:vep_do_include:
  478|  21.4k|{
  479|  21.4k|	const char *p, *q, *h;
  480|  21.4k|	ssize_t l;
  481|  21.4k|	char incl;
  482|       |
  483|  21.4k|	Debug("DO_INCLUDE(%d)\n", what);
  484|  21.4k|	if (what == DO_ATTR) {
  ------------------
  |  Branch (484:6): [True: 11.5k, False: 9.89k]
  ------------------
  485|  11.5k|		Debug("ATTR (%s) (%s)\n", vep->match_hit->match,
  486|  11.5k|			VSB_data(vep->attr_vsb));
  487|  11.5k|		if (!vstrcmp("src=", vep->match_hit->match)) {
  ------------------
  |  |  336|  11.5k|#  define vstrcmp(s1, s2) __builtin_strcmp(s1, s2)
  ------------------
  |  Branch (487:7): [True: 11.5k, False: 0]
  ------------------
  488|  11.5k|			include_attr_src(vep);
  489|  11.5k|			return;
  490|  11.5k|		}
  491|      0|		if (!vstrcmp("onerror=", vep->match_hit->match)) {
  ------------------
  |  |  336|      0|#  define vstrcmp(s1, s2) __builtin_strcmp(s1, s2)
  ------------------
  |  Branch (491:7): [True: 0, False: 0]
  ------------------
  492|      0|			include_attr_onerror(vep);
  493|      0|			return;
  494|      0|		}
  495|      0|		WRONG("Unhandled <esi:include> attribute");
  ------------------
  |  |   88|      0|#define WRONG(expl)							\
  |  |   89|      0|do {									\
  |  |   90|      0|	VAS_Fail(__func__, __FILE__, __LINE__, expl, VAS_WRONG);	\
  |  |   91|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (91:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
  496|      0|	}
  497|  9.89k|	assert(what == DO_TAG);
  ------------------
  |  |   65|  9.89k|#define assert(e)							\
  |  |   66|  9.89k|do {									\
  |  |   67|  9.89k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 9.89k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.89k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.89k]
  |  |  ------------------
  ------------------
  498|  9.89k|	if (!vep->emptytag)
  ------------------
  |  Branch (498:6): [True: 9.61k, False: 285]
  ------------------
  499|  9.61k|		vep_warn(vep, "ESI 1.0 <esi:include> lacks final '/'");
  500|  9.89k|	if (vep->include_src == NULL) {
  ------------------
  |  Branch (500:6): [True: 608, False: 9.28k]
  ------------------
  501|    608|		vep_error(vep, "ESI 1.0 <esi:include> lacks src attr");
  502|    608|		return;
  503|    608|	}
  504|       |
  505|       |	/*
  506|       |	 * Strictly speaking, we ought to spit out any piled up skip before
  507|       |	 * emitting the VEC for the include, but objectively that makes no
  508|       |	 * difference and robs us of a chance to collapse another skip into
  509|       |	 * this on so we don't do that.
  510|       |	 * However, we cannot tolerate any verbatim stuff piling up.
  511|       |	 * The mark_skip() before calling dostuff should have taken
  512|       |	 * care of that.  Make sure.
  513|       |	 */
  514|  9.28k|	assert(vep->o_wait == 0 || vep->last_mark == SKIP);
  ------------------
  |  |   65|  9.28k|#define assert(e)							\
  |  |   66|  9.28k|do {									\
  |  |   67|  18.5k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:8): [True: 0, False: 9.28k]
  |  |  |  Branch (67:8): [True: 9.28k, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.28k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.28k]
  |  |  ------------------
  ------------------
  515|       |	/* XXX: what if it contains NUL bytes ?? */
  516|  9.28k|	p = VSB_data(vep->include_src);
  517|  9.28k|	l = VSB_len(vep->include_src);
  518|  9.28k|	h = 0;
  519|       |
  520|  9.28k|	incl = vep->include_continue ? VEC_IC : VEC_IA;
  ------------------
  |  |   43|      0|#define	VEC_IC	(0x60 + 9)
  ------------------
              	incl = vep->include_continue ? VEC_IC : VEC_IA;
  ------------------
  |  |   42|  18.5k|#define	VEC_IA	(0x40 + 9)
  ------------------
  |  Branch (520:9): [True: 0, False: 9.28k]
  ------------------
  521|       |
  522|  9.28k|	if (l > 7 && !memcmp(p, "http://", 7)) {
  ------------------
  |  Branch (522:6): [True: 4.61k, False: 4.66k]
  |  Branch (522:15): [True: 1.57k, False: 3.04k]
  ------------------
  523|  1.57k|		h = p + 7;
  524|  1.57k|		p = strchr(h, '/');
  525|  1.57k|		if (p == NULL) {
  ------------------
  |  Branch (525:7): [True: 298, False: 1.27k]
  ------------------
  526|    298|			vep_error(vep,
  527|    298|			    "ESI 1.0 <esi:include> invalid src= URL");
  528|    298|			vep->state = VEP_TAGERROR;
  529|    298|			AZ(vep->attr_vsb);
  ------------------
  |  |   83|    298|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|    298|#define assert(e)							\
  |  |  |  |   66|    298|do {									\
  |  |  |  |   67|    298|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 298]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|    298|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 298]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 298]
  |  |  ------------------
  ------------------
  530|    298|			VSB_destroy(&vep->include_src);
  531|    298|			return;
  532|    298|		}
  533|  1.27k|		Debug("HOST <%.*s> PATH <%s>\n", (int)(p-h),h, p);
  534|  1.27k|		VSB_printf(vep->vsb, "%c", incl);
  535|  1.27k|		VSB_printf(vep->vsb, "Host: %.*s%c", (int)(p-h), h, 0);
  536|  7.71k|	} else if (l > 8 && !memcmp(p, "https://", 8)) {
  ------------------
  |  Branch (536:13): [True: 2.81k, False: 4.90k]
  |  Branch (536:22): [True: 1.43k, False: 1.37k]
  ------------------
  537|  1.43k|		if (!vep->flags.esi_ignore_https) {
  ------------------
  |  Branch (537:7): [True: 459, False: 979]
  ------------------
  538|    459|			vep_warn(vep,
  539|    459|			    "ESI 1.0 <esi:include> with https:// ignored");
  540|    459|			vep->state = VEP_TAGERROR;
  541|    459|			AZ(vep->attr_vsb);
  ------------------
  |  |   83|    459|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|    459|#define assert(e)							\
  |  |  |  |   66|    459|do {									\
  |  |  |  |   67|    459|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 459]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|    459|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 459]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 459]
  |  |  ------------------
  ------------------
  542|    459|			VSB_destroy(&vep->include_src);
  543|    459|			return;
  544|    459|		}
  545|    979|		vep_warn(vep,
  546|    979|		    "ESI 1.0 <esi:include> https:// treated as http://");
  547|    979|		h = p + 8;
  548|    979|		p = strchr(h, '/');
  549|    979|		if (p == NULL) {
  ------------------
  |  Branch (549:7): [True: 734, False: 245]
  ------------------
  550|    734|			vep_error(vep,
  551|    734|			    "ESI 1.0 <esi:include> invalid src= URL");
  552|    734|			vep->state = VEP_TAGERROR;
  553|    734|			AZ(vep->attr_vsb);
  ------------------
  |  |   83|    734|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|    734|#define assert(e)							\
  |  |  |  |   66|    734|do {									\
  |  |  |  |   67|    734|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 734]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|    734|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 734]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 734]
  |  |  ------------------
  ------------------
  554|    734|			VSB_destroy(&vep->include_src);
  555|    734|			return;
  556|    734|		}
  557|    245|		VSB_printf(vep->vsb, "%c", incl);
  558|    245|		VSB_printf(vep->vsb, "Host: %.*s%c", (int)(p-h), h, 0);
  559|  6.27k|	} else if (*p == '/') {
  ------------------
  |  Branch (559:13): [True: 668, False: 5.60k]
  ------------------
  560|    668|		VSB_printf(vep->vsb, "%c", incl);
  561|    668|		VSB_printf(vep->vsb, "%c", 0);
  562|  5.60k|	} else {
  563|  5.60k|		VSB_printf(vep->vsb, "%c", incl);
  564|  5.60k|		VSB_printf(vep->vsb, "%c", 0);
  565|       |		/* Look for the last / before a '?' */
  566|  5.60k|		h = NULL;
  567|  11.2k|		for (q = vep->url; *q && *q != '?'; q++)
  ------------------
  |  Branch (567:22): [True: 5.60k, False: 5.60k]
  |  Branch (567:28): [True: 5.60k, False: 0]
  ------------------
  568|  5.60k|			if (*q == '/')
  ------------------
  |  Branch (568:8): [True: 5.60k, False: 0]
  ------------------
  569|  5.60k|				h = q;
  570|  5.60k|		if (h == NULL)
  ------------------
  |  Branch (570:7): [True: 0, False: 5.60k]
  ------------------
  571|      0|			h = q + 1;
  572|       |
  573|  5.60k|		Debug("INCL:: [%.*s]/[%s]\n",
  574|  5.60k|		    (int)(h - vep->url), vep->url, p);
  575|  5.60k|		VSB_printf(vep->vsb, "%.*s/", (int)(h - vep->url), vep->url);
  576|  5.60k|	}
  577|  7.79k|	l -= (p - VSB_data(vep->include_src));
  578|  6.14M|	for (q = p; *q != '\0'; ) {
  ------------------
  |  Branch (578:14): [True: 6.13M, False: 7.79k]
  ------------------
  579|  6.13M|		if (*q == '&') {
  ------------------
  |  Branch (579:7): [True: 36.1k, False: 6.09M]
  ------------------
  580|  36.1k|#define R(w,f,r)							\
  581|  36.1k|			if (q + w <= p + l && !memcmp(q, f, w)) { \
  582|  36.1k|				VSB_printf(vep->vsb, "%c", r);	\
  583|  36.1k|				q += w;				\
  584|  36.1k|				continue;			\
  585|  36.1k|			}
  586|  36.1k|			R(6, "&apos;", '\'');
  ------------------
  |  |  581|  36.1k|			if (q + w <= p + l && !memcmp(q, f, w)) { \
  |  |  ------------------
  |  |  |  Branch (581:8): [True: 35.2k, False: 968]
  |  |  |  Branch (581:26): [True: 4.20k, False: 31.0k]
  |  |  ------------------
  |  |  582|  4.20k|				VSB_printf(vep->vsb, "%c", r);	\
  |  |  583|  4.20k|				q += w;				\
  |  |  584|  4.20k|				continue;			\
  |  |  585|  4.20k|			}
  ------------------
  587|  31.9k|			R(6, "&quot;", '"');
  ------------------
  |  |  581|  31.9k|			if (q + w <= p + l && !memcmp(q, f, w)) { \
  |  |  ------------------
  |  |  |  Branch (581:8): [True: 31.0k, False: 968]
  |  |  |  Branch (581:26): [True: 1.16k, False: 29.8k]
  |  |  ------------------
  |  |  582|  1.16k|				VSB_printf(vep->vsb, "%c", r);	\
  |  |  583|  1.16k|				q += w;				\
  |  |  584|  1.16k|				continue;			\
  |  |  585|  1.16k|			}
  ------------------
  588|  30.8k|			R(4, "&lt;", '<');
  ------------------
  |  |  581|  30.8k|			if (q + w <= p + l && !memcmp(q, f, w)) { \
  |  |  ------------------
  |  |  |  Branch (581:8): [True: 30.2k, False: 595]
  |  |  |  Branch (581:26): [True: 640, False: 29.5k]
  |  |  ------------------
  |  |  582|    640|				VSB_printf(vep->vsb, "%c", r);	\
  |  |  583|    640|				q += w;				\
  |  |  584|    640|				continue;			\
  |  |  585|    640|			}
  ------------------
  589|  30.1k|			R(4, "&gt;", '>');
  ------------------
  |  |  581|  30.1k|			if (q + w <= p + l && !memcmp(q, f, w)) { \
  |  |  ------------------
  |  |  |  Branch (581:8): [True: 29.5k, False: 595]
  |  |  |  Branch (581:26): [True: 3.58k, False: 25.9k]
  |  |  ------------------
  |  |  582|  3.58k|				VSB_printf(vep->vsb, "%c", r);	\
  |  |  583|  3.58k|				q += w;				\
  |  |  584|  3.58k|				continue;			\
  |  |  585|  3.58k|			}
  ------------------
  590|  26.5k|			R(5, "&amp;", '&');
  ------------------
  |  |  581|  26.5k|			if (q + w <= p + l && !memcmp(q, f, w)) { \
  |  |  ------------------
  |  |  |  Branch (581:8): [True: 25.8k, False: 784]
  |  |  |  Branch (581:26): [True: 750, False: 25.0k]
  |  |  ------------------
  |  |  582|    750|				VSB_printf(vep->vsb, "%c", r);	\
  |  |  583|    750|				q += w;				\
  |  |  584|    750|				continue;			\
  |  |  585|    750|			}
  ------------------
  591|  25.8k|		}
  592|  6.12M|		VSB_printf(vep->vsb, "%c", *q++);
  593|  6.12M|	}
  594|  7.79k|#undef R
  595|  7.79k|	VSB_printf(vep->vsb, "%c", 0);
  596|  7.79k|	VSB_destroy(&vep->include_src);
  597|  7.79k|	vep->include_continue = 0;
  598|  7.79k|}
cache_esi_parse.c:include_attr_src:
  439|  11.5k|{
  440|  11.5k|	const char *p;
  441|       |
  442|  11.5k|	if (vep->include_src != NULL) {
  ------------------
  |  Branch (442:6): [True: 969, False: 10.5k]
  ------------------
  443|    969|		vep_error(vep,
  444|    969|		    "ESI 1.0 <esi:include> "
  445|    969|		    "has multiple src= attributes");
  446|    969|		vep->state = VEP_TAGERROR;
  447|    969|		VSB_destroy(&vep->attr_vsb);
  448|    969|		VSB_destroy(&vep->include_src);
  449|    969|		return;
  450|    969|	}
  451|  14.0M|	for (p = VSB_data(vep->attr_vsb); *p != '\0'; p++)
  ------------------
  |  Branch (451:36): [True: 13.9M, False: 10.3k]
  ------------------
  452|  13.9M|		if (vct_islws(*p))
  ------------------
  |  |   72|  13.9M|#define vct_islws(x) vct_is(x, VCT_LWS)
  |  |  ------------------
  |  |  |  |   39|  13.9M|#define VCT_LWS			(VCT_CRLF | VCT_OWS)
  |  |  |  |  ------------------
  |  |  |  |  |  |   38|  13.9M|#define VCT_CRLF		(1<<1)
  |  |  |  |  ------------------
  |  |  |  |               #define VCT_LWS			(VCT_CRLF | VCT_OWS)
  |  |  |  |  ------------------
  |  |  |  |  |  |   37|  13.9M|#define VCT_OWS			(1<<0)
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (72:22): [True: 265, False: 13.9M]
  |  |  ------------------
  ------------------
  453|    265|			break;
  454|  10.5k|	if (*p != '\0') {
  ------------------
  |  Branch (454:6): [True: 265, False: 10.3k]
  ------------------
  455|    265|		vep_error(vep,
  456|    265|		    "ESI 1.0 <esi:include> "
  457|    265|		    "has whitespace in src= attribute");
  458|    265|		vep->state = VEP_TAGERROR;
  459|    265|		VSB_destroy(&vep->attr_vsb);
  460|    265|		if (vep->include_src != NULL)
  ------------------
  |  Branch (460:7): [True: 0, False: 265]
  ------------------
  461|      0|			VSB_destroy(&vep->include_src);
  462|    265|		return;
  463|    265|	}
  464|  10.3k|	vep->include_src = vep->attr_vsb;
  465|       |	vep->attr_vsb = NULL;
  466|  10.3k|}
cache_esi_parse.c:vep_warn:
  217|  11.0k|{
  218|  11.0k|	VSC_C_main->esi_warnings++;
  219|  11.0k|	VSLb(vep->vc->wrk->vsl, SLT_ESI_xmlerror, "WARN: after %zd %s",
  220|  11.0k|	     vep->o_last, p);
  221|  11.0k|}
cache_esi_parse.c:vep_do_remove:
  420|  4.45k|{
  421|  4.45k|	Debug("DO_REMOVE(%d, end %d empty %d remove %d)\n",
  422|  4.45k|	    what, vep->endtag, vep->emptytag, vep->remove);
  423|  4.45k|	assert(what == DO_TAG);
  ------------------
  |  |   65|  4.45k|#define assert(e)							\
  |  |   66|  4.45k|do {									\
  |  |   67|  4.45k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 4.45k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  4.45k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 4.45k]
  |  |  ------------------
  ------------------
  424|  4.45k|	if (vep->emptytag)
  ------------------
  |  Branch (424:6): [True: 1.82k, False: 2.62k]
  ------------------
  425|  1.82k|		vep_error(vep, "ESI 1.0 <esi:remove/> not legal");
  426|  2.62k|	else if (vep->remove && !vep->endtag)
  ------------------
  |  Branch (426:11): [True: 1.49k, False: 1.12k]
  |  Branch (426:26): [True: 761, False: 737]
  ------------------
  427|    761|		vep_error(vep, "ESI 1.0 <esi:remove> already open");
  428|  1.86k|	else if (!vep->remove && vep->endtag)
  ------------------
  |  Branch (428:11): [True: 1.12k, False: 737]
  |  Branch (428:27): [True: 302, False: 825]
  ------------------
  429|    302|		vep_error(vep, "ESI 1.0 <esi:remove> not open");
  430|  1.56k|	else
  431|  1.56k|		vep->remove = !vep->endtag;
  432|  4.45k|}
cache_esi_parse.c:vep_do_comment:
  408|  1.72k|{
  409|  1.72k|	Debug("DO_COMMENT(%d)\n", what);
  410|  1.72k|	assert(what == DO_TAG);
  ------------------
  |  |   65|  1.72k|#define assert(e)							\
  |  |   66|  1.72k|do {									\
  |  |   67|  1.72k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.72k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.72k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.72k]
  |  |  ------------------
  ------------------
  411|  1.72k|	if (!vep->emptytag)
  ------------------
  |  Branch (411:6): [True: 1.30k, False: 412]
  ------------------
  412|  1.30k|		vep_error(vep, "ESI 1.0 <esi:comment> needs final '/'");
  413|  1.72k|}
cache_esi_parse.c:vep_match:
  229|   144k|{
  230|   144k|	struct vep_match *vm;
  231|   144k|	const char *q, *r;
  232|       |
  233|   144k|	AN(vep->match);
  ------------------
  |  |   84|   144k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|   144k|#define assert(e)							\
  |  |  |  |   66|   144k|do {									\
  |  |  |  |   67|   144k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 144k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|   144k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 144k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 144k]
  |  |  ------------------
  ------------------
  234|   439k|	for (vm = vep->match; vm->match != NULL; vm++) {
  ------------------
  |  Branch (234:24): [True: 411k, False: 27.5k]
  ------------------
  235|   411k|		assert(vstrlen(vm->match) <= sizeof (vep->tag));
  ------------------
  |  |   65|   411k|#define assert(e)							\
  |  |   66|   411k|do {									\
  |  |   67|   411k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 411k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   411k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 411k]
  |  |  ------------------
  ------------------
  236|   411k|		r = b;
  237|  1.09M|		for (q = vm->match; *q != '\0' && r < e; q++, r++)
  ------------------
  |  Branch (237:23): [True: 978k, False: 117k]
  |  Branch (237:37): [True: 978k, False: 34]
  ------------------
  238|   978k|			if (*q != *r)
  ------------------
  |  Branch (238:8): [True: 294k, False: 684k]
  ------------------
  239|   294k|				break;
  240|   411k|		if (*q == '\0')
  ------------------
  |  Branch (240:7): [True: 117k, False: 294k]
  ------------------
  241|   117k|			break;
  242|   294k|		if (r == e)
  ------------------
  |  Branch (242:7): [True: 34, False: 294k]
  ------------------
  243|     34|			return (NULL);
  244|   294k|	}
  245|   144k|	return (vm);
  246|   144k|}
cache_esi_parse.c:vep_mark_pending:
  390|    214|{
  391|    214|	ssize_t l;
  392|       |
  393|    214|	AN(vep->ver_p);
  ------------------
  |  |   84|    214|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|    214|#define assert(e)							\
  |  |  |  |   66|    214|do {									\
  |  |  |  |   67|    214|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 214]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|    214|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 214]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 214]
  |  |  ------------------
  ------------------
  394|    214|	l = p - vep->ver_p;
  395|    214|	assert(l > 0);
  ------------------
  |  |   65|    214|#define assert(e)							\
  |  |   66|    214|do {									\
  |  |   67|    214|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 214]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|    214|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 214]
  |  |  ------------------
  ------------------
  396|    214|	vep->crcp = crc32(vep->crcp, (const void *)vep->ver_p, l);
  ------------------
  |  |   38|    214|#  define crc32                 z_crc32
  ------------------
  397|    214|	vep->ver_p = p;
  398|       |
  399|    214|	vep->o_pending += l;
  400|    214|	vep->nm_pending++;
  401|    214|}
cache_esi_parse.c:vep_default_cb:
 1055|   462k|{
 1056|   462k|	ssize_t *s;
 1057|       |
 1058|   462k|	CHECK_OBJ_NOTNULL(vc, VFP_CTX_MAGIC);
  ------------------
  |  |   66|   462k|	do {								\
  |  |   67|   462k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|   462k|#define assert(e)							\
  |  |  |  |   66|   462k|do {									\
  |  |  |  |   67|   462k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 462k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|   462k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 462k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|   462k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|   462k|#define assert(e)							\
  |  |  |  |   66|   462k|do {									\
  |  |  |  |   67|   462k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 462k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|   462k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 462k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|   462k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 462k]
  |  |  ------------------
  ------------------
 1059|   462k|	AN(priv);
  ------------------
  |  |   84|   462k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|   462k|#define assert(e)							\
  |  |  |  |   66|   462k|do {									\
  |  |  |  |   67|   462k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 462k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|   462k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 462k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 462k]
  |  |  ------------------
  ------------------
 1060|   462k|	s = priv;
 1061|   462k|	*s += l;
 1062|   462k|	(void)flg;
 1063|   462k|	return (*s);
 1064|   462k|}
cache_esi_parse.c:vep_emit_common:
  298|   186k|{
  299|       |
  300|   186k|	assert(l >= 0);
  ------------------
  |  |   65|   186k|#define assert(e)							\
  |  |   66|   186k|do {									\
  |  |   67|   186k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 186k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   186k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 186k]
  |  |  ------------------
  ------------------
  301|   186k|	if (l == 0)
  ------------------
  |  Branch (301:6): [True: 1.61k, False: 184k]
  ------------------
  302|  1.61k|		return;
  303|   184k|	assert(mark == SKIP || mark == VERBATIM);
  ------------------
  |  |   65|   184k|#define assert(e)							\
  |  |   66|   184k|do {									\
  |  |   67|   265k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:8): [True: 104k, False: 80.5k]
  |  |  |  Branch (67:8): [True: 80.5k, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   184k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 184k]
  |  |  ------------------
  ------------------
  304|   184k|	if (mark == SKIP)
  ------------------
  |  Branch (304:6): [True: 104k, False: 80.5k]
  ------------------
  305|   104k|		vep_emit_skip(vep, l);
  306|  80.5k|	else
  307|  80.5k|		vep_emit_verbatim(vep, l, vep->o_crc);
  308|       |
  309|   184k|	vep->crc = crc32(0L, Z_NULL, 0);
  ------------------
  |  |   38|   184k|#  define crc32                 z_crc32
  ------------------
              	vep->crc = crc32(0L, Z_NULL, 0);
  ------------------
  |  |  217|   184k|#define Z_NULL  0  /* for initializing zalloc, zfree, opaque */
  ------------------
  310|   184k|	vep->o_crc = 0;
  311|   184k|	vep->o_total += l;
  312|   184k|}
cache_esi_parse.c:vep_emit_skip:
  278|   104k|{
  279|       |
  280|   104k|	vep_emit_len(vep, l, VEC_S1, VEC_S2, VEC_S8);
  ------------------
  |  |   39|   104k|#define	VEC_S1	(0x60 + 1)
  ------------------
              	vep_emit_len(vep, l, VEC_S1, VEC_S2, VEC_S8);
  ------------------
  |  |   40|   104k|#define	VEC_S2	(0x60 + 2)
  ------------------
              	vep_emit_len(vep, l, VEC_S1, VEC_S2, VEC_S8);
  ------------------
  |  |   41|   104k|#define	VEC_S8	(0x60 + 8)
  ------------------
  281|   104k|}
cache_esi_parse.c:vep_emit_len:
  254|   184k|{
  255|   184k|	uint8_t buf[9];
  256|       |
  257|   184k|	assert(l > 0);
  ------------------
  |  |   65|   184k|#define assert(e)							\
  |  |   66|   184k|do {									\
  |  |   67|   184k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 184k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   184k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 184k]
  |  |  ------------------
  ------------------
  258|   184k|	if (l < 256) {
  ------------------
  |  Branch (258:6): [True: 183k, False: 1.37k]
  ------------------
  259|   183k|		buf[0] = (uint8_t)m8;
  260|   183k|		buf[1] = (uint8_t)l;
  261|   183k|		assert((ssize_t)buf[1] == l);
  ------------------
  |  |   65|   183k|#define assert(e)							\
  |  |   66|   183k|do {									\
  |  |   67|   183k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 183k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   183k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 183k]
  |  |  ------------------
  ------------------
  262|   183k|		VSB_bcat(vep->vsb, buf, 2);
  263|   183k|	} else if (l < 65536) {
  ------------------
  |  Branch (263:13): [True: 1.22k, False: 148]
  ------------------
  264|  1.22k|		buf[0] = (uint8_t)m16;
  265|  1.22k|		vbe16enc(buf + 1, (uint16_t)l);
  266|  1.22k|		assert((ssize_t)vbe16dec(buf + 1) == l);
  ------------------
  |  |   65|  1.22k|#define assert(e)							\
  |  |   66|  1.22k|do {									\
  |  |   67|  1.22k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.22k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.22k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.22k]
  |  |  ------------------
  ------------------
  267|  1.22k|		VSB_bcat(vep->vsb, buf, 3);
  268|  1.22k|	} else {
  269|    148|		buf[0] = (uint8_t)m64;
  270|    148|		vbe64enc(buf + 1, l);
  271|    148|		assert((ssize_t)vbe64dec(buf + 1) == l);
  ------------------
  |  |   65|    148|#define assert(e)							\
  |  |   66|    148|do {									\
  |  |   67|    148|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 148]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|    148|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 148]
  |  |  ------------------
  ------------------
  272|    148|		VSB_bcat(vep->vsb, buf, 9);
  273|    148|	}
  274|   184k|}
cache_esi_parse.c:vep_emit_verbatim:
  285|  80.5k|{
  286|  80.5k|	uint8_t buf[4];
  287|       |
  288|  80.5k|	vep_emit_len(vep, l, VEC_V1, VEC_V2, VEC_V8);
  ------------------
  |  |   33|  80.5k|#define	VEC_V1	(0x40 + 1)
  ------------------
              	vep_emit_len(vep, l, VEC_V1, VEC_V2, VEC_V8);
  ------------------
  |  |   34|  80.5k|#define	VEC_V2	(0x40 + 2)
  ------------------
              	vep_emit_len(vep, l, VEC_V1, VEC_V2, VEC_V8);
  ------------------
  |  |   35|  80.5k|#define	VEC_V8	(0x40 + 8)
  ------------------
  289|  80.5k|	if (vep->dogzip) {
  ------------------
  |  Branch (289:6): [True: 0, False: 80.5k]
  ------------------
  290|      0|		vep_emit_len(vep, l_crc, VEC_C1, VEC_C2, VEC_C8);
  ------------------
  |  |   36|      0|#define	VEC_C1	(0x50 + 1)
  ------------------
              		vep_emit_len(vep, l_crc, VEC_C1, VEC_C2, VEC_C8);
  ------------------
  |  |   37|      0|#define	VEC_C2	(0x50 + 2)
  ------------------
              		vep_emit_len(vep, l_crc, VEC_C1, VEC_C2, VEC_C8);
  ------------------
  |  |   38|      0|#define	VEC_C8	(0x50 + 8)
  ------------------
  291|      0|		vbe32enc(buf, vep->crc);
  292|      0|		VSB_bcat(vep->vsb, buf, sizeof buf);
  293|      0|	}
  294|  80.5k|}

WS_Rollback:
   85|  1.61k|{
   86|       |
   87|  1.61k|	WS_Assert(ws);
   88|       |
   89|  1.61k|	if (pp == 0)
  ------------------
  |  Branch (89:6): [True: 1.61k, False: 0]
  ------------------
   90|  1.61k|		pp = (uintptr_t)ws->s;
   91|  1.61k|	ws_ClearOverflow(ws);
   92|  1.61k|	WS_Reset(ws, pp);
   93|  1.61k|}
cache_ws_common.c:ws_ClearOverflow:
   60|  1.61k|{
   61|  1.61k|	CHECK_OBJ_NOTNULL(ws, WS_MAGIC);
  ------------------
  |  |   66|  1.61k|	do {								\
  |  |   67|  1.61k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  1.61k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
   62|       |
   63|  1.61k|	ws->id[0] |= 0x20;		// cheesy tolower()
   64|  1.61k|}

WS_Assert:
   76|  9.70k|{
   77|  9.70k|	struct ws_emu *we;
   78|  9.70k|	struct ws_alloc *wa, *wa2 = NULL;
   79|  9.70k|	size_t len;
   80|       |
   81|  9.70k|	CHECK_OBJ_NOTNULL(ws, WS_MAGIC);
  ------------------
  |  |   66|  9.70k|	do {								\
  |  |   67|  9.70k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|  9.70k|#define assert(e)							\
  |  |  |  |   66|  9.70k|do {									\
  |  |  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  9.70k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  9.70k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|  9.70k|#define assert(e)							\
  |  |  |  |   66|  9.70k|do {									\
  |  |  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  9.70k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|  9.70k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
   82|  9.70k|	assert(ws->s != NULL);
  ------------------
  |  |   65|  9.70k|#define assert(e)							\
  |  |   66|  9.70k|do {									\
  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.70k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
   83|  9.70k|	assert(PAOK(ws->s));
  ------------------
  |  |   65|  9.70k|#define assert(e)							\
  |  |   66|  9.70k|do {									\
  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.70k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
   84|  9.70k|	assert(ws->e != NULL);
  ------------------
  |  |   65|  9.70k|#define assert(e)							\
  |  |   66|  9.70k|do {									\
  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.70k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
   85|  9.70k|	assert(PAOK(ws->e));
  ------------------
  |  |   65|  9.70k|#define assert(e)							\
  |  |   66|  9.70k|do {									\
  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.70k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
   86|       |
   87|  9.70k|	we = ws_emu(ws);
   88|  9.70k|	len = pdiff(ws->s, ws->e);
   89|  9.70k|	assert(len == we->len);
  ------------------
  |  |   65|  9.70k|#define assert(e)							\
  |  |   66|  9.70k|do {									\
  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.70k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
   90|       |
   91|  9.70k|	len = 0;
   92|  9.70k|	VTAILQ_FOREACH(wa, &we->head, list) {
  ------------------
  |  |  460|  9.70k|	for ((var) = VTAILQ_FIRST((head));				\
  |  |  ------------------
  |  |  |  |  457|  9.70k|#define	VTAILQ_FIRST(head)	((head)->vtqh_first)
  |  |  ------------------
  |  |  461|  14.5k|	    (var);							\
  |  |  ------------------
  |  |  |  Branch (461:6): [True: 4.85k, False: 9.70k]
  |  |  ------------------
  |  |  462|  9.70k|	    (var) = VTAILQ_NEXT((var), field))
  |  |  ------------------
  |  |  |  |  542|  4.85k|#define	VTAILQ_NEXT(elm, field) ((elm)->field.vtqe_next)
  |  |  ------------------
  ------------------
   93|  4.85k|		CHECK_OBJ_NOTNULL(wa, WS_ALLOC_MAGIC);
  ------------------
  |  |   66|  4.85k|	do {								\
  |  |   67|  4.85k|		assert((ptr) != NULL);					\
  |  |  ------------------
  |  |  |  |   65|  4.85k|#define assert(e)							\
  |  |  |  |   66|  4.85k|do {									\
  |  |  |  |   67|  4.85k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 4.85k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  4.85k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 4.85k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  4.85k|		assert((ptr)->magic == type_magic);			\
  |  |  ------------------
  |  |  |  |   65|  4.85k|#define assert(e)							\
  |  |  |  |   66|  4.85k|do {									\
  |  |  |  |   67|  4.85k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 4.85k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  4.85k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 4.85k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   69|  4.85k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 4.85k]
  |  |  ------------------
  ------------------
   94|  4.85k|		wa2 = wa;
   95|  4.85k|		assert(len == wa->off);
  ------------------
  |  |   65|  4.85k|#define assert(e)							\
  |  |   66|  4.85k|do {									\
  |  |   67|  4.85k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 4.85k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  4.85k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 4.85k]
  |  |  ------------------
  ------------------
   96|  4.85k|		if (wa->ptr == ws->f || wa->ptr == NULL) /* reservation */
  ------------------
  |  Branch (96:7): [True: 0, False: 4.85k]
  |  Branch (96:27): [True: 0, False: 4.85k]
  ------------------
   97|      0|			break;
   98|  4.85k|		AN(wa->len);
  ------------------
  |  |   84|  4.85k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  4.85k|#define assert(e)							\
  |  |  |  |   66|  4.85k|do {									\
  |  |  |  |   67|  4.85k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 4.85k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  4.85k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 4.85k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 4.85k]
  |  |  ------------------
  ------------------
   99|  4.85k|		len += PRNDUP(wa->len);
  ------------------
  |  |  153|  4.85k|#define PRNDUP(p)   (((uintptr_t)(p) + PALGN) & ~PALGN)	/* Round up */
  |  |  ------------------
  |  |  |  |  149|  4.85k|#  define PALGN	    (sizeof(void *) - 1)	/* size of alignment */
  |  |  ------------------
  |  |               #define PRNDUP(p)   (((uintptr_t)(p) + PALGN) & ~PALGN)	/* Round up */
  |  |  ------------------
  |  |  |  |  149|  4.85k|#  define PALGN	    (sizeof(void *) - 1)	/* size of alignment */
  |  |  ------------------
  ------------------
  100|  4.85k|		assert(len <= we->len);
  ------------------
  |  |   65|  4.85k|#define assert(e)							\
  |  |   66|  4.85k|do {									\
  |  |   67|  4.85k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 4.85k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  4.85k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 4.85k]
  |  |  ------------------
  ------------------
  101|  4.85k|	}
  102|       |
  103|  9.70k|	if (wa != NULL) {
  ------------------
  |  Branch (103:6): [True: 0, False: 9.70k]
  ------------------
  104|      0|		AZ(VTAILQ_NEXT(wa, list));
  ------------------
  |  |   83|      0|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|      0|#define assert(e)							\
  |  |  |  |   66|      0|do {									\
  |  |  |  |   67|      0|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|      0|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 0]
  |  |  ------------------
  ------------------
  105|      0|		if (wa->ptr == NULL) {
  ------------------
  |  Branch (105:7): [True: 0, False: 0]
  ------------------
  106|      0|			AZ(wa->len);
  ------------------
  |  |   83|      0|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|      0|#define assert(e)							\
  |  |  |  |   66|      0|do {									\
  |  |  |  |   67|      0|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|      0|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 0]
  |  |  ------------------
  ------------------
  107|      0|			assert(ws->f == ws->e);
  ------------------
  |  |   65|      0|#define assert(e)							\
  |  |   66|      0|do {									\
  |  |   67|      0|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
  108|      0|			assert(ws->r == ws->e);
  ------------------
  |  |   65|      0|#define assert(e)							\
  |  |   66|      0|do {									\
  |  |   67|      0|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
  109|      0|		} else {
  110|      0|			AN(wa->len);
  ------------------
  |  |   84|      0|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|      0|#define assert(e)							\
  |  |  |  |   66|      0|do {									\
  |  |  |  |   67|      0|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|      0|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 0]
  |  |  ------------------
  ------------------
  111|      0|			assert(ws->f == wa->ptr);
  ------------------
  |  |   65|      0|#define assert(e)							\
  |  |   66|      0|do {									\
  |  |   67|      0|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
  112|      0|			assert(ws->r == ws->f + wa->len);
  ------------------
  |  |   65|      0|#define assert(e)							\
  |  |   66|      0|do {									\
  |  |   67|      0|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
  113|      0|		}
  114|      0|		len += PRNDUP(wa->len);
  ------------------
  |  |  153|      0|#define PRNDUP(p)   (((uintptr_t)(p) + PALGN) & ~PALGN)	/* Round up */
  |  |  ------------------
  |  |  |  |  149|      0|#  define PALGN	    (sizeof(void *) - 1)	/* size of alignment */
  |  |  ------------------
  |  |               #define PRNDUP(p)   (((uintptr_t)(p) + PALGN) & ~PALGN)	/* Round up */
  |  |  ------------------
  |  |  |  |  149|      0|#  define PALGN	    (sizeof(void *) - 1)	/* size of alignment */
  |  |  ------------------
  ------------------
  115|      0|		assert(len <= we->len);
  ------------------
  |  |   65|      0|#define assert(e)							\
  |  |   66|      0|do {									\
  |  |   67|      0|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|      0|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  ------------------
  ------------------
  116|  9.70k|	} else {
  117|  9.70k|		AZ(ws->f);
  ------------------
  |  |   83|  9.70k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  9.70k|#define assert(e)							\
  |  |  |  |   66|  9.70k|do {									\
  |  |  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  9.70k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
  118|  9.70k|		AZ(ws->r);
  ------------------
  |  |   83|  9.70k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  9.70k|#define assert(e)							\
  |  |  |  |   66|  9.70k|do {									\
  |  |  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  9.70k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
  119|  9.70k|	}
  120|       |
  121|  9.70k|	DSLb(DBG_WORKSPACE, "WS(%p) = (%s, %p %zu %zu %zu)",
  ------------------
  |  |  621|  9.70k|	do {							\
  |  |  622|  9.70k|		if (DO_DEBUG(debug_bit))			\
  |  |  ------------------
  |  |  |  |  612|  9.70k|#define DO_DEBUG(x)	COM_DO_DEBUG(cache_param->debug_bits, x)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (612:21): [True: 0, False: 9.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  623|  9.70k|			WRK_Log(SLT_Debug, __VA_ARGS__);	\
  |  |  ------------------
  |  |  |  Branch (623:23): [True: 0, False: 0]
  |  |  |  Branch (623:23): [True: 0, False: 0]
  |  |  ------------------
  |  |  624|  9.70k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (624:11): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
  122|  9.70k|	    ws, ws->id, ws->s, wa2 == NULL ? 0 : wa2->off + PRNDUP(wa2->len),
  123|  9.70k|	    ws->r == NULL ? 0 : pdiff(ws->f, ws->r),
  124|  9.70k|	    pdiff(ws->s, ws->e));
  125|  9.70k|}
WS_Init:
  159|  1.61k|{
  160|  1.61k|	struct ws_emu *we;
  161|       |
  162|  1.61k|	DSLb(DBG_WORKSPACE,
  ------------------
  |  |  621|  1.61k|	do {							\
  |  |  622|  1.61k|		if (DO_DEBUG(debug_bit))			\
  |  |  ------------------
  |  |  |  |  612|  1.61k|#define DO_DEBUG(x)	COM_DO_DEBUG(cache_param->debug_bits, x)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (612:21): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  623|  1.61k|			WRK_Log(SLT_Debug, __VA_ARGS__);	\
  |  |  624|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (624:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  163|  1.61k|	    "WS_Init(%p, \"%s\", %p, %u)", ws, id, space, len);
  164|  1.61k|	assert(space != NULL);
  ------------------
  |  |   65|  1.61k|#define assert(e)							\
  |  |   66|  1.61k|do {									\
  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  165|  1.61k|	assert(PAOK(space));
  ------------------
  |  |   65|  1.61k|#define assert(e)							\
  |  |   66|  1.61k|do {									\
  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  166|  1.61k|	assert(len >= sizeof *we);
  ------------------
  |  |   65|  1.61k|#define assert(e)							\
  |  |   66|  1.61k|do {									\
  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  167|       |
  168|  1.61k|	len = PRNDDN(len - 1);
  ------------------
  |  |  152|  1.61k|#define PRNDDN(p)   ((uintptr_t)(p) & ~PALGN)		/* Round down */
  |  |  ------------------
  |  |  |  |  149|  1.61k|#  define PALGN	    (sizeof(void *) - 1)	/* size of alignment */
  |  |  ------------------
  ------------------
  169|  1.61k|	INIT_OBJ(ws, WS_MAGIC);
  ------------------
  |  |   15|  1.61k|	do {								\
  |  |   16|  1.61k|		(void)memset(to, 0, sizeof *(to));			\
  |  |   17|  1.61k|		(to)->magic = (type_magic);				\
  |  |   18|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (18:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  170|  1.61k|	ws->s = space;
  171|  1.61k|	ws->e = ws->s + len;
  172|       |
  173|  1.61k|	assert(id[0] & 0x20);		// cheesy islower()
  ------------------
  |  |   65|  1.61k|#define assert(e)							\
  |  |   66|  1.61k|do {									\
  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  174|  1.61k|	bstrcpy(ws->id, id);
  ------------------
  |  |   66|  1.61k|	do {								\
  |  |   67|  1.61k|		assert(vstrlen(src) + 1 <= sizeof (dst));		\
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   68|  1.61k|		strcpy((dst), (src));					\
  |  |   69|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (69:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  175|       |
  176|  1.61k|	we = space;
  177|  1.61k|	INIT_OBJ(we, WS_EMU_MAGIC);
  ------------------
  |  |   15|  1.61k|	do {								\
  |  |   16|  1.61k|		(void)memset(to, 0, sizeof *(to));			\
  |  |   17|  1.61k|		(to)->magic = (type_magic);				\
  |  |   18|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (18:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  178|  1.61k|	VTAILQ_INIT(&we->head);
  ------------------
  |  |  499|  1.61k|#define	VTAILQ_INIT(head) do {						\
  |  |  500|  1.61k|	VTAILQ_FIRST((head)) = NULL;					\
  |  |  ------------------
  |  |  |  |  457|  1.61k|#define	VTAILQ_FIRST(head)	((head)->vtqh_first)
  |  |  ------------------
  |  |  501|  1.61k|	(head)->vtqh_last = &VTAILQ_FIRST((head));			\
  |  |  ------------------
  |  |  |  |  457|  1.61k|#define	VTAILQ_FIRST(head)	((head)->vtqh_first)
  |  |  ------------------
  |  |  502|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (502:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  179|  1.61k|	we->len = len;
  180|       |
  181|  1.61k|	WS_Assert(ws);
  182|  1.61k|}
WS_Reset:
  198|  1.61k|{
  199|  1.61k|	struct ws_emu *we;
  200|  1.61k|	struct ws_alloc *wa;
  201|  1.61k|	char *p;
  202|       |
  203|  1.61k|	WS_Assert(ws);
  204|  1.61k|	AN(pp);
  ------------------
  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  205|  1.61k|	if (pp == snap_overflowed) {
  ------------------
  |  Branch (205:6): [True: 0, False: 1.61k]
  ------------------
  206|      0|		DSLb(DBG_WORKSPACE, "WS_Reset(%p, overflowed)", ws);
  ------------------
  |  |  621|      0|	do {							\
  |  |  622|      0|		if (DO_DEBUG(debug_bit))			\
  |  |  ------------------
  |  |  |  |  612|      0|#define DO_DEBUG(x)	COM_DO_DEBUG(cache_param->debug_bits, x)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (612:21): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  623|      0|			WRK_Log(SLT_Debug, __VA_ARGS__);	\
  |  |  624|      0|	} while (0)
  |  |  ------------------
  |  |  |  Branch (624:11): [Folded, False: 0]
  |  |  ------------------
  ------------------
  207|      0|		AN(WS_Overflowed(ws));
  ------------------
  |  |   84|      0|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|      0|#define assert(e)							\
  |  |  |  |   66|      0|do {									\
  |  |  |  |   67|      0|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|      0|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 0]
  |  |  ------------------
  ------------------
  208|      0|		return;
  209|      0|	}
  210|  1.61k|	p = (char *)pp;
  211|  1.61k|	DSLb(DBG_WORKSPACE, "WS_Reset(%p, %p)", ws, p);
  ------------------
  |  |  621|  1.61k|	do {							\
  |  |  622|  1.61k|		if (DO_DEBUG(debug_bit))			\
  |  |  ------------------
  |  |  |  |  612|  1.61k|#define DO_DEBUG(x)	COM_DO_DEBUG(cache_param->debug_bits, x)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (612:21): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  623|  1.61k|			WRK_Log(SLT_Debug, __VA_ARGS__);	\
  |  |  624|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (624:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  212|  1.61k|	AZ(ws->r);
  ------------------
  |  |   83|  1.61k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  213|       |
  214|  1.61k|	we = ws_emu(ws);
  215|  3.23k|	while ((wa = VTAILQ_LAST(&we->head, ws_alloc_head)) != NULL &&
  ------------------
  |  |  540|  3.23k|	(*(((struct headname *)((head)->vtqh_last))->vtqh_last))
  ------------------
  |  Branch (215:9): [True: 1.61k, False: 1.61k]
  ------------------
  216|  1.61k|	    wa->ptr != p)
  ------------------
  |  Branch (216:6): [True: 1.61k, False: 0]
  ------------------
  217|  1.61k|		ws_alloc_free(we, &wa);
  218|  1.61k|	if (wa == NULL)
  ------------------
  |  Branch (218:6): [True: 1.61k, False: 0]
  ------------------
  219|  1.61k|		assert(p == ws->s);
  ------------------
  |  |   65|  1.61k|#define assert(e)							\
  |  |   66|  1.61k|do {									\
  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  220|       |
  221|  1.61k|	WS_Assert(ws);
  222|  1.61k|}
WS_Alloc:
  304|  1.61k|{
  305|  1.61k|	struct ws_alloc *wa;
  306|       |
  307|  1.61k|	assert(bytes > 0);
  ------------------
  |  |   65|  1.61k|#define assert(e)							\
  |  |   66|  1.61k|do {									\
  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  308|  1.61k|	wa = ws_emu_alloc(ws, bytes);
  309|  1.61k|	WS_Assert(ws);
  310|  1.61k|	if (wa != NULL) {
  ------------------
  |  Branch (310:6): [True: 1.61k, False: 0]
  ------------------
  311|  1.61k|		AN(wa->ptr);
  ------------------
  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  312|  1.61k|		DSLb(DBG_WORKSPACE, "WS_Alloc(%p, %u) = %p",
  ------------------
  |  |  621|  1.61k|	do {							\
  |  |  622|  1.61k|		if (DO_DEBUG(debug_bit))			\
  |  |  ------------------
  |  |  |  |  612|  1.61k|#define DO_DEBUG(x)	COM_DO_DEBUG(cache_param->debug_bits, x)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (612:21): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  623|  1.61k|			WRK_Log(SLT_Debug, __VA_ARGS__);	\
  |  |  624|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (624:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  313|  1.61k|		    ws, bytes, wa->ptr);
  314|  1.61k|		return (wa->ptr);
  315|  1.61k|	}
  316|      0|	return (NULL);
  317|  1.61k|}
cache_ws_emu.c:ws_emu:
   67|  12.9k|{
   68|  12.9k|	struct ws_emu *we;
   69|       |
   70|  12.9k|	CAST_OBJ_NOTNULL(we, (void *)ws->s, WS_EMU_MAGIC);
  ------------------
  |  |   85|  12.9k|	do {								\
  |  |   86|  12.9k|		(to) = (from);						\
  |  |   87|  12.9k|		AN((to));						\
  |  |  ------------------
  |  |  |  |   84|  12.9k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  12.9k|#define assert(e)							\
  |  |  |  |  |  |   66|  12.9k|do {									\
  |  |  |  |  |  |   67|  12.9k|	if (!(e)) {							\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (67:6): [True: 0, False: 12.9k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |  |  |   70|      0|	}								\
  |  |  |  |  |  |   71|  12.9k|} while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (71:10): [Folded, False: 12.9k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (84:52): [Folded, False: 12.9k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   88|  12.9k|		CHECK_OBJ((to), (type_magic));				\
  |  |  ------------------
  |  |  |  |   61|  12.9k|	do {								\
  |  |  |  |   62|  12.9k|		assert((ptr)->magic == type_magic);			\
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  12.9k|#define assert(e)							\
  |  |  |  |  |  |   66|  12.9k|do {									\
  |  |  |  |  |  |   67|  12.9k|	if (!(e)) {							\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (67:6): [True: 0, False: 12.9k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |  |  |   70|      0|	}								\
  |  |  |  |  |  |   71|  12.9k|} while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (71:10): [Folded, False: 12.9k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   63|  12.9k|	} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (63:11): [Folded, False: 12.9k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   89|  12.9k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (89:11): [Folded, False: 12.9k]
  |  |  ------------------
  ------------------
   71|  12.9k|	return (we);
   72|  12.9k|}
cache_ws_emu.c:ws_alloc_free:
  186|  1.61k|{
  187|  1.61k|	struct ws_alloc *wa;
  188|       |
  189|  1.61k|	TAKE_OBJ_NOTNULL(wa, wap, WS_ALLOC_MAGIC);
  ------------------
  |  |   92|  1.61k|	do {								\
  |  |   93|  1.61k|		AN((pfrom));						\
  |  |  ------------------
  |  |  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |  |  |   70|      0|	}								\
  |  |  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   94|  1.61k|		(to) = *(pfrom);					\
  |  |   95|  1.61k|		*(pfrom) = NULL;					\
  |  |   96|  1.61k|		CHECK_OBJ_NOTNULL((to), (type_magic));			\
  |  |  ------------------
  |  |  |  |   66|  1.61k|	do {								\
  |  |  |  |   67|  1.61k|		assert((ptr) != NULL);					\
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |  |  |   70|      0|	}								\
  |  |  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   68|  1.61k|		assert((ptr)->magic == type_magic);			\
  |  |  |  |  ------------------
  |  |  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |  |  |   70|      0|	}								\
  |  |  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  ------------------
  |  |  |  |   69|  1.61k|	} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (69:11): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   97|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (97:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  190|  1.61k|	AZ(VTAILQ_NEXT(wa, list));
  ------------------
  |  |   83|  1.61k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  191|  1.61k|	VTAILQ_REMOVE(&we->head, wa, list);
  ------------------
  |  |  547|  1.61k|#define	VTAILQ_REMOVE(head, elm, field) do {				\
  |  |  548|  1.61k|	if ((VTAILQ_NEXT((elm), field)) != NULL)			\
  |  |  ------------------
  |  |  |  |  542|  1.61k|#define	VTAILQ_NEXT(elm, field) ((elm)->field.vtqe_next)
  |  |  ------------------
  |  |  |  Branch (548:6): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |  549|  1.61k|		VTAILQ_NEXT((elm), field)->field.vtqe_prev =		\
  |  |  ------------------
  |  |  |  |  542|      0|#define	VTAILQ_NEXT(elm, field) ((elm)->field.vtqe_next)
  |  |  ------------------
  |  |  550|      0|		    (elm)->field.vtqe_prev;				\
  |  |  551|  1.61k|	else {								\
  |  |  552|  1.61k|		(head)->vtqh_last = (elm)->field.vtqe_prev;		\
  |  |  553|  1.61k|	}								\
  |  |  554|  1.61k|	*(elm)->field.vtqe_prev = VTAILQ_NEXT((elm), field);		\
  |  |  ------------------
  |  |  |  |  542|  1.61k|#define	VTAILQ_NEXT(elm, field) ((elm)->field.vtqe_next)
  |  |  ------------------
  |  |  555|  1.61k|	TRASHIT(*oldnext);						\
  |  |  556|  1.61k|	TRASHIT(*oldprev);						\
  |  |  557|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (557:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  192|  1.61k|	free(wa->ptr);
  193|       |	FREE_OBJ(wa);
  ------------------
  |  |   51|  1.61k|	do {								\
  |  |   52|  1.61k|		ZERO_OBJ(&(to)->magic, sizeof (to)->magic);		\
  |  |  ------------------
  |  |  |  |    9|  1.61k|	do {								\
  |  |  |  |   10|  1.61k|		void *(*volatile z_obj)(void *, int, size_t) = memset;	\
  |  |  |  |   11|  1.61k|		(void)z_obj(to, 0, sz);					\
  |  |  |  |   12|  1.61k|	} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (12:11): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   53|  1.61k|		free(to);						\
  |  |   54|  1.61k|		to = NULL;						\
  |  |   55|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (55:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  194|  1.61k|}
cache_ws_emu.c:ws_emu_alloc:
  269|  1.61k|{
  270|  1.61k|	struct ws_emu *we;
  271|  1.61k|	struct ws_alloc *wa;
  272|  1.61k|	size_t off = 0;
  273|       |
  274|  1.61k|	WS_Assert(ws);
  275|  1.61k|	AZ(ws->r);
  ------------------
  |  |   83|  1.61k|#define AZ(foo)		do { assert((foo) == 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (83:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  276|       |
  277|  1.61k|	we = ws_emu(ws);
  278|  1.61k|	wa = VTAILQ_LAST(&we->head, ws_alloc_head);
  ------------------
  |  |  540|  1.61k|	(*(((struct headname *)((head)->vtqh_last))->vtqh_last))
  ------------------
  279|  1.61k|	CHECK_OBJ_ORNULL(wa, WS_ALLOC_MAGIC);
  ------------------
  |  |   72|  1.61k|	do {								\
  |  |   73|  1.61k|		if ((ptr) != NULL)					\
  |  |  ------------------
  |  |  |  Branch (73:7): [True: 0, False: 1.61k]
  |  |  ------------------
  |  |   74|  1.61k|			assert((ptr)->magic == type_magic);		\
  |  |  ------------------
  |  |  |  |   65|      0|#define assert(e)							\
  |  |  |  |   66|      0|do {									\
  |  |  |  |   67|      0|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|      0|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |   75|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (75:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  280|       |
  281|  1.61k|	if (wa != NULL)
  ------------------
  |  Branch (281:6): [True: 0, False: 1.61k]
  ------------------
  282|      0|		off = wa->off + PRNDUP(wa->len);
  ------------------
  |  |  153|      0|#define PRNDUP(p)   (((uintptr_t)(p) + PALGN) & ~PALGN)	/* Round up */
  |  |  ------------------
  |  |  |  |  149|      0|#  define PALGN	    (sizeof(void *) - 1)	/* size of alignment */
  |  |  ------------------
  |  |               #define PRNDUP(p)   (((uintptr_t)(p) + PALGN) & ~PALGN)	/* Round up */
  |  |  ------------------
  |  |  |  |  149|      0|#  define PALGN	    (sizeof(void *) - 1)	/* size of alignment */
  |  |  ------------------
  ------------------
  283|  1.61k|	if (off + len > we->len) {
  ------------------
  |  Branch (283:6): [True: 0, False: 1.61k]
  ------------------
  284|      0|		WS_MarkOverflow(ws);
  285|      0|		return (NULL);
  286|      0|	}
  287|  1.61k|	if (len == 0)
  ------------------
  |  Branch (287:6): [True: 0, False: 1.61k]
  ------------------
  288|      0|		len = we->len - off;
  289|       |
  290|  1.61k|	ALLOC_OBJ(wa, WS_ALLOC_MAGIC);
  ------------------
  |  |   27|  1.61k|	do {								\
  |  |   28|  1.61k|		(to) = calloc((size_t)1, sizeof *(to));			\
  |  |   29|  1.61k|		if ((to) != NULL)					\
  |  |  ------------------
  |  |  |  Branch (29:7): [True: 1.61k, False: 0]
  |  |  ------------------
  |  |   30|  1.61k|			(to)->magic = (type_magic);			\
  |  |   31|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (31:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  291|  1.61k|	AN(wa);
  ------------------
  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  292|  1.61k|	wa->off = off;
  293|  1.61k|	wa->len = len;
  294|  1.61k|	if (len > 0) {
  ------------------
  |  Branch (294:6): [True: 1.61k, False: 0]
  ------------------
  295|  1.61k|		wa->ptr = malloc(len);
  296|  1.61k|		AN(wa->ptr);
  ------------------
  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  297|  1.61k|	}
  298|  1.61k|	VTAILQ_INSERT_TAIL(&we->head, wa, list);
  ------------------
  |  |  532|  1.61k|#define	VTAILQ_INSERT_TAIL(head, elm, field) do {			\
  |  |  533|  1.61k|	VTAILQ_NEXT((elm), field) = NULL;				\
  |  |  ------------------
  |  |  |  |  542|  1.61k|#define	VTAILQ_NEXT(elm, field) ((elm)->field.vtqe_next)
  |  |  ------------------
  |  |  534|  1.61k|	(elm)->field.vtqe_prev = (head)->vtqh_last;			\
  |  |  535|  1.61k|	*(head)->vtqh_last = (elm);					\
  |  |  536|  1.61k|	(head)->vtqh_last = &VTAILQ_NEXT((elm), field);			\
  |  |  ------------------
  |  |  |  |  542|  1.61k|#define	VTAILQ_NEXT(elm, field) ((elm)->field.vtqe_next)
  |  |  ------------------
  |  |  537|  1.61k|} while (0)
  |  |  ------------------
  |  |  |  Branch (537:10): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  299|  1.61k|	return (wa);
  300|  1.61k|}

cache_ws_emu.c:COM_DO_DEBUG:
   51|  14.5k|{
   52|  14.5k|	return ((p[(unsigned)x>>3] & (0x80U >> ((unsigned)x & 7))) != 0);
   53|  14.5k|}

VSLb:
   76|  33.2k|{
   77|  33.2k|	(void)vsl;
   78|  33.2k|	(void)tag;
   79|  33.2k|	(void)fmt;
   80|  33.2k|}
LLVMFuzzerTestOneInput:
  121|  1.61k|{
  122|  1.61k|	struct VSC_main __VSC_C_main;
  123|  1.61k|	struct params __cache_param;
  124|  1.61k|	struct http req[1];
  125|  1.61k|	struct http resp[1];
  126|  1.61k|	struct vfp_ctx vc[1];
  127|  1.61k|	struct worker wrk[1];
  128|  1.61k|	struct ws ws[1];
  129|  1.61k|	struct vep_state *vep;
  130|  1.61k|	struct vsb *vsb;
  131|  1.61k|	txt hd[HTTP_HDR_URL + 1];
  132|  1.61k|	struct vep_flags flags = {0};
  133|  1.61k|	char ws_buf[1024];
  134|       |
  135|  1.61k|	if (size < 1)
  ------------------
  |  Branch (135:6): [True: 0, False: 1.61k]
  ------------------
  136|      0|		return (0);
  137|       |
  138|  1.61k|	AN(data);
  ------------------
  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  139|       |
  140|  1.61k|	VSC_C_main = &__VSC_C_main;
  141|  1.61k|	cache_param = &__cache_param;
  142|       |
  143|  1.61k|	memset(&__cache_param, 0, sizeof(__cache_param));
  144|  1.61k|	if (data[0] & 0x8f)
  ------------------
  |  Branch (144:6): [True: 1.57k, False: 46]
  ------------------
  145|  1.57k|		flags.esi_ignore_https = 1;
  146|  1.61k|	if (size > 1 && data[1] & 0x8f)
  ------------------
  |  Branch (146:6): [True: 1.58k, False: 29]
  |  Branch (146:18): [True: 1.53k, False: 53]
  ------------------
  147|  1.53k|		flags.esi_disable_xml_check = 1;
  148|  1.61k|	if (size > 2 && data[2] & 0x8f)
  ------------------
  |  Branch (148:6): [True: 1.56k, False: 54]
  |  Branch (148:18): [True: 1.49k, False: 65]
  ------------------
  149|  1.49k|		flags.esi_ignore_other_elements = 1;
  150|  1.61k|	if (size > 3 && data[3] & 0x8f)
  ------------------
  |  Branch (150:6): [True: 1.55k, False: 67]
  |  Branch (150:18): [True: 1.50k, False: 45]
  ------------------
  151|  1.50k|		flags.esi_remove_bom = 1;
  152|       |
  153|       |	/* Setup ws */
  154|  1.61k|	WS_Init(ws, "req", ws_buf, sizeof ws_buf);
  155|       |
  156|       |	/* Setup req */
  157|  1.61k|	INIT_OBJ(req, HTTP_MAGIC);
  ------------------
  |  |   15|  1.61k|	do {								\
  |  |   16|  1.61k|		(void)memset(to, 0, sizeof *(to));			\
  |  |   17|  1.61k|		(to)->magic = (type_magic);				\
  |  |   18|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (18:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  158|  1.61k|	req->hd = hd;
  159|  1.61k|	req->hd[HTTP_HDR_URL].b = "/";
  160|  1.61k|	req->ws = ws;
  161|       |
  162|       |	/* Setup resp */
  163|  1.61k|	INIT_OBJ(resp, HTTP_MAGIC);
  ------------------
  |  |   15|  1.61k|	do {								\
  |  |   16|  1.61k|		(void)memset(to, 0, sizeof *(to));			\
  |  |   17|  1.61k|		(to)->magic = (type_magic);				\
  |  |   18|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (18:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  164|  1.61k|	resp->ws = ws;
  165|       |
  166|       |	/* Setup wrk */
  167|  1.61k|	INIT_OBJ(wrk, WORKER_MAGIC);
  ------------------
  |  |   15|  1.61k|	do {								\
  |  |   16|  1.61k|		(void)memset(to, 0, sizeof *(to));			\
  |  |   17|  1.61k|		(to)->magic = (type_magic);				\
  |  |   18|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (18:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  168|       |
  169|       |	/* Setup vc */
  170|  1.61k|	INIT_OBJ(vc, VFP_CTX_MAGIC);
  ------------------
  |  |   15|  1.61k|	do {								\
  |  |   16|  1.61k|		(void)memset(to, 0, sizeof *(to));			\
  |  |   17|  1.61k|		(to)->magic = (type_magic);				\
  |  |   18|  1.61k|	} while (0)
  |  |  ------------------
  |  |  |  Branch (18:11): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  171|  1.61k|	vc->wrk = wrk;
  172|  1.61k|	vc->resp = resp;
  173|       |
  174|  1.61k|	vep = VEP_Init(vc, req, NULL, NULL, flags);
  175|       |
  176|  1.61k|	AN(vep);
  ------------------
  |  |   84|  1.61k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  1.61k|#define assert(e)							\
  |  |  |  |   66|  1.61k|do {									\
  |  |  |  |   67|  1.61k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 1.61k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  1.61k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 1.61k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 1.61k]
  |  |  ------------------
  ------------------
  177|  1.61k|	VEP_Parse(vep, (const char *)data, size);
  178|  1.61k|	vsb = VEP_Finish(vep);
  179|  1.61k|	if (vsb != NULL)
  ------------------
  |  Branch (179:6): [True: 1.11k, False: 500]
  ------------------
  180|  1.11k|		VSB_destroy(&vsb);
  181|  1.61k|	WS_Rollback(ws, 0);
  182|       |
  183|  1.61k|	return (0);
  184|  1.61k|}

cache_ws_emu.c:pdiff:
  143|  9.70k|{
  144|       |
  145|  9.70k|	AN(b);
  ------------------
  |  |   84|  9.70k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  9.70k|#define assert(e)							\
  |  |  |  |   66|  9.70k|do {									\
  |  |  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  9.70k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
  146|  9.70k|	AN(e);
  ------------------
  |  |   84|  9.70k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  9.70k|#define assert(e)							\
  |  |  |  |   66|  9.70k|do {									\
  |  |  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  9.70k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
  147|  9.70k|	assert(b <= e);
  ------------------
  |  |   65|  9.70k|#define assert(e)							\
  |  |   66|  9.70k|do {									\
  |  |   67|  9.70k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 9.70k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  9.70k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 9.70k]
  |  |  ------------------
  ------------------
  148|  9.70k|	return ((size_t)((const char *)e - (const char *)b));
  149|  9.70k|}

cache_esi_parse.c:vct_is:
   63|  33.5M|{
   64|       |
   65|  33.5M|	x &= 0xff;
   66|  33.5M|	return (vct_typtab[x] & (y));
   67|  33.5M|}

cache_esi_parse.c:vbe16enc:
   93|  1.22k|{
   94|  1.22k|	uint8_t *p = (uint8_t *)pp;
   95|       |
   96|  1.22k|	p[0] = (u >> 8) & 0xff;
   97|  1.22k|	p[1] = u & 0xff;
   98|  1.22k|}
cache_esi_parse.c:vbe16dec:
   41|  1.22k|{
   42|  1.22k|	uint8_t const *p = (uint8_t const *)pp;
   43|       |
   44|  1.22k|	return ((p[0] << 8) | p[1]);
   45|  1.22k|}
cache_esi_parse.c:vbe64enc:
  113|    148|{
  114|    148|	uint8_t *p = (uint8_t *)pp;
  115|       |
  116|    148|	vbe32enc(p, (uint32_t)(u >> 32));
  117|    148|	vbe32enc(p + 4, (uint32_t)(u & 0xffffffffU));
  118|    148|}
cache_esi_parse.c:vbe32enc:
  102|    296|{
  103|    296|	uint8_t *p = (uint8_t *)pp;
  104|       |
  105|    296|	p[0] = (u >> 24) & 0xff;
  106|    296|	p[1] = (u >> 16) & 0xff;
  107|    296|	p[2] = (u >> 8) & 0xff;
  108|    296|	p[3] = u & 0xff;
  109|    296|}
cache_esi_parse.c:vbe64dec:
   57|    148|{
   58|    148|	uint8_t const *p = (uint8_t const *)pp;
   59|       |
   60|    148|	return (((uint64_t)vbe32dec(p) << 32) | vbe32dec(p + 4));
   61|    148|}
cache_esi_parse.c:vbe32dec:
   49|    296|{
   50|    296|	uint8_t const *p = (uint8_t const *)pp;
   51|       |
   52|    296|	return (((unsigned)p[0] << 24) | (p[1] << 16) | (p[2] << 8) | p[3]);
   53|    296|}

z_crc32_z:
  695|   462k|                              z_size_t len) {
  696|       |    /* Return initial CRC, if requested. */
  697|   462k|    if (buf == Z_NULL) return 0;
  ------------------
  |  |  217|   462k|#define Z_NULL  0  /* for initializing zalloc, zfree, opaque */
  ------------------
  |  Branch (697:9): [True: 188k, False: 274k]
  ------------------
  698|       |
  699|       |#ifdef DYNAMIC_CRC_TABLE
  700|       |    once(&made, make_crc_table);
  701|       |#endif /* DYNAMIC_CRC_TABLE */
  702|       |
  703|       |    /* Pre-condition the CRC */
  704|   274k|    crc = (~crc) & 0xffffffff;
  705|       |
  706|   274k|#ifdef W
  707|       |
  708|       |    /* If provided enough bytes, do a braided CRC calculation. */
  709|   274k|    if (len >= N * W + W - 1) {
  ------------------
  |  |   57|   274k|#  define N 5
  ------------------
                  if (len >= N * W + W - 1) {
  ------------------
  |  |   83|   274k|#      define W 8
  ------------------
                  if (len >= N * W + W - 1) {
  ------------------
  |  |   83|   274k|#      define W 8
  ------------------
  |  Branch (709:9): [True: 9.56k, False: 264k]
  ------------------
  710|  9.56k|        z_size_t blks;
  711|  9.56k|        z_word_t const *words;
  712|  9.56k|        unsigned endian;
  713|  9.56k|        int k;
  714|       |
  715|       |        /* Compute the CRC up to a z_word_t boundary. */
  716|  41.4k|        while (len && ((z_size_t)buf & (W - 1)) != 0) {
  ------------------
  |  |   83|  41.4k|#      define W 8
  ------------------
  |  Branch (716:16): [True: 41.4k, False: 0]
  |  Branch (716:23): [True: 31.8k, False: 9.56k]
  ------------------
  717|  31.8k|            len--;
  718|  31.8k|            crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
  719|  31.8k|        }
  720|       |
  721|       |        /* Compute the CRC on as many N z_word_t blocks as are available. */
  722|  9.56k|        blks = len / (N * W);
  ------------------
  |  |   57|  9.56k|#  define N 5
  ------------------
                      blks = len / (N * W);
  ------------------
  |  |   83|  9.56k|#      define W 8
  ------------------
  723|  9.56k|        len -= blks * N * W;
  ------------------
  |  |   57|  9.56k|#  define N 5
  ------------------
                      len -= blks * N * W;
  ------------------
  |  |   83|  9.56k|#      define W 8
  ------------------
  724|  9.56k|        words = (z_word_t const *)(intptr_t)buf;
  725|       |
  726|       |        /* Do endian check at execution time instead of compile time, since ARM
  727|       |           processors can change the endianness at execution time. If the
  728|       |           compiler knows what the endianness will be, it can optimize out the
  729|       |           check and the unused branch. */
  730|  9.56k|        endian = 1;
  731|  9.56k|        if (*(unsigned char *)&endian) {
  ------------------
  |  Branch (731:13): [True: 9.56k, False: 0]
  ------------------
  732|       |            /* Little endian. */
  733|       |
  734|  9.56k|            z_crc_t crc0;
  735|  9.56k|            z_word_t word0;
  736|  9.56k|#if N > 1
  737|  9.56k|            z_crc_t crc1;
  738|  9.56k|            z_word_t word1;
  739|  9.56k|#if N > 2
  740|  9.56k|            z_crc_t crc2;
  741|  9.56k|            z_word_t word2;
  742|  9.56k|#if N > 3
  743|  9.56k|            z_crc_t crc3;
  744|  9.56k|            z_word_t word3;
  745|  9.56k|#if N > 4
  746|  9.56k|            z_crc_t crc4;
  747|  9.56k|            z_word_t word4;
  748|       |#if N > 5
  749|       |            z_crc_t crc5;
  750|       |            z_word_t word5;
  751|       |#endif
  752|  9.56k|#endif
  753|  9.56k|#endif
  754|  9.56k|#endif
  755|  9.56k|#endif
  756|       |
  757|       |            /* Initialize the CRC for each braid. */
  758|  9.56k|            crc0 = crc;
  759|  9.56k|#if N > 1
  760|  9.56k|            crc1 = 0;
  761|  9.56k|#if N > 2
  762|  9.56k|            crc2 = 0;
  763|  9.56k|#if N > 3
  764|  9.56k|            crc3 = 0;
  765|  9.56k|#if N > 4
  766|  9.56k|            crc4 = 0;
  767|       |#if N > 5
  768|       |            crc5 = 0;
  769|       |#endif
  770|  9.56k|#endif
  771|  9.56k|#endif
  772|  9.56k|#endif
  773|  9.56k|#endif
  774|       |
  775|       |            /*
  776|       |              Process the first blks-1 blocks, computing the CRCs on each braid
  777|       |              independently.
  778|       |             */
  779|  1.26M|            while (--blks) {
  ------------------
  |  Branch (779:20): [True: 1.25M, False: 9.56k]
  ------------------
  780|       |                /* Load the word for each braid into registers. */
  781|  1.25M|                word0 = crc0 ^ words[0];
  782|  1.25M|#if N > 1
  783|  1.25M|                word1 = crc1 ^ words[1];
  784|  1.25M|#if N > 2
  785|  1.25M|                word2 = crc2 ^ words[2];
  786|  1.25M|#if N > 3
  787|  1.25M|                word3 = crc3 ^ words[3];
  788|  1.25M|#if N > 4
  789|  1.25M|                word4 = crc4 ^ words[4];
  790|       |#if N > 5
  791|       |                word5 = crc5 ^ words[5];
  792|       |#endif
  793|  1.25M|#endif
  794|  1.25M|#endif
  795|  1.25M|#endif
  796|  1.25M|#endif
  797|  1.25M|                words += N;
  ------------------
  |  |   57|  1.25M|#  define N 5
  ------------------
  798|       |
  799|       |                /* Compute and update the CRC for each word. The loop should
  800|       |                   get unrolled. */
  801|  1.25M|                crc0 = crc_braid_table[0][word0 & 0xff];
  802|  1.25M|#if N > 1
  803|  1.25M|                crc1 = crc_braid_table[0][word1 & 0xff];
  804|  1.25M|#if N > 2
  805|  1.25M|                crc2 = crc_braid_table[0][word2 & 0xff];
  806|  1.25M|#if N > 3
  807|  1.25M|                crc3 = crc_braid_table[0][word3 & 0xff];
  808|  1.25M|#if N > 4
  809|  1.25M|                crc4 = crc_braid_table[0][word4 & 0xff];
  810|       |#if N > 5
  811|       |                crc5 = crc_braid_table[0][word5 & 0xff];
  812|       |#endif
  813|  1.25M|#endif
  814|  1.25M|#endif
  815|  1.25M|#endif
  816|  1.25M|#endif
  817|  10.0M|                for (k = 1; k < W; k++) {
  ------------------
  |  |   83|  10.0M|#      define W 8
  ------------------
  |  Branch (817:29): [True: 8.80M, False: 1.25M]
  ------------------
  818|  8.80M|                    crc0 ^= crc_braid_table[k][(word0 >> (k << 3)) & 0xff];
  819|  8.80M|#if N > 1
  820|  8.80M|                    crc1 ^= crc_braid_table[k][(word1 >> (k << 3)) & 0xff];
  821|  8.80M|#if N > 2
  822|  8.80M|                    crc2 ^= crc_braid_table[k][(word2 >> (k << 3)) & 0xff];
  823|  8.80M|#if N > 3
  824|  8.80M|                    crc3 ^= crc_braid_table[k][(word3 >> (k << 3)) & 0xff];
  825|  8.80M|#if N > 4
  826|  8.80M|                    crc4 ^= crc_braid_table[k][(word4 >> (k << 3)) & 0xff];
  827|       |#if N > 5
  828|       |                    crc5 ^= crc_braid_table[k][(word5 >> (k << 3)) & 0xff];
  829|       |#endif
  830|  8.80M|#endif
  831|  8.80M|#endif
  832|  8.80M|#endif
  833|  8.80M|#endif
  834|  8.80M|                }
  835|  1.25M|            }
  836|       |
  837|       |            /*
  838|       |              Process the last block, combining the CRCs of the N braids at the
  839|       |              same time.
  840|       |             */
  841|  9.56k|            crc = crc_word(crc0 ^ words[0]);
  842|  9.56k|#if N > 1
  843|  9.56k|            crc = crc_word(crc1 ^ words[1] ^ crc);
  844|  9.56k|#if N > 2
  845|  9.56k|            crc = crc_word(crc2 ^ words[2] ^ crc);
  846|  9.56k|#if N > 3
  847|  9.56k|            crc = crc_word(crc3 ^ words[3] ^ crc);
  848|  9.56k|#if N > 4
  849|  9.56k|            crc = crc_word(crc4 ^ words[4] ^ crc);
  850|       |#if N > 5
  851|       |            crc = crc_word(crc5 ^ words[5] ^ crc);
  852|       |#endif
  853|  9.56k|#endif
  854|  9.56k|#endif
  855|  9.56k|#endif
  856|  9.56k|#endif
  857|  9.56k|            words += N;
  ------------------
  |  |   57|  9.56k|#  define N 5
  ------------------
  858|  9.56k|        }
  859|      0|        else {
  860|       |            /* Big endian. */
  861|       |
  862|      0|            z_word_t crc0, word0, comb;
  863|      0|#if N > 1
  864|      0|            z_word_t crc1, word1;
  865|      0|#if N > 2
  866|      0|            z_word_t crc2, word2;
  867|      0|#if N > 3
  868|      0|            z_word_t crc3, word3;
  869|      0|#if N > 4
  870|      0|            z_word_t crc4, word4;
  871|       |#if N > 5
  872|       |            z_word_t crc5, word5;
  873|       |#endif
  874|      0|#endif
  875|      0|#endif
  876|      0|#endif
  877|      0|#endif
  878|       |
  879|       |            /* Initialize the CRC for each braid. */
  880|      0|            crc0 = byte_swap(crc);
  881|      0|#if N > 1
  882|      0|            crc1 = 0;
  883|      0|#if N > 2
  884|      0|            crc2 = 0;
  885|      0|#if N > 3
  886|      0|            crc3 = 0;
  887|      0|#if N > 4
  888|      0|            crc4 = 0;
  889|       |#if N > 5
  890|       |            crc5 = 0;
  891|       |#endif
  892|      0|#endif
  893|      0|#endif
  894|      0|#endif
  895|      0|#endif
  896|       |
  897|       |            /*
  898|       |              Process the first blks-1 blocks, computing the CRCs on each braid
  899|       |              independently.
  900|       |             */
  901|      0|            while (--blks) {
  ------------------
  |  Branch (901:20): [True: 0, False: 0]
  ------------------
  902|       |                /* Load the word for each braid into registers. */
  903|      0|                word0 = crc0 ^ words[0];
  904|      0|#if N > 1
  905|      0|                word1 = crc1 ^ words[1];
  906|      0|#if N > 2
  907|      0|                word2 = crc2 ^ words[2];
  908|      0|#if N > 3
  909|      0|                word3 = crc3 ^ words[3];
  910|      0|#if N > 4
  911|      0|                word4 = crc4 ^ words[4];
  912|       |#if N > 5
  913|       |                word5 = crc5 ^ words[5];
  914|       |#endif
  915|      0|#endif
  916|      0|#endif
  917|      0|#endif
  918|      0|#endif
  919|      0|                words += N;
  ------------------
  |  |   57|      0|#  define N 5
  ------------------
  920|       |
  921|       |                /* Compute and update the CRC for each word. The loop should
  922|       |                   get unrolled. */
  923|      0|                crc0 = crc_braid_big_table[0][word0 & 0xff];
  924|      0|#if N > 1
  925|      0|                crc1 = crc_braid_big_table[0][word1 & 0xff];
  926|      0|#if N > 2
  927|      0|                crc2 = crc_braid_big_table[0][word2 & 0xff];
  928|      0|#if N > 3
  929|      0|                crc3 = crc_braid_big_table[0][word3 & 0xff];
  930|      0|#if N > 4
  931|      0|                crc4 = crc_braid_big_table[0][word4 & 0xff];
  932|       |#if N > 5
  933|       |                crc5 = crc_braid_big_table[0][word5 & 0xff];
  934|       |#endif
  935|      0|#endif
  936|      0|#endif
  937|      0|#endif
  938|      0|#endif
  939|      0|                for (k = 1; k < W; k++) {
  ------------------
  |  |   83|      0|#      define W 8
  ------------------
  |  Branch (939:29): [True: 0, False: 0]
  ------------------
  940|      0|                    crc0 ^= crc_braid_big_table[k][(word0 >> (k << 3)) & 0xff];
  941|      0|#if N > 1
  942|      0|                    crc1 ^= crc_braid_big_table[k][(word1 >> (k << 3)) & 0xff];
  943|      0|#if N > 2
  944|      0|                    crc2 ^= crc_braid_big_table[k][(word2 >> (k << 3)) & 0xff];
  945|      0|#if N > 3
  946|      0|                    crc3 ^= crc_braid_big_table[k][(word3 >> (k << 3)) & 0xff];
  947|      0|#if N > 4
  948|      0|                    crc4 ^= crc_braid_big_table[k][(word4 >> (k << 3)) & 0xff];
  949|       |#if N > 5
  950|       |                    crc5 ^= crc_braid_big_table[k][(word5 >> (k << 3)) & 0xff];
  951|       |#endif
  952|      0|#endif
  953|      0|#endif
  954|      0|#endif
  955|      0|#endif
  956|      0|                }
  957|      0|            }
  958|       |
  959|       |            /*
  960|       |              Process the last block, combining the CRCs of the N braids at the
  961|       |              same time.
  962|       |             */
  963|      0|            comb = crc_word_big(crc0 ^ words[0]);
  964|      0|#if N > 1
  965|      0|            comb = crc_word_big(crc1 ^ words[1] ^ comb);
  966|      0|#if N > 2
  967|      0|            comb = crc_word_big(crc2 ^ words[2] ^ comb);
  968|      0|#if N > 3
  969|      0|            comb = crc_word_big(crc3 ^ words[3] ^ comb);
  970|      0|#if N > 4
  971|      0|            comb = crc_word_big(crc4 ^ words[4] ^ comb);
  972|       |#if N > 5
  973|       |            comb = crc_word_big(crc5 ^ words[5] ^ comb);
  974|       |#endif
  975|      0|#endif
  976|      0|#endif
  977|      0|#endif
  978|      0|#endif
  979|      0|            words += N;
  ------------------
  |  |   57|      0|#  define N 5
  ------------------
  980|      0|            crc = byte_swap(comb);
  981|      0|        }
  982|       |
  983|       |        /*
  984|       |          Update the pointer to the remaining bytes to process.
  985|       |         */
  986|  9.56k|        buf = (unsigned char const *)words;
  987|  9.56k|    }
  988|       |
  989|   274k|#endif /* W */
  990|       |
  991|       |    /* Complete the computation of the CRC on any remaining bytes. */
  992|   341k|    while (len >= 8) {
  ------------------
  |  Branch (992:12): [True: 67.6k, False: 274k]
  ------------------
  993|  67.6k|        len -= 8;
  994|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
  995|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
  996|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
  997|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
  998|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
  999|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
 1000|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
 1001|  67.6k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
 1002|  67.6k|    }
 1003|  1.10M|    while (len) {
  ------------------
  |  Branch (1003:12): [True: 831k, False: 274k]
  ------------------
 1004|   831k|        len--;
 1005|   831k|        crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff];
 1006|   831k|    }
 1007|       |
 1008|       |    /* Return the CRC, post-conditioned. */
 1009|   274k|    return crc ^ 0xffffffff;
 1010|   462k|}
z_crc32:
 1016|   462k|                            uInt len) {
 1017|   462k|    return crc32_z(crc, buf, len);
  ------------------
  |  |   44|   462k|#  define crc32_z               z_crc32_z
  ------------------
 1018|   462k|}
z_crc32_combine64:
 1021|    151|uLong ZEXPORT crc32_combine64(uLong crc1, uLong crc2, z_off64_t len2) {
 1022|       |#ifdef DYNAMIC_CRC_TABLE
 1023|       |    once(&made, make_crc_table);
 1024|       |#endif /* DYNAMIC_CRC_TABLE */
 1025|    151|    return multmodp(x2nmodp(len2, 3), crc1) ^ (crc2 & 0xffffffff);
 1026|    151|}
z_crc32_combine:
 1029|    151|uLong ZEXPORT crc32_combine(uLong crc1, uLong crc2, z_off_t len2) {
 1030|    151|    return crc32_combine64(crc1, crc2, (z_off64_t)len2);
  ------------------
  |  |   40|    151|#  define crc32_combine64       z_crc32_combine64
  ------------------
 1031|    151|}
crc32.c:crc_word:
  676|  47.8k|local z_crc_t crc_word (z_word_t data) {
  677|  47.8k|    int k;
  678|   430k|    for (k = 0; k < W; k++)
  ------------------
  |  |   83|   430k|#      define W 8
  ------------------
  |  Branch (678:17): [True: 382k, False: 47.8k]
  ------------------
  679|   382k|        data = (data >> 8) ^ crc_table[data & 0xff];
  680|  47.8k|    return (z_crc_t)data;
  681|  47.8k|}
crc32.c:multmodp:
  155|    767|local z_crc_t multmodp(z_crc_t a, z_crc_t b) {
  156|    767|    z_crc_t m, p;
  157|       |
  158|    767|    m = (z_crc_t)1 << 31;
  159|    767|    p = 0;
  160|  18.3k|    for (;;) {
  161|  18.3k|        if (a & m) {
  ------------------
  |  Branch (161:13): [True: 8.26k, False: 10.0k]
  ------------------
  162|  8.26k|            p ^= b;
  163|  8.26k|            if ((a & (m - 1)) == 0)
  ------------------
  |  Branch (163:17): [True: 767, False: 7.49k]
  ------------------
  164|    767|                break;
  165|  8.26k|        }
  166|  17.5k|        m >>= 1;
  167|  17.5k|        b = b & 1 ? (b >> 1) ^ POLY : b >> 1;
  ------------------
  |  |  149|  7.47k|#define POLY 0xedb88320         /* p(x) reflected, with x^32 implied */
  ------------------
  |  Branch (167:13): [True: 7.47k, False: 10.0k]
  ------------------
  168|  17.5k|    }
  169|    767|    return p;
  170|    767|}
crc32.c:x2nmodp:
  176|    151|local z_crc_t x2nmodp(z_off64_t n, unsigned k) {
  177|    151|    z_crc_t p;
  178|       |
  179|    151|    p = (z_crc_t)1 << 31;           /* x^0 == 1 */
  180|    946|    while (n) {
  ------------------
  |  Branch (180:12): [True: 795, False: 151]
  ------------------
  181|    795|        if (n & 1)
  ------------------
  |  Branch (181:13): [True: 616, False: 179]
  ------------------
  182|    616|            p = multmodp(x2n_table[k & 31], p);
  183|    795|        n >>= 1;
  184|    795|        k++;
  185|    795|    }
  186|    151|    return p;
  187|    151|}

VSB_new_auto:
  227|  14.8k|{
  228|  14.8k|	struct vsb *s;
  229|       |
  230|  14.8k|	s = SBMALLOC(sizeof(*s));
  ------------------
  |  |   47|  14.8k|#define	SBMALLOC(size)		malloc(size)
  ------------------
  231|  14.8k|	if (s == NULL)
  ------------------
  |  Branch (231:6): [True: 0, False: 14.8k]
  ------------------
  232|      0|		return (NULL);
  233|  14.8k|	if (VSB_newbuf(s, NULL, 0, VSB_AUTOEXTEND) == NULL) {
  ------------------
  |  |   47|  14.8k|#define	VSB_AUTOEXTEND	0x00000001	/* automatically extend buffer */
  ------------------
  |  Branch (233:6): [True: 0, False: 14.8k]
  ------------------
  234|      0|		SBFREE(s);
  ------------------
  |  |   48|      0|#define	SBFREE(buf)		free(buf)
  ------------------
  235|      0|		return (NULL);
  236|      0|	}
  237|  14.8k|	VSB_SETFLAG(s, VSB_DYNSTRUCT);
  ------------------
  |  |   64|  14.8k|#define	VSB_SETFLAG(s, f)	do { (s)->s_flags |= (f); } while (0)
  |  |  ------------------
  |  |  |  Branch (64:62): [Folded, False: 14.8k]
  |  |  ------------------
  ------------------
  238|  14.8k|	return (s);
  239|  14.8k|}
VSB_bcat:
  286|   184k|{
  287|   184k|	assert_VSB_integrity(s);
  ------------------
  |  |  108|   184k|#define	assert_VSB_integrity(s) _assert_VSB_integrity(__func__, (s))
  ------------------
  288|   184k|	assert_VSB_state(s, 0);
  ------------------
  |  |  109|   184k|#define	assert_VSB_state(s, i)	 _assert_VSB_state(__func__, (s), (i))
  ------------------
  289|       |
  290|   184k|	assert(len >= 0);
  ------------------
  |  |   65|   184k|#define assert(e)							\
  |  |   66|   184k|do {									\
  |  |   67|   184k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 184k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|   184k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 184k]
  |  |  ------------------
  ------------------
  291|   184k|	if (s->s_error != 0)
  ------------------
  |  Branch (291:6): [True: 0, False: 184k]
  ------------------
  292|      0|		return (-1);
  293|   184k|	if (len == 0)
  ------------------
  |  Branch (293:6): [True: 0, False: 184k]
  ------------------
  294|      0|		return (0);
  295|   184k|	_vsb_indent(s);
  296|   184k|	if (len > VSB_FREESPACE(s)) {
  ------------------
  |  |   58|   184k|#define	VSB_FREESPACE(s)	((s)->s_size - ((s)->s_len + 1L))
  ------------------
  |  Branch (296:6): [True: 806, False: 183k]
  ------------------
  297|    806|		if (VSB_extend(s, len - VSB_FREESPACE(s)) < 0)
  ------------------
  |  |   58|    806|#define	VSB_FREESPACE(s)	((s)->s_size - ((s)->s_len + 1L))
  ------------------
  |  Branch (297:7): [True: 0, False: 806]
  ------------------
  298|      0|			s->s_error = ENOMEM;
  299|    806|		if (s->s_error != 0)
  ------------------
  |  Branch (299:7): [True: 0, False: 806]
  ------------------
  300|      0|			return (-1);
  301|    806|	}
  302|   184k|	memcpy(s->s_buf + s->s_len, buf, len);
  303|   184k|	s->s_len += len;
  304|   184k|	return (0);
  305|   184k|}
VSB_vprintf:
  340|  6.16M|{
  341|  6.16M|	va_list ap_copy;
  342|  6.16M|	int len;
  343|       |
  344|  6.16M|	assert_VSB_integrity(s);
  ------------------
  |  |  108|  6.16M|#define	assert_VSB_integrity(s) _assert_VSB_integrity(__func__, (s))
  ------------------
  345|  6.16M|	assert_VSB_state(s, 0);
  ------------------
  |  |  109|  6.16M|#define	assert_VSB_state(s, i)	 _assert_VSB_state(__func__, (s), (i))
  ------------------
  346|       |
  347|  6.16M|	KASSERT(fmt != NULL,
  ------------------
  |  |   46|  6.16M|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  6.16M|#define assert(e)							\
  |  |  |  |   66|  6.16M|do {									\
  |  |  |  |   67|  6.16M|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 6.16M]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  6.16M|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 6.16M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  348|  6.16M|	    ("%s called with a NULL format string", __func__));
  349|       |
  350|  6.16M|	if (s->s_error != 0)
  ------------------
  |  Branch (350:6): [True: 0, False: 6.16M]
  ------------------
  351|      0|		return (-1);
  352|  6.16M|	_vsb_indent(s);
  353|       |
  354|       |	/*
  355|       |	 * For the moment, there is no way to get vsnprintf(3) to hand
  356|       |	 * back a character at a time, to push everything into
  357|       |	 * VSB_putc_func() as was done for the kernel.
  358|       |	 *
  359|       |	 * In userspace, while drains are useful, there's generally
  360|       |	 * not a problem attempting to malloc(3) on out of space.  So
  361|       |	 * expand a userland vsb if there is not enough room for the
  362|       |	 * data produced by VSB_[v]printf(3).
  363|       |	 */
  364|       |
  365|  6.16M|	do {
  366|  6.16M|		va_copy(ap_copy, ap);
  367|  6.16M|		len = vsnprintf(&s->s_buf[s->s_len], VSB_FREESPACE(s) + 1,
  ------------------
  |  |   58|  6.16M|#define	VSB_FREESPACE(s)	((s)->s_size - ((s)->s_len + 1L))
  ------------------
  368|  6.16M|		    fmt, ap_copy);
  369|  6.16M|		va_end(ap_copy);
  370|  6.16M|		if (len < 0) {
  ------------------
  |  Branch (370:7): [True: 0, False: 6.16M]
  ------------------
  371|      0|			s->s_error = errno;
  372|      0|			return (-1);
  373|      0|		}
  374|  6.16M|	} while (len > VSB_FREESPACE(s) &&
  ------------------
  |  |   58|  12.3M|#define	VSB_FREESPACE(s)	((s)->s_size - ((s)->s_len + 1L))
  ------------------
  |  Branch (374:11): [True: 2.61k, False: 6.16M]
  ------------------
  375|  2.61k|	    VSB_extend(s, len - VSB_FREESPACE(s)) == 0);
  ------------------
  |  |   58|  2.61k|#define	VSB_FREESPACE(s)	((s)->s_size - ((s)->s_len + 1L))
  ------------------
  |  Branch (375:6): [True: 2.61k, False: 0]
  ------------------
  376|       |
  377|       |	/*
  378|       |	 * s->s_len is the length of the string, without the terminating nul.
  379|       |	 * When updating s->s_len, we must subtract 1 from the length that
  380|       |	 * we passed into vsnprintf() because that length includes the
  381|       |	 * terminating nul.
  382|       |	 *
  383|       |	 * vsnprintf() returns the amount that would have been copied,
  384|       |	 * given sufficient space, so don't over-increment s_len.
  385|       |	 */
  386|  6.16M|	s->s_len += vmin_t(ssize_t, len, VSB_FREESPACE(s));
  ------------------
  |  |  206|  6.16M|#define vmin_t(type, a, b)	vtake(min, type, type, a, b)
  |  |  ------------------
  |  |  |  |  200|  6.16M|#define vtake(n, ta, tb, a, b)	_vtake(op ## n, ta, tb, a, b,		\
  |  |  |  |  ------------------
  |  |  |  |  |  |  191|  6.16M|	({								\
  |  |  |  |  |  |  192|  6.16M|	ta _va = (a);							\
  |  |  |  |  |  |  193|  6.16M|	tb _vb = (b);							\
  |  |  |  |  |  |  194|  6.16M|	(void)(&_va == &_vb);						\
  |  |  |  |  |  |  195|  6.16M|	_va op _vb ? _va : _vb;						\
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  |  Branch (195:2): [True: 6.16M, False: 2.47k]
  |  |  |  |  |  |  ------------------
  |  |  |  |  |  |  196|  6.16M|})
  |  |  |  |  ------------------
  |  |  |  |  201|  6.16M|    VUNIQ_NAME(_v ## n ## A), VUNIQ_NAME(_v ## n ## B))
  |  |  ------------------
  ------------------
  387|  6.16M|	if (!VSB_HASROOM(s) && !VSB_CANEXTEND(s))
  ------------------
  |  |   57|  12.3M|#define	VSB_HASROOM(s)		((s)->s_len < (s)->s_size - 1L)
  ------------------
              	if (!VSB_HASROOM(s) && !VSB_CANEXTEND(s))
  ------------------
  |  |   59|  2.47k|#define	VSB_CANEXTEND(s)	((s)->s_flags & VSB_AUTOEXTEND)
  |  |  ------------------
  |  |  |  |   47|  2.47k|#define	VSB_AUTOEXTEND	0x00000001	/* automatically extend buffer */
  |  |  ------------------
  ------------------
  |  Branch (387:6): [True: 2.47k, False: 6.16M]
  |  Branch (387:25): [True: 0, False: 2.47k]
  ------------------
  388|      0|		s->s_error = ENOMEM;
  389|       |
  390|  6.16M|	KASSERT(s->s_len < s->s_size,
  ------------------
  |  |   46|  6.16M|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  6.16M|#define assert(e)							\
  |  |  |  |   66|  6.16M|do {									\
  |  |  |  |   67|  6.16M|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 6.16M]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  6.16M|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 6.16M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  391|  6.16M|	    ("wrote past end of vsb (%d >= %d)", s->s_len, s->s_size));
  392|       |
  393|  6.16M|	if (s->s_error != 0)
  ------------------
  |  Branch (393:6): [True: 0, False: 6.16M]
  ------------------
  394|      0|		return (-1);
  395|  6.16M|	return (0);
  396|  6.16M|}
VSB_printf:
  403|  6.16M|{
  404|  6.16M|	va_list ap;
  405|  6.16M|	int result;
  406|       |
  407|  6.16M|	va_start(ap, fmt);
  408|  6.16M|	result = VSB_vprintf(s, fmt, ap);
  409|       |	va_end(ap);
  410|  6.16M|	return (result);
  411|  6.16M|}
VSB_putc:
  418|  19.3M|{
  419|       |
  420|  19.3M|	VSB_put_byte(s, c);
  421|  19.3M|	if (s->s_error != 0)
  ------------------
  |  Branch (421:6): [True: 0, False: 19.3M]
  ------------------
  422|      0|		return (-1);
  423|  19.3M|	return (0);
  424|  19.3M|}
VSB_finish:
  441|  14.0k|{
  442|       |
  443|  14.0k|	assert_VSB_integrity(s);
  ------------------
  |  |  108|  14.0k|#define	assert_VSB_integrity(s) _assert_VSB_integrity(__func__, (s))
  ------------------
  444|  14.0k|	assert_VSB_state(s, 0);
  ------------------
  |  |  109|  14.0k|#define	assert_VSB_state(s, i)	 _assert_VSB_state(__func__, (s), (i))
  ------------------
  445|       |
  446|  14.0k|	s->s_buf[s->s_len] = '\0';
  447|  14.0k|	VSB_SETFLAG(s, VSB_FINISHED);
  ------------------
  |  |   64|  14.0k|#define	VSB_SETFLAG(s, f)	do { (s)->s_flags |= (f); } while (0)
  |  |  ------------------
  |  |  |  Branch (64:62): [Folded, False: 14.0k]
  |  |  ------------------
  ------------------
  448|  14.0k|	errno = s->s_error;
  449|  14.0k|	if (s->s_error)
  ------------------
  |  Branch (449:6): [True: 0, False: 14.0k]
  ------------------
  450|      0|		return (-1);
  451|  14.0k|	return (0);
  452|  14.0k|}
VSB_data:
  459|  27.6k|{
  460|       |
  461|  27.6k|	assert_VSB_integrity(s);
  ------------------
  |  |  108|  27.6k|#define	assert_VSB_integrity(s) _assert_VSB_integrity(__func__, (s))
  ------------------
  462|  27.6k|	assert_VSB_state(s, VSB_FINISHED);
  ------------------
  |  |  109|  27.6k|#define	assert_VSB_state(s, i)	 _assert_VSB_state(__func__, (s), (i))
  ------------------
  463|       |
  464|  27.6k|	return (s->s_buf);
  465|  27.6k|}
VSB_len:
  472|  10.9k|{
  473|       |
  474|  10.9k|	assert_VSB_integrity(s);
  ------------------
  |  |  108|  10.9k|#define	assert_VSB_integrity(s) _assert_VSB_integrity(__func__, (s))
  ------------------
  475|       |	/* don't care if it's finished or not */
  476|       |
  477|  10.9k|	if (s->s_error != 0)
  ------------------
  |  Branch (477:6): [True: 0, False: 10.9k]
  ------------------
  478|      0|		return (-1);
  479|  10.9k|	return (s->s_len);
  480|  10.9k|}
VSB_destroy:
  494|  14.8k|{
  495|       |
  496|  14.8k|	AN(s);
  ------------------
  |  |   84|  14.8k|#define AN(foo)		do { assert((foo) != 0); } while (0)
  |  |  ------------------
  |  |  |  |   65|  14.8k|#define assert(e)							\
  |  |  |  |   66|  14.8k|do {									\
  |  |  |  |   67|  14.8k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 14.8k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  14.8k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 14.8k]
  |  |  |  |  ------------------
  |  |  ------------------
  |  |  |  Branch (84:52): [Folded, False: 14.8k]
  |  |  ------------------
  ------------------
  497|  14.8k|	assert_VSB_integrity(*s);
  ------------------
  |  |  108|  14.8k|#define	assert_VSB_integrity(s) _assert_VSB_integrity(__func__, (s))
  ------------------
  498|  14.8k|	assert(VSB_ISDYNAMIC(*s));
  ------------------
  |  |   65|  14.8k|#define assert(e)							\
  |  |   66|  14.8k|do {									\
  |  |   67|  14.8k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 14.8k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  14.8k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 14.8k]
  |  |  ------------------
  ------------------
  499|  14.8k|	assert(VSB_ISDYNSTRUCT(*s));
  ------------------
  |  |   65|  14.8k|#define assert(e)							\
  |  |   66|  14.8k|do {									\
  |  |   67|  14.8k|	if (!(e)) {							\
  |  |  ------------------
  |  |  |  Branch (67:6): [True: 0, False: 14.8k]
  |  |  ------------------
  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |   70|      0|	}								\
  |  |   71|  14.8k|} while (0)
  |  |  ------------------
  |  |  |  Branch (71:10): [Folded, False: 14.8k]
  |  |  ------------------
  ------------------
  500|  14.8k|	SBFREE((*s)->s_buf);
  ------------------
  |  |   48|  14.8k|#define	SBFREE(buf)		free(buf)
  ------------------
  501|  14.8k|	memset(*s, 0, sizeof(**s));
  502|  14.8k|	SBFREE(*s);
  ------------------
  |  |   48|  14.8k|#define	SBFREE(buf)		free(buf)
  ------------------
  503|       |	*s = NULL;
  504|  14.8k|}
vsb.c:VSB_newbuf:
  185|  14.8k|{
  186|       |
  187|  14.8k|	memset(s, 0, sizeof(*s));
  188|  14.8k|	s->magic = VSB_MAGIC;
  ------------------
  |  |   41|  14.8k|#define VSB_MAGIC	0x4a82dd8a
  ------------------
  189|  14.8k|	s->s_flags = flags;
  190|  14.8k|	s->s_size = length;
  191|  14.8k|	s->s_buf = buf;
  192|       |
  193|  14.8k|	if ((s->s_flags & VSB_AUTOEXTEND) == 0) {
  ------------------
  |  |   47|  14.8k|#define	VSB_AUTOEXTEND	0x00000001	/* automatically extend buffer */
  ------------------
  |  Branch (193:6): [True: 0, False: 14.8k]
  ------------------
  194|      0|		KASSERT(s->s_size > 1,
  ------------------
  |  |   46|      0|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|      0|#define assert(e)							\
  |  |  |  |   66|      0|do {									\
  |  |  |  |   67|      0|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 0]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|      0|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 0]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  195|      0|		    ("attempt to create a too small vsb"));
  196|      0|	}
  197|       |
  198|  14.8k|	if (s->s_buf != NULL)
  ------------------
  |  Branch (198:6): [True: 0, False: 14.8k]
  ------------------
  199|      0|		return (s);
  200|       |
  201|  14.8k|	if ((flags & VSB_AUTOEXTEND) != 0)
  ------------------
  |  |   47|  14.8k|#define	VSB_AUTOEXTEND	0x00000001	/* automatically extend buffer */
  ------------------
  |  Branch (201:6): [True: 14.8k, False: 0]
  ------------------
  202|  14.8k|		s->s_size = VSB_extendsize(s->s_size);
  203|       |
  204|  14.8k|	s->s_buf = SBMALLOC(s->s_size);
  ------------------
  |  |   47|  14.8k|#define	SBMALLOC(size)		malloc(size)
  ------------------
  205|  14.8k|	if (s->s_buf == NULL)
  ------------------
  |  Branch (205:6): [True: 0, False: 14.8k]
  ------------------
  206|      0|		return (NULL);
  207|  14.8k|	VSB_SETFLAG(s, VSB_DYNAMIC);
  ------------------
  |  |   64|  14.8k|#define	VSB_SETFLAG(s, f)	do { (s)->s_flags |= (f); } while (0)
  |  |  ------------------
  |  |  |  Branch (64:62): [Folded, False: 14.8k]
  |  |  ------------------
  ------------------
  208|  14.8k|	return (s);
  209|  14.8k|}
vsb.c:VSB_extendsize:
  122|  30.3k|{
  123|  30.3k|	ssize_t newsize;
  124|       |
  125|  30.3k|	if (size < (int)VSB_MAXEXTENDSIZE) {
  ------------------
  |  |   73|  30.3k|#define	VSB_MAXEXTENDSIZE	4096
  ------------------
  |  Branch (125:6): [True: 24.2k, False: 6.07k]
  ------------------
  126|  24.2k|		newsize = VSB_MINEXTENDSIZE;
  ------------------
  |  |   67|  24.2k|#define	VSB_MINEXTENDSIZE	16		/* Should be power of 2. */
  ------------------
  127|  51.3k|		while (newsize < size)
  ------------------
  |  Branch (127:10): [True: 27.0k, False: 24.2k]
  ------------------
  128|  27.0k|			newsize *= 2;
  129|  24.2k|	} else {
  130|  6.07k|		newsize = rndup2(size, VSB_MAXEXTENDINCR);
  ------------------
  |  |   50|  6.07k|#define	rndup2(x, y)	(((x)+((y)-1))&(~((y)-1))) /* if y is powers of two */
  ------------------
  131|  6.07k|	}
  132|  30.3k|	KASSERT(newsize >= size, ("%s: %d < %d\n", __func__, newsize, size));
  ------------------
  |  |   46|  30.3k|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  30.3k|#define assert(e)							\
  |  |  |  |   66|  30.3k|do {									\
  |  |  |  |   67|  30.3k|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 30.3k]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  30.3k|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 30.3k]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  133|  30.3k|	return (newsize);
  134|  30.3k|}
vsb.c:_assert_VSB_integrity:
   83|  25.8M|{
   84|       |
   85|  25.8M|	(void)fun;
   86|  25.8M|	(void)s;
   87|  25.8M|	KASSERT(s != NULL,
  ------------------
  |  |   46|  25.8M|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  25.8M|#define assert(e)							\
  |  |  |  |   66|  25.8M|do {									\
  |  |  |  |   67|  25.8M|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 25.8M]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  25.8M|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 25.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   88|  25.8M|	    ("%s called with a NULL vsb pointer", fun));
   89|  25.8M|	KASSERT(s->magic == VSB_MAGIC,
  ------------------
  |  |   46|  25.8M|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  25.8M|#define assert(e)							\
  |  |  |  |   66|  25.8M|do {									\
  |  |  |  |   67|  25.8M|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 25.8M]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  25.8M|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 25.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   90|  25.8M|	    ("%s called with a bogus vsb pointer", fun));
   91|  25.8M|	KASSERT(s->s_buf != NULL,
  ------------------
  |  |   46|  25.8M|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  25.8M|#define assert(e)							\
  |  |  |  |   66|  25.8M|do {									\
  |  |  |  |   67|  25.8M|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 25.8M]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  25.8M|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 25.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   92|  25.8M|	    ("%s called with uninitialized or corrupt vsb", fun));
   93|  25.8M|	KASSERT(s->s_len < s->s_size,
  ------------------
  |  |   46|  25.8M|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  25.8M|#define assert(e)							\
  |  |  |  |   66|  25.8M|do {									\
  |  |  |  |   67|  25.8M|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 25.8M]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  25.8M|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 25.8M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
   94|  25.8M|	    ("wrote past end of vsb (%d >= %d)", s->s_len, s->s_size));
   95|  25.8M|}
vsb.c:_assert_VSB_state:
   99|  25.7M|{
  100|       |
  101|  25.7M|	(void)fun;
  102|  25.7M|	(void)s;
  103|  25.7M|	(void)state;
  104|  25.7M|	KASSERT((s->s_flags & VSB_FINISHED) == state,
  ------------------
  |  |   46|  25.7M|#define	KASSERT(e, m)		assert(e)
  |  |  ------------------
  |  |  |  |   65|  25.7M|#define assert(e)							\
  |  |  |  |   66|  25.7M|do {									\
  |  |  |  |   67|  25.7M|	if (!(e)) {							\
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (67:6): [True: 0, False: 25.7M]
  |  |  |  |  ------------------
  |  |  |  |   68|      0|		VAS_Fail(__func__, __FILE__, __LINE__,			\
  |  |  |  |   69|      0|		    #e, VAS_ASSERT);					\
  |  |  |  |   70|      0|	}								\
  |  |  |  |   71|  25.7M|} while (0)
  |  |  |  |  ------------------
  |  |  |  |  |  Branch (71:10): [Folded, False: 25.7M]
  |  |  |  |  ------------------
  |  |  ------------------
  ------------------
  105|  25.7M|	    ("%s called with %sfinished or corrupt vsb", fun,
  106|  25.7M|	    (state ? "un" : "")));
  107|  25.7M|}
vsb.c:_vsb_indent:
  165|  25.7M|{
  166|  25.7M|	if (s->s_indent == 0 || s->s_error != 0 ||
  ------------------
  |  Branch (166:6): [True: 25.7M, False: 0]
  |  Branch (166:26): [True: 0, False: 0]
  ------------------
  167|      0|	    (s->s_len > 0 && s->s_buf[s->s_len - 1] != '\n'))
  ------------------
  |  Branch (167:7): [True: 0, False: 0]
  |  Branch (167:23): [True: 0, False: 0]
  ------------------
  168|  25.7M|		return;
  169|      0|	if (VSB_FREESPACE(s) <= s->s_indent &&
  ------------------
  |  |   58|      0|#define	VSB_FREESPACE(s)	((s)->s_size - ((s)->s_len + 1L))
  ------------------
  |  Branch (169:6): [True: 0, False: 0]
  ------------------
  170|      0|	    VSB_extend(s, s->s_indent) < 0) {
  ------------------
  |  Branch (170:6): [True: 0, False: 0]
  ------------------
  171|      0|		s->s_error = ENOMEM;
  172|      0|		return;
  173|      0|	}
  174|      0|	memset(s->s_buf + s->s_len, ' ', s->s_indent);
  175|      0|	s->s_len += s->s_indent;
  176|      0|}
vsb.c:VSB_extend:
  141|  15.5k|{
  142|  15.5k|	char *newbuf;
  143|  15.5k|	ssize_t newsize;
  144|       |
  145|  15.5k|	if (!VSB_CANEXTEND(s))
  ------------------
  |  |   59|  15.5k|#define	VSB_CANEXTEND(s)	((s)->s_flags & VSB_AUTOEXTEND)
  |  |  ------------------
  |  |  |  |   47|  15.5k|#define	VSB_AUTOEXTEND	0x00000001	/* automatically extend buffer */
  |  |  ------------------
  ------------------
  |  Branch (145:6): [True: 0, False: 15.5k]
  ------------------
  146|      0|		return (-1);
  147|  15.5k|	newsize = VSB_extendsize(s->s_size + addlen);
  148|  15.5k|	if (VSB_ISDYNAMIC(s))
  ------------------
  |  |   55|  15.5k|#define	VSB_ISDYNAMIC(s)	((s)->s_flags & VSB_DYNAMIC)
  |  |  ------------------
  |  |  |  |   49|  15.5k|#define	VSB_DYNAMIC	0x00010000	/* s_buf must be freed */
  |  |  ------------------
  |  |  |  Branch (55:26): [True: 15.5k, False: 0]
  |  |  ------------------
  ------------------
  149|  15.5k|		newbuf = realloc(s->s_buf, newsize);
  150|      0|	else
  151|      0|		newbuf = SBMALLOC(newsize);
  ------------------
  |  |   47|      0|#define	SBMALLOC(size)		malloc(size)
  ------------------
  152|  15.5k|	if (newbuf == NULL)
  ------------------
  |  Branch (152:6): [True: 0, False: 15.5k]
  ------------------
  153|      0|		return (-1);
  154|  15.5k|	if (!VSB_ISDYNAMIC(s)) {
  ------------------
  |  |   55|  15.5k|#define	VSB_ISDYNAMIC(s)	((s)->s_flags & VSB_DYNAMIC)
  |  |  ------------------
  |  |  |  |   49|  15.5k|#define	VSB_DYNAMIC	0x00010000	/* s_buf must be freed */
  |  |  ------------------
  ------------------
  |  Branch (154:6): [True: 0, False: 15.5k]
  ------------------
  155|      0|		memcpy(newbuf, s->s_buf, s->s_size);
  156|      0|		VSB_SETFLAG(s, VSB_DYNAMIC);
  ------------------
  |  |   64|      0|#define	VSB_SETFLAG(s, f)	do { (s)->s_flags |= (f); } while (0)
  |  |  ------------------
  |  |  |  Branch (64:62): [Folded, False: 0]
  |  |  ------------------
  ------------------
  157|      0|	}
  158|  15.5k|	s->s_buf = newbuf;
  159|  15.5k|	s->s_size = newsize;
  160|  15.5k|	return (0);
  161|  15.5k|}
vsb.c:VSB_put_byte:
  264|  19.3M|{
  265|       |
  266|  19.3M|	assert_VSB_integrity(s);
  ------------------
  |  |  108|  19.3M|#define	assert_VSB_integrity(s) _assert_VSB_integrity(__func__, (s))
  ------------------
  267|  19.3M|	assert_VSB_state(s, 0);
  ------------------
  |  |  109|  19.3M|#define	assert_VSB_state(s, i)	 _assert_VSB_state(__func__, (s), (i))
  ------------------
  268|       |
  269|  19.3M|	if (s->s_error != 0)
  ------------------
  |  Branch (269:6): [True: 0, False: 19.3M]
  ------------------
  270|      0|		return;
  271|  19.3M|	_vsb_indent(s);
  272|  19.3M|	if (VSB_FREESPACE(s) <= 0) {
  ------------------
  |  |   58|  19.3M|#define	VSB_FREESPACE(s)	((s)->s_size - ((s)->s_len + 1L))
  ------------------
  |  Branch (272:6): [True: 12.1k, False: 19.3M]
  ------------------
  273|  12.1k|		if (VSB_extend(s, 1) < 0)
  ------------------
  |  Branch (273:7): [True: 0, False: 12.1k]
  ------------------
  274|      0|			s->s_error = ENOMEM;
  275|  12.1k|		if (s->s_error != 0)
  ------------------
  |  Branch (275:7): [True: 0, False: 12.1k]
  ------------------
  276|      0|			return;
  277|  12.1k|	}
  278|  19.3M|	s->s_buf[s->s_len++] = (char)c;
  279|  19.3M|}

