'bins' Filtering

SystemVerilog Assertions and Functional Coverage From Scratch SystemVerilog Functional Coverage Language Features
16 minutes
Share the link to this page
Copied
  Completed
You need to have access to the item to view this lesson.
One-time Fee
$39.95
List Price:  $149.95
You save:  $110
₹1,480
List Price:  ₹9,995
You save:  ₹8,515
€38.44
List Price:  €144.28
You save:  €105.84
£31.93
List Price:  £119.86
You save:  £87.93
CA$57.45
List Price:  CA$215.64
You save:  CA$158.19
A$64.12
List Price:  A$240.67
You save:  A$176.55
S$54.27
List Price:  S$203.70
You save:  S$149.43
HK$310.47
List Price:  HK$1,165.34
You save:  HK$854.86
CHF 35.74
List Price:  CHF 134.15
You save:  CHF 98.41
NOK kr456.25
List Price:  NOK kr1,712.53
You save:  NOK kr1,256.27
DKK kr286.72
List Price:  DKK kr1,076.21
You save:  DKK kr789.48
NZ$70.92
List Price:  NZ$266.22
You save:  NZ$195.29
د.إ146.73
List Price:  د.إ550.75
You save:  د.إ404.02
৳4,792.38
List Price:  ৳17,987.92
You save:  ৳13,195.54
RM180.09
List Price:  RM675.97
You save:  RM495.88
₦62,179.77
List Price:  ₦233,388.17
You save:  ₦171,208.40
₨11,161.13
List Price:  ₨41,892.66
You save:  ₨30,731.52
฿1,376.19
List Price:  ฿5,165.47
You save:  ฿3,789.28
₺1,405.79
List Price:  ₺5,276.58
You save:  ₺3,870.78
B$246.73
List Price:  B$926.09
You save:  B$679.36
R734.27
List Price:  R2,756.05
You save:  R2,021.78
Лв75.23
List Price:  Лв282.40
You save:  Лв207.16
₩57,882.25
List Price:  ₩217,257.66
You save:  ₩159,375.41
₪145.78
List Price:  ₪547.21
You save:  ₪401.42
₱2,350.49
List Price:  ₱8,822.45
You save:  ₱6,471.96
¥6,261.91
List Price:  ¥23,503.72
You save:  ¥17,241.81
MX$810.63
List Price:  MX$3,042.66
You save:  MX$2,232.03
QR146.36
List Price:  QR549.38
You save:  QR403.02
P552.40
List Price:  P2,073.41
You save:  P1,521.01
KSh5,163.53
List Price:  KSh19,381.03
You save:  KSh14,217.50
E£2,034.16
List Price:  E£7,635.12
You save:  E£5,600.95
ብር5,099.95
List Price:  ብር19,142.37
You save:  ብር14,042.42
Kz36,674.10
List Price:  Kz137,654.10
You save:  Kz100,980
CLP$39,616.41
List Price:  CLP$148,697.91
You save:  CLP$109,081.50
CN¥291.59
List Price:  CN¥1,094.47
You save:  CN¥802.87
RD$2,439
List Price:  RD$9,154.65
You save:  RD$6,715.65
DA5,375.65
List Price:  DA20,177.19
You save:  DA14,801.54
FJ$92.73
List Price:  FJ$348.08
You save:  FJ$255.34
Q308.92
List Price:  Q1,159.54
You save:  Q850.61
GY$8,390.52
List Price:  GY$31,493.33
You save:  GY$23,102.81
ISK kr5,555.04
List Price:  ISK kr20,850.54
You save:  ISK kr15,295.50
DH402.49
List Price:  DH1,510.75
You save:  DH1,108.25
L735.86
List Price:  L2,762.03
You save:  L2,026.16
ден2,366.27
List Price:  ден8,881.68
You save:  ден6,515.40
MOP$320.99
List Price:  MOP$1,204.85
You save:  MOP$883.85
N$733.03
List Price:  N$2,751.42
You save:  N$2,018.38
C$1,476.03
List Price:  C$5,540.19
You save:  C$4,064.16
रु5,459.94
List Price:  रु20,493.58
You save:  रु15,033.64
S/149.71
List Price:  S/561.93
You save:  S/412.22
K162.56
List Price:  K610.15
You save:  K447.59
SAR150.11
List Price:  SAR563.45
You save:  SAR413.33
ZK1,109.90
List Price:  ZK4,165.96
You save:  ZK3,056.06
L191.30
List Price:  L718.05
You save:  L526.74
Kč966.19
List Price:  Kč3,626.54
You save:  Kč2,660.35
Ft15,901.88
List Price:  Ft59,686.78
You save:  Ft43,784.90
SEK kr440.95
List Price:  SEK kr1,655.10
You save:  SEK kr1,214.15
ARS$40,829.29
List Price:  ARS$153,250.37
You save:  ARS$112,421.08
Bs277.12
List Price:  Bs1,040.18
You save:  Bs763.05
COP$174,918.24
List Price:  COP$656,545.43
You save:  COP$481,627.19
₡20,168.90
List Price:  ₡75,702.82
You save:  ₡55,533.91
L1,018.04
List Price:  L3,821.16
You save:  L2,803.12
₲313,289.69
List Price:  ₲1,175,914.62
You save:  ₲862,624.93
$U1,782.11
List Price:  $U6,689.05
You save:  $U4,906.94
zł163.79
List Price:  zł614.79
You save:  zł451
Subscription
$149.95
$39.95
per week
Payment Plan
$149.96
$39.95
per week
4 payments
Already have an account? Log In

Transcript

Hello, and welcome to this lecture where I'll describe for the nuances of bends. As you know, I've covered bins at length in previous lectures. So, here basically I'm going to show how to filter bins, in the sense that veins right now, from what I have discussed before, are normally created using content values on the on the right hand side, but this is very limited, and you end up creating veins that may not be of much use. So here's an example. I've covered this example before, but I'm taking it a bit further. So I have a PowerPoint, and I want to cover the war, the variable serial underscore war, but what I'm saying is cover only those bits of syrup or feature set, because that's what count wants will give us.

But I want to use this particular value that is returned by count once in declaring beds. So I'm saying wait, set beds count create only that many bins, explicit bans, which are required by zero colon dollar bait cereal award. So they simply convert cereal word into bits. So for example, let's say cereal board is only two bits. Why and the value of cereal board ends up as 102. So here what we are saying is create three bins where the values of zero comma one comma two of cereal board are captured.

Now this is a very trivial example but Let's say your serial war was of type int. And you may end up creating to raise to 32 wins. But with this, you're restricted to only those bits of 32 bits are set. So this is one way of what I call filtering. vents are one way of restricting bids to what you want. Now there is another clause called with clause as part of the language.

And that is quite useful. So let's look at an example. I have my value and x of guide eight. And I'd say cover in x and create more six number of beds. And I'm saying that govern only those values of x v char from zero to 255. Basically 256 values, but restrict creating veins of 256 with whenever or whatever the value of my value mod six is equal to zero.

So don't create all the 256 bands, but only those bands were more of six of my value is equal to zero. So this is one more way of restricting the number of into create with some expression with the with clause. Just to point out that the wait clause is not simply a feature of functional coverage language, but it's basically a feature of the system very log language, but it is useful in the functional coverage also. And the next example, again, I'm saying cover x, but I'm sick. As you notice, I'm using the PowerPoint x itself. And the definition of bins.

So I'm saying date all the values of x, which are which have a mod of six equal to zero. So the point is, this is similar to the previous example. But here I'm using the point itself to say that take all the various PowerPoint and and only capture those where the mod of my value is equal to zero. Now you can also ask the question, What if I just took our point x and Baines equal to x without the root cause, but that doesn't make sense, because no point x and beans equal to x will cover the same thing. So as we can, and sometimes compiler may even give you a warning. So when you want to use the PowerPoint itself in the definition of veins, you might as well use an expression specifically Bit of a clause.

And this is another example where the bid clause comes handy. I have a cover group called verse size, and it takes into parameters next and the size of type eight. And I'm saying cover B size. And I'm declaring three bids. I'm saying that being small, should have been those values of v size, which is equal to one. And the main cover those values are Besides we like to call on max minus one rep max is that input parameter.

And be large basically takes whatever the value of Max is. Now this is what's going to happen. Let's say max value is two as shown here. So this is how the bean will look like one is a constant. So it's one Do colon two minus one is two, column one, and this is two. So you see that to our left with the two value two here, as well as one or left with a value one here, essentially you're creating three different bands, but covering the same values or similar values, and this will skew your coverage report.

Similarly, if you have Mac's equal to one, then this is two colon zero. This is one, so that overlaps with two columns, zero, and one also overlaps with one itself. Again, not good. And if you have Mexico to zero, then this becomes a negative value, and there's no good either. So now, let's say x is equal to three. In that case, nothing will overlap.

One, two colon two, which is fine and three So nothing overlaps. And that's the correct definition. So how would you restrict the value of Max, that's where the VIP clause comes into picture. This is the same example, on this side. But now I'm saying that when you create Ben Smith, with this equation, so to say, but make sure that Max is greater than or equal to three, what what that means is if you end up giving the same value to do on on on Max, then these bins simply won't be created because the condition here is Max must be greater than or equal to three. And just like I say, lesser the values for Yeah, you can do the math and none of the beads with overlap.

So this is one way of restricting a particular right hand side expression to create veins with a with clause. Now We have seen cross and means of intersect before. So I'm just showing that sometimes cross will create literally gazillion cross products. And you may not want that. And that's where reserve intersect comes into picture. So in this example, I have two variables v underscore a and V underscore v. And I'm saying our V underscore a, and create four bins with the value specified on the right hand side.

Similarly cover v, B, and grade four bins. Now I'm saying take up Cross of a and b. So first, let's see how many cross products are created. So basically, you ready to cross off a and b you the cross products are going to be here one B one a one B two, a one b v3 and v4. Similarly for a two similarly for a three Similarly, for a for total of 16 cross products, that's what I've shown here. Now, from within this cross, I want to restrict the cross product.

So what I'm saying here is not have bins of a intersect with a value zero 100 to 200. So let's give a side note for a while, what are the cross products of bins of a intersect value 100 to 200. So a, a has four bins, a one does not have the value 100 to 200. So there's not into the picture, a two has values which are part of 100 to 200. So has a three and so has a four. But since we are saying a Gnar, that means the cross products That will use a value a two, a three, a four, often out of not interest, only a one is of interest.

So the number of cross products are going to be a one B one, a one, B two, B three and a one before. That's what I've shown here. Similarly, I'm saying that take bins of aid or a too explicit bin or bins of B dot v two is an all so a one sorry, a dot a two will cross with the bins of B. So a to b one a two B two, a two B three A to B four. Similarly, the bins of B dot b to meaning this will cross with the brains of a again we do a one B two a two, B two, a three a Between a four, but not then when we were doing Cross of a dot a two with V, we already had a two v two since sort of eight cross products, you're going to get seven cross products.

And lastly, I'm showing explicit means of a one eight or a one, and beans or B dot before so synthesis and N, we're saying create only one cross product, which is a one comma before. So this is just to show that you can create intersect to restrict the number of cross products, and you need to know how to read these cross products, how to understand the cross products that you want to create. This is just a simple example showing If you end up creating things in a certain way that you will get compiler warnings. And the simulator that I have tried gave me compiler warnings, but since the LRM does not dictate that you should give a warning, hopefully, all the simulators get this warning. So I have two variables one is p ONE OF GOD pig two colon zero, and variable p two of that the signed to column zero.

So this will have value zero to seven of P one. And since this is scientists will have values minus four to three. Now in our group, g one, I'm saying cover p one, but as specific bins this way, I'm saying one values are one of P 1-234-567-8910. But remember that P one only can take values zero to seven. So this base definition is called truncate to one comma 2345 comma six seven and simulator with simply no the other values eight 910 and you will get a warning. Similarly, here we are saying minus one that does not exist between zero to seven.

So, if you have 1234567 and the other way is to not p one will never have those values. So, the simulator will truncate this vanes definition to one colon seven. Similarly, for PowerPoint the two which is of type sign, if I say 12345 and 678 910 Well, the only values that we can take are one and two three. So, the rest of the values will be simply ignore and you may get a warning. Similarly here minus one is part of P two 123 is part of P two progress or not. So the basic definition will truncate to minus one, comma one colon three.

So this is just a way of showing you that you need to be careful when you create bins, you need to keep in mind what we're going to cover. And this is we have seen that transition wins at length, but it's just to further explain how to re transition base. So here I'm saying I've been stayed in zero, we will cover values with the go to operator remember go to operator is part of this overload assertions. And you can effectively use that for transition pains during functional coverage. And since it's a go to operator What that means is that transitions that must be covered our head say out and offer any number of calls hex head game and hex a game. But since this is gold wallpaper, the last one he said must come after the last edition of hex a similarly, I have different kinds of transitions specified here, seven, eight to nine is straightforward, but here you need to be careful, there is no transition called 10 to 11 to 12 because what we are saying transition from 1011 to 1314 and 12 to 1314.

So, you get 10 to 1310 to 1411 to 1311 to 14 to 13. Now, you can make the non consequential reputation operator with guru operator. So, here what this means is once you transition to four to five to six, and the last one should come right after the six transition. So, this is just to show you that you can have different kind of server assertion operators used to specify transition beans. So that's pretty much it. Simple lecture.

Hopefully you got a little bit more on how to figure beans and how to specify. Cross shipmates. Thank you

Sign Up

Share

Share with friends, get 20% off
Invite your friends to LearnDesk learning marketplace. For each purchase they make, you get 20% off (upto $10) on your next purchase.