Skip to content
Snippets Groups Projects
Commit 8b71641b authored by Pieter Donker's avatar Pieter Donker
Browse files

L2SDP-1032, now a better assert format

parent 76d64c1a
Branches
Tags
1 merge request!403L2SDP-1032, apply vhdl_style assert/report rule
Pipeline #78173 passed
......@@ -442,22 +442,22 @@ begin
-- Verify, only log when wrong
if I = 0 then
assert tx_mon_nof_sop_arr(I) = c_mon_nof_sop_first
report
c_tb_str & "Wrong tx nof_sop for stream (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong tx nof_sop for stream (" & natural'image(I) & ")"
severity ERROR;
assert tx_mon_nof_valid_arr(I) = c_mon_nof_valid_first_tx
report
c_tb_str & "Wrong tx nof_valid for stream (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong tx nof_valid for stream (" & natural'image(I) & ")"
severity ERROR;
else
assert tx_mon_nof_sop_arr(I) = c_mon_nof_sop_others
report
c_tb_str & "Wrong tx nof_sop for stream (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong tx nof_sop for stream (" & natural'image(I) & ")"
severity ERROR;
assert tx_mon_nof_valid_arr(I) = c_mon_nof_valid_others_tx
report
c_tb_str & "Wrong tx nof_valid for stream (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong tx nof_valid for stream (" & natural'image(I) & ")"
severity ERROR;
end if;
assert tx_mon_latency_arr(I) = c_tx_exp_latency
report
c_tb_str & "Wrong tx latency for stream (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong tx latency for stream (" & natural'image(I) & ")"
severity ERROR;
-- For short block lengths the Rx latency appears to become less, the
-- exact Rx latency is therefore hard to predetermine. The actual
......@@ -465,8 +465,8 @@ begin
-- the latency when it is more or less fixed.
if c_rx_exp_latency_en then
assert almost_equal(rx_mon_latency_arr(I), c_rx_exp_latency_st, 10)
report
c_tb_str & "Wrong rx latency using st interface (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong rx latency using st interface (" & natural'image(I) & ")"
severity ERROR;
end if;
end if;
end loop;
......
......@@ -217,8 +217,8 @@ begin
proc_mem_mm_bus_rd(2 * I, mm_clk, reg_bsn_align_cipo, reg_bsn_align_copi);
proc_mem_mm_bus_rd_latency(1, mm_clk);
assert reg_bsn_align_cipo.rddata(0) = '1'
report
"Wrong stream disable for output " & int_to_str(I) severity ERROR;
report "Wrong stream disable for output " & int_to_str(I)
severity ERROR;
end loop;
-- Write stream enable bits for stream_en_arr
......@@ -233,8 +233,8 @@ begin
proc_mem_mm_bus_rd(2 * I, mm_clk, reg_bsn_align_cipo, reg_bsn_align_copi);
proc_mem_mm_bus_rd_latency(1, mm_clk);
assert reg_bsn_align_cipo.rddata(0) = '0'
report
"Wrong BSN align stream enable for output " & int_to_str(I) severity ERROR;
report "Wrong BSN align stream enable for output " & int_to_str(I)
severity ERROR;
end loop;
-- Write stream enable bits for stream_en_arr
......@@ -249,8 +249,8 @@ begin
proc_mem_mm_bus_rd(2 * I, mm_clk, reg_bsn_align_cipo, reg_bsn_align_copi);
proc_mem_mm_bus_rd_latency(1, mm_clk);
assert reg_bsn_align_cipo.rddata(0) = '1'
report
"Wrong BSN align stream enable for output " & int_to_str(I) severity ERROR;
report "Wrong BSN align stream enable for output " & int_to_str(I)
severity ERROR;
end loop;
-- End of MM test
......@@ -272,8 +272,7 @@ begin
if g_lost_input = true and I = c_nof_streams - 1 then
v_exp_latency := -1; -- -1 for BSN monitor timeout due to lost input
assert mon_latency_input_arr(I) = v_exp_latency
report
"Wrong input BSN monitor latency timeout for input " & int_to_str(I) &
report "Wrong input BSN monitor latency timeout for input " & int_to_str(I) &
" (" & int_to_str(mon_latency_input_arr(I)) &
" /= " & int_to_str(v_exp_latency) &
")"
......@@ -281,8 +280,7 @@ begin
else
v_exp_latency := c_mon_sync_latency + func_input_delay(I);
assert mon_latency_input_arr(I) = v_exp_latency
report
"Wrong input BSN monitor latency for input " & int_to_str(I) &
report "Wrong input BSN monitor latency for input " & int_to_str(I) &
" (" & int_to_str(mon_latency_input_arr(I)) &
" /= " & int_to_str(v_exp_latency) &
")"
......@@ -298,8 +296,7 @@ begin
proc_common_wait_some_cycles(mm_clk, 1);
v_exp_latency := c_mon_sync_latency + c_total_latency;
assert mon_latency_output = v_exp_latency
report
"Wrong output BSN monitor latency (" & int_to_str(mon_latency_output) &
report "Wrong output BSN monitor latency (" & int_to_str(mon_latency_output) &
" /= " & int_to_str(v_exp_latency) &
")"
severity ERROR;
......
......@@ -359,8 +359,8 @@ begin
-- the latency when it is more or less fixed.
if c_rx_exp_latency_en then
assert almost_equal(rx_mon_latency, c_rx_exp_latency_st, 0)
report
c_tb_str & "Wrong rx latency using st interface" severity ERROR;
report c_tb_str & "Wrong rx latency using st interface"
severity ERROR;
end if;
end if;
......
......@@ -543,18 +543,18 @@ begin
if g_nof_streams = 1 then
if g_eth_sim_level = 0 then
assert almost_equal(rx_mon_latency_arr(I), c_rx_exp_latency_tech_tse, 10)
report
c_tb_str & "Wrong rx latency using tech_tse interface" severity ERROR;
report c_tb_str & "Wrong rx latency using tech_tse interface"
severity ERROR;
elsif g_eth_sim_level = 1 then
assert almost_equal(rx_mon_latency_arr(I), c_rx_exp_latency_sim_tse, 10)
report
c_tb_str & "Wrong rx latency using sim_tse interface" severity ERROR;
report c_tb_str & "Wrong rx latency using sim_tse interface"
severity ERROR;
end if;
end if;
else
assert almost_equal(rx_mon_latency_arr(I), c_rx_exp_latency_st, 10)
report
c_tb_str & "Wrong rx latency using st interface (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong rx latency using st interface (" & natural'image(I) & ")"
severity ERROR;
end if;
end if;
end if;
......
......@@ -482,8 +482,8 @@ begin
-- the latency when it is more or less fixed.
if c_rx_exp_latency_en then
assert almost_equal(rx_mon_latency_arr(I), c_rx_exp_latency_st, 10)
report
c_tb_str & "Wrong rx latency using st interface (" & natural'image(I) & ")" severity ERROR;
report c_tb_str & "Wrong rx latency using st interface (" & natural'image(I) & ")"
severity ERROR;
end if;
end if;
end loop;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment