4 ms·
Interested in whether anyone has compared how these analyzers compare with expensive enterprise options? So much of this enterprise software is junk, but it se
by P_I_Staker 3y ago
Interested in whether anyone has compared how these analyzers compare with expensive enterprise options?
So much of this enterprise software is junk, but it seems like the options much more basic. In this case, perhaps the simple version is worse.
I'm not as sure how these are designed either. Usually, this requires some fairly sophisticated management of the static test environment, and providing information to the tool.
Perhaps it's just embedded systems, but you also have to manage a custom preprocessor. I'm not sure if these tool have any good rulesets, either default or stuff geared towards eg. CERT-C and MISRA-C.
Anyway, I've played around with Unit test frameworks, too. I'm not sure if I found any that provide good coverage metrics. Also here, it seems in both cases you do get a basic suite of behavior
static: rules you can enable for static checks, logs/reports, etc
unit: framework, scripts, assert, test sequencing, etc
Anybody use anything "heavier weight"? It doesn't have to be "free free", but not for $6-50k+... say less than $2k.
- canucker2016 3y agoPC-Lint/Flexelint is the grownup/commercial version of lint/compiler analyzers. Looks like they merged with a more corporate software company, but you can still find their webpages on archive.org. see https://web.archive.org/web/20061206130312/http://gimpel.com/html/lintchks.htm https://web.archive.org/web/20061206130312/http://gimpel.com... and https://web.archive.org/web/20061208002102/http://www.gimpel.com/html/pub80/msg.txt https://web.archive.org/web/20061208002102/http://www.gimpel.... And for fun, see https://web.archive.org/web/20070204002103/http://www.gimpel.com/html/bugs.htm https://web.archive.org/web/20070204002103/http://www.gimpel... Two commercial static analyzers I've heard of are Klocwork and Coverity. I know Coverity has a program to scan open source projects. So you can take a look at the output of their scans to see how they fare. For PC-lint, it was relatively easy to integrate into the build process. Just a few changes in each makefile - probably less if you use something like ninja/cmake to drive the build process. But adding static analysis to your build is similar to getting a home energy efficiency audit. The auditor comes in and analyzes your house and points out where you can improve the house's energy efficiency (go from single to double/triple pane windows, fill in cracks around doors, don't use oil/coal to heat the house, etc.) But once they're done and you've adjusted the house accordingly, further audits won't bring up any new issues unless something in the house has changed. Similar thing with static analyzer (and with turning on compiler warnings). First time you use that feature, you'll get a lot of issues - some of them you may modify, some you'll ignore. But further static analysis won't bring up many new issues, if at all, unless the code has changed. Which means it's important to run the analysis when code is committed. Besides being cheaper/faster to fix problems before the commit, issues won't build up until the next time you run the static analyzer. These tools don't eat, don't sleep, don't take vacation/sick days, won't get tired looking at the same code over and over again, and know much more about gotchas/footguns in the programming language than most programmers. When I talked with a programmer who had worked on an enterprise-level commercial static analyzer, we agreed that these types of tools would find about up to 10% of bugs in a project - closer to 10% for the lower quality projects.