Can someone help me understand why the first code snippet works as I would expect it, but the second snippet simulation holds all values at 'U'?
Note: WRITE_ENABLE_FIBRE_REG(0) is assigned in a different process;
Works fine:
Nothing but 'U':
Note: WRITE_ENABLE_FIBRE_REG(0) is assigned in a different process;
Works fine:
HTML Code:
process (CLK, RESET_N) is
begin
if CLK'event and CLK = '1' then -- rising clock edge
WRITE_ENABLE_FIBRE_REG(1) <= WRITE_ENABLE_FIBRE_REG(0);
WRITE_ENABLE_FIBRE_REG(2) <= WRITE_ENABLE_FIBRE_REG(1);
end if;
end process;
HTML Code:
process (CLK, RESET_N) is
begin
if CLK'event and CLK = '1' then -- rising clock edge
for i in 1 to 2 loop
WRITE_ENABLE_FIBRE_REG(i) <= WRITE_ENABLE_FIBRE_REG(i - 1);
end loop; -- i
end if;
end process;