In reply to Himanshu m soni:
Lots of syntax errors in your code, but perhaps this is what you are looking for:
int wvar;
int var_a,var_b,var_c;
covergroup cg;
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 (wvar==0);
}
endgroup
The iff keyword only disables sampling of existing bins, it does not eliminate them.