vivado_proto.xml 9.48 KB
<?xml version="1.0" encoding="UTF-8"?>
<!-- 
 /*******************************************************************************
 * Copyright (c) 2014 Elphel, Inc.
 * This file is a part of VDT plug-in.
 * VDT plug-in is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * VDT plug-in is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 * 
 *  Additional permission under GNU GPL version 3 section 7:
 * If you modify this Program, or any covered work, by linking or combining it
 * with Eclipse or Eclipse plugins (or a modified version of those libraries),
 * containing parts covered by the terms of EPL/CPL, the licensors of this
 * Program grant you additional permission to convey the resulting work.
 * {Corresponding Source for a non-source form of such a combination shall
 * include the source code for the parts of Eclipse or Eclipse plugins used
 * as well as that of the covered work.}
 *******************************************************************************/
 Warnings was (was in an attempt to catch "CRITICAL WARNING" too?):
  default=".*([^ ]WARNING:) (\[.*\].*)\[(.*):([0-9]+)\]"
  Problem was - missing 1-st line as group 0 had the previous end of line)
 -->
<vdt-project>
	<tool name="VivadoToolPrototype" label="VivadoToolPrototype"
	    project="FPGA_project"
		interface="VivadoInterface"
		package="FPGA_package"
		shell="/bin/bash"
		description="Vivado tool prototype"
		abstract="true"
		>
<!-- parser parameters -->
        <parameter	id="PatternErrors"   label="Errors" tooltip= "Regular expression for error messages"
        			default=".*(ERROR:|CRITICAL WARNING:) (\[.*\].*)\[(.*):([0-9]+)\]"
        			visible="true"  type="String" format="CopyValue"/>
        <parameter	id="PatternWarnings"   label="Warnings" tooltip= "Regular expression for warnings messages"
        			default=".*(WARNING:) (\[.*\].*)\[(.*):([0-9]+)\]"
        			visible="true"  type="String" format="CopyValue"/>
        <parameter	id="PatternInfo"   label="Info" tooltip= "Regular expression for info messages"
        			default=".*(INFO:) (\[.*\].*)\[(.*):([0-9]+)\]"
        			visible="true"  type="String" format="CopyValue"/>
        			
        <parameter	id="InstanceCapture"   label="Instance capture"
        			tooltip= "Regular expression to extract hierarchical instance name (outer '()' enclose the hierarchical name itself)"
        			default="((([#a-zA-Z_$]([a-zA-Z_$0-9]|\[[0-9:]+\])*)(\.|:))+([a-zA-Z_$]([a-zA-Z_$0-9]|\[[0-9:]+\])*))"
        			visible="true"  type="String" format="CopyValue"/>
        <parameter	id="InstanceSeparator"   label="Instance separator"
        			tooltip= "Regular expression to extract hierarchical name separator, for literal '.' it is '\.'"
        			default="\."
        			visible="true"  type="String" format="CopyValue"/>
        <parameter	id="InstanceSuffix"   label="Instance suffix"
        			tooltip= "Regular expression to match/remove name suffixes automatically added by the tools"
        			default="_reg|__parameterized[0-9]*"
        			visible="true"  type="String" format="CopyValue"/>
       
        <parameter 	id="parser_mode" label="Parser mode" tooltip= "Parser mode (consolidation of bits of the same instance)"
        			default="1" visible="true" omit="" type="ParserModeType" format="CopyValue"/>
        			
        <parameter	id="NoFileProblem"   label="No-file problems" tooltip= "Report problems that do not specify particular source file/line"
        			default="true" visible="true" omit="false" type="Boolean" format="None"/>
        <parameter	id="Drc"       label="Drc"     tooltip= "Enable problems with [Drc to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Vivado_Tcl" label="Vivado_Tcl"  tooltip= "Enable problems with [Vivado_Tcl to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Route"     label="Route" tooltip= "Enable problems with [Route to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Memdata"   label="Memdata" tooltip= "Enable problems with [Memdata to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Synth"     label="Synth"   tooltip= "Enable problems with [Synth to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Netlist"   label="Netlist" tooltip= "Enable problems with [Netlist to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Opt"       label="Opt"     tooltip= "Enable problems with [Opt to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Project"   label="Project" tooltip= "Enable problems with [Project to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Timing"    label="Timing"  tooltip= "Enable problems with [Timing to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="Pwropt"    label="Pwropt"  tooltip= "Enable problems with [Pwropt to be reported"
        			default="true" visible="true" omit="true" type="Boolean" format="GrepFilterProblemSyntax"/>
        <parameter	id="OtherProblems"    label="Other problems"  tooltip= "Other problem patterns (after opening '[') to be suppressed)"
        			default="" visible="true" omit="" type="Stringlist" format="GrepFilterProblemOtherSyntax"/>

        <parameter id="ShowWarnings" label="Show Warnings" tooltip="Parse warning messages"
		           default="true"
		           type= "Boolean" format="None"/>
        <parameter id="ShowInfo" label="Show info" tooltip="Parse info messages"
		           default="true"
		           type= "Boolean" format="None"/>
        <parameter id="PreGrepW" visible="false"
                   type="String" format="None"
                   default="?%ShowWarnings=true: |WARNING, "/>
        <parameter id="PreGrepI" visible="false"
                   type="String" format="None"
                   default="?%ShowInfo=true: |INFO, "/>
        <parameter id="GrepEWI" label="Grep filter" tooltip="Calculated grep filter"
                   default="grep --line-buffered -E 'ERROR|CRITICAL WARNING%PreGrepW%PreGrepI'"
                   type="String" format="CopyValue"
                   visible="true" readonly="true"/>

        <parameter id="parsers_path" label="Parsers Path" tooltip= "parsers directory in plugins"
        			default="%%ParsersPath" visible="true" omit="" type="String" format="CopyValue"/>
        <parameter id="parser_name" label="Vivado parser name" tooltip= "Vivado output parser script path"
        			default="parser_vivado.py" visible="true" omit="" type="String" format="CopyValue"/>

        <parameter	id="MaxMsg"    outid="set_param messaging.defaultLimit"
        		    label="Maximal messages" tooltip= "Maximum number of messages to output (per type)"
        			default="1000"  visible="true" omit="100" type="Cardinal" format="NameValue"/>

        			
		<input>
			<group name="Parser"
			       weight="10">
				"parsers_path"
				"parser_name"
				"---"
				"ShowWarnings"
				"ShowInfo"
				"MaxMsg"
				"GrepEWI"
				"---"
				"NoFileProblem"
		        "Drc"
		        "Vivado_Tcl"
				"Route"
				"Memdata"
				"Synth"
		        "Netlist"
		        "Opt"
		        "Project"
		        "Timing"
		        "Pwropt"
		        "OtherProblems"
				"---"
				"PatternErrors"
				"PatternWarnings"
 				"PatternInfo"
 				"InstanceCapture"
 				"InstanceSeparator"
 				"InstanceSuffix"
 				"parser_mode"
			</group>
		</input>
		<output>
			<line name="parser_Vivado"
				errors=   "PatternErrors"
				warnings= "PatternWarnings"
				info=     "PatternInfo"
				instance-capture=  "InstanceCapture"
 				instance-separator="InstanceSeparator"
 				instance-suffix=   "InstanceSuffix">
				"-c"
				"python -u %parsers_path%parser_name %%ToolName %%TopModule %parser_mode| "
     			"%GrepEWI"
     			"| %VivadoSedPaths"
     			<if NoBabyTalk="true">
     				"| grep --line-buffered -v \"license\""
     			</if>
     			"%Drc"
		        "%Vivado_Tcl"
		        "%Route"
     			"%Memdata"
     			"%Synth"
		        "%Netlist"
		        "%Opt"
		        "%Project"
		        "%Timing"
		        "%Pwropt"
		        "%OtherProblems"
		        <!-- TODO: change Placement to Routing? or such -->
     			<if NoFileProblem="true">
	  				<!-- Add  [Placement:0000] to lines that do not have [file:line] - then "Placement" will appear in "Problems" location-->
     				"| sed -u 's@^[^\[]*\[[^\[]*$@&amp;\[%%ToolName:0000\]@'"
     			</if>
			</line>
		</output>
	</tool>
</vdt-project>