- 論壇徽章:
- 0
|
回復 147# 冬瓜頭
冬瓜頭 發(fā)表于 2014-05-20 08:53 ![]()
關于tcpip運行在host內(nèi)核還是運行在芯片firmware里更快的問題。個人膚淺理解,還請廖博指正,這也是一直以來 ...
看來還是逃不脫對這個問題展開討論。
我們看看Wikipedia 怎么說:
TCP is a complex protocol. However, while significant enhancements have been made and proposed over the years, its most basic operation has not changed significantly since its first specification RFC 675 in 1974, and the v4 specification RFC 793, published in September 1981. RFC 1122, Host Requirements for Internet Hosts, clarified a number of TCP protocol implementation requirements. RFC 2581, TCP Congestion Control, one of the most important TCP-related RFCs in recent years, describes updated algorithms that avoid undue congestion. In 2001, RFC 3168 was written to describe explicit congestion notification (ECN), a congestion avoidance signaling mechanism.
The original TCP congestion avoidance algorithm was known as "TCP Tahoe", but many alternative algorithms have since been proposed (including TCP Reno, TCP Vegas, FAST TCP, TCP New Reno, and TCP Hybla).
TCP Interactive (iTCP) [28] is a research effort into TCP extensions that allows applications to subscribe to TCP events and register handler components that can launch applications for various purposes, including application-assisted congestion control.
Multipath TCP (MPTCP) [29][30] is an ongoing effort within the IETF that aims at allowing a TCP connection to use multiple paths to maximise resource usage and increase redundancy. The redundancy offered by Multipath TCP in the context of wireless networks [31]enables statistical multiplexing of resources, and thus increases TCP throughput dramatically. Multipath TCP also brings performance benefits in datacenter environments.[32] The reference implementation[33] of Multipath TCP is being developed in the Linux kernel.[34][35]
TCP Cookie Transactions (TCPCT) is an extension proposed in December 2009 to secure servers against denial-of-service attacks. Unlike SYN cookies, TCPCT does not conflict with other TCP extensions such as window scaling. TCPCT was designed due to necessities of DNSSEC, where servers have to handle large numbers of short-lived TCP connections.
tcpcrypt is an extension proposed in July 2010 to provide transport-level encryption directly in TCP itself. It is designed to work transparently and not require any configuration. Unlike TLS (SSL), tcpcrypt itself does not provide authentication, but provides simple primitives down to the application to do that. As of 2010, the first tcpcrypt IETF draft has been published and implementations exist for several major platforms.
TCP Fast Open is an extension to speed up the opening of successive TCP connections between two endpoints. It works by skipping the three-way handshake using a cryptographic "cookie". It is similar to an earlier proposal called T/TCP, which was not widely adopted due to security issues.[36] As of July 2012, it is an IETF Internet draft.[37]
Hardware implementations[edit]
One way to overcome the processing power requirements of TCP is to build hardware implementations of it, widely known as TCP Offload Engines (TOE). The main problem of TOEs is that they are hard to integrate into computing systems, requiring extensive changes in the operating system of the computer or device. One company to develop such a device was Alacritech.
我發(fā)表些謬論供大家參考:
1) TCP 沒有一個正則(formal)的單一規(guī)范(即以形式語言,或狀態(tài)機表述)。而是一系列的自然語言的描述文本,有些描述屬于需求性的描述而非行為性描述。因此最接近正則描述的就是廣為人接受的Linux Kernel中的源代碼。由于缺乏正則性描述,而又有諸多需求復雜性,因此,具體實現(xiàn)就成了規(guī)范,當然,也就帶來了依賴于具體實現(xiàn)的性能局限和開銷。比如,恐怕沒有人能回答這個問題:TCP單一連接,可否以1Tbps的速率傳送數(shù)據(jù)?因為相關的因素太多,連接的長度?網(wǎng)絡延遲, 每一步驟所需的跳變世界,包長?數(shù)據(jù)長度? ACK的到達時間,是否在不同階段丟包?
2) TCP在協(xié)議棧中所處的核心地位,對上,對下,都耦合了大量其它協(xié)議,這些協(xié)議是不同的軟件模塊,因此很難把它單獨提取出來硬化。
3) TCP的核心地位,直接影響系統(tǒng)穩(wěn)定性,兼容性,還直接影響網(wǎng)絡協(xié)議棧上層和下層的今后發(fā)展的耦合關系。因此, Linus要牢牢把握住Kernel 軟件對它的絕對掌控,是考慮到這些大局的長遠因素。
結(jié)論:TCP不能完全硬件化,單一線程TCP的通信速度是不能無限提速的,協(xié)議本身已經(jīng)成為性能瓶頸。想突破這個瓶頸,必須另辟蹊徑。
|
|