quick.gif

space2.gif

space2.gif

space2.gif

space2.gif

space2.gif

space2.gif

space2.gif

   

space.gif

   

space.gif

  ../images/main/bullet_star_pink.gif Another named property

One property can call another property, this is allowed for performing operation as mentioned in next few pages. Below example shows how to do this.

   

space.gif

   

space.gif

  ../images/main/4blue_dots_bullets.gif Example : Another named property
   

space.gif


  1 //+++++++++++++++++++++++++++++++++++++++++++++++++
  2 //   DUT With assertions
  3 //+++++++++++++++++++++++++++++++++++++++++++++++++
  4 module nameproperty_assertion();
  5 
  6 logic req,gnt,clk;
  7 //=================================================
  8 //  Clock generator
  9 //=================================================
 10 initial begin
 11  clk = 0; 
 12  forever  #1  clk ++;
 13 end
 14 //=================================================
 15 // Simple DUT behaviour
 16 //=================================================
 17 always @ (posedge clk)
 18   gnt <= req;
 19 //=================================================
 20 // Test Vector generation
 21 //=================================================
 22 initial begin
 23   req <= 0;
 24    #3  req <= 1;
 25    #5  req <= 0;
 26    #1  $finish;
 27 end
 28 //=================================================
 29 // One property called inside another property
 30 //=================================================
 31 property vanila_prop;
 32    req  ##1  gnt;
 33 endproperty
 34 
 35 property nameproperty_prop;
 36   @ (posedge clk)
 37     vanila_prop;
 38 endproperty
 39 //=================================================
 40 // Assertion Directive Layer
 41 //=================================================
 42 nameproperty_assert : assert property (nameproperty_prop);
 43 
 44 endmodule
You could download file nameproperty_assertion.sv here
   

space.gif

  ../images/main/4blue_dots_bullets.gif Simulation : Another named property
   

space.gif

 "nameproperty_assertion.sv", 42: 
 nameproperty_assertion.nameproperty_assert: started at 1s failed at 1s
         Offending 'req'
 "nameproperty_assertion.sv", 42: 
 nameproperty_assertion.nameproperty_assert: started at 3s failed at 3s
         Offending 'req'
 $finish called from file "nameproperty_assertion.sv", line 26.
   

space.gif

   

space.gif

   

space.gif

   

space.gif

space2.gif

space2.gif

space2.gif

space2.gif

space2.gif

  

Copyright © 1998-2014

Deepak Kumar Tala - All rights reserved

Do you have any Comment? mail me at:deepak@asic-world.com