Examples of using PSL for functional and formal verification of VHDL with GHDL (and SymbiYosys)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
708 B

  1. vunit psl_vunit_vu (psl_vunit(beh)) {
  2. -- All is sensitive to rising edge of clk
  3. default clock is rising_edge(clk);
  4. gen_0 : if FORMAL = "SERE_0" or formal = "ALL" generate
  5. -- This assertion holds
  6. SERE_0_a : assert {a};
  7. end generate gen_0;
  8. gen_1 : if FORMAL = "SERE_1" or formal = "ALL" generate
  9. -- This assertion holds
  10. SERE_1_a : assert {a; a};
  11. end generate gen_1;
  12. gen_2 : if FORMAL = "SERE_2" or formal = "ALL" generate
  13. -- This assertion holds
  14. SERE_2_a : assert {a; a and b};
  15. end generate gen_2;
  16. gen_3 : if FORMAL = "SERE_3" or formal = "ALL" generate
  17. -- This assertion doesn't hold at cycle 2
  18. SERE_3_a : assert always {a; a};
  19. end generate gen_3;
  20. }