Condition Coverage

blib/lib/CPU/x86_64/InstructionWriter.pm
Criterion Covered Total %
condition 65 193 33.6


and 3 conditions

line !l l&&!r l&&r condition
95 0 61 78 defined $name and defined $labels->{$name}
870 0 0 371 defined $reg1 && defined $reg2
875 0 0 0 $old_reg1 and $old_reg1 > 3
0 0 0 $old_reg2 and $old_reg2 > 3
959 0 0 0 not $rex and ($base_reg // 0) < 8
0 0 0 not $rex and ($base_reg // 0) < 8 and ($index_reg // 0) < 8
1052 56 84 252 defined $opcode8 && $value >> 7 == $value >> 8
1073 56 336 0 defined $opcode8 && ($value >> 7 == $value >> 8 || $value >> 8 == 16777215)
1096 49 294 0 defined $opcode8 && ($value >> 7 == $value >> 8 || $value >> 8 == 255)
1143 504 756 2268 defined $opcode8 && $value >> 7 == $value >> 8
1162 504 3024 0 defined $opcode8 && ($value >> 7 == $value >> 8 || $value >> 8 == 16777215)
1182 441 2646 0 defined $opcode8 && ($value >> 7 == $value >> 8 || $value >> 8 == 255)

or 2 conditions

line l !l condition
759 28 0 $nesting //= 0
959 0 0 $base_reg // 0
0 0 $index_reg // 0
1004 24768 0 $scale // 1
1024 8256 0 $scale // 1

or 3 conditions

line l !l&&r !l&&!r condition
181 7 0 0 $regnum64{$reg} // croak("$reg is not a 64-bit register")
230 7 0 0 $regnum64{$reg} // croak("$reg is not a 64-bit register")
327 63 0 0 $regnum64{$reg} // croak("$reg is not a 64-bit register")
350 56 0 0 $regnum32{$reg} // croak("$reg is not a 32-bit register")
357 49 0 0 $regnum16{$reg} // croak("$reg is not a 16-bit register")
368 20 0 0 $regnum8_high{$_[1]} // croak("$_[1] is not a 8-bit register")
729 7 0 0 $regnum64{$reg} // croak("$reg is not a 64-bit register")
749 7 0 0 $regnum64{$reg} // croak("$reg is not a 64-bit register")
760 0 0 28 ref $varspace || ref $nesting
833 686 0 0 $regnum64{$reg1} // croak("$reg1 is not a 64-bit register")
834 686 0 0 $regnum64{$reg2} // croak("$reg2 is not a 64-bit register")
843 595 0 0 $regnum32{$reg1} // croak("$reg1 is not a 32-bit register")
844 595 0 0 $regnum32{$reg2} // croak("$reg2 is not a 32-bit register")
854 553 0 0 $regnum16{$reg1} // croak("$reg1 is not a 16-bit register")
855 553 0 0 $regnum16{$reg2} // croak("$reg2 is not a 16-bit register")
873 0 0 0 $regnum8_high{$_[2]} // croak("$_[2] is not a valid 8-bit register")
874 0 0 0 $regnum8_high{$_[3]} // croak("$_[3] is not a valid 8-bit register")
875 0 0 0 $old_reg1 and $old_reg1 > 3 or $old_reg2 and $old_reg2 > 3
881 245 90 36 $reg1 > 3 || $reg2 > 3
898 72 0 0 $regnum8_high{$_[3]} // croak("$_[3] is not a valid 8-bit register")
913 7938 0 0 $regnum64{$reg} // croak("$reg is not a valid 64-bit register")
915 6048 0 0 $regnum64{$base_reg} // croak("$base_reg is not a valid 64-bit register")
917 6048 0 0 $regnum64{$index_reg} // croak("$index_reg is not a valid 64-bit register")
926 7686 0 0 $regnum32{$reg} // croak("$reg is not a valid 32-bit register")
928 5856 0 0 $regnum64{$base_reg} // croak("$base_reg is not a valid 64-bit register")
930 5856 0 0 $regnum64{$index_reg} // croak("$index_reg is not a valid 64-bit register")
938 7686 0 0 $regnum16{$reg} // croak("$reg is not a valid 16-bit register")
940 5856 0 0 $regnum64{$base_reg} // croak("$base_reg is not a valid 64-bit register")
942 5856 0 0 $regnum64{$index_reg} // croak("$index_reg is not a valid 64-bit register")
951 4896 0 0 $regnum64{$base_reg} // croak("$base_reg is not a valid 64-bit register")
953 4896 0 0 $regnum64{$index_reg} // croak("$index_reg is not a valid 64-bit register")
958 0 0 0 $regnum8_high{$_[3]} // croak("$_[3] is not a valid 8-bit register")
973 960 0 0 $regnum64{$base_reg} // croak("$base_reg is not a valid 64-bit register")
975 960 0 0 $regnum64{$index_reg} // croak("$index_reg is not a valid 64-bit register")
1004 24768 0 0 $SIB_scale{$scale // 1} // croak("invalid index multiplier $scale")
1024 8256 0 0 $SIB_scale{$scale // 1} // croak("invalid index multiplier $scale")
1045 392 0 0 $regnum64{$args[4]} // croak("$args[4] is not a 64-bit register")
1066 392 0 0 $regnum32{$args[4]} // croak("$args[4] is not a 32-bit register")
1089 343 0 0 $regnum16{$args[4]} // croak("$args[4] is not a 16-bit register")
1117 0 0 0 $regnum8_high{$_[1]} // croak("$reg is not a 8-bit register")
1134 2688 0 0 $regnum64{$base_reg} // croak("$base_reg is not a 64-bit register")
1136 2688 0 0 $regnum64{$index_reg} // croak("$index_reg is not a 64-bit register")
1153 2688 0 0 $regnum64{$base_reg} // croak("$base_reg is not a 64-bit register")
1155 2688 0 0 $regnum64{$index_reg} // croak("$index_reg is not a 64-bit register")
1172 2352 0 0 $regnum64{$base_reg} // croak("$base_reg is not a 64-bit register")
1174 2352 0 0 $regnum64{$index_reg} // croak("$index_reg is not a 64-bit register")
1192 1680 0 0 $regnum64{$base_reg} // croak("$base_reg is not a 64-bit register")
1194 1680 0 0 $regnum64{$index_reg} // croak("$index_reg is not a 64-bit register")
1298 0 0 0 $args[$unknown_pos]->value // croak("Value $encoder_args->[$unknown_pos] is still unresolved")