From: Frank on
Hello,

Any recommendations on some static code analysis tools which checks for
compliance with MISRA-C 2004 ?





From: Tim Wescott on
On 06/09/2010 03:07 PM, Frank wrote:
> Hello,
>
> Any recommendations on some static code analysis tools which checks for
> compliance with MISRA-C 2004 ?

I wonder if the Toyota engine control system code is compliant -- I'll
bet it is.

--
Tim Wescott
Control system and signal processing consulting
www.wescottdesign.com
From: Rob Gaddi on
On 6/9/2010 3:26 PM, Tim Wescott wrote:
> On 06/09/2010 03:07 PM, Frank wrote:
>> Hello,
>>
>> Any recommendations on some static code analysis tools which checks for
>> compliance with MISRA-C 2004 ?
>
> I wonder if the Toyota engine control system code is compliant -- I'll
> bet it is.
>

*shrug* MISRA-C is a way of forcing some of the guns away from your
foot. From what I've seen of it, most of the recommendations seem like
they help more often than not. But anyone selling "The coding standard
that makes it always work." had better be willing to accept bridges in
trade.

--
Rob Gaddi, Highland Technology
Email address is currently out of order
From: Erik de Castro Lopo on
Frank wrote:

> Hello,
>
> Any recommendations on some static code analysis tools which checks for
> compliance with MISRA-C 2004 ?

Never heard of MISRA-C 2004, but have seen the output of Coverity
when applied to my libsndfile project. I blogged it here:

http://www.mega-nerd.com/erikd/Blog/CodeHacking/libsndfile/rel_19.html

I think Coverity is an excellent tool and for some applications may
even be worth what a Coverity license costs.

However, you should not rely on only one tool. This presentation from
on the the JPL guys relates how they use tools, code reviews and coding
standards to get reliable code:

http://www.infoq.com/presentations/Scrub-Spin

Erik
--
----------------------------------------------------------------------
Erik de Castro Lopo
http://www.mega-nerd.com/
From: Tim Wescott on
On 06/09/2010 03:31 PM, Rob Gaddi wrote:
> On 6/9/2010 3:26 PM, Tim Wescott wrote:
>> On 06/09/2010 03:07 PM, Frank wrote:
>>> Hello,
>>>
>>> Any recommendations on some static code analysis tools which checks for
>>> compliance with MISRA-C 2004 ?
>>
>> I wonder if the Toyota engine control system code is compliant -- I'll
>> bet it is.
>>
>
> *shrug* MISRA-C is a way of forcing some of the guns away from your
> foot. From what I've seen of it, most of the recommendations seem like
> they help more often than not. But anyone selling "The coding standard
> that makes it always work." had better be willing to accept bridges in
> trade.

Sorry -- my cynicism burst forth. Coding standards are great things,
and enforcing them is even better. But it's like making sure that the
brakes in your car work, when the component with the biggest problems is
always the nut behind the wheel.

--
Tim Wescott
Control system and signal processing consulting
www.wescottdesign.com