Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
20704 Discussions

derive_pll_clocks cmd and it's generated clk

Altera_Forum
Honored Contributor II
1,750 Views

Hi, 

 

I have a question regarding derive_pll_clocks. 

 

Quote taken from QII Handbook Vol 3 pg 6-36 Under title Derive PLL Clocks 

"If you use the write_sdc command after the derive_pll_clock command, the new SDC file contains the individual create_generated_clock commands for the PLL output clock pins and not the derive_pll_clocks command." 

 

My objective here is to get the individual create_generated_clock commands for all PLL output clocks. After full compilation is successful, in TQ analyzer, I do the below: 

1. Create timing netlist, Read SDC, Update timing netlist 

2. Type "write_sdc mysdc.sdc" in the tcl console in TQ analyzer 

 

When I open up mysdc.sdc, I did not get individual create_gen_clk commands in the sdc file, instead what I get is only the command "derive_pll_clocks" in the sdc. 

 

Is my step incorrect or is the QII handbook not right (the quote above)? 

Can some kind souls point me to how I can get individual create_gen_clk commands? 

(the reason I want the individual gen_clk is because I need the exact name of the pll inclk port and the pll outclk port) 

 

Thank you.
0 Kudos
3 Replies
Altera_Forum
Honored Contributor II
594 Views

It probably used to write out the individual commands, but I believe write_sdc has been changed to try to look more like the original commands put into it rather than there "synthesized" versions. For example, if you did something like a wildcarded command like: 

set_output_delay -clock outclock 4.0 dout* 

and dout* was a 32-bit bus, you'd end up with 128 individual dout commands, with -max/-min and -rise/-fall options, which was very annoying. 

That being said, you already have what you want. When you ran derive_pll_clocks and did derive_pll_clocks, there will be an info message in TimeQuest telling you the exact commands, so just cut and paste from there. 

I find that's useful, but I also recommend making use of the report_clocks command in the Task bar, which many people overlook but should have the same information(just not in SDC syntax, but it should have your input and output pin names you are looking for). 

Personally, I stay far away from write_sdc, and really haven't found any reason to use it. (It does write out a searchable text file, but I usually find what I want with report_sdc.)
0 Kudos
Altera_Forum
Honored Contributor II
594 Views

Thanks Rysc, I get it now. 

 

I think Altera should update it's Handbook information since the write_sdc command has been changed and no longer write out individual PLL generated clocks. This is to avoid poor souls like me (noob) thinking over and over again if I've did sth not right. :p 

 

Thanks again!
0 Kudos
Altera_Forum
Honored Contributor II
594 Views

write_sdc still works like it used to if you use "write_sdc -expand". 

 

From the on-line help for write_sdc: 

 

 

--- Quote Start ---  

Generates an SDC file with all current constraints and exceptions. When you use the -expand option, derive_clocks, derive_pll_clocks, derive_lvds_clocks and derive_clock_uncertainty macros are be expanded to corresponding sdc assignments before they are written to a file. If you do not use the -expand option, these macros are preserved. 

--- Quote End ---  

0 Kudos
Reply