Home
last modified time | relevance | path

Searched refs:__builtin_expect (Results 1 – 25 of 35) sorted by relevance

12

/lighttpd1.4/src/
H A Drequest.c78 if (__builtin_expect( (s[i] == 127), 0)) in __attribute_nonnull__()
88 if (__builtin_expect( (s[i] == '\0'), 0)) return s+i; in __attribute_nonnull__()
89 if (__builtin_expect( (s[i] == '\r'), 0)) return s+i; in __attribute_nonnull__()
90 if (__builtin_expect( (s[i] == '\n'), 0)) return s+i; in __attribute_nonnull__()
115 if (__builtin_expect( (0 == hlen), 0)) return -1; in request_check_hostname()
116 if (__builtin_expect( (h[hlen-1] == '.'), 0)) { in request_check_hostname()
787 if (__builtin_expect( (*v <= 0x20), 0)) { in http_request_parse_header()
801 if (__builtin_expect( (j != klen), 0)) { in http_request_parse_header()
1223 if (__builtin_expect( (r->http_host != NULL), 1)) { in http_request_parse()
1340 if (__builtin_expect( (0 != r->http_status), 0)) { in http_request_headers_process()
[all …]
H A Dhttp-header-glue.c321 if (__builtin_expect( (NULL == sce), 0) in http_response_send_file()
340 if (__builtin_expect( (!r->conf.follow_symlink), 0) in http_response_send_file()
353 if (__builtin_expect( (!S_ISREG(sce->st.st_mode)), 0)) { in http_response_send_file()
369 if (__builtin_expect( (!content_type), 0) in http_response_send_file()
382 if (__builtin_expect( (allow_caching), 1)) { in http_response_send_file()
774 if (__builtin_expect( (n >= 0), 1)) { in http_response_append_splice()
827 if (__builtin_expect( (0 != rc), 0)) in http_response_transfer_cqlen()
1226 if (__builtin_expect( (0 != rc), 0)) in http_response_parse_headers()
1251 if (__builtin_expect( (rc > 0), 1)) in http_response_read()
1363 if (__builtin_expect( (0 != rc), 0)) { in http_response_read()
[all …]
H A Dresponse.c96 if (__builtin_expect( (0 == r->conf.max_keep_alive_idle), 0) in http_response_write_header()
142 if (__builtin_expect( (0 == klen), 0)) continue; in http_response_write_header()
143 if (__builtin_expect( (0 == vlen), 0)) continue; in http_response_write_header()
164 if (__builtin_expect ( (tlast != cur_ts), 0)) in http_response_write_header()
218 if (__builtin_expect( (sce != NULL), 1)) { in http_response_physical_path_check()
367 if (__builtin_expect( (!r->conf.allow_http11), 0) in http_response_config()
374 if (__builtin_expect( (r->reqbody_length > 0), 0) in http_response_config()
403 if (__builtin_expect( (!r->async_callback), 1)) { in http_response_prepare()
551 if (__builtin_expect( (NULL == r->handler_module), 0)) { in http_response_prepare()
553 if (__builtin_expect( (0 == r->http_status), 0)) { in http_response_prepare()
[all …]
H A Dbuffer.c163 if (__builtin_expect( (NULL == s), 0)) s = ""; in buffer_copy_string()
178 if (__builtin_expect( (NULL == s), 0)) s = ""; in buffer_append_string()
328 if (__builtin_expect( (NULL == tm), 0)) return; in buffer_append_strftime()
336 if (__builtin_expect( (0 == rv), 0) || __builtin_expect( (rv > 63), 0)) { in buffer_append_strftime()
666 if (__builtin_expect( (*ds >= ' ' && *ds <= '~'), 1)) in buffer_append_string_c_escaped()
690 if (__builtin_expect( (*ds >= ' ' && *ds <= '~'), 1)) in buffer_append_string_c_escaped()
898 if (__builtin_expect( (buffer_is_blank(b)), 0)) { in buffer_path_simplify()
913 if (__builtin_expect( (*walk == '/'), 1)) { in buffer_path_simplify()
921 if (__builtin_expect( (walk == end), 1)) { in buffer_path_simplify()
942 if (__builtin_expect( (walk[0] == '/'), 0)) { in buffer_path_simplify()
[all …]
H A Dchunk.c635 if (__builtin_expect( (len > 0), 1)) { in chunkqueue_use_memory()
709 if (__builtin_expect( (NULL == c), 0)) break; in chunkqueue_steal()
718 if (__builtin_expect( (0 != clen), 1)) { in chunkqueue_steal()
1003 if (__builtin_expect( (wr < dlen), 0)) in chunkqueue_append_cqmem_to_tempfile()
1155 if (__builtin_expect( (wr <= 0), 0)) in chunkqueue_append_splice_sock_tempfile()
1174 if (__builtin_expect( (NULL == c), 0)) break; in chunkqueue_steal_with_tempfiles()
1180 if (__builtin_expect( (clen < 0), 0)) return -1; in chunkqueue_steal_with_tempfiles()
1522 if (__builtin_expect( (0 == len), 1)) in chunkqueue_small_resp_optim()
1568 if (__builtin_expect( (0 == have), 0)) in chunkqueue_peek_data()
1583 if (__builtin_expect( (0 == len), 0)) in chunkqueue_peek_data()
[all …]
H A Dfirst.h174 #ifndef __builtin_expect
175 #if !__has_builtin(__builtin_expect) \
177 #define __builtin_expect(x,y) (x) macro
H A Dhttp_header.c99 if (__builtin_expect( (slen < sizeof(http_headers_off)), 1)) { in http_header_hkey_get()
104 if (__builtin_expect( (i != -1), 1)) { in http_header_hkey_get()
106 if (__builtin_expect( (c != kv->value[0]), 1)) in http_header_hkey_get()
120 if (__builtin_expect( (slen < sizeof(http_headers_off)), 1)) { in http_header_hkey_get_lc()
124 if (__builtin_expect( (i != -1), 1)) { in http_header_hkey_get_lc()
126 if (__builtin_expect( (c != kv->value[0]), 1)) in http_header_hkey_get_lc()
H A Dhttp_kv.c211 if (__builtin_expect( (0 != kv->vlen), 1)) in http_status_append()
221 if (__builtin_expect( (0 != kv->vlen), 1)) in http_version_append()
H A Dlog.c92 if (__builtin_expect( (0 == count), 1)) in write_all()
123 if (__builtin_expect( (tlast != ts.tv_sec), 0)) in __attribute_nonnull__()
133 if (__builtin_expect( (tlast != log_epoch_secs), 0)) { in __attribute_nonnull__()
H A Dconfigfile-glue.c523 if (__builtin_expect( (buffer_is_empty(l)), 0)) in config_check_cond_nocache_eval()
670 if (__builtin_expect( (0 == dc->capture_idx), 1)) in config_pcre_match()
678 if (__builtin_expect( (NULL == match_data), 0)) { in config_pcre_match()
704 if (__builtin_expect( (0 == dc->capture_idx), 1)) { in config_pcre_match()
713 if (__builtin_expect( (NULL == cond_match->matches), 0)) { in config_pcre_match()
H A Dnetwork_write.c384 if (__builtin_expect( (*p_max_bytes <= 0), 0)) return -3; in network_write_file_chunk_sendfile()
427 if (__builtin_expect( (0 != rc), 0)) return (-3 == rc) ? 0 : rc; in network_write_chunkqueue_writev()
457 if (__builtin_expect( (0 != rc), 0)) return (-3 == rc) ? 0 : rc; in network_write_chunkqueue_sendfile()
H A Dmod_cgi.c536 else if (__builtin_expect( (r->h2_connect_ext != 0), 0) in cgi_response_headers()
656 if (__builtin_expect( (env->osize == env->oused), 0)) in cgi_env_add()
888 if (__builtin_expect( (env->osize == env->oused), 0)) in cgi_create_env()
1009 if (__builtin_expect( (r->h2_connect_ext != 0), 0) && !p->conf.upgrade) { in URIHANDLER_FUNC()
1031 if (__builtin_expect( (r->h2_connect_ext != 0), 0)) { in URIHANDLER_FUNC()
1076 if (__builtin_expect( in SUBREQUEST_FUNC()
H A Dburl.c70 if (__builtin_expect( (s[i] == '?'), 0) && -1 == qs) qs = j; in burl_normalize_basic_unreserved_fix()
107 if (__builtin_expect( (s[i] == '?'), 0) && -1 == qs) qs = i; in burl_normalize_basic_unreserved()
143 if (__builtin_expect( (s[i] == '?'), 0)) qs = j; in burl_normalize_basic_required_fix()
H A Dh2.c1121 if (__builtin_expect( (n >= 0), 1)) /*(force wupd below w/ +16384)*/ in h2_recv_data()
1421 if (__builtin_expect( (rc == LSHPACK_OK), 1)) { in h2_parse_headers_frame()
1435 if (__builtin_expect( (0 != http_status), 0)) { in h2_parse_headers_frame()
1608 if (__builtin_expect( (trailers), 0)) in h2_recv_headers()
1686 if (__builtin_expect( (400 == r->http_status), 0)) { in h2_recv_headers()
2157 if (__builtin_expect( (200 == r->http_status), 1)) { in h2_send_headers()
2196 if (__builtin_expect( (0 == klen), 0)) continue; in h2_send_headers()
2197 if (__builtin_expect( (0 == vlen), 0)) continue; in h2_send_headers()
2215 __builtin_expect( (buffer_string_space(&ds->value) >= klen), 1) in h2_send_headers()
2218 if (__builtin_expect( (ds->ext != HTTP_HEADER_OTHER), 1)) { in h2_send_headers()
[all …]
H A Dbase64.c53 if (__builtin_expect( (ch < 0), 0)) { in li_base64_dec()
H A Dconnections.c671 if (__builtin_expect( (c->offset > USHRT_MAX), 0)) /*(highly unlikely)*/ in connection_handle_read_state()
693 if (__builtin_expect( (0 != header_len), 1)) { in connection_handle_read_state()
694 if (__builtin_expect( (hoff[0] > 1), 1)) in connection_handle_read_state()
1242 if (__builtin_expect((!chunkqueue_is_empty(&r->write_queue)), 1) in connection_state_machine_h2()
1266 if (__builtin_expect( (r->conf.log_state_handling), 0)) in connection_state_machine_h2()
H A Dmod_auth.c1153 if (__builtin_expect( (ae->ulen <= sizeof(ai->userbuf)), 1)) { in mod_auth_digest_get()
1251 if (__builtin_expect( (*c != '='), 0)) { in mod_auth_digest_parse_authorization()
1518 if (__builtin_expect( (HANDLER_GO_ON != rc), 0)) in mod_auth_check_digest()
1522 if (__builtin_expect( (HANDLER_GO_ON != rc), 0)) in mod_auth_check_digest()
1526 if (__builtin_expect( (HANDLER_GO_ON != rc), 0)) in mod_auth_check_digest()
H A Dhttp_date.c273 return (__builtin_expect( (NULL != gmtime64_r(&t, &tm)), 1)) in http_date_time_to_str()
H A Dmod_magnet.c1065 while (__builtin_expect( (*s != '\\'), 1) && ++s < end) ; in magnet_buffer_append_bsdec()
1099 if (__builtin_expect( (s[1] != '0'), 0) in magnet_buffer_append_bsdec()
1100 || __builtin_expect( (s[2] != '0'), 0)) { in magnet_buffer_append_bsdec()
1111 if (__builtin_expect( (c > 0x7F), 0)) { in magnet_buffer_append_bsdec()
1458 if (__builtin_expect( (*s == '"'), 1)) in magnet_push_quoted_string_range()
2181 if (__builtin_expect( (lua_isnil(L, 3)), 0)) { in magnet_envvar_set()
3213 if (__builtin_expect( (lua_gettop(L) != lighty_table_ndx), 0)) { in magnet_attract()
H A Dmod_proxy.c899 if (__builtin_expect( (hctx->conf.header.force_http10), 0)) in proxy_create_env()
920 if (__builtin_expect( ('p' == (ds->key.ptr[0] | 0x20)), 0)) { in proxy_create_env()
1083 else if (__builtin_expect( (r->h2_connect_ext != 0), 0) in proxy_response_headers()
H A Darray.c351 if (__builtin_expect( (prev != NULL), 0)) in array_insert_data_at_pos()
364 if (__builtin_expect( (ndx), 1)) in array_insert_data_at_pos()
H A Dmod_dirlisting.c1088 if (__builtin_expect( (p->jcomma), 1))/*(to avoid excess comma)*/ in http_read_directory()
1276 if (__builtin_expect( (write_all(hctx->jfd, BUF_PTR_LEN(jb)) < 0), 0)) { in mod_dirlisting_json_append()
1537 if (__builtin_expect( (wr > 0), 1)) in mod_dirlisting_write_cq()
H A Dconfigfile.c1310 if (__builtin_expect( (srv->config_captures != 0), 0)) { in config_finalize()
1314 if (__builtin_expect( (0 == dc->capture_idx), 1)) in config_finalize()
1350 if (__builtin_expect( (NULL == srv->match_data), 0)) { in config_finalize()
2140 if (__builtin_expect( (ret <= 0), 0)) in config_parse()
2184 if (__builtin_expect( (avail < 1024), 0)) { in config_parse_stdin()
H A Dmod_mbedtls.c2046 if (__builtin_expect( (0 != hctx->close_notify), 0)) in connection_write_cq_ssl()
2061 if (__builtin_expect( (0 == data_len), 0)) { in connection_write_cq_ssl()
2252 if (__builtin_expect( (0 != hctx->close_notify), 0)) in connection_read_cq_ssl()
2617 if (__builtin_expect( (NULL == ciphersuite_info), 0)) return; in http_cgi_ssl_env()
2635 if (__builtin_expect( (NULL == cipher_info), 0)) return; in http_cgi_ssl_env()
H A Dmod_openssl.c3037 if (__builtin_expect( (0 != hctx->close_notify), 0)) in connection_write_cq_ssl()
3048 if (__builtin_expect( (0 == data_len), 0)) { in connection_write_cq_ssl()
3065 if (__builtin_expect( (hctx->renegotiations > 1), 0)) { in connection_write_cq_ssl()
3090 if (__builtin_expect( (0 != hctx->close_notify), 0)) in connection_write_cq_ssl_ktls()
3132 if (__builtin_expect( (0 != hctx->close_notify), 0)) in connection_read_cq_ssl()

12