diff options
Diffstat (limited to 'risugen_m68k.pm')
-rw-r--r-- | risugen_m68k.pm | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/risugen_m68k.pm b/risugen_m68k.pm index 74e4937..7d62b13 100644 --- a/risugen_m68k.pm +++ b/risugen_m68k.pm @@ -160,9 +160,8 @@ sub write_test_code($) my $numinsns = $params->{ 'numinsns' }; my $outfile = $params->{ 'outfile' }; - my @pattern_re = @{ $params->{ 'pattern_re' } }; - my @not_pattern_re = @{ $params->{ 'not_pattern_re' } }; my %insn_details = %{ $params->{ 'details' } }; + my @keys = @{ $params->{ 'keys' } }; # Specify the order to use for insn32() and insn16() writes. set_endian(1); @@ -176,21 +175,6 @@ sub write_test_code($) # TODO better random number generator? srand(0); - # Get a list of the insn keys which are permitted by the re patterns - my @keys = sort keys %insn_details; - if (@pattern_re) { - my $re = '\b((' . join(')|(',@pattern_re) . '))\b'; - @keys = grep /$re/, @keys; - } - # exclude any specifics - if (@not_pattern_re) { - my $re = '\b((' . join(')|(',@not_pattern_re) . '))\b'; - @keys = grep !/$re/, @keys; - } - if (!@keys) { - print STDERR "No instruction patterns available! (bad config file or --pattern argument?)\n"; - exit(1); - } print "Generating code using patterns: @keys...\n"; progress_start(78, $numinsns); |