int var;
int var_a,var_b,var_c;
coverpoint a : var_a
{
bins a_1 = {0};
bins a_2 = {1};
}
coverpoint b : var_b
{
bins b_1 = {0};
bins b_2 = {1};
}
coverpoint c : var_c
{
bins c_1 = {0};
bins c_2 = {1};
}
cross_all_cfg : cross a, cross b, cross c
{
ignore_bins invalid = binsof (a) iff (var =0);
}
Result : if i am doing it like this it shows only invalid bin in covergroup and not showing other bits of b and c in gui.
MY_EXPECTATION : i was expecting it will cross all bins a, b ,c only if (var=0) it will ignore bin of a
Thanks Dave,
I am grtting this error while using following piece of code
all_cfg: cross a, b, c
{
ignore_bins invalid = binsof (a) with (wvar==0);
} The ‘with’ clause specified on the cross bin does not have any impact and is
invalid; it should contain at least one occurence of the constituent
coverpoint names.
Please remove or correct the clause and compile
There is no such restriction in the LRM. I did have to make one small change to get it to compile on 3 out of 4 simulators on EDAPlayground. That was to make the variable used in the with clause an argument to the covergroup.
int wvar;
int var_a,var_b,var_c;
covergroup cg(int v;
a : coverpoint var_a
{
bins a_1 = {0};
bins a_2 = {1};
}
b : coverpoint var_b
{
bins b_1 = {0};
bins b_2 = {1};
}
c : coverpoint var_c
{
bins c_1 = {0};
bins c_2 = {1};
}
all_cfg: cross a, b, c
{
ignore_bins invalid = binsof (a) with (v==0);
}
endgroup