Changeset 20453 in vbox for trunk/src/VBox
- Timestamp:
- Jun 10, 2009 1:41:54 AM (16 years ago)
- Location:
- trunk/src/VBox/Devices/Network/slirp
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Network/slirp/counters.h
r20376 r20453 52 52 COUNTING_COUTER(IOWrite_rest_bytes, "SB IOWrite_rest_bytes"); 53 53 54 PROFILE_COUNTER(IOSBAppend_pf, "Profiling sbuf::append common"); 55 PROFILE_COUNTER(IOSBAppend_pf_wa, "Profiling sbuf::append all writen in network"); 56 PROFILE_COUNTER(IOSBAppend_pf_wf, "Profiling sbuf::append writen fault"); 57 PROFILE_COUNTER(IOSBAppend_pf_wp, "Profiling sbuf::append writen partly"); 54 58 COUNTING_COUTER(IOSBAppend, "SB: Append total"); 55 59 COUNTING_COUTER(IOSBAppend_wa, "SB: Append all is written to network "); … … 62 66 COUNTING_COUTER(IOSBAppendSB_w_ge_r, "SB: AppendSB (sb_wptr >= sb_rptr)"); 63 67 COUNTING_COUTER(IOSBAppendSB_w_alter, "SB: AppendSB (altering of sb_wptr)"); 68 69 PROFILE_COUNTER(TCP_reassamble, "TCP::reasamble"); 70 PROFILE_COUNTER(TCP_input, "TCP::input"); -
trunk/src/VBox/Devices/Network/slirp/sbuf.c
r20377 r20453 78 78 int ret = 0; 79 79 80 SLIRP_PROFILE_START(IOSBAppend_pf, a); 80 81 DEBUG_CALL("sbappend"); 81 82 DEBUG_ARG("so = %lx", (long)so); … … 127 128 */ 128 129 sbappendsb(pData, &so->so_rcv, m); 130 SLIRP_PROFILE_STOP(IOSBAppend_pf_wf, a); 129 131 goto done; 130 132 } … … 139 141 m->m_data += ret; 140 142 sbappendsb(pData, &so->so_rcv, m); 143 SLIRP_PROFILE_STOP(IOSBAppend_pf_wp, a); 141 144 goto done; 142 145 } /* else */ 143 146 /* Whatever happened, we free the mbuf */ 144 147 SLIRP_COUNTER_INC(IOSBAppend_wa); 148 SLIRP_PROFILE_STOP(IOSBAppend_pf_wa, a); 145 149 done: 146 150 m_free(pData, m); -
trunk/src/VBox/Devices/Network/slirp/tcp_input.c
r20377 r20453 79 79 struct socket *so = tp->t_socket; 80 80 int flags; 81 SLIRP_PROFILE_START(TCP_reassamble, tcp_reassamble); 81 82 82 83 /* … … 108 109 m_freem(pData, m); 109 110 *tlenp = 0; 111 SLIRP_PROFILE_STOP(TCP_reassamble, tcp_reassamble); 110 112 return (0); 111 113 } … … 121 123 m_freem(pData, m); 122 124 *tlenp = 0; 125 SLIRP_PROFILE_STOP(TCP_reassamble, tcp_reassamble); 123 126 return (0); 124 127 } … … 218 221 */ 219 222 if (!TCPS_HAVEESTABLISHED(tp->t_state)) 223 { 224 SLIRP_PROFILE_STOP(TCP_reassamble, tcp_reassamble); 220 225 return (0); 226 } 221 227 q = LIST_FIRST(&tp->t_segq); 222 228 if (!q || q->tqe_th->th_seq != tp->rcv_nxt) 229 { 230 SLIRP_PROFILE_STOP(TCP_reassamble, tcp_reassamble); 223 231 return (0); 232 } 224 233 do 225 234 { … … 250 259 while (q && q->tqe_th->th_seq == tp->rcv_nxt); 251 260 261 SLIRP_PROFILE_STOP(TCP_reassamble, tcp_reassamble); 252 262 return flags; 253 263 } … … 273 283 u_long tiwin; 274 284 /* int ts_present = 0; */ 285 SLIRP_PROFILE_START(TCP_input, counter_input); 275 286 276 287 DEBUG_CALL("tcp_input"); … … 303 314 /* mbuf should be cleared in sofree called from tcp_close */ 304 315 tcp_close(pData, tp); 316 SLIRP_PROFILE_STOP(TCP_input, counter_input); 305 317 return; 306 318 } … … 637 649 638 650 SOCKET_UNLOCK(so); 651 SLIRP_PROFILE_STOP(TCP_input, counter_input); 639 652 return; 640 653 } … … 682 695 tcp_output(pData, tp); 683 696 SOCKET_UNLOCK(so); 697 SLIRP_PROFILE_STOP(TCP_input, counter_input); 684 698 return; 685 699 } … … 781 795 } 782 796 SOCKET_UNLOCK(so); 797 SLIRP_PROFILE_STOP(TCP_input, counter_input); 783 798 return; 784 799 … … 1607 1622 1608 1623 SOCKET_UNLOCK(so); 1624 SLIRP_PROFILE_STOP(TCP_input, counter_input); 1609 1625 return; 1610 1626 … … 1621 1637 (void) tcp_output(pData, tp); 1622 1638 SOCKET_UNLOCK(so); 1639 SLIRP_PROFILE_STOP(TCP_input, counter_input); 1623 1640 return; 1624 1641 … … 1636 1653 if (so != &tcb) 1637 1654 SOCKET_UNLOCK(so); 1655 SLIRP_PROFILE_STOP(TCP_input, counter_input); 1638 1656 return; 1639 1657 … … 1651 1669 #endif 1652 1670 1671 SLIRP_PROFILE_STOP(TCP_input, counter_input); 1653 1672 return; 1654 1673 }
Note:
See TracChangeset
for help on using the changeset viewer.