NDIS 6 hardware features that increases network performance

Windows 2003 / Vista / 2008 / 7 will detect if the network hardware has capabilities that allows it to offload the CPU.

Note Windows 2003 SP1 requires the Scalable Networking Pack to make use of these hardware features (Win2k3 R2 / SP2 has them by default). More Info MS KB936594

To see what features currently enabled on the computer:

netsh int tcp show global

More Info Microsoft - Scalable Networking Whitepapers
More Info MS Technet - Networking features in Vista / 2008
More Info The Cable Guy - Scalable Networking Pack
TCP Chimney Offload
TCP Chimney Offload is an extension of NDIS 5 offloading and makes it possible for a Network Interface Card (NIC) to "replace" the Windows TCP stack with its own implementation. When a TCP connection is created in Windows, then the TCP connection state is transfered to the NIC miniport driver (Offload Target), which when completely handles the traffic between the application and the remote host.

The NIC miniport driver provides a chimney that goes from the top to the bottom of the TCP stack, which promises to handle the network traffic (smoke) for the TCP connection. The chimney can decide for it self how to keep this promise, and Windows only need to handle the final data transfer to and from the chimney. There are Vents in the chimney, so Windows still can access and modify the TCP connection state (ex. if the applications closes or similar events).

TCP Chimney Offload improves the performance of long-lived connections with large-sized packet payloads, such as those associated with file server, backup and storage workloads and TCP-based multimedia streaming.

TCP Chimney Offload will automatically be disabled if one of the following features are turned on:
  • Windows Firewall (or any other 3rd party firewall)
  • Internet Connection Sharing
  • Internet Protocol security (IPsec)
  • Internet Protocol Network Address Translation (IPNAT)
Note to disable TCP Offload Engine (TOE):

netsh interface tcp set global chimney=disabled

[HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Services \Tcpip \Parameters]
EnableTCPChimney = 0

More Info WHDC - Scalable Networking with TCP Chimney
More Info Set chimney state for a particular application.
More Info MS KB951037
Receive-side Scaling
Enables use of multiple CPU's to handle the received packets, where the Network Interface Card (NIC) spreads the load to the available CPU's. Instead of using only a single CPU to to process all interrupts from the NIC with the following deferred procedure call (DPC) to process the received data.

Note the calculations needed to spread the load properly are so CPU intensive, that if they are done in software then it will be slower than not using RSS. The NIC should support the calculation in hardware.

Note older CPU's like the Intel Pentium 4 and Itanium doesn't support that the DPC is handled by another CPU than the one receiving the interrupt.

RSS should not be activated if one of the following features are turned on: Note to disable Receive-side Scaling (RSS):

netsh interface tcp set global rss=disabled

[HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Services \Tcpip \Parameters]
EnableRSS = 0

More Info WHDC - Scalable Networking with RSS
Network Direct Memory Access
NetDMA minimizes the amount of processing that a CPU must do to move packet contents between memory buffers. It requires special hardware like such as Intel I/O Acceleration Technology (Intel I/OAT) available with Intel Xeon processors to function.

NetDMA will not work together with "TCP Chimney Offload" and requires "Receive-side Scaling". Windows will choose NetDMA if it detects that both NetDMA and TCP Chimney Offload is supported.

NetDMA will automatically be disabled if one of the following features are turned on:
  • Windows Firewall (or any other 3rd party firewall)
  • Internet Connection Sharing
  • Internet Protocol security (IPsec)
  • Internet Protocol Network Address Translation (IPNAT)
Note to disable NetDMA:

[HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Services \Tcpip \Parameters]
EnableTCPA = 0

More Info MS KB947773
More Info MS KB951037

Direct Cache Access
NetDMA 2.0 (Windows 2008/7) adds support for Direct Cache Access (DCA), that allows the network data to move directly into the CPU cache, instead of the CPU have to spend cycles on retrieving it from the RAM.

Note to disable NetDCA:

netsh int tcp set global dca=disable

[HKEY_LOCAL_MACHINE \SYSTEM \CurrentControlSet \Services \Tcpip \Parameters]
EnableDCA = 0

Updated: 4 August 2014

Comments:

  1. BADJAG says:

    Thanks for this article. Explains the netsh TCP Global Parameters pretty well.

Leave a Reply

Your email address will not be published. Required fields are marked *