i386: Don't add 0x66 prefix to IRET for .code16gcc
authorH.J. Lu <hjl.tools@gmail.com>
Fri, 26 Apr 2019 17:19:53 +0000 (10:19 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Fri, 26 Apr 2019 17:19:53 +0000 (10:19 -0700)
commit7cb22ff84745da0856bf74578b9bd7dff4379ed5
treedfabab348a1df3900215b53045792e1a7f827cd0
parentc54f15248ee990df6cea0b4730cd61b227a0e082
i386: Don't add 0x66 prefix to IRET for .code16gcc

The .code16gcc directive supports 16bit mode with 32-bit address.  Since
IRET (opcode 0xcf) in 16bit mode returns from an interrupt in 16bit mode,
we shouldn't add 0x66 prefix for IRET.

PR gas/24485
* config/tc-i386.c (process_suffix): Don't add DATA_PREFIX_OPCODE
to IRET for .code16gcc.
* testsuite/gas/i386/jump16.s: Add IRET tests.
* testsuite/gas/i386/jump16.d: Updated.
gas/ChangeLog
gas/config/tc-i386.c
gas/testsuite/gas/i386/jump16.d
gas/testsuite/gas/i386/jump16.s
This page took 0.025825 seconds and 4 git commands to generate.