Lines Matching refs:tlen
738 int tlen = compile_length_tree(qn->target, reg); in compile_length_quantifier_node() local
740 if (tlen < 0) return tlen; in compile_length_quantifier_node()
750 return SIZE_OP_ANYCHAR_STAR_PEEK_NEXT + tlen * qn->lower + cklen; in compile_length_quantifier_node()
752 return SIZE_OP_ANYCHAR_STAR + tlen * qn->lower + cklen; in compile_length_quantifier_node()
757 mod_tlen = tlen + (SIZE_OP_NULL_CHECK_START + SIZE_OP_NULL_CHECK_END); in compile_length_quantifier_node()
759 mod_tlen = tlen; in compile_length_quantifier_node()
781 len = SIZE_OP_JUMP + tlen; in compile_length_quantifier_node()
788 len = SIZE_OP_STATE_CHECK_PUSH + tlen; in compile_length_quantifier_node()
791 len = SIZE_OP_PUSH + tlen; in compile_length_quantifier_node()
795 len = tlen; in compile_length_quantifier_node()
799 len = SIZE_OP_PUSH + cklen + SIZE_OP_JUMP + tlen; in compile_length_quantifier_node()
818 int tlen = compile_length_tree(qn->target, reg); in compile_quantifier_node() local
820 if (tlen < 0) return tlen; in compile_quantifier_node()
860 mod_tlen = tlen + (SIZE_OP_NULL_CHECK_START + SIZE_OP_NULL_CHECK_END); in compile_quantifier_node()
862 mod_tlen = tlen; in compile_quantifier_node()
910 r = add_opcode_rel_addr(reg, OP_JUMP, tlen); in compile_quantifier_node()
924 r = add_rel_addr(reg, tlen); in compile_quantifier_node()
927 r = add_opcode_rel_addr(reg, OP_PUSH, tlen); in compile_quantifier_node()
947 r = add_opcode_rel_addr(reg, OP_JUMP, tlen); in compile_quantifier_node()
971 int tlen = compile_length_tree(qn->target, reg); in compile_length_quantifier_node() local
973 if (tlen < 0) return tlen; in compile_length_quantifier_node()
979 return SIZE_OP_ANYCHAR_STAR_PEEK_NEXT + tlen * qn->lower; in compile_length_quantifier_node()
981 return SIZE_OP_ANYCHAR_STAR + tlen * qn->lower; in compile_length_quantifier_node()
986 mod_tlen = tlen + (SIZE_OP_NULL_CHECK_START + SIZE_OP_NULL_CHECK_END); in compile_length_quantifier_node()
988 mod_tlen = tlen; in compile_length_quantifier_node()
991 (qn->lower <= 1 || tlen * qn->lower <= QUANTIFIER_EXPAND_LIMIT_SIZE)) { in compile_length_quantifier_node()
992 if (qn->lower == 1 && tlen > QUANTIFIER_EXPAND_LIMIT_SIZE) { in compile_length_quantifier_node()
996 len = tlen * qn->lower; in compile_length_quantifier_node()
1011 len = SIZE_OP_JUMP + tlen; in compile_length_quantifier_node()
1014 (qn->upper == 1 || (tlen + SIZE_OP_PUSH) * qn->upper in compile_length_quantifier_node()
1016 len = tlen * qn->lower; in compile_length_quantifier_node()
1017 len += (SIZE_OP_PUSH + tlen) * (qn->upper - qn->lower); in compile_length_quantifier_node()
1020 len = SIZE_OP_PUSH + SIZE_OP_JUMP + tlen; in compile_length_quantifier_node()
1036 int tlen = compile_length_tree(qn->target, reg); in compile_quantifier_node() local
1038 if (tlen < 0) return tlen; in compile_quantifier_node()
1060 mod_tlen = tlen + (SIZE_OP_NULL_CHECK_START + SIZE_OP_NULL_CHECK_END); in compile_quantifier_node()
1062 mod_tlen = tlen; in compile_quantifier_node()
1065 (qn->lower <= 1 || tlen * qn->lower <= QUANTIFIER_EXPAND_LIMIT_SIZE)) { in compile_quantifier_node()
1066 if (qn->lower == 1 && tlen > QUANTIFIER_EXPAND_LIMIT_SIZE) { in compile_quantifier_node()
1124 r = add_opcode_rel_addr(reg, OP_JUMP, tlen); in compile_quantifier_node()
1129 (qn->upper == 1 || (tlen + SIZE_OP_PUSH) * qn->upper in compile_quantifier_node()
1138 (n - i) * tlen + (n - i - 1) * SIZE_OP_PUSH); in compile_quantifier_node()
1147 r = add_opcode_rel_addr(reg, OP_JUMP, tlen); in compile_quantifier_node()
1161 int tlen; in compile_length_option_node() local
1165 tlen = compile_length_tree(node->target, reg); in compile_length_option_node()
1168 if (tlen < 0) return tlen; in compile_length_option_node()
1172 + tlen + SIZE_OP_SET_OPTION; in compile_length_option_node()
1175 return tlen; in compile_length_option_node()
1208 int tlen; in compile_length_enclose_node() local
1214 tlen = compile_length_tree(node->target, reg); in compile_length_enclose_node()
1215 if (tlen < 0) return tlen; in compile_length_enclose_node()
1218 tlen = 0; in compile_length_enclose_node()
1224 len = SIZE_OP_MEMORY_START_PUSH + tlen in compile_length_enclose_node()
1235 len += tlen + (BIT_STATUS_AT(reg->bt_mem_end, node->regnum) in compile_length_enclose_node()
1246 len += tlen + (BIT_STATUS_AT(reg->bt_mem_end, node->regnum) in compile_length_enclose_node()
1254 tlen = compile_length_tree(qn->target, reg); in compile_length_enclose_node()
1255 if (tlen < 0) return tlen; in compile_length_enclose_node()
1257 len = tlen * qn->lower in compile_length_enclose_node()
1258 + SIZE_OP_PUSH + tlen + SIZE_OP_POP + SIZE_OP_JUMP; in compile_length_enclose_node()
1261 len = SIZE_OP_PUSH_STOP_BT + tlen + SIZE_OP_POP_STOP_BT; in compile_length_enclose_node()
1388 int tlen = 0; in compile_length_anchor_node() local
1391 tlen = compile_length_tree(node->target, reg); in compile_length_anchor_node()
1392 if (tlen < 0) return tlen; in compile_length_anchor_node()
1397 len = SIZE_OP_PUSH_POS + tlen + SIZE_OP_POP_POS; in compile_length_anchor_node()
1400 len = SIZE_OP_PUSH_POS_NOT + tlen + SIZE_OP_FAIL_POS; in compile_length_anchor_node()
1403 len = SIZE_OP_LOOK_BEHIND + tlen; in compile_length_anchor_node()
1406 len = SIZE_OP_PUSH_LOOK_BEHIND_NOT + tlen + SIZE_OP_FAIL_LOOK_BEHIND_NOT; in compile_length_anchor_node()
2060 int tlen; in get_char_length_tree1() local
2068 r = get_char_length_tree1(NCAR(node), reg, &tlen, level); in get_char_length_tree1()
2070 *len = distance_add(*len, tlen); in get_char_length_tree1()
2079 r = get_char_length_tree1(NCAR(node), reg, &tlen, level); in get_char_length_tree1()
2083 if (tlen != tlen2) in get_char_length_tree1()
2095 *len = tlen; in get_char_length_tree1()
2115 r = get_char_length_tree1(qn->target, reg, &tlen, level); in get_char_length_tree1()
2117 *len = distance_multiply(tlen, qn->lower); in get_char_length_tree1()