Altera_Forum
Honored Contributor
14 years agoAdvices on VHDL signals initialization (Quartus synthesis vs Modelsim simulation)
Hi everybody,
I use Modelsim to simulate my VHDL design, and when declaring signals I usually don't add any initialization since I know that inside the FPGA the logic is "automatically" initialized after the device exits from POR. Unfortunately this is becoming an issue with Modelsim since to "safely" run the simulation all the signals should be initialized, generally to '0' or (others => '0'). Up to now I've worked by adding initializations to all signals when using the file in Modelsim, and commenting them away when using them in my Quartus project: signal a : std_logic; --Quartus signal a : std_logic := '0'; --Modelsim Now I'm wondering: from the Quartus synthesis point of view is it advisable to initialize ALL the signals when declaring them in my VHDL? Will Quartus treat all the signals initialized to '0' in the same way as the uninitialized ones? This way I could avoid adding/working with the 2 versions of each files (with and without signals initialization). Any suggestion? Thank you very much for your help :) Claudio