cv32e40p icon indicating copy to clipboard operation
cv32e40p copied to clipboard

Blocking assignment in an always_latch block

Open MikeOpenHWGroup opened this issue 2 years ago • 6 comments

As discussed in #753, cv32e40p_register_file_latch.sv uses a blocking assignment in an always_latch block, and I believe that is not compliant with the LRM (clause 9.2.2.3 of 1800-2017).

It is not clear to me that this has caused any functional issues in either RTL or gate-sims.

MikeOpenHWGroup avatar Jan 20 '23 14:01 MikeOpenHWGroup

as cv32e40p supports at TRL5 only the FF-based RF I added the WAIVED label, but still to be fixed in my opinion. @pascalgouedo ? what do you think? will you use the latch-based RF in your project?

davideschiavone avatar Jan 23 '23 18:01 davideschiavone

Hi, We are not using latch-based design. But in my opinion we should correct it and cv32e40p_sim_clock_gate as well to totally get rid of further problems or remarks.

Even if as said by @MikeOpenHWGroup Verilator is not an OpenHW target, it is heavily used by Embecosm to verify all new v2 features for next GCC toolchain.

Cheers, Pascal.

pascalgouedo avatar Jan 24 '23 10:01 pascalgouedo

the clock gate file should be correct (it uses <= and not =)

For Verilator we can always apply a compile time waiver

davideschiavone avatar Jan 24 '23 11:01 davideschiavone

I also faced the same error. I just replaced the <= with < and now it's compiling without any error.

gullahmed1251 avatar Jan 24 '23 15:01 gullahmed1251

Hi @gullahmed1251, I hope you meant to say "I just replaced the <= with =".

MikeOpenHWGroup avatar Jan 24 '23 22:01 MikeOpenHWGroup

Yeah, you are right. I just noticed it.

gullahmed1251 avatar Jan 25 '23 12:01 gullahmed1251

Hi @davideschiavone and @pascalgouedo, what is the status of this issue. I believe it was agreed to fix it, but there hasn't been a resolution and the "waived" label was still applied.

I have removed the label and assigned the issue to both of you.

MikeOpenHWGroup avatar Mar 22 '24 15:03 MikeOpenHWGroup