Explicitly check against '1' in if statements
authorAnton Blanchard <anton@linux.ibm.com>
Wed, 11 Sep 2019 23:19:31 +0000 (09:19 +1000)
committerAnton Blanchard <anton@ozlabs.org>
Wed, 11 Sep 2019 23:19:31 +0000 (09:19 +1000)
nvc doesn't like what I think is a VHDL 2008 construct. Lets just
check against '1' explicitly.

Signed-off-by: Anton Blanchard <anton@linux.ibm.com>
decode1.vhdl
decode2.vhdl

index 38d31dd09d1c0f61f6e270ff36c8b479751cd35b..10367b6850a0500b952a7a92b17edc90df159db6 100644 (file)
@@ -248,7 +248,7 @@ begin
 
                ppc_insn := PPC_ILLEGAL;
 
-               if f_in.valid then
+               if f_in.valid = '1' then
                        v.nia  := f_in.nia;
                        v.insn := f_in.insn;
 
index 3aff41e7246c5aed2b6d81ea37c59f7e3162ac62..07bfb795c638eacf78e25ac5878ab6d5a8d9b7f4 100644 (file)
@@ -260,7 +260,7 @@ begin
                v.e.cr := c_in.read_cr_data;
                v.e.input_carry := d_in.decode.input_carry;
                v.e.output_carry := d_in.decode.output_carry;
-               if d_in.decode.lr then
+               if d_in.decode.lr = '1' then
                        v.e.lr := insn_lk(d_in.insn);
                end if;
                v.e.const1 := decode_const_a(d_in.decode.const_a, d_in.insn);