Blog Post

NASA scrubbed Mars Rover code clean — over and over

Stay on Top of Enterprise Technology Trends

Get updates impacting your industry from our GigaOm Research Community
Join the Community!

More than 2 million lines of software code drove NASA’s successful Rover Curiosity landing on Mars. And, for the last two years, every single line was analyzed and scrubbed by static analysis products from Coverity, Grammatech, Semmle, and Uno.

Engineers at NASA’s Jet Propulsion Laboratory used all of the aforementioned products plus a GCC compiler and a homegrown tool to comb through the software, looking for errors or possible errors.

One of the tricky things about checking all that  code — most written in C — is that sometimes it’s hard to know what to look for. “If you put software through three code reviews you’ll find stuff, and then if you put it through a fourth review, you’ll find something else. All these products all have their own strengths,’ said Gerard Holzmann, chief scientist for the JPL Lab for Reliable Software.

Ben Cichy, chief software engineer at JPL, said these programs check for things like array overloads, which can corrupt system memory and lead to all sorts of hard-to-foresee results.

The fact that space agency used a full suite of analysis tools illustrates just how important the $2.5 billion Mars project was to the agency. NASA tends to use a redundant “belt and braces approach” said Chris Adlard, Coverity’s senior manager, worldwide customer advocacy. Apparently, given the mission’s success, all that work did the trick.

Feature image courtesy of NASA/JPL-Caltech


7 Responses to “NASA scrubbed Mars Rover code clean — over and over”

  1. Tsahi Levent-Levi

    The tools they use are quite diverse in both cost and capabilities.

    In my past employer, we used Klocwork, PC-Lint and a large number of compilers of different operating systems (we did a cross platform SDK).
    And we got to the same conclusion – each tool will find different bugs in the code, so using more than a single tool made sense.

  2. Kevin Szabo

    Regarding ADA, sometimes it is a staffing issue. Hard enough to find good embedded developers in the first place, then find ones that are both proficient and *want* to work in Ada.

  3. John Markott

    With or without grammatical errors, I really appreciate seeing a ‘Secure by Design’ success story. The industry needs more stories like these! Well done Barb. And fantastic work NASA!

  4. WhereIsTheQA

    Looks like some of that analysis software used to scrub Curiosity’s code could have been used to check all the formatting and spelling errors in this article. Come on. This isn’t quality journalism.