-- Copyright 2000 UCR all rights reserved
-- this program may be copy or altered so
-- long as this header stays intake
-- Original design Randy January rjanuary@cs.ucr.edu

library IEEE;
use IEEE.STD_LOGIC_1164.all;
use IEEE.STD_LOGIC_ARITH.all;

entity scpu_sign is
  
  port (
    reset    : in  std_logic; 
    Input    : in  unsigned (31 downto 0);
    signChk  : in std_logic;
    sign_out   : out std_logic
    );

end scpu_sign;

architecture beh of scpu_sign is

begin  -- beh

  process (reset, Input, signChk)
  begin

    if (reset = '1') then 
      sign_out <= '0';
    elsif (signChk = '1') then
      sign_out <= Input(31);
    else
      sign_out <= '0';
    end if;
  end process;

end beh;
