diff options
author | Doug Evans <dje@google.com> | 1998-04-03 20:15:57 +0000 |
---|---|---|
committer | Doug Evans <dje@google.com> | 1998-04-03 20:15:57 +0000 |
commit | 050ac694c55f653fbaf665a13e1020cca13f9445 (patch) | |
tree | 9487d531db56c7724db4bccdc7c5ccdb41dbaf0b | |
parent | f6f81e4a92b89ff92747a36d46215e4c1037f145 (diff) | |
download | gdb-050ac694c55f653fbaf665a13e1020cca13f9445.zip gdb-050ac694c55f653fbaf665a13e1020cca13f9445.tar.gz gdb-050ac694c55f653fbaf665a13e1020cca13f9445.tar.bz2 |
* config/tc-dvp.c (assemble_vif): Put relaxable insns in their
own fragment.
-rw-r--r-- | gas/ChangeLog | 7 | ||||
-rw-r--r-- | gas/config/tc-dvp.c | 28 |
2 files changed, 32 insertions, 3 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index 0925506..0a899c0 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,10 @@ +start-sanitize-sky +Fri Apr 3 12:13:03 1998 Doug Evans <devans@canuck.cygnus.com> + + * config/tc-dvp.c (assemble_vif): Put relaxable insns in their + own fragment. + +end-sanitize-sky Fri Apr 3 11:58:19 1998 Alan Modra <alan@spri.levels.unisa.edu.au> * config/tc-i386.h: Reorder operand flags and opcode modifier diff --git a/gas/config/tc-dvp.c b/gas/config/tc-dvp.c index 83d6bc0..8facff1 100644 --- a/gas/config/tc-dvp.c +++ b/gas/config/tc-dvp.c @@ -545,6 +545,15 @@ assemble_vif (str) Do this by putting the mpg insn in a relaxable fragment with a symbol that marks the beginning of the aligned data. */ + /* Ensure relaxable fragments are in their own fragment. + Otherwise there can be two fixups in one fragment + (e.g. a dma tag followed by a `direct' insn) and md_apply_fix3 + has trouble determining where to apply the fixup (because + we set fr_opcode for the `direct' insn because it can move + in the fragment). */ + frag_wane (frag_now); + frag_new (0); + /* This dance with frag_grow is to ensure the variable part and fixed part are in the same fragment. */ frag_grow (8); @@ -588,6 +597,15 @@ assemble_vif (str) Do this by putting the direct insn in a relaxable fragment. with a symbol that marks the beginning of the aligned data. */ + /* Ensure relaxable fragments are in their own fragment. + Otherwise there can be two fixups in one fragment + (e.g. a dma tag followed by a `direct' insn) and md_apply_fix3 + has trouble determining where to apply the fixup (because + we set fr_opcode for the `direct' insn because it can move + in the fragment). */ + frag_wane (frag_now); + frag_new (0); + /* This dance with frag_grow is to ensure the variable part and fixed part are in the same fragment. */ frag_grow (16); @@ -2614,9 +2632,6 @@ s_endunpack (internal_p) return; } - /* Round up to next word boundary. */ - frag_align (2, 0, 0); - /* Record in the end data symbol the current location. */ if (now_seg != S_GET_SEGMENT (vif_data_end)) as_bad (".endunpack in different section"); @@ -2627,10 +2642,17 @@ s_endunpack (internal_p) { symbolS *s; s = expr_build_binary (O_subtract, vif_data_end, vif_data_start); + /* Round up to next quadword boundary. */ + /* FIXME: This isn't correct, the size of the input data is not the + size of the output data. Someone else can fix this. */ + s = expr_build_binary (O_add, s, expr_build_uconstant (15)); s = expr_build_binary (O_divide, s, expr_build_uconstant (16)); unpackloc_sym = expr_build_binary (O_add, unpackloc_sym, s); } + /* Round up to next word boundary. */ + frag_align (2, 0, 0); + set_asm_state (ASM_INIT); /* Needn't be reset, but to catch bugs it is. */ |