diff options
author | Alan Modra <amodra@gmail.com> | 1999-12-27 16:10:31 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 1999-12-27 16:10:31 +0000 |
commit | 3138f287b13f7f83b9290011391bbf77cbf65da0 (patch) | |
tree | aca6129dab6f19a0f643d335d1369ea08b921f2c /gas | |
parent | 221f77a9db36dc14f5f529d616808e5a46d6bb94 (diff) | |
download | gdb-3138f287b13f7f83b9290011391bbf77cbf65da0.zip gdb-3138f287b13f7f83b9290011391bbf77cbf65da0.tar.gz gdb-3138f287b13f7f83b9290011391bbf77cbf65da0.tar.bz2 |
x86 indirect jump/call syntax fixes. Disassembly fix for lcall.
Diffstat (limited to 'gas')
-rw-r--r-- | gas/ChangeLog | 6 | ||||
-rw-r--r-- | gas/config/tc-i386.c | 16 |
2 files changed, 14 insertions, 8 deletions
diff --git a/gas/ChangeLog b/gas/ChangeLog index 39fb313..e9ad534 100644 --- a/gas/ChangeLog +++ b/gas/ChangeLog @@ -1,3 +1,9 @@ +1999-12-27 Alan Modra <alan@spri.levels.unisa.edu.au> + + * config/tc-i386.c (MATCH): Relax JumpAbsolute check. Emit a + warning for absolute jump/call without `*' in non-intel mode. No + need to set i.types[0] JumpAbsolute in intel mode. + 1999-12-22 Philip Blundell <pb@futuretv.com> * config/tc-arm.c (arm_s_text): If OBJ_ELF, call the appropriate diff --git a/gas/config/tc-i386.c b/gas/config/tc-i386.c index 5219113..2aba752 100644 --- a/gas/config/tc-i386.c +++ b/gas/config/tc-i386.c @@ -1255,9 +1255,8 @@ md_assemble (line) with the template operand types. */ #define MATCH(overlap, given, template) \ - ((overlap) \ - && ((given) & BaseIndex) == ((overlap) & BaseIndex) \ - && ((given) & JumpAbsolute) == ((template) & JumpAbsolute)) + ((overlap & ~JumpAbsolute) \ + && ((given) & (BaseIndex|JumpAbsolute)) == ((overlap) & (BaseIndex|JumpAbsolute))) /* If given types r0 and r1 are registers they must be of the same type unless the expected operand type register overlap is null. @@ -1347,11 +1346,6 @@ md_assemble (line) i.types[xchg1] = temp_type; } - if (!strcmp(mnemonic,"jmp") - || !strcmp (mnemonic, "call")) - if ((i.types[0] & Reg) || i.types[0] & BaseIndex) - i.types[0] |= JumpAbsolute; - } overlap0 = 0; overlap1 = 0; @@ -1460,6 +1454,12 @@ md_assemble (line) return; } + if (!intel_syntax + && (i.types[0] & JumpAbsolute) != (t->operand_types[0] & JumpAbsolute)) + { + as_warn (_("Indirect %s without `*'"), t->name); + } + if ((t->opcode_modifier & (IsPrefix|IgnoreSize)) == (IsPrefix|IgnoreSize)) { /* Warn them that a data or address size prefix doesn't affect |