[JIRA] (JENKINS-59985) Warnings Next Generation Plugin for IAR C_STAT does not report warnings

19 views
Skip to first unread message

Roger_Smith@waters.com (JIRA)

unread,
Oct 30, 2019, 10:04:02 AM10/30/19
to jenkinsc...@googlegroups.com
Roger Smith created an issue
 
Jenkins / Bug JENKINS-59985
Warnings Next Generation Plugin for IAR C_STAT does not report warnings
Issue Type: Bug Bug
Assignee: Ulli Hafner
Attachments: BoardEE.c.html, cstat_result.html, ErrorCodes.c.html
Components: warnings-ng-plugin
Created: 2019-10-30 14:03
Environment: Warnings Next Generation Plugin: 7.1.0
Jenkins: 2.190.2
Windows 7
IAR Embedded Workbench for Renesas RX: 4.11.1
Priority: Minor Minor
Reporter: Roger Smith

Using IAR Embedded Workbench RX.

From the build, the IAR Compiler (C/C++) tool within Warnings NG Plugin works well. Correctly reports compiler warnings from the console during build.

The IAR C_STAT tool within Warnings NG Plugin does not appear to work. Does not report any issues. I have this set to look at the .html reports.

In IAR, using the iarbuild -cstat_analyze to analyse the project, then ireport to generate .html report files.

Example files attached. cstat_result.html is the summary file. BoardEE.c.html contains High severity messages. ErrorCodes.c.html contains Medium and Low severity messages.

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.13.6#713006-sha1:cc4451f)
Atlassian logo

ullrich.hafner@gmail.com (JIRA)

unread,
Oct 30, 2019, 6:08:03 PM10/30/19
to jenkinsc...@googlegroups.com
Ulli Hafner commented on Bug JENKINS-59985
 
Re: Warnings Next Generation Plugin for IAR C_STAT does not report warnings

The parser does not understand HTML. Did you use the option --no_wrap_diagnostics as suggested in the help text of the parser?

Roger_Smith@waters.com (JIRA)

unread,
Oct 31, 2019, 9:40:02 AM10/31/19
to jenkinsc...@googlegroups.com

The --no_wrap_diagnostics option does not appear to be valid. Not sure if this option is only available in certain versions of IAR EWB (and not in the version for Renesas RX).
If I try to use it I get the error message:
ERROR, Unknown command: "--no_wrap_diagnostics" is not a valid command

For the compiler, the following command is OK and gives messages which the IAR Compiler (C/C++) tool can use.:
iarbuild %project_file% -make Release -log all
These give errors:
iarbuild %project_file% -make Release -log all --no_wrap_diagnostics
iarbuild %project_file% -make Release --no_wrap_diagnostics

For C-STAT, the following command runs OK (and produces a .db file) but gives no messages to the console, hence the IAR C-STAT tool thinks everything is OK:
iarbuild %project_file% -cstat_analyze Release -log all
These give errors:
iarbuild %project_file% -cstat_analyze Release -log all --no_wrap_diagnostics
iarbuild %project_file% -cstat_analyze Release --no_wrap_diagnostics

Once cstat .db file has been generated, I then convert these to html with the command (again, no warnings in the console):
ireport --db .\Release\Obj\cstat.db --project %project_file% --full --output .\cstat_html\cstat_result.html

Roger_Smith@waters.com (JIRA)

unread,
Oct 31, 2019, 9:47:02 AM10/31/19
to jenkinsc...@googlegroups.com

I should probably add that I am primarily an FPGA designer working in VHDL. I set up out Jenkins system initially to check our FPGA projects, compiling with Xilinx and Altera tools and simulating with ModelSim.

I'm not working directly on the MCU projects and have little knowledge of IAR EWB (but I'm keen to bring as much as I can into Jenkins) and the engineers working on the MCUs normally use the GUI, not command line, so it may be that I'm missing something fundamental.

ullrich.hafner@gmail.com (JIRA)

unread,
Oct 31, 2019, 10:44:02 AM10/31/19
to jenkinsc...@googlegroups.com

jenkins@xca.ch (JIRA)

unread,
Nov 1, 2019, 2:57:05 AM11/1/19
to jenkinsc...@googlegroups.com

The IAR cstat parser parses the stdout of the icstat command lines and does not parse the html files. Like this all suppressed messages are already suppressed and do not appear on the warnings chart. You need to call 'icstat' as described in the guideline: http://netstorage.iar.com/SuppDB/Public/UPDINFO/013062/ew/doc/EW_CSTATGuide.ENU.pdf on page 16:
icstat --db a.db --checks checks.ch commands commands.txt

commands.txt contains:
{{analyze – iccxxxxxcompiler_opts cstat1.c
analyze – iccxxxxxcompiler_opts cstat2.c}}

If you do it like this the output format matches the one mentioned by Ulli Hafner: https://github.com/jenkinsci/analysis-model/blob/master/src/test/resources/edu/hm/hafner/analysis/parser/iar-cstat.txt

jenkins@xca.ch (JIRA)

unread,
Nov 1, 2019, 2:58:04 AM11/1/19
to jenkinsc...@googlegroups.com
Lorenz Aebi edited a comment on Bug JENKINS-59985
The IAR cstat parser parses the stdout of the icstat command lines and does not parse the html files. Like this all suppressed messages are already suppressed and do not appear on the warnings chart. You need to call 'icstat' as described in the guideline: http://netstorage.iar.com/SuppDB/Public/UPDINFO/013062/ew/doc/EW_CSTATGuide.ENU.pdf on page 16:
{{icstat --db a.db --checks checks.ch commands commands.txt}}

commands.txt contains:
{{analyze -- iccxxxxxcompiler_opts cstat1.c }}
{{ analyze -- iccxxxxxcompiler_opts cstat2.c}}


If you do it like this the output format matches the one mentioned by Ulli Hafner: https://github.com/jenkinsci/analysis-model/blob/master/src/test/resources/edu/hm/hafner/analysis/parser/iar-cstat.txt

Roger_Smith@waters.com (JIRA)

unread,
Nov 1, 2019, 3:15:02 AM11/1/19
to jenkinsc...@googlegroups.com

Thank you.

It appears that there are two different commands for running the IAR cstat.

I had been using the iarbuild ... -cstat_analyze …  command.

I will try changing to the icstat and the analyze commands.

It will be next week before I can try this, but I will report back here as soon as I can.

 

ullrich.hafner@gmail.com (JIRA)

unread,
Nov 1, 2019, 7:11:04 AM11/1/19
to jenkinsc...@googlegroups.com

ullrich.hafner@gmail.com (JIRA)

unread,
Nov 7, 2019, 3:45:04 PM11/7/19
to jenkinsc...@googlegroups.com

ullrich.hafner@gmail.com (JIRA)

unread,
Nov 7, 2019, 3:45:04 PM11/7/19
to jenkinsc...@googlegroups.com
Ulli Hafner resolved as Not A Defect
Change By: Ulli Hafner
Status: Open Resolved
Resolution: Not A Defect

ullrich.hafner@gmail.com (JIRA)

unread,
Nov 7, 2019, 3:45:04 PM11/7/19
to jenkinsc...@googlegroups.com

Roger_Smith@waters.com (JIRA)

unread,
Nov 8, 2019, 1:49:03 AM11/8/19
to jenkinsc...@googlegroups.com

Roger_Smith@waters.com (JIRA)

unread,
Nov 8, 2019, 1:57:02 AM11/8/19
to jenkinsc...@googlegroups.com
Roger Smith commented on Bug JENKINS-59985
 
Re: Warnings Next Generation Plugin for IAR C_STAT does not report warnings

Thanks Ulli.

The additions to the help messages in the plugin are good.

I'm not able to change to using the icstat and the analyze commands at present due to other commitments on my time. Until I can make the change, I will continue to use the iarbuild ... -cstat_analyze …  command and generate html results. Now running a batch file script to check the html output and using the Text Finder plugin to check for messages from this script.

This is a compromise, and no where near as good as using the Warnings NG Plugin, but in case there's anyone else in the same situation I've attached a copy of my script cstat_html_check.bat . Unlike the Warnings NG Plugin this does not provide good analysis and reporting of the warnings found, it only puts messages to the console.

Reply all
Reply to author
Forward
0 new messages