intMAN  version 0.2_20130422
c_slack.vhd
Go to the documentation of this file.
1 -------------------------------------------------------
2 --! @file
3 --! @brief Slack-condition check for the intMAN hardware
4 --! @author Josef Strnadel, Brno University of Technology, Faculty of Information Technology
5 --! @email strnadel@fit.vutbr.cz
6 --! @date 2013-04-17
7 -------------------------------------------------------
8 
9 library IEEE;
10 use IEEE.STD_LOGIC_1164.ALL;
11 use IEEE.NUMERIC_STD.ALL;
12 -- use IEEE.STD_LOGIC_ARITH.ALL;
13 use work.intMAN_package.all;
14 
15 --
16 --
17 --
18 --! Entity of the slack-condition check unit for the intMAN hardware (interface)
19 --
20 entity c_slack is
21  port(
22  monpri : in STD_LOGIC_VECTOR(t_pri_width_range); --! priority of the running task (being monitored)
23  monslack : in STD_LOGIC; --! slack signal (being monitored)
24  valid : out STD_LOGIC --! priority-condition result
25  );
26 end c_slack;
27 
28 --
29 --
30 --
31 --! Architecture of the slack-condition check unit for the intMAN hardware (inner structure)
32 --
33 architecture arch of c_slack is
34 begin
35  --! Slack-condition check process being sensitive to the change of monitored priority and slack line
36  p_cslack : process(monpri, monslack)
37  begin
38  if((TO_INTEGER(UNSIGNED(monpri)) > PRI_HARD_LAST) or (monslack = '1')) then
39  valid <= '1';
40  else
41  valid <= '0';
42  end if;
43  end process;
44 end arch;
© 2013 Josef Strnadel (email, web), Faculty of Information Technology, Brno University of Technology (web)