X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2Fscripts%2Fgenerate_new_opcodes.pl;h=1a634a6e37c5ba6b7623fdcf873022de63c0566a;hb=eba5516120eb38bcae5464e628aa0d2cb8708866;hp=85e26270e07041c88dbf6ab42bf29c478ef7f006;hpb=c45f60ae7b8fe118934d17e0fcddda03e14f7256;p=libfirm diff --git a/ir/be/scripts/generate_new_opcodes.pl b/ir/be/scripts/generate_new_opcodes.pl index 85e26270e..1a634a6e3 100755 --- a/ir/be/scripts/generate_new_opcodes.pl +++ b/ir/be/scripts/generate_new_opcodes.pl @@ -265,6 +265,12 @@ foreach my $op (keys(%nodes)) { $attr_type = $default_attr_type; } + # determine hash function + my $hash_func; + if (exists($n{"hash_func"})) { + $hash_func = $n{"hash_func"}; + } + # determine compare function my $cmp_attr_func; if (exists($n{"cmp_attr"})) { @@ -575,6 +581,9 @@ foreach my $op (keys(%nodes)) { if (defined($copy_attr_func)) { push(@obst_new_irop, "\tops.copy_attr = ${copy_attr_func};\n"); } + if (defined($hash_func)) { + push(@obst_new_irop, "\tops.hash = ${hash_func};\n"); + } $n_opcodes++; my $n_res = $out_arity; @@ -708,6 +717,8 @@ void $arch\_create_opcodes(const arch_irn_ops_t *be_ops) { #define K irop_flag_keep #define M irop_flag_machine #define O irop_flag_machine_op +#define NB irop_flag_dump_noblock +#define NI irop_flag_dump_noinput #define R (irop_flag_user << 0) ir_op_ops ops; @@ -1173,21 +1184,6 @@ sub generate_requirements { 0 /* different pos */ }; -EOF - } elsif ($reqs =~ /^new_reg_(.*)$/) { - if(!is_reg_class($1)) { - die "$1 is not a register class in requirements for $op\n"; - } - $class = $1; - $result = <