X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gas%2Ftestsuite%2Fgas%2Fi386%2Fgeneral.s;h=385b478990847c2398c0c234925aadb3dc57b358;hb=f03fe4c1100351b498e353d4f3ec126df634e2ca;hp=c794157c89de9eb5bfce3263fdc68c6897504b7b;hpb=72ec28b8afa357cdde70c612b4e0e9f37a34f8e4;p=deliverable%2Fbinutils-gdb.git diff --git a/gas/testsuite/gas/i386/general.s b/gas/testsuite/gas/i386/general.s index c794157c89..385b478990 100644 --- a/gas/testsuite/gas/i386/general.s +++ b/gas/testsuite/gas/i386/general.s @@ -1,5 +1,34 @@ .psize 0 .text +#test jumps and calls +1: jmp 1b + jmp xxx + jmp *xxx + jmp xxx(,1) + jmp *%edi + jmp %edi + jmp *(%edi) + jmp (%edi) + ljmp *xxx(,%edi,4) + ljmp xxx(,%edi,4) + ljmp *xxx + ljmp xxx(,1) + ljmp $0x1234,$xxx + + call 1b + call xxx + call *xxx + call xxx(,1) + call *%edi + call %edi + call *(%edi) + call (%edi) + lcall *xxx(,%edi,4) + lcall xxx(,%edi,4) + lcall *xxx + lcall xxx(,1) + lcall $0x1234,$xxx + # test various segment reg insns push %ds pushl %ds @@ -61,9 +90,23 @@ inb $255 inw $2 inl $4 - outl %eax,%dx - out %al, $42 in $13, %ax + out %al,%dx + out %ax,%dx + out %eax,%dx + out %al,(%dx) + out %ax,(%dx) + out %eax,(%dx) + outb %al,%dx + outw %ax,%dx + outl %eax,%dx + outb %dx + outw %dx + outl %dx + outb $255 + outw $2 + outl $4 + out %ax, $13 # These are used in AIX. inw (%dx) outw (%dx) @@ -147,6 +190,19 @@ mov %esi,(,%ebx,1) andb $~0x80,foo + and $0xfffe,%ax + and $0xff00,%ax + and $0xfffe,%eax + and $0xff00,%eax + and $0xfffffffe,%eax + +.code16 + and $0xfffe,%ax + and $0xff00,%ax + and $0xfffe,%eax + and $0xff00,%eax + and $0xfffffffe,%eax + #check 16-bit code auto address prefix .code16gcc leal -256(%ebp),%edx @@ -156,33 +212,9 @@ movl %eax,140(%esp) .code32 - jmp 1b - jmp xxx - jmp *xxx - jmp xxx(,1) - jmp *%edi - jmp %edi - jmp *(%edi) - jmp (%edi) - ljmp *xxx(,%edi,4) - ljmp xxx(,%edi,4) - ljmp *xxx - ljmp xxx(,1) - ljmp $0x1234,$xxx - - call 1b - call xxx - call *xxx - call xxx(,1) - call *%edi - call %edi - call *(%edi) - call (%edi) - lcall *xxx(,%edi,4) - lcall xxx(,%edi,4) - lcall *xxx - lcall xxx(,1) - lcall $0x1234,$xxx +# Make sure that we won't remove movzb by accident. + movzb %al,%di + movzb %al,%ecx # Force a good alignment. .p2align 4,0