write.c: Complain about .space or .org moving backwards.

Do generic rs_machine_dependent relaxation only if TC_GENERIC_RELAX_TABLE is
defined.  Use its value as the base of the table, so the actual declaration
can be cpu-specific (and const or not as appropriate).  For other cpus where
this isn't done (the majority), delete md_relax_table altogether.

For machines with WORKING_DOT_WORD, delete md_{short,long}_jump_size.
This commit is contained in:
Ken Raeburn 1995-04-11 06:10:34 +00:00
parent 49073be098
commit 9b0da28b13
11 changed files with 19 additions and 26 deletions

View file

@ -32,11 +32,6 @@
#define machine_ip a29k_ip
#define machine_it a29k_it
const relax_typeS md_relax_table[] =
{
{ 0, 0, 0, 0 }
};
#define IMMEDIATE_BIT 0x01000000 /* Turns RB into Immediate */
#define ABSOLUTE_BIT 0x01000000 /* Turns PC-relative to Absolute */
#define CE_BIT 0x00800000 /* Coprocessor enable in LOAD */

View file

@ -49,9 +49,6 @@ const pseudo_typeS md_pseudo_table[] =
{ NULL, 0, 0 },
};
const int md_short_jump_size = 4;
const int md_long_jump_size = 4;
/* This array holds the chars that always start a comment. If the
pre-processor is disabled, these aren't very useful */
const char comment_chars[] = "#;";
@ -1009,11 +1006,6 @@ md_estimate_size_before_relax (fragp, seg)
abort ();
}
const relax_typeS md_relax_table[] =
{
{ 0 }
};
/* Convert a machine dependent frag. We never generate these. */
void

View file

@ -87,7 +87,7 @@ const char FLT_CHARS[] = "rRsSfFdDxXpP";
#define WORD_F 32767
#define WORD_B 32768
const relax_typeS md_relax_table[C (END, 0)];
relax_typeS md_relax_table[C (END, 0)];
static struct hash_control *opcode_hash_control; /* Opcode mnemonics */

View file

@ -41,4 +41,7 @@
#define md_operand(x)
extern struct relax_type md_relax_table[];
#define TC_GENERIC_RELAX_TABLE md_relax_table
/* end of tc-h8500.h */

View file

@ -1168,9 +1168,6 @@ md_estimate_size_before_relax (fragP, segment_type)
return (-1);
}
const relax_typeS md_relax_table[] =
{0};
#if 0
/* As far as I can tell, this routine is never called. What is it

View file

@ -252,6 +252,7 @@ md_parse_option (c, arg)
Motorola PowerPC 603/604. */
else if (strcmp (arg, "ppc") == 0
|| strcmp (arg, "ppc32") == 0
|| strcmp (arg, "403") == 0
|| strcmp (arg, "603") == 0
|| strcmp (arg, "604") == 0)
ppc_cpu = PPC_OPCODE_PPC;
@ -306,7 +307,7 @@ PowerPC options:\n\
-mpwrx generate code for IBM POWER/2 (RIOS2)\n\
-mpwr generate code for IBM POWER (RIOS1)\n\
-m601 generate code for Motorola PowerPC 601\n\
-mppc, -mppc32, -m603, -m604\n\
-mppc, -mppc32, -m403, -m603, -m604\n\
generate code for Motorola PowerPC 603/604\n\
-many generate code for any architecture (PWR/PWRX/PPC)\n");
#ifdef OBJ_ELF
@ -592,6 +593,8 @@ ppc_elf_validate_fix (fixS *fixp, segT seg)
&& !fixp->fx_pcrel
&& fixp->fx_r_type <= BFD_RELOC_UNUSED
&& strcmp (segment_name (seg), ".got2") != 0
&& strcmp (segment_name (seg), ".dtors") != 0
&& strcmp (segment_name (seg), ".ctors") != 0
&& strcmp (segment_name (seg), ".stab") != 0)
{
as_warn_where (fixp->fx_file, fixp->fx_line,
@ -2371,11 +2374,6 @@ md_estimate_size_before_relax (fragp, seg)
abort ();
}
const relax_typeS md_relax_table[] =
{
{ 0 }
};
/* Convert a machine dependent frag. We never generate these. */
void

View file

@ -53,4 +53,7 @@
#define md_operand(x)
extern const struct relax_type md_relax_table[];
#define TC_GENERIC_RELAX_TABLE md_relax_table
#endif

View file

@ -247,8 +247,7 @@ pc_rel_disp? That sort of thing.) */
/* This is the table used by gas to figure out relaxing modes. The fields are
forward_branch reach, backward_branch reach, number of bytes it would take,
where the next biggest branch is. */
const relax_typeS
md_relax_table[] =
const relax_typeS md_relax_table[] =
{
{
1, 1, 0, 0

View file

@ -28,6 +28,9 @@
#define md_operand(x)
extern const struct relax_type md_relax_table[];
#define TC_GENERIC_RELAX_TABLE md_relax_table
/*
* Local Variables:
* comment-column: 0

View file

@ -108,7 +108,7 @@ int X; /* X flag */
#define WORD_F 32767
#define WORD_B 32768
const relax_typeS md_relax_table[C (END, 0)];
relax_typeS md_relax_table[C (END, 0)];
/*
This function is called once, at assembler startup time. This should

View file

@ -46,4 +46,7 @@ int tc_cons_reloc;
#define md_operand(x)
extern struct relax_type md_relax_table[];
#define TC_GENERIC_RELAX_TABLE md_relax_table
/* end of tc-w65.h */