Subscribe to EDN

Mission-critical design may be the future for the SoC world

April 5, 2010

Toyota’s recent travails have stimulated discussion lately about the risks of having unsupervised software in control of a system that can do harm. The Toyota issue was whether engine-control software could cause unintended acceleration. But similar questions have been asked about other automotive systems such as ABS, and about medical systems ranging from radiation-therapy equipment to implanted pacemaker/defibrillators to robotic surgeons. There has even been angst about a computer-driven securities trading system running amok, as has apparently already happened a few times.

These are not new problems. the aerospace industry faced them decades ago, when airframe designers for missiles and combat aircraft began producing dynamically unstable designs in the pursuit of performance. They had to rely on flight-control software to keep the vehicles in the air and in one piece. There were some unfortunate incidents.

That industry’s eventual response was a formal approach to requiring best practices, quantifying the progress of verification, and demanding an exhaustive regimen of reporting to ensure compliance. Mandatory programs such as DO-178B for software or DO-254—intended for full systems but in fact only enforced today for FPGAs and ASICs—became an expensive fact of life for folks who make stuff fly.

Now, design teams outside the aerospace industry are beginning to look at these disciplines, if not for adoption—they can be ruinously expensive by non-military standards—at least for emulation. "The medical equipment industry has been looking at certification ever since the problems with the Therac 25, 25 years ago," says Nat Hillary, field applications engineer for LDRA Software Technology. "But the result from the FDA was only a set of ad-hoc guidelines, with no specific metrics or mandatory steps." LDRA vice president of business development John Greenland adds that in the auto industry, already deeply into drive-by-wire, there is interest in the aerospace experience, but no move toward industry-wide standards. "Automotive is where the aerospace industry was ten or fifteen years ago," Greenland opines.

Nor is interest in such methodologies likely to stop at the boundary of mission-critical systems. Today, the failure of a product due to design errors can be as lethal to a company as a speeding car might be to its driver. The level of pain a design team is willing to endure to make sure that an SoC and its associated software function in the customer’s system may be nearly as great as the pain aerospace contractors endure to avoid airliner crashes.

DO-178B is both rigorous and independently monitored. "It’s not just a set of metrics, but a process," Hillary says. When a team is working on a mission-critical design, an FAA representative must approve the design process. Then throughout the program the designers generate documentation that proves compliance with the approved process. Among other things, DO-178B enforces a list of allowable code constructs, and requires rigor in moving from high-level code to implementation. For example, the mandate requires verifiers to prove that there are no branches in the object code that don’t explicitly exist in the source code. And it requires 100 percent code coverage in verification, as well as coverage of every possible path out of decision blocks. Vendors like LDRA provide analysis tools to assess the source code and direct the verification efforts, helping to automate what otherwise can be an enormous manual process resting on the discipline of lots of individuals.

Another key facet of DO-178B is traceability. Every byte of object code must be traceable back to the source code line that generated it, and to the statement in the requirements definition for which the line of source code was written. This allows quality-assurance teams to answer vital questions such as "why is this code here?" and "have we tested the code that implements this requirement yet?" LDRA tools also support the creation of traceability.

Not everything in DO-178B makes sense for a hardware design. Intuitively, Verilog or VHDL could play the role of source code, but the analogy breaks down quickly. "At the execution level hardware and software are very different," Greenland laments. "Chips are inherently parallel." And so there is a quite different procedure, DO-254, for mission-critical FPGAs and ASICs.

DO-254 also demands strict traceability. And it was while working with a customer on a DO-254-goverend project that Mentor Graphics recognized the need for a generalized traceability tool, according to Mentor program manager Pete Decher. "We found that most teams were still tracking traceability manually, and it was costing on average 25 person-hours for every 1000 requirements," Decher says. Mentor’s answer is ReqTracer.

ReqTracer starts by assisting in identifying, isolating, and tagging individual requirements. These can be as detailed as the need for a controller to generate an acknowledge pulse of a certain length within a certain time after it recognizes its address, for example. So the number of individual requirements in a large system can be huge. The task requires ReqTracer to read text documents, Microsoft Office files, and data from other systems such as IBM’s DOORS. ReqTracer then allows users to include the appropriate tags when they generate design data: high-level designs in C/C++, SystemC or Matlab, or implementation code in Verilog or VHDL. As the design team creates and refines the design, the tags go in. Significantly, the verification team can also tag items in the test bench to identify which requirements each module is to verify.

With the tags in place, design teams can analyze such issues as the completeness of the code set and the presence of orphaned code. They can drive the verification process based on coverage of the requirements, rather then an arbitrary approximation like code coverage. And they have a powerful tool for estimating the impact of ECOs: not by formally evaluation dependencies, but by projecting the dependencies identified in the requirements document through the design data to the implementation.

All by themselves the abilities to do requirements-driven verification and to estimate the implications of ECOs might justify the cost and overhead of a tool like ReqTracer. But in the larger context of a necessary move towards mission-critical design methodology—just to get enormously complex SoCs out the door—tools such as Mentor’s ReqTracer and LDRA’s DO-178B-support take on a different level of appeal.

Posted by Ron Wilson on April 5, 2010 | Comments (8)

April 7, 2010
In response to: Mission-critical design may be the future for the SoC world
Jüri Põldre commented:

It is not the case that there are no stable sw modules available nor that there are no good programmers around. Often all is neglected because it is _cheaper_ and everybody in value chain has belief that 'maybe we get lucky this time with small nr of bugs' and ' it can be fixed later'


April 7, 2010
In response to: Mission-critical design may be the future for the SoC world
Axel commented:

I've been working in Aerospace for 10 years, and involved in DO254 since 2004. The best practises and guidelines specified defines, most of the times, what a good designer must do to match the project reqs and prove that it is working as expected (where prove means providing documentation, project plans, test results, code coverage, formal verification and so on and, as you can imagine, where the process become expensive and time-costing). And last but not least, find bugs in the early steps of the process. The point is that DO254/DO178B do not state anything special, as these kind of guidelines where defined years before. The difference is that now it is asked to give evidence of the safety of the design.


April 7, 2010
In response to: Mission-critical design may be the future for the SoC world
Andre Kutzick commented:

The problem is the independence of functionality. Old mechanical systems often do not have a single point of failure. If e.g. ABS is in a single controller and has no relation (input) of other systems, I would accept that. But modern management systems ares placed highly integrated on one chip/system. Therefore they are able to manipulate each other. Here everything is integrated with the focus on cost reduction into ONE management system. If one software component fails, all other components are touched. This is are HW/SW related architecture problem but really solvable. There are enough failsafe embedded OS available. But the people hired for these jobs often do not have enough experience (because they are cheap), the software used is "high sophisticated" and the people are experienced in PC programming but not embedded systems. These are two really different worlds. Last year I had an medical equipment project and the (experienced) programmers were not experienced in embedded systems. The result was: the product was over-sophisticated, got a mess of bugs and was hard to debug. Help: Use "real" embedded SW engineers with experience. Maybe they are expensive, but it's cheaper at all. Crying for a HW support makes the systems often more complex and that's the fault.


April 6, 2010
In response to: Mission-critical design may be the future for the SoC world
Ron Lawrence commented:

I almost died in my company provided 2007 Chevy Trailblazer, due to a software inconsistency. The interaction of the ABS and stability control software (even when the switch is OFF for stability control!) makes descending steep slopes hazzardous! Chevy has denied any issue, but the dealer has duplicated the issue on numerous vehicles. If you apply the brakes, you will many times false the ABS and end up gaining speed! Proof of the interaction came when the stability control sensor wiring from the rear of the vehicle was damaged. Vehicle then braked perfectly!


April 6, 2010
In response to: Mission-critical design may be the future for the SoC world
Don Thompson commented:

To answer San Jose Geek: Yes. There was a time when designers, analysts and programmers actually took time to think things through. When a system with two possible inputs was programmed and those involved would ask the questions: "What if there are no inputs?" and "What if there are both inputs?" A time when buffers did not overflow, because the routines moving data into them counted to make sure. And a time when interrupts processing first involved determining whether or not something more important was happening. But much of the corporate philosophy of the time was longer term than it is today, so projects were viewed differently.


April 6, 2010
In response to: Mission-critical design may be the future for the SoC world
Bob Leif commented:

I suggest that you look at Ada (www.adaic.org/) and its dialect SPARK (www.sparkada.com/). Some of you might have tried Ada 25 years ago. It is much faster and much improved with an excellent object model.


April 6, 2010
In response to: Mission-critical design may be the future for the SoC world
OldDog commented:

This is nothing new to other simple low cost safety related products. In the late 80's I did a quick consulting job for a sensor company interested in moving their industrial light curtains to safety rated devices ( i.e. don't chop the fingers off in the punch press). While I did not do the design I suggested the solution in the form of dual processors cross checking each other. Beyond that each was a different manufacturer and each was programmed in a different language by different programmers. Each programmer worked from a spec document that outlined the functions not the way to code it. To my knowledge th design is still in production with a good performance record. With the microprocessor in an electronic throttle body costing probably less than $0.50 there is no excuse for the added redundancy. Even the sensors for the throttle pedal and throttle bodie are already available with dual sensors in the same package.


April 6, 2010
In response to: Mission-critical design may be the future for the SoC world
San Jose Geek commented:

Has anyone seen any software product that comes out 1st time without a "bug" that needs fixing at some point? We might be at a point that cars will not stop because the code is wrong and someone forgot to "update" their software and someone needed to answer the question "Are you sure?" when they wanted to stop (as if reboot command is typed). I still love my old car, no electronics and no software anywhere on them.

POST A COMMENT
Display Name
captcha

Before submitting this form, please type the characters displayed above. Note the letters are case sensitive:

Advertisement
Advertisement
Advertisement
About EDN   |   Site Map   |   Contact Us   |   Subscription   |   RSS
© 2012 UBM Electronics. All rights reserved.
Use of this Web site is subject to its Terms of Use | Privacy Policy

Please visit these other UBM Canon sites

UBM Canon | Design News | Test & Measurement World | Packaging Digest | EDN | Qmed | Pharmalive | Appliance Magazine | Plastics Today | Powder Bulk Solids | Canon Trade Shows