diff options
Diffstat (limited to 'gas/config/tc-sh.c')
-rw-r--r-- | gas/config/tc-sh.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gas/config/tc-sh.c b/gas/config/tc-sh.c index 561f282..b8b452c 100644 --- a/gas/config/tc-sh.c +++ b/gas/config/tc-sh.c @@ -222,8 +222,10 @@ md_begin () /* Insert unique names into hash table */ for (opcode = sh_table; opcode->name; opcode++) { - if (opcode->arch & target_arch && strcmp (prev_name, opcode->name)) + if (strcmp (prev_name, opcode->name)) { + if (! (opcode->arch & target_arch)) + continue; prev_name = opcode->name; hash_insert (opcode_hash_control, opcode->name, (char *) opcode); } @@ -1148,6 +1150,8 @@ get_specific (opcode, operands) goto fail; } } + if ( !(valid_arch & this_try->arch)) + goto fail; valid_arch &= this_try->arch; return this_try; fail:; |