[英]Incomplete sensitivity list in VHDL with Sigasi editor
Currently, I try to develop my VHDL skills and therefore I use the Sigasi plugin for Eclipse to write some VHDL code. 当前,我尝试发展我的VHDL技能,因此我使用Sigasi Eclipse插件来编写一些VHDL代码。 Sigasi is a great tool, but there is one thing, which is bothering me, though. Sigasi是一个很棒的工具,但是有一件事让我感到困扰。 Constantly, Sigasi tosses warnings about incomplete sensitivity lists in process definitions, which are not justified from my point of view. 不断地,Sigasi会在过程定义中抛出有关灵敏度列表不完整的警告,从我的观点来看,这是不合理的。 One example is the following entity with the corresponding architecture. 一个示例是具有相应体系结构的以下实体。 It's the description of a ring shift register 这是一个移位寄存器的描述
library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;
entity RingShiftReg is
generic(
WIDTH : integer := 8
);
port(
clock : in std_ulogic;
reset : in std_ulogic;
set : in std_ulogic;
initValue : in std_ulogic_vector(WIDTH - 1 downto 0);
value : out std_ulogic_vector(WIDTH - 1 downto 0)
);
end;
architecture ringShiftRegArch of RingShiftReg is
signal innerValue : std_ulogic_vector(WIDTH - 1 downto 0);
begin
P1: process(clock, reset)
begin
if reset = '1' then
innerValue <= (others => '0');
elsif rising_edge(clock) then
if set = '1' then
innerValue <= initValue;
end if;
else
innerValue <= innerValue(WIDTH - 2 downto 0) & innerValue(WIDTH - 1);
end if;
end process;
value <= innerValue;
end ringShiftRegArch;
The Sigasi Linter claims that the sensitivity list of process P1
is incomplete, because the signal innerValue
is missing. Sigasi Linter声称过程P1
的灵敏度列表不完整,因为缺少信号innerValue
。 But in my opinion, it's not necessary to put innerValue
in the sensitivity list, because it's totally dependent from clock
and reset
. 但是我认为,不必将innerValue
放入灵敏度列表,因为它完全取决于clock
和reset
。
What is correct, now? 现在正确吗?
To make it short, your 简而言之,您的
else
innerValue <= ...
end if;
does not make sense in classical digital hardware because in this context your else
means: 在传统的数字硬件中没有意义,因为在这种情况下,您的else
意思是:
clock
or reset
(or both) changed, and clock
或reset
(或同时更改),以及 reset
is not equal to '1'
, and reset
不等于'1'
,并且 clock
. 这不是clock
的上升沿。 So, it can be: 因此,可以是:
reset
, or reset
的下降沿,或者 clock
while reset
equals '0'
. reset
时clock
的下降沿等于'0'
。 Probably not what you intended. 可能不是您的意图。 If it is what you intended, you should try to find another target technology. 如果这是您想要的,则应尝试找到其他目标技术。 Classical digital hardware cannot achieve this because there are no multi-clocks, multi-edges, registers in ASIC standard cells libraries or in FPGAs. 传统的数字硬件无法实现这一点,因为ASIC标准单元库或FPGA中没有多时钟,多边缘,寄存器。
Did you perhaps mean this? 你可能是这个意思吗?
elsif rising_edge(clock) then
if set = '1' then
innerValue <= initValue;
else
innerValue <= innerValue(WIDTH - 2 downto 0) & innerValue(WIDTH - 1);
end if;
end if;
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.