# Logical Equivalence Check of Quasar RISC-V Core 1.0 from Lampro Mellon
This repository contains the EL2 SweRV Core, Quasar Core design in RTL, and the setup files. To run logical equivalency check on the two designs follow these instructions.
Following changes have been made in the design files to get them ready for tool, if you wants to clone the golden design from chipsalliance repository do following changes in the golden design.
The directory $RV_ROOT/verif/LEC/LEC_RTL is not available initially when the Quasar RISC-V core is clonned from repository. It will be generated when the "make -f $RV_ROOT/tools/Makefile lec" is executed. Once this command is executed, it will generated the RTL of Quasar RISC-V core and place it in the $RV_ROOT/generated_rtl.
Including el2_param.vh in the golden design (El2 SweRV core) yields syntax error as formality tool does not accept parameter in this format, for further detail please refer to FMR_VLOG-481 formality error message. To fix this issue follow following steps
1. Remove all pt. from all design files
2. Remove #(.pt(pt)) in module instantiation from all design files
5. Replace el2_param.vh with the parameter.sv file.
Importing el2_pkg in all design files yields FMR_VLOG-224 formality error message which explains that a reference to the given package should be analyzed before its declaration has been analyzed. In order to ensure this, the packet file which has all the packets should be included in the quasar top.
There are some registers which are potentionally constants when a test pattern is applied to these signals by the tool it causes design failures. To solve this problem the potionally constant registers were identified, and a constant value is applied to the register in setup mode. The constant setup file is present in $RV_ROOT/verif/LEC/setup_files/constant.fms
The tool matches the compare points on either name based or by signal analysis, but in some cases the tools fails to identify the equivalent points. All these unmatched points were matched manually through "set_user_match" command. The unmatched point can be a flop, port, latch or a black box pins, their details are present in the following directory respectively.