Forum Discussion
Altera_Forum
Honored Contributor
8 years agoThere are also issues with your code.
You are using std_logic inputs, and using > to compare them. in VHDL, std_logic is a 9 state type, with ('U', 'X'. '0', '1', 'Z', 'W', 'L', 'H', '-') as all the states. In simulation, using > may lead to some odd situations as 'Z' and '-' are bother greater than '1'. In real hardware, only '0' and '1' can exist (and 'Z' on a tri state, but it cannot be checked for on hardware). So, I recomend using only = when comparing std_logic