Branch Coverage

lib/Math/FastGF2/Matrix.pm
Criterion Covered Total %
branch 112 228 49.1


line true false branch
50 0 174 unless (defined $o{$_})
56 58 0 if (defined $o{'org'}) { }
57 51 7 if ($o{'org'} eq 'rowwise') { }
7 0 elsif ($o{'org'} eq 'colwise') { }
72 0 44 if ($o{'width'} != 1 and $o{'width'} != 2 and $o{'width'} != 4)
77 0 58 if $errors
93 0 445 unless (defined $o{'size'} and $o{'size'} > 0)
97 0 26 unless (defined $o{'width'} and $o{'width'} == 1 || $o{'width'} == 2 || $o{'width'} == 4)
102 0 445 unless (defined $o{'org'} and $o{'org'} eq 'rowwise' || $o{'org'} == 'colwise')
107 445 0 $o{'org'} eq 'rowwise' ? :
110 0 445 unless $id
129 0 14 unless (defined $other and ref $other eq $class)
133 0 14 unless ($self->COLS == $other->ROWS)
137 0 14 unless ($self->WIDTH == $other->WIDTH)
142 1 13 if (defined $result) { }
143 0 1 unless (ref $result eq $class)
147 0 1 unless ($self->ROWS == $result->ROWS)
151 0 1 unless ($self->WIDTH == $result->WIDTH)
158 0 13 unless (defined $result and ref $result eq $class)
175 0 259 unless (defined $other and ref $other eq $class)
179 0 259 unless ($self->COLS == $other->COLS)
182 0 259 unless ($self->COLS == $other->COLS)
185 0 259 unless ($self->WIDTH == $other->WIDTH)
197 0 212 unless (defined $other and ref $other eq $class)
201 1 211 if ($self->COLS != $other->COLS)
204 0 211 if ($self->COLS != $other->COLS)
207 0 211 if ($self->WIDTH != $other->WIDTH)
223 0 0 if (int $offset != $offset)
227 0 0 if ($offset < 0 or $offset >= $ROWS * $COLS)
231 0 0 if (1 == $self->ORGNUM) { }
246 0 12 if ($row < 0 or $row >= $self->ROWS)
250 0 12 if ($col < 0 or $col >= $self->COLS)
254 4 8 if ($self->ORG eq 'rowwise') { }
274 0 696 unless ($class)
282 0 696 unless (defined $row and defined $col and defined $words)
286 0 696 if ($order < 0 or $order > 2)
292 0 696 if ($row < 0 or $row >= $ROWS)
296 0 696 if ($col < 0 or $row >= $ROWS)
303 687 9 unless $want_list
306 1 8 if ($WIDTH == 1) { }
4 4 elsif ($WIDTH == 2) { }
323 685 13 unless defined $order
329 0 698 unless ($class)
333 0 698 unless (defined $row and defined $col)
337 0 698 if ($order < 0 or $order > 2)
341 0 698 if ($row < 0 or $row >= $ROWS)
345 0 698 if ($col < 0 or $row >= $ROWS)
350 18 680 if (ref $vals) { }
352 0 18 unless ($words = scalar @$vals)
356 4 14 if ($WIDTH == 1) { }
11 3 elsif ($WIDTH == 2) { }
370 0 698 if (1 == $self->ORGNUM and $words + $COLS * $row + $col > $msize or $words + $ROWS * $col + $row > $msize)
388 0 440 unless (defined $other and ref $other eq $class)
392 0 440 unless ($self->WIDTH == $other->WIDTH)
396 0 440 unless ($self->ROWS == $other->ROWS)
403 0 440 unless defined $cat
404 440 0 if ($self->ORG eq 'rowwise') { }
432 0 90 if $row1 == $row2
433 0 90 unless defined $start_col
438 90 0 if ($self->ORG eq 'rowwise') { }
459 0 0 if $col1 == $col2
460 0 0 unless defined $start_row
465 0 0 if ($self->ORG eq 'colwise') { }
495 0 440 unless ($cols > $rows)
508 90 1260 if ($self->getval($row, $row) == 0)
512 0 90 if $row == $other_row
513 90 0 if ($self->getval($other_row, $row) != 0)
518 0 90 unless defined $found
533 1350 2860 if $row == $other_row
536 382 2478 if $other == 0
565 0 440 unless ($self->COLS == $self->ROWS)
573 0 440 unless defined $cat
612 0 0 if (defined $o{'xyvals'}) { }
614 0 0 if defined $xvals
615 0 0 if defined $yvals
617 0 0 if (defined $rows and not defined $cols) { }
0 0 elsif (defined $cols and not defined $rows) { }
636 0 0 if defined $xvals and not defined $rows
637 0 0 if defined $yvals and not defined $cols
640 0 0 unless defined $xvals and defined $yvals
642 0 0 unless @$xvals == $rows
643 0 0 unless @$yvals == $cols
644 0 0 unless $rows >= $cols
652 0 0 unless ref $self
704 0 0 unless defined $o{'xvals'}
713 0 0 if @x - @y
714 0 0 if @$key < 2 * $k
715 0 0 if @x != $k
719 0 0 unless ref $self
727 0 0 if ($n < 3) { }
816 0 1 unless ref $xvals eq 'ARRAY'
817 0 1 unless defined $cols and $cols > 0
823 0 1 unless ref $self
881 3 221 if (defined $submatrix) { }
217 4 elsif (defined $rows or defined $cols) { }
882 0 3 if (defined $rows or defined $cols)
887 0 3 unless (defined $row1 and defined $col1 and defined $row2 and defined $col2)
893 0 3 unless ($row1 >= 0 and $row1 <= $row2 and $row2 < $self->ROWS and $col1 >= 0 and $col1 <= $col2 and $col2 < $self->COLS)
901 3 0 if ($self->ORG eq 'rowwise') { }
918 0 217 if (defined $rows and not ref $rows)
922 0 217 if (defined $cols and not ref $cols)
927 2 215 if (defined $rows and defined $cols) { }
212 3 elsif (defined $rows and $self->ORG eq 'rowwise') { }
0 3 elsif (defined $cols and $self->ORG eq 'colwise') { }
970 3 0 unless defined $rows
971 0 3 unless defined $cols
993 0 4 unless defined $mat
1028 3 3 if ($o{'org'} ne $self->ORG) { }
1036 3 3 if ($transpose) { }
2 1 elsif ($fliporg) { }
1040 0 3 unless defined $mat
1041 1 2 if ($fliporg) { }
1057 0 2 unless defined $mat
1081 1 0 if ($self->ORG eq 'rowwise') { }