/* tc-ip2k.c -- Assembler for the Scenix IP2xxx.
- Copyright (C) 2000, 2002 Free Software Foundation.
+ Copyright (C) 2000, 2002, 2003 Free Software Foundation.
This file is part of GAS, the GNU Assembler.
Boston, MA 02111-1307, USA. */
#include <stdio.h>
-#include <ctype.h>
-
#include "as.h"
-#include "dwarf2dbg.h"
#include "subsegs.h"
#include "symcat.h"
#include "opcodes/ip2k-desc.h"
/* The target specific pseudo-ops which we support. */
const pseudo_typeS md_pseudo_table[] =
{
- { "file", dwarf2_directive_file, 0 },
- { "loc", dwarf2_directive_loc, 0 },
{ "text", ip2k_elf_section_text, 0 },
{ "sect", ip2k_elf_section_rtn, 0 },
{ NULL, NULL, 0 }
enum cgen_parse_operand_result result_type;
long value;
const char *curpc_plus_2 = ".+2";
+ const char *err;
- errmsg = cgen_parse_address (gas_cgen_cpu_desc, & curpc_plus_2,
- IP2K_OPERAND_ADDR16CJP,
- BFD_RELOC_IP2K_PC_SKIP,
- & result_type, & value);
- if (errmsg)
+ err = cgen_parse_address (gas_cgen_cpu_desc, & curpc_plus_2,
+ IP2K_OPERAND_ADDR16CJP,
+ BFD_RELOC_IP2K_PC_SKIP,
+ & result_type, & value);
+ if (err)
{
- as_bad ("%s", errmsg);
+ as_bad ("%s", err);
return;
}
}
LITTLENUM_TYPE words [MAX_LITTLENUMS];
LITTLENUM_TYPE *wordP;
char * t;
- char * atof_ieee PARAMS ((char *, int, LITTLENUM_TYPE *));
switch (type)
{
{
switch (fix->fx_r_type)
{
- /* (No C++ support in ip2k. */
- /* case BFD_RELOC_VTABLE_INHERIT: */
- /* case BFD_RELOC_VTABLE_ENTRY: */
-
case BFD_RELOC_IP2K_FR9:
case BFD_RELOC_IP2K_FR_OFFSET:
case BFD_RELOC_IP2K_BANK:
return 1;
case BFD_RELOC_16:
- if (fix->fx_subsy && S_IS_DEFINED (fix->fx_subsy)
+ if (fix->fx_subsy && S_IS_DEFINED (fix->fx_subsy)
&& fix->fx_addsy && S_IS_DEFINED (fix->fx_addsy)
&& (S_GET_SEGMENT (fix->fx_addsy)->flags & SEC_CODE))
{
fix->fx_r_type = BFD_RELOC_IP2K_TEXT;
return 0;
}
- return 0;
+ break;
default:
- return 0;
+ break;
}
+
+ return generic_force_reloc (fix);
}
void