# Removing warning FF/Latch trimming

I have a 16 bit signal, for me only the last 4 bits are important and the first 12 bits are always "0", so I'm doing nothing with the first 12 bits and in the end it goes out of my component to next component like this :

my16bitsignal <= x"000"& my4bitsignal;


In my VHDL component I do lots of operations etc. with my4bitsignal but in the end when I synthesize Xilinx gives me these warnings:

WARNING:Xst:1710 - FF/Latch <my16bitsignal_4> (without init value) has a constant value of 0 in block <MYCOMPONENT>. This FF/Latch will be trimmed during the optimization process.
WARNING:Xst:1895 - Due to other FF/Latch trimming, FF/Latch <my16bitsignal_5> (without init value) has a constant value of 0 in block <MYCOMPONENT>. This FF/Latch will be trimmed during the optimization process.
.
.
WARNING:Xst:1895 - Due to other FF/Latch trimming, FF/Latch <my16bitsignal_15> (without init value) has a constant value of 0 in block <MYCOMPONENT>. This FF/Latch will be trimmed during the optimization process.
WARNING:Xst:2404 -  FFs/Latches <my16bitsignal<15:4>> (without init value) have a constant value of 0 in block <MYCOMPONENT>.


How can I avoid these warnings? Create a temporary 12 bit signal with zeros and then assign it to first 12 bits? This solution seems very lame to me, is there another way?

• Accept that these are warnings, not errors. If you ever use Xilinx's own IP you will find it generates hundreds of such warnings, and there is nothing you can do about that (except avoiding vendor IP). Jun 17, 2014 at 11:20
• @BrianDrummond what do you mean with own IP? Our prof says I don't like latches thus I have to remove it somehow ... Jun 17, 2014 at 11:21
• Read the warning : it tells you the FF or latch is being removed (trimmed) for you. Jun 17, 2014 at 11:23
• @BrianDrummond you have a point =) thanks! I can give him this argument, but still I would be glad to know if there is a way of removing it. Jun 17, 2014 at 11:27
• Only this : make my16bitsignal the correct width ... 4 bits ... and fix its name! Jun 17, 2014 at 11:28