Technology Review - Published By MIT
Advertisement
[1] 2 Next »

April 2003

Writing Software Right

Companies invest in programs that banish bugs.

By Wade Roush

smaller text tool iconmedium text tool iconlarger text tool icon

Much of today's software is built and updated in a slapdash process. Programmers give life to cool new features in quick-and-dirty code, throw the code at a computer to see whether the program runs, and excise the worst bugs, one by one, until the program works well enough to release.

Naturally, many errors evade this kind of testing, and those that remain can create both minor annoyances and such major inconveniences as late January's worldwide Internet slowdown, the work of a self-replicating "worm" called Slammer that exploited a programming flaw in Microsoft's SQL Server software.

That laissez-faire design philosophy is coming under fire. Sun Microsystems, Microsoft, and IBM are all plotting ways to revolutionize the practice of software engineering. Although their strategies differ, the efforts are all geared toward saving time, reducing development costs, sparing programmers the more mind-numbing aspects of software debugging, and-most important for consumers and business users-producing software that works well the first time it's released.

"Our challenge is to get our software to the point that people expect it to work instead of expecting it to fail," says Jim Larus, leader of a software quality project at Microsoft Research in Redmond, WA.

One of the most radical attempts at improving software is under way at Sun Microsystems Laboratories in Santa Clara, CA. Code-named Jackpot, the project aims to overhaul the software-writing tools that have been created by Sun and many other software companies over the past 20 years. Most of these desktop programs comprise an editor to write and manipulate computer code; a debugger to search for the most common types of programming errors; and a compiler to translate programmers' computer code into the ones and zeroes that machines can act upon. The problem is that although these tools are good at finding such errors as misplaced punctuation, they can't see larger structural problems that make code inefficient, says Michael Van De Vanter, who runs the Jackpot group at Sun Laboratories.

The solution: software that thinks about other software. Van De Vanter's team is building an "analysis engine" that reads a programmer's code and constructs an internal abstract model of the software. The group contends that such models will give programmers substantive real-time feedback as they work.

For example, the Jackpot team wants to provide programmers with a kind of meter that continually gauges a program's complexity-a step beyond the primitive measures, such as the number of lines in a program, provided by today's development tools. The analysis engine would detect whether complexity was getting out of hand-creating lots of hiding places for bugs-and would give programmers "an early warning," says Van De Vanter.

Helping programmers visualize their code is another way to battle complexity, he says. It's easy for software writers to nest instructions such as "if x, then y, else z" within other similar clauses-ad infinitum. But "there is a lot of psychological work showing that if they are nested too deep, people won't get it anymore," Van De Vanter says. The visual tools his team is developing would draw on the analysis engine to transform nested structures into easy-to-understand tables, maps, and highlighted text.

In addition, the Jackpot researchers are designing a debugger that doesn't simply find errors in programming syntax-a missing semicolon in a line of Java code, for example-but also identifies general instances of good or bad programming. "People tend to write code in predictable ways: the analogy in natural language is idiom," Van De Vanter explains. "We want something that will monitor for bad idioms." Widespread implementation of Jackpot at Sun is "several years out," he says, but the researchers plan to test it soon with Sun programmers.

[1] 2 Next »
April 2003

Would you like to read more articles from the April 2003 issue?

This article is from the April 2003 Issue of Technology Review. To read other articles from this issue simply register for My.TechnologyReview.com. It's free.

Subscribe today and save up to 41% »

Comments

Advertisement

Current Issue

Technology Review November/December 2008
Sun + Water = Fuel
An MIT chemist has opened the way to making hydrogen fuel from water using sunlight.
•  Subscribe
Save 41%
•  Table of Contents
•  MIT News

Magazine Services

Career Resources

MIT Technology Insider

Stories and breaking news from inside MIT about the latest research, innovations, and startups--in a convenient monthly e-newsletter. Subscribe today
Advertisement

Follow us on Twitter

Twitter

Get Technology Review updates via the web, cellphone, or Instant Messager – Follow techreview on Twitter!

Advertisement

More Technology News from Forbes

Advertisement
Advertisement
TECHNOLOGY RESOURCES
Advertisement
MIT Massachusetts Institute of Technology