Commit 97b1bfc2 authored by Mikhail Karpenko's avatar Mikhail Karpenko
Browse files

WIP: fitter interface

parent dcf0e089
Loading
Loading
Loading
Loading
+14 −12
Original line number Original line Diff line number Diff line
@@ -70,15 +70,16 @@
			<line name="quartus_restore"
			<line name="quartus_restore"
			      dest="QuartusConsole"
			      dest="QuartusConsole"
			      mark="``" 
			      mark="``" 
			      sep=" "
			      sep="\n"
			      failure="ERROR"
			      failure="ERROR"
			      prompt="@@FINISH@@"
			      prompt="@@FINISH@@"
			      log="">
			      log="">
			      "cd ~/%QuartusProjectRoot\n"
				  "puts \"\Restoring snapshot %%StateFile""
			      "set outputDir ~/%QuartusProjectRoot/%QuartusRemoteDir\n"			      
			      "cd ~/%QuartusProjectRoot"
			      "file mkdir $outputDir\n"
			      "set outputDir ~/%QuartusProjectRoot/%QuartusRemoteDir"
		          "open_checkpoint %QuartusRemoteDir/%%StateFile\n"
			      "file mkdir $outputDir"
		          "puts \"@@FINISH@@\"\n"
		          "project_restore %QuartusRemoteDir/%%StateFile"
		          "puts \"@@FINISH@@\""
		    </line>
		    </line>
		</output>
		</output>
	</tool>
	</tool>
@@ -95,15 +96,16 @@
			<line name="quartus_save"
			<line name="quartus_save"
			      dest="QuartusConsole"
			      dest="QuartusConsole"
			      mark="``" 
			      mark="``" 
			      sep=" "
			      sep="\n"
			      prompt="@@FINISH@@"
			      prompt="@@FINISH@@"
			      failure="ERROR"
			      failure="ERROR"
			      log="">
			      log="">
			      "cd ~/%QuartusProjectRoot\n"
				  "puts \"Saving snapshot %%StateFile\""
			      "set outputDir ~/%QuartusProjectRoot/%QuartusRemoteDir\n"			      
			      "cd ~/%QuartusProjectRoot"
			      "file mkdir $outputDir\n"
			      "set outputDir ~/%QuartusProjectRoot/%QuartusRemoteDir"
	      		  "write_checkpoint -force %QuartusRemoteDir/%%StateFile\n"
			      "file mkdir $outputDir"
	      		  "puts \"@@FINISH@@\"\n"
	      		  "project_archive -overwrite %QuartusRemoteDir/%%StateFile"
	      		  "puts \"@@FINISH@@\""
			</line>
			</line>
			<line name="quartus_copy_after_save">
			<line name="quartus_copy_after_save">
					"-c"
					"-c"
+35 −27
Original line number Original line Diff line number Diff line
@@ -74,6 +74,7 @@ may decrease as fast-synthesis netlists take longer to route."/>
		restore="RestoreQuartusSynthesis"
		restore="RestoreQuartusSynthesis"
		disable="DisableQuartusSynth"
		disable="DisableQuartusSynth"
		save="SaveQuartusSynthesis"
		save="SaveQuartusSynthesis"
		autosave="AutosaveQuartusSynthesis"
		inherits="QuartusToolPrototype"
		inherits="QuartusToolPrototype"
		>
		>


@@ -107,9 +108,9 @@ spaces. If you need to add space between words in the family name, make sure tha
			minimum area usage or high speed performance with minimal area cost during synthesis."
			minimum area usage or high speed performance with minimal area cost during synthesis."
			default="balanced" visible="true" readonly="false" omit="balanced" type="OptimizeDesign" format="DoubleDash"/>
			default="balanced" visible="true" readonly="false" omit="balanced" type="OptimizeDesign" format="DoubleDash"/>
		<parameter id="parallel" label="# of processors to use" tooltip="Controls parallel compilation. If 0 is specified, the Quartus software
		<parameter id="parallel" label="# of processors to use" tooltip="Controls parallel compilation. If 0 is specified, the Quartus software
uses all processors detected on the system. Otherwise, the software
uses all processors detected on the system. Otherwise, the software attempts to use the specified number of processors.
attempts to use the specified number of processors."
Note: this feature is not licenced for the Web Edition and this parameter should be set to 1"
			default="0" visible="true" readonly="false" omit="0" type="Cardinal" format="DoubleDash"/>
			default="1" visible="true" readonly="false" omit="0" type="Cardinal" format="DoubleDash"/>
		<parameter id="part_synth" outid="part" label="Part (see Project)" tooltip="Altera device to use (configured in 'project' dialog)"
		<parameter id="part_synth" outid="part" label="Part (see Project)" tooltip="Altera device to use (configured in 'project' dialog)"
			default="%part" visible="true" readonly="true" omit="" type="String" format="DoubleDash"/>
			default="%part" visible="true" readonly="true" omit="" type="String" format="DoubleDash"/>
		<parameter id="state_machine_encoding" label="FSM encoding" tooltip="Finite state machine encoding."
		<parameter id="state_machine_encoding" label="FSM encoding" tooltip="Finite state machine encoding."
@@ -129,8 +130,8 @@ attempts to use the specified number of processors."
			default="" label="Constraints files" tooltip="Select constraint files to load to Quartus" readonly="false"
			default="" label="Constraints files" tooltip="Select constraint files to load to Quartus" readonly="false"
			visible="true" />
			visible="true" />
			
			
		<parameter id="SkipSnapshotSynth" label="Skip snapshot" tooltip="Do not create snapshot after synthesis"
		<parameter id="AutosaveQuartusSynthesis" label="Create snapshot" tooltip="Automatically create snapshot after successful synthesis"
		           default="false" type= "Boolean" format="None"/>
		           default="true" type= "Boolean" format="None"/>
		<parameter id="ResetProject" label="Reset project" tooltip="Reset project before loading source files"
		<parameter id="ResetProject" label="Reset project" tooltip="Reset project before loading source files"
		           default="true" type= "Boolean" format="None"/>
		           default="true" type= "Boolean" format="None"/>
		<parameter id="SkipPreSynth" label="Skip pre-synthesis" tooltip="Do not run pre-synthesis TCL commands"
		<parameter id="SkipPreSynth" label="Skip pre-synthesis" tooltip="Do not run pre-synthesis TCL commands"
@@ -144,7 +145,7 @@ attempts to use the specified number of processors."
			    "FilteredSourceListPar"
			    "FilteredSourceListPar"
			    "FilteredIncludesListPar"
			    "FilteredIncludesListPar"
				"ConstraintsFiles"
				"ConstraintsFiles"
				"SkipSnapshotSynth"
				"AutosaveQuartusSynthesis"
 				"QuartusSnapshotSynth" <!--  same as in project -->
 				"QuartusSnapshotSynth" <!--  same as in project -->
				"ResetProject"
				"ResetProject"
				"---"
				"---"
@@ -206,45 +207,52 @@ attempts to use the specified number of processors."
			<line name="quartus_run_synth"
			<line name="quartus_run_synth"
			      dest="QuartusConsole"
			      dest="QuartusConsole"
			      mark="``" 
			      mark="``" 
			      sep=" "
			      sep="\n"
				  prompt="@@FINISH@@"
				  prompt="@@FINISH@@"
				  success="@@FINISH@@"
				  success="@@FINISH@@"
				  log=""
				  log=""
				  stdout="parser_Quartus">
				  stdout="parser_Quartus">
				"cd ~/%QuartusProjectRoot\n"
				"cd ~/%QuartusProjectRoot"
				"set projectName %%ProjectName\n"
				"load_package flow"
			    "set outputDir ~/%QuartusProjectRoot/%QuartusRemoteDir\n"
				"set projectName %%ProjectName"
			    "set outputDir ~/%QuartusProjectRoot/%QuartusRemoteDir"
				"file mkdir $outputDir"
				<!-- Load all project files -->
				<if ResetProject="true">
				<if ResetProject="true">
					<!-- "project_close" -->
					"if [is_project_open] { project_close }"
				</if>
				</if>
				"file mkdir $outputDir\n"
				"if [project_exists $projectName] {"
				<!-- Load all project files -->
				"project_open $projectName"
				"foreach file [list %FilteredSourceListPar] {\n"
				"} else {"
				"puts \"Adding $file to project\"\n"
				"project_new $projectName }"
				"set_global_assignment -name VERILOG_FILE $file }\n"
				"foreach file [list %FilteredSourceListPar] {"
				"puts \"Adding $file to project\""
				"set_global_assignment -name VERILOG_FILE $file }"
				<if QuartusSynthActionIndex="0">
				<if QuartusSynthActionIndex="0">
					<if ConstraintsFiles="">
					<if ConstraintsFiles="">
						"puts \"No constraints files specified, skipping read_qdc command\";\n"
						"puts \"No constraints files specified, skipping read_qdc command\";"
					</if>
					</if>
					<if-not ConstraintsFiles="">
					<if-not ConstraintsFiles="">
						"%read_qdc\n"
						"%read_qdc"
					</if-not>
					</if-not>
				</if>
				</if>
				<!-- Run pre-synthesis TCL commands (if specified) -->
				<!-- Run pre-synthesis TCL commands (if specified) -->
				<if SkipPreSynth="false">
				<if SkipPreSynth="false">
					<if-not PreTCL="">
					<if-not PreTCL="">
						"%PreTCL\n"
						"%PreTCL"
					</if-not>
					</if-not>
					<if PreTCL="">
					<if PreTCL="">
						"puts \"No pre-synthesis TCL commands specified\"\n"'
						"puts \"No pre-synthesis TCL commands specified\""
					</if>
					</if>
				</if>
				</if>
				<!--"if {[catch {execute_module -tool map -args $synth_args} result]} {\n"
				<!-- Start synthesizer -->
				"puts \"\nResult: $result\n\""
				"if {[catch {execute_module -tool map -args $synth_args} result]} {"
				"puts \"ERROR: Analysis and Synthesis faild. See the report file.\n\""
				"puts \"Result: $result\""
				"} else {\n"
				"puts \"ERROR: Analysis and Synthesis faild. See the report file.\""
				"puts \"\nINFO: Analysis and Synthesis was successful. }\n\""-->
				"} else {"
				"puts \"@@FINISH@@\"\n"
				"puts \"INFO: Analysis and Synthesis was successful.\""
				"}"
				"puts \"@@FINISH@@\""
			</line>
			</line>
		</output>
		</output>
	</tool>
	</tool>
+4 −0
Original line number Original line Diff line number Diff line
@@ -189,6 +189,10 @@
				label="Synthesize design"
				label="Synthesize design"
				icon="Retort.png"
				icon="Retort.png"
				call="QuartusSynthesis"/>
				call="QuartusSynthesis"/>
			<menuitem name="QuartusFitter"
				label="Place and route design"
				icon="route66.png"
				call="QuartusPlace"/>
		</menu>
		</menu>
                          
                          
                          
                          
+6 −1
Original line number Original line Diff line number Diff line
@@ -463,7 +463,12 @@


		<parameter id="QuartusSnapshotSynth"
		<parameter id="QuartusSnapshotSynth"
			label="Synthesis snapshot" tooltip="Name of Quartus snapshot archive"
			label="Synthesis snapshot" tooltip="Name of Quartus snapshot archive"
			default="%%ProjectName.qar"
			default="%%ProjectName-synth.qar"
			type="String" format="CopyValue" />

		<parameter id="QuartusSnapshotPlace"
			label="Place and route snapshot" tooltip="Name of Quartus snapshot archive"
			default="%%ProjectName-par.qar"
			type="String" format="CopyValue" />
			type="String" format="CopyValue" />


		<input>
		<input>