23 use IEEE.STD_LOGIC_1164.
ALL;
24 use IEEE.STD_LOGIC_UNSIGNED.
ALL;
43 L1id : in STD_LOGIC_vector(23 downto 0);
44 ECRid : in STD_LOGIC_vector(7 downto 0);
46 timeout_threshold : in STD_LOGIC_vector(31 downto 0);
47 l1id_continuity_control : in STD_LOGIC_vector (31 downto 0);
48 l1id_continuity_status : out STD_LOGIC_vector (31 downto 0);
49 l1id_local_miss : out STD_LOGIC_vector (31 downto 0);
50 l1id_ttc_miss : out STD_LOGIC_vector (31 downto 0);
51 l1id_error_count : out STD_LOGIC_vector(31 downto 0);
52 repeat_counter : out STD_LOGIC_vector(31 downto 0)
62 signal L1id_counter : STD_LOGIC_vector(23 downto 0);
63 signal ECRid_counter : STD_LOGIC_vector(7 downto 0);
64 signal timeout_counter : STD_LOGIC_vector(31 downto 0);
65 signal L1id_error_counter : STD_LOGIC_vector(31 downto 0);
66 signal timeout_enable : STD_LOGIC;
67 signal timeout : STD_LOGIC;
68 signal L1id_mismatch : STD_LOGIC;
69 signal l1id_compare : STD_LOGIC;
70 signal ECRid_compare : STD_LOGIC;
71 signal capture : STD_LOGIC;
72 signal l1id_local_miss_i : STD_LOGIC_vector (31 downto 0);
73 signal l1id_ttc_miss_i : STD_LOGIC_vector (31 downto 0);
77 signal clear : std_logic;
78 signal clear_s : std_logic;
79 signal clear_s_del : std_logic;
80 signal armed : std_logic;
81 signal armed_s : std_logic;
82 signal armed_s_del : std_logic;
83 signal armed_pulse : std_logic;
84 signal armed_stat : std_logic;
85 signal triggered : std_logic;
86 signal l1id_del : std_logic;
87 signal ECRid_del : std_logic;
88 signal word_counter : std_logic_vector (1 downto 0);
89 signal current_l1ID : std_logic_vector (31 downto 0);
90 signal last_l1ID : std_logic_vector (31 downto 0);
91 signal repeat_counter_i : std_logic_vector (31 downto 0);
92 signal clear_local_l1id : std_logic;
93 signal clear_local_ECRid : std_logic;
95 COMPONENT ila_l1id_cont
100 probe0 :
IN STD_LOGIC_VECTOR(
1 DOWNTO 0);
101 probe1 :
IN STD_LOGIC_VECTOR(
0 DOWNTO 0);
102 probe2 :
IN STD_LOGIC_VECTOR(
0 DOWNTO 0);
103 probe3 :
IN STD_LOGIC_VECTOR(
0 DOWNTO 0);
104 probe4 :
IN STD_LOGIC_VECTOR(
0 DOWNTO 0);
105 probe5 :
IN STD_LOGIC_VECTOR(
0 DOWNTO 0);
106 probe6 :
IN STD_LOGIC_VECTOR(
0 DOWNTO 0);
107 probe7 :
IN STD_LOGIC_VECTOR(
0 DOWNTO 0);
108 probe8 :
IN STD_LOGIC_VECTOR(
23 DOWNTO 0);
109 probe9 :
IN STD_LOGIC_VECTOR(
7 DOWNTO 0);
110 probe10 :
IN STD_LOGIC_VECTOR(
23 DOWNTO 0);
111 probe11 :
IN STD_LOGIC_VECTOR(
7 DOWNTO 0);
112 probe12 :
IN STD_LOGIC_VECTOR(
31 DOWNTO 0);
113 probe13 :
IN STD_LOGIC_VECTOR(
31 DOWNTO 0);
114 probe14 :
IN STD_LOGIC_VECTOR(
31 DOWNTO 0)
123 timeout_enable <= '1';
124 clear_local_l1id <= l1id_continuity_control(4);
125 clear_local_ECRid <= l1id_continuity_control(5);
127 process (clock)
begin
128 if rising_edge (clock) then
132 ECRid_compare <= '0';
135 l1id_compare <= l1id_del;
137 ECRid_compare <= ECRid_del;
143 process (clock)
begin
144 if rising_edge (clock) then
145 if (reset = '1') or ((L1A = '1') and (word_counter = 3)) then
146 timeout_counter <= (others=> '0');
148 elsif (timeout_enable = '1') and (timeout_counter <= timeout_threshold) then
149 timeout_counter <= (timeout_counter + '1');
150 elsif (timeout_counter >= timeout_threshold) then
153 timeout_counter <= timeout_counter;
162 process (clock)
begin
163 if rising_edge (clock) then
164 if (reset = '1') then
165 word_counter <= (others=> '0');
166 elsif (L1A = '1') or (ECR = '1') then
167 word_counter <= (word_counter + 1);
169 word_counter <= word_counter;
175 process (clock)
begin
176 if rising_edge (clock) then
177 if (reset = '1') or (clear_local_l1id = '1') then
178 L1id_counter <= (others=> '0');
180 elsif (L1A = '1') and (timeout = '0') and (word_counter = x"2") then
181 L1id_counter <= (L1id_counter + '1');
182 elsif (L1A = '1') and (timeout = '1') and (word_counter = x"2") then
183 L1id_counter <= L1id;
184 elsif (l1id_compare = '1') and (word_counter = x"3") and (L1id_counter /= L1ID) then
185 L1id_counter <= L1ID;
188 L1id_counter <= L1id_counter;
198 process (clock)
begin
199 if rising_edge (clock) then
200 if (reset = '1') or (clear = '1') then
201 L1id_error_counter <= (others=> '0');
204 l1id_local_miss_i <= (others => '0');
205 l1id_ttc_miss_i <= (others => '0');
206 elsif (armed_pulse = '1') then
208 elsif (l1id_compare = '1')and (word_counter = x"3") and ((ECRid_counter & L1id_counter) /= (ECRid & L1ID)) and ((ECRid & L1ID) /= x"00000000") and timeout = '0' then
209 L1id_error_counter <= L1id_error_counter + '1';
210 if (armed_stat = '1') then
213 l1id_local_miss_i <= ECRid_counter & l1id_counter;
214 l1id_ttc_miss_i <= ECRid & l1id;
216 triggered <= triggered;
217 l1id_local_miss_i <= l1id_local_miss_i;
218 l1id_ttc_miss_i <= l1id_ttc_miss_i;
222 L1id_error_counter <= L1id_error_counter;
231 l1id_local_miss <= l1id_local_miss_i;
232 l1id_ttc_miss <= l1id_ttc_miss_i;
234 l1id_error_count <= L1id_error_counter;
238 process (clock)
begin
239 if rising_edge (clock) then
240 if (reset = '1') then
241 L1id_mismatch <= '0';
242 elsif (L1id_counter /= L1id) and (timeout = '0') then
243 L1id_mismatch <= '1';
245 L1id_mismatch <= L1id_mismatch;
252 process (clock)
begin
253 if rising_edge (clock) then
254 if (reset = '1') or (clear_local_ECRid = '1')then
255 ECRid_counter <= (others=> '0');
257 elsif (ECR = '1') and (timeout = '0') and (word_counter = x"2") then
258 ECRid_counter <= (ECRid_counter + '1');
259 elsif (ECR = '1') and (timeout = '1') and (word_counter = x"2") then
260 ECRid_counter <= ECRid;
261 elsif (l1id_compare = '1') and (word_counter = x"3") and (ECRid_counter /= ECRID) then
262 ECRid_counter <= ECRID;
265 ECRid_counter <= ECRid_counter;
273 process (clock)
begin
274 if rising_edge (clock) then
275 if (reset = '1') then
276 current_l1id <= (others=> '0');
277 last_l1id <= (others=> '0');
278 elsif (word_counter = x"3")and(l1id_compare = '1') then
279 current_l1ID <= (ECRid & L1id);
280 last_L1id <= current_l1ID;
285 process (clock)
begin
286 if rising_edge (clock) then
287 if (reset = '1') or (clear = '1')then
288 repeat_counter_i <= (others=> '0');
289 elsif (word_counter = x"3") and (l1id_compare = '1')and (current_l1id = (ECRid & L1id)) and (current_l1id /= x"00000000") then
290 repeat_counter_i <= (repeat_counter_i + 1);
295 repeat_counter <= repeat_counter_i;
305 if rising_edge (clock) then
306 clear_s <= l1id_continuity_control(1);
307 clear_s_del <= clear_s;
311 clear <= clear_s_del and not clear_s;
314 if rising_edge (clock) then
315 armed_s <= l1id_continuity_control(0);
316 armed_s_del <= armed_s;
320 armed_pulse <= armed_s_del and not armed_s;
323 if rising_edge (clock) then
324 if (armed_pulse = '1') then
326 elsif (triggered = '1') or (clear = '1') or (reset = '1') then
329 armed_stat <= armed_stat;
335 l1id_continuity_status <= x"0000000" & "00" & triggered & armed_stat;
337 ila_l1id_cont_check: ila_l1id_cont
340 probe0 => word_counter,
341 probe1
(0) => l1id_compare,
344 probe4
(0) => triggered,
345 probe5
(0) => capture,
346 probe6
(0) => armed_stat,
347 probe7
(0) => timeout,
350 probe10 => L1id_counter,
351 probe11 => ECRID_counter,
352 probe12 => repeat_counter_i,
353 probe13 => current_l1id,