/* tc-moxie.c -- Assemble code for moxie
- Copyright (C) 2009-2020 Free Software Foundation, Inc.
+ Copyright (C) 2009-2021 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
const char line_comment_chars[] = "#";
static int pending_reloc;
-static struct hash_control *opcode_hash_control;
+static htab_t opcode_hash_control;
const pseudo_typeS md_pseudo_table[] =
{
{
int count;
const moxie_opc_info_t *opcode;
- opcode_hash_control = hash_new ();
+ opcode_hash_control = str_htab_create ();
/* Insert names into hash table. */
for (count = 0, opcode = moxie_form1_opc_info; count++ < 64; opcode++)
- hash_insert (opcode_hash_control, opcode->name, (char *) opcode);
+ str_hash_insert (opcode_hash_control, opcode->name, opcode, 0);
for (count = 0, opcode = moxie_form2_opc_info; count++ < 4; opcode++)
- hash_insert (opcode_hash_control, opcode->name, (char *) opcode);
+ str_hash_insert (opcode_hash_control, opcode->name, opcode, 0);
for (count = 0, opcode = moxie_form3_opc_info; count++ < 10; opcode++)
- hash_insert (opcode_hash_control, opcode->name, (char *) opcode);
+ str_hash_insert (opcode_hash_control, opcode->name, opcode, 0);
bfd_set_arch_mach (stdoutput, TARGET_ARCH, 0);
}
if (nlen == 0)
as_bad (_("can't find opcode "));
- opcode = (moxie_opc_info_t *) hash_find (opcode_hash_control, op_start);
+ opcode = (moxie_opc_info_t *) str_hash_find (opcode_hash_control, op_start);
*op_end = pend;
if (opcode == NULL)
(p - frag_now->fr_literal),
2,
&arg,
- TRUE,
+ true,
BFD_RELOC_MOXIE_10_PCREL);
}
break;