aboutsummaryrefslogtreecommitdiff
path: root/gas/config/tc-i386.c
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1998-03-24 23:34:45 +0000
committerIan Lance Taylor <ian@airs.com>1998-03-24 23:34:45 +0000
commitdddc8a823d98a8b09119dc3b59b39b64d56b652e (patch)
tree93e458586d3a098300a6407bb5a690f0001070bf /gas/config/tc-i386.c
parent3173839b6a4ca56be7fb6109f53713405902e7c6 (diff)
downloadgdb-dddc8a823d98a8b09119dc3b59b39b64d56b652e.zip
gdb-dddc8a823d98a8b09119dc3b59b39b64d56b652e.tar.gz
gdb-dddc8a823d98a8b09119dc3b59b39b64d56b652e.tar.bz2
Tue Mar 24 18:30:58 1998 H.J. Lu <hjl@gnu.org>
* config/tc-i386.h (LinearAddress): Define. * config/tc-i386.c (md_assemble): If LinearAddress is set for the instruction, don't use a default segment.
Diffstat (limited to 'gas/config/tc-i386.c')
-rw-r--r--gas/config/tc-i386.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c
index cec18e7..ea57da8 100644
--- a/gas/config/tc-i386.c
+++ b/gas/config/tc-i386.c
@@ -1,5 +1,6 @@
/* i386.c -- Assemble code for the Intel 80386
- Copyright (C) 1989, 91, 92, 93, 94, 95, 96, 1997 Free Software Foundation.
+ Copyright (C) 1989, 91, 92, 93, 94, 95, 96, 97, 1998
+ Free Software Foundation.
This file is part of GAS, the GNU Assembler.
@@ -1542,9 +1543,10 @@ md_assemble (line)
exp->X_op_symbol = (symbolS *) 0;
}
- /* Find the default segment for the memory operand.
- Used to optimize out explicit segment specifications. */
- if (i.seg)
+ /* Find the default segment for the memory
+ operand. Used to optimize out explicit segment
+ specifications. */
+ if (i.seg && (t->opcode_modifier & LinearAddress) == 0)
{
unsigned int seg_index;
@@ -2113,8 +2115,15 @@ i386_operand (operand_string)
SKIP_WHITESPACE ();
exp_seg = expression (exp);
if (*input_line_pointer != '\0')
- as_bad ("unrecognized characters `%s' in expression",
- input_line_pointer);
+ {
+ /* This should be as_bad, but some versions of gcc, up to
+ about 2.8 and egcs 1.01, generate a bogus @GOTOFF(%ebx)
+ in certain cases. Oddly, the code in question turns out
+ to work correctly anyhow, so we make this just a warning
+ until those versions of gcc are obsolete. */
+ as_warn ("warning: unrecognized characters `%s' in expression",
+ input_line_pointer);
+ }
input_line_pointer = save_input_line_pointer;
if (exp->X_op == O_absent)