.Net Acceleration

Source: Developer.NET UPDATE [Developer_dotNET_UPDATE@lists.sqlmag.com]

Date: February 11, 2003

************************

1. ==== DEVELOPER .NET PERSPECTIVES ====

(contributed by Rodney Guzman, rodneyg@interknowlogy.com)

* .NET ACCELERATION

As software engineers, we're always searching for techniques to achieve better reliability, scalability, and performance. This search can be a struggle because we're often forced to use less-than-desirable tools and technologies to create software. (I don't know about you, but I never want to build another WinDNA

application.) Fortunately, when building Microsoft .NET software, you no longer need to be a master craftsman to maximize your applications'

performance: With .NET, that performance is more closely correlated to the hardware on which an application runs than to how you write the application's code. But even though .NET lets your software run faster on faster computers, the software must still contend for the same resources as all the other applications running on a server. After all, you can't expect your CPU to be stingy and give all its attention to your application. Or can you?

Your motherboard's CPU must remain application-agnostic and generic and must deal with all the mundane activities involved in simply keeping your server running. A function-specific accelerator board that offloads CPU--for example, Secure Sockets Layer (SSL) accelerators such as Hewlett-Packard's HP/Atalla AXL600L SSL Accelerator Card, which performs all SSL decryption algorithms, or graphics accelerator boards--can free up CPU so that it's free to perform other functions. (In a Web environment, for example, a system that uses an SSL accelerator can perform SSL-decrypting operations much more efficiently because of the hardware layer specifically designed and "hard-wired" for SSL processing.) But creating an accelerator board for every server task will take you only so far; after all, servers have a limited number of PCI slots. For a truly powerful platform, you need the ability to use the same accelerator board for many functions--even your custom applications.

Reprogrammable silicon has been in use for many years. Most application developers haven't come across this technology because it's typically been reserved for low-level hardware engineers. Additionally, the technology required a significant investment in time and money. You needed to experience debilitating performance problems before even considering this type of technology. Fortunately, newer techniques are available and don't require the services of a hardware engineer. For example, you can use higher-level languages to create software that can then be accelerated. Several companies are working on this type of solution, including an Intel spin-off company called Tarari. This company has been working closely with Microsoft to integrate hardware-acceleration technology into Microsoft server products and technologies. The possibilities have made Microsoft take notice of the hardware-acceleration industry.

The first question every application developer will ask is, "How much faster can my code run?" The answer isn't straightforward because it depends entirely on the operations that you're accelerating. Not every piece of code is suitable for acceleration. Under the correct conditions, you can experience more than a 100x performance improvement--that's 100 times faster than the code currently runs. Additionally, because the heavy algorithms run on a separate processor on the hardware accelerator, a system's CPU is free to perform other functions.

Why is acceleration important to .NET developers? Consider the possibilities if Microsoft makes the .NET Framework hardware-accelerator aware. By simply placing the hardware in your server, your applications would execute faster without requiring any custom code. For example, Microsoft could provide an accelerated XPath algorithm that would shred through XML documents. Every application that uses XPath could take advantage of the acceleration, causing a dramatic, rippling performance improvement throughout the system.

You might see new constructs in the .NET languages to handle hardware acceleration. For example, .NET developers are familiar with using the WebMethod attribute to signify that Microsoft IIS should expose a method as a Web service. Imagine being able to simply place an Accelerate attribute on a function to get better performance. Accelerated algorithms could be built automatically at compilation. On your development machine, you could run agents against a software-based acceleration simulator rather than a hardware accelerator. Of course, you'd still need to discover the recipe that would let each application and algorithm take best advantage of the technology.

Now that reprogrammable hardware-acceleration technology is being developed for the mainstream software developer, you can expect to see more and more examples of its use. As with SSL hardware accelerators, you won't even know that you're using an accelerator--only that you're experiencing an optimized technology. Fewer servers will be necessary to serve the same loads for your applications, and .NET server products and technologies will perform at levels we haven't yet conceived of.

************************

No Comments