Howdy Jef,
i understand that it is difficult to help me out on this one. Without criticizing you, your first two paragraphs are of no use to me, but ...
To summarized them:
1. You wondered if the "Register X is equivalent to Y" warnings were a problem. My response is that the optimizers do this kind of thing all the time, so it is very possible that it is NOT a problem...UNLESS you have a problem in your design.
2. If your design doesn't work in simulation EXACTLY as you would expect it to, don't bother loading it into the FPGA.
The last paragraph is more than interesting to me, I have heard from those clock banks from time to time, but never thought of using them, everything always seemed to work out fine without them. Maybe time to start using them.
Can you give me a short push in the back and tell me how I can use them?
Sure, although here in a second, I'll propose a better route to take. To get a global clock buffer in Xilinx, just add:
- Code: Select all
gclk_1 : BUFG port map (I => unbuffered_clk_in, O => global_clk_out);
after your BEGIN statement. You may need to add a Xilinx library and/or a component declaration (*) to the top of your .vhd file as well, if you don't have it already. I see in your synth results that clk is already on a global clock buffer - the tools will do that for you sometimes.
The gotcha to generating a clock with flops and then putting it onto the global clock network is that it incurs extra delay, so the maximum frequency of your design is likely to go down considerably (2 or 4 ns easily, and possibly quite a bit more). If the design can't live with that kind of slow-down, you might be able to use a DCM to remove most of the delay, but now it's a kludge on top of another kludge.
A better solution than adding a bunch of BUFG's and DCM's is to use only one clock for the whole design. Instead of feeding all your xclk's and sync's into the clock inputs of the flip-flops, feed them into the clock enable of the flop. Then make sure all your clock inputs come from the single clk signal. This is a little more radical change to your design since you'll have to modify the xclk's and sync(s) to be a single "clk" cycle wide (rather than 50% duty cycle), but it will result in fewer problems in the long run - and it'll be easier to reach higher clock frequencies).
Good luck,
Marc
(*) BUFG component declaration goes before the BEGIN statement, and is simply
- Code: Select all
COMPONENT BUFG IS
PORT (
I : IN std_logic;
O : OUT std_logic);
END COMPONENT BUFG;