Wednesday, October 11, 2006

Networking Myths: Software, ASICs, and Network Processors

Google managed to dig up a nice Vyatta reference over at Seeking Alpha: The Future of Network Processing Units Doesn't Look Too Rosy. This was an interesting article because it discusses the technological underpinnings of the networking market. What's the best way to get packets from place to place: software-only, network processors, or dedicated ASICs?

All of these approaches have been tried over the past few decades. I have been fortunate to have participated in the design cycles for some of the key products in the industry. I have worked on designs that have used all three approaches. The answer to the question varies at any given point in time because of technology forces at play in the market, and it depends on what you are trying to optimize for.

What has been interesting is watching the reaction to Vyatta in the market place. There are networking users out there that have been so schooled by vendor FUD that they don't believe a given product can do a particular job unless it's implemented with a given technology. With respect to Vyatta, this typically manifests itself in a statement such as, "Everybody knows that software routing can't do the job; Vendor XYZ has ASICs." It's as if some people believe routers must be implemented with ASICs or they somehow won't work.

Now, not to get too theoretical on you here, but let's talk through some of the issues. All network devices (all computers, actually) are simply big state machines. In response to external stimuli (networking packets in the case of networking devices), the machine jumps from state to state and produces output (switched packets, routing updates, etc.). The only difference between software, network processors, and ASICs is how that state machine is implemented and how quickly it runs.

The short rule in the industry is that if it can be implemented in software, it probably should be. If the functionality is at all complex, it is bound to have bugs that need to be fixed, or additional features to be added. Software gives you the ability to change things down the road.

ASICs are interesting for two reasons. First, they are sometimes more cost effective. You can build a machine to do a custom function with fewer logic gates that the millions and millions required to implement a general-purpose CPU. This is offset by higher design costs and lower volumes for specialized silicon, however. Second, dedicated logic can do things in parallel that software might have to implement with a serial design, thus improving performance. Dedicated hardware will be faster, in the abstract, than software running on a general-purpose processor. The question is, how fast is fast enough given all the other tradeoffs (cost, flexibility, etc.)?

Network processors and field-programmable gate arrays (FPGAs) offer an interesting middle ground. Network processors are CPUs tuned for performing networking tasks. While they are sometimes faster for very specific tasks, they achieve that speed by optimizing for a very specific task: network processing. It's very easy to push a network processor outside the sweet spot of its design target by adding new functionality. Once this occurs, the network processor is often slower than a general-purpose processor performing the same task. Network processors often have very low clock speeds, for instance (hundreds of MHz vs. GHz for x86 processors). They often have small instruction code memory or caches that are optimized for very small loops or very structured data sets. Finally, the costs for network processors is often on-par or even more expensive than a general-purpose CPU, since volumes are smaller and the market more specialized.

A good example here might be the old word processor market. When word processing first came on the scene, Wang made dedicated machines that performed the function. They were custom tuned to do word processing and word processing only. They did it well. And then they died when general-purpose PCs became cheap enough to do word processing and spreadsheets and presentation graphics and all the other things that people wanted to do on their desktops besides word processing that Wang's machines were unable to do.

FPGAs offer another interesting middle-ground. FPGAs allow dedicated hardware logic to be implemented in a chip that can be reprogrammed in the field. The reprogramming can be done whenever a bug is found or some additional functionality is desired. While these features are advantageous, there are still limits. Further, FPGAs are relatively expensive compared with ASICs, though they eliminate some of the up-front ASIC design expenses.

What's going to be interesting is watching Vyatta exploit all of these potential hardware avenues. What many of the early "Everybody knows that software routing can't do the job; Vendor XYZ has ASICs," comments miss is that:

  1. Software can do the job for a nice sweet spot in the market. Vyatta has demonstrated great price/performance characteristics in the T1 to 2 Gbps segment with its currently-available appliance. This is not to be taken lightly. While dedicated hardware is still advantageous in the low-end, for low cost, or the high-end, for performance, software routing works very well in the mid-range.
  2. Vyatta is not limited to running on standard x86 hardware. Vyatta can take advantage of standard CPUs, network processors, ASICs, and FPGAs. Which will we pick? Well, that depends on what we're trying to achieve and for which market segment.

If you have thoughts about these issues, we'd love to hear from you. Feel free to drop me a note directly or join our mailing lists. I'm "dave" at Vyatta.

7 Comments:

Anonymous Anonymous said...

>Network processors often have
>very low clock speeds, for
>instance (hundreds of MHz vs.
>GHz for x86 processors).

Intel's ixp28xx chips have microengines that run at 1.4Ghz, have 8 hw threads for very fast context switching when otherwise they would have stalled for memory accesses. In this way, processing can continue even though fetching data for a thread. x86 cannot do this. So you need lots of x86s to compete if you want parallel processing pipeline architectures. Multicore chips look interesting.

Tue Oct 17, 11:33:00 AM 2006  
Blogger Dave Roberts said...

Yup, it is true that some network processors do have higher clock speeds. Hardware threading on network processors is typically very different than multicore chips, however (more efficient at some level, typically with close coupling to the memory subsystem, but with limitations such as a single small, shared cache).

While this allows network processors to do more in parallel than your average x86 processor, the scope of tasks is still fairly restricted versus your average x86. As long as your required tasks fits within the constraints of a network processor, it will do a fine job. Ditto with ASICs or full general-purpose software processing. And that was basically the point of the original post.

Tue Oct 17, 11:41:00 AM 2006  
Blogger Karla said...

buy viagra
viagra online
generic viagra

Thu Jun 24, 07:34:00 AM 2010  
Blogger javieth said...

In addressing the router enables wireless networking connection, really amazing what Technology has changed these days. I like meeting new things. This is why i have come to this blog, I find it very interesting.This is like
costa rica investment opportunities really interesting too.

Thu Jul 29, 12:45:00 PM 2010  
Anonymous Honeywell Thermostats said...

you need lots of x86s to compete if you want parallel processing pipeline architectures. Multicore chips look interesting.
Honeywell Thermostats

Mon Mar 12, 04:14:00 AM 2012  
Anonymous Viagra said...

Thank you for clearing up these myths!

Thu Apr 05, 11:39:00 AM 2012  
Anonymous Anonymous said...

You should do a follow up article now that it is years later.

Tue Jul 24, 12:24:00 AM 2012  

Post a Comment

Links to this post:

Create a Link

<< Home