https://sourceware.org/bugzilla/show_bug.cgi?id=18770
Bug ID: 18770 Summary: Does not allow 32-bit address in 64-bit mode for memory operand of i386 BNDMOV, etc. Product: binutils Version: 2.24 Status: NEW Severity: normal Priority: P2 Component: gas Assignee: unassigned at sourceware dot org Reporter: m at rolle dot name Target Milestone: --- I did not indicate Critical only because gas does not produce incorrect code. However, the bug is a serious one because gas will reject a valid instruction. In BNDMOV and a few other similar instructions, one of the operands may be located in memory. There is NO restriction as to whether 32 or 64 bit addresses are allowed. #UD will occur with 16 bit addresses (which can't happen in 64-bit mode anyway). When I try to assemble bndmov [eax], bnd1 I get the message Error: 32-bit address isn't allowed in 64-bit MPX instructions. Likewise with bndmk bnd1, [eax+16] I think the programmers got confused about 32- and 64-bit addresses. These apply only to the contents of the bound registers themselves (i.e., bnd1 in the above example). Instructions like BNDMK load the register with a 32 or 64 bit address, depending on the processor mode. But even in these cases, a 32 bit address can be used in 64 bit mode, and will just be zero-extended to 64 bits. A similar problem exists with objdump disassembly, which is being filed as a separate bug. -- You are receiving this mail because: You are on the CC list for the bug. _______________________________________________ bug-binutils mailing list bug-binutils@gnu.org https://lists.gnu.org/mailman/listinfo/bug-binutils