aboutsummaryrefslogtreecommitdiff
path: root/gas
diff options
context:
space:
mode:
authorDoug Evans <dje@google.com>1998-09-21 20:27:28 +0000
committerDoug Evans <dje@google.com>1998-09-21 20:27:28 +0000
commit3c62de83cd08d5d9e62043f8c436fb9ff149318a (patch)
tree64556d7e61717c8223675affd59567afd9a0f8ea /gas
parentfa41e1a3faf7e9778b82b30892434cb98c65bf94 (diff)
downloadgdb-3c62de83cd08d5d9e62043f8c436fb9ff149318a.zip
gdb-3c62de83cd08d5d9e62043f8c436fb9ff149318a.tar.gz
gdb-3c62de83cd08d5d9e62043f8c436fb9ff149318a.tar.bz2
update tc-dvp.c with sky-980617-branch
Diffstat (limited to 'gas')
-rw-r--r--gas/ChangeLog23
-rw-r--r--gas/config/tc-dvp.c51
2 files changed, 67 insertions, 7 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog
index 0ee16da..2f71e92 100644
--- a/gas/ChangeLog
+++ b/gas/ChangeLog
@@ -1,3 +1,10 @@
+start-sanitize-sky
+Mon Sep 21 13:08:01 1998 Doug Evans <devans@canuck.cygnus.com>
+
+ * config/tc-dvp.c (md_begin): Set st_other field of mpgloc_sym.
+ (assemble_vif,create_vuoverlay_section,s_endmpg,s_vu): Ditto.
+
+end-sanitize-sky
Mon Sep 21 10:42:57 1998 Nick Clifton <nickc@cygnus.com>
* config/tc-m32r.c (m32r_do_align): After inserting NOPs, reset
@@ -14,6 +21,14 @@ Sun Sep 20 00:58:12 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.
relocs.
* config/tc-m68k.c (md_apply_fix_2): Do nothing for vtable relocs.
+start-sanitize-sky
+Tue Sep 15 17:04:43 EDT 1998 Jim Lemke <jlemke@cygnus.com>
+
+ * config/tc-dvp.c (parse_float): Strtol() will not convert
+ 0xFfffFfff properly, it returns 0x7fffFfff.
+ Changed to use strtoul() which does work properly.
+
+end-sanitize-sky
Tue Sep 15 08:51:07 1998 Catherine Moore <clm@cygnus.com>
* config/obj-elf.c (obj_elf_vtable_inherit): Handle arm
@@ -26,6 +41,14 @@ Tue Sep 15 08:51:07 1998 Catherine Moore <clm@cygnus.com>
(elf32_arm_force_relocation): New.
(armelf_frob_symbol): Remove coff-style symbol support.
+start-sanitize-sky
+Mon Sep 14 22:28:24 1998 Doug Evans <devans@canuck.cygnus.com>
+
+ * config/tc-dvp.c (parse_float): Support 0fNNN.
+ (tc_gen_reloc): Don't crash if given a pc-relative reloc for .word,
+ just signal an error.
+
+end-sanitize-sky
Wed Sep 9 11:27:16 1998 Richard Henderson <rth@cygnus.com>
* config/tc-i386.c (i386_operand): Fix typo in last patch.
diff --git a/gas/config/tc-dvp.c b/gas/config/tc-dvp.c
index 6f397eb..68f0d90 100644
--- a/gas/config/tc-dvp.c
+++ b/gas/config/tc-dvp.c
@@ -159,7 +159,10 @@ static symbolS *vif_data_start;
static symbolS *vif_data_end;
/* Special symbol $.mpgloc. The value is in bytes.
- This value is kept absolute, for simplicity. */
+ This value is kept absolute, for simplicity.
+ The st_other field for this must always be set to STO_DVP_VU because
+ symbols computed from this will get their st_other field clobbered
+ with this one (via resolve_symbol_value,copy_symbol_attributes). */
static symbolS *mpgloc_sym;
/* Handle of the current vu overlay section. */
@@ -320,6 +323,7 @@ md_begin ()
/* Initialize $.mpgloc. */
mpgloc_sym = expr_build_uconstant (0);
+ S_SET_OTHER (mpgloc_sym, STO_DVP_VU);
/* Create the vu overlay table section. */
{
@@ -677,11 +681,16 @@ assemble_vif (str)
{
/* The value is recorded in bytes, mpgloc is in dwords. */
mpgloc_sym = expr_build_uconstant (mpgloc * 8);
+ S_SET_OTHER (mpgloc_sym, STO_DVP_VU);
}
section_name = vuoverlay_section_name (mpgloc_sym);
vif_data_start = create_colon_label (STO_DVP_VU,
+#if 0
VUOVERLAY_START_PREFIX,
+#else
+ LOCAL_LABEL_PREFIX,
+#endif
section_name);
insn_frag->fr_symbol = vif_data_start;
@@ -2069,7 +2078,14 @@ tc_gen_reloc (section, fixP)
return NULL;
}
- assert (!fixP->fx_pcrel == !reloc->howto->pc_relative);
+ if (!fixP->fx_pcrel != !reloc->howto->pc_relative)
+ {
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ fixP->fx_pcrel
+ ? "PC-relative reloc not supported here"
+ : "PC-relative reloc required here");
+ return NULL;
+ }
reloc->addend = fixP->fx_addnumber;
@@ -2173,12 +2189,15 @@ parse_float (pstr, errmsg)
{
long value;
(*pstr) += 2;
- value = strtol (*pstr, pstr, 16);
+ value = strtoul (*pstr, pstr, 16);
return value;
}
else
{
LITTLENUM_TYPE words[MAX_LITTLENUMS];
+ if ((*pstr)[0] == '0'
+ && isalpha ((*pstr)[1]))
+ (*pstr) += 2;
*pstr = atof_ieee (*pstr, 'f', words);
return (words[0] << 16) | words[1];
}
@@ -2375,6 +2394,21 @@ create_vuoverlay_section (section_name, addr, start_label, end_label)
if (addr->sy_value.X_op == O_constant)
bfd_set_section_vma (stdoutput, vuoverlay_section, S_GET_VALUE (addr));
#endif
+
+#if 1
+ /* Create a symbol marking the start of the section.
+ This is different than START_LABEL as this one is for gdb.
+ It needs a symbol to start a section so we give it one.
+ This one could be combined with START_LABEL, but I haven't since
+ they serve different purposes. */
+ {
+ symbolS * gdb_start_sym;
+ gdb_start_sym = create_colon_label (STO_DVP_VU, VUOVERLAY_START_PREFIX,
+ section_name);
+ gdb_start_sym->sy_value = addr->sy_value;
+ }
+#endif
+
/* The size of the section won't be known until we see the .endmpg,
but we can compute it from the start and end labels. */
/* FIXME: This causes the section to occupy space in the file. */
@@ -2382,14 +2416,11 @@ create_vuoverlay_section (section_name, addr, start_label, end_label)
frag_var (rs_space, 1, 1, (relax_substateT) 0,
expr_build_binary (O_subtract, end_label, start_label),
(offsetT) 0, (char *) 0);
-#if 0
- /* Create a symbol marking the start of the section. */
- begin_label = create_colon_label (STO_DVP_VU, "__start_", section_name);
-#endif
#if 0 /* already done */
/* Initialize $.mpgloc. */
mpgloc_sym = expr_build_uconstant (addr);
+ S_SET_OTHER (mpgloc_sym, STO_DVP_VU);
#endif
#if 0 /* $.mpgloc is kept in the ABS section. */
@@ -2714,6 +2745,10 @@ insert_mpg_marker (ignore)
/* Record the cpu type in case we're in the middle of reading binary
data. */
record_mach (DVP_VUUP, 0);
+ /* We need a stabs line number entry at the start of the vu code.
+ This has already been called, but too early and we can't stop that.
+ So just emit another. */
+ generate_lineno_debug ();
}
/* Finish off the current unpack insn and start a new one.
@@ -3077,6 +3112,7 @@ s_endmpg (caller)
result we're ok. The new value is the old value plus the number of
double words in this chunk. */
mpgloc_sym = compute_mpgloc (mpgloc_sym, vif_data_start, vif_data_end);
+ S_SET_OTHER (mpgloc_sym, STO_DVP_VU);
pop_asm_state (1);
@@ -3240,6 +3276,7 @@ s_vu (ignore)
to be supported everywhere. */
vif_data_start = expr_build_dot ();
mpgloc_sym = expr_build_uconstant (0);
+ S_SET_OTHER (mpgloc_sym, STO_DVP_VU);
#if 0 /* ??? wip */
create_vuoverlay_section (vuoverlay_section_name (NULL), mpgloc_sym,
NULL, NULL);