From: nobody <> Date: Thu, 14 Mar 2002 10:05:26 +0000 (+0000) Subject: This commit was manufactured by cvs2svn to create branch 'binutils- X-Git-Tag: binutils-2_12_1~99 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=a00b065c3ef38e3f6b645d20c7a2984b38db6ffc;p=thirdparty%2Fbinutils-gdb.git This commit was manufactured by cvs2svn to create branch 'binutils- 2_12-branch'. Cherrypick from master 2002-03-14 10:05:25 UTC Hans-Peter Nilsson ' * gas/mmix/weak1.d, gas/mmix/weak1.d: New test.': gas/testsuite/gas/i386/x86-64-inval.l gas/testsuite/gas/i386/x86-64-inval.s gas/testsuite/gas/mmix/weak1.d gas/testsuite/gas/mmix/weak1.s --- diff --git a/gas/testsuite/gas/i386/x86-64-inval.l b/gas/testsuite/gas/i386/x86-64-inval.l new file mode 100644 index 00000000000..05416d7c02e --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-inval.l @@ -0,0 +1,30 @@ +.*: Assembler messages: +.*:3: Error: .* +.*:4: Error: .* +.*:5: Error: .* +.*:6: Error: .* +.*:7: Error: .* +.*:8: Error: .* +.*:9: Error: .* +.*:10: Error: .* +.*:11: Error: .* +.*:12: Error: .* +.*:13: Error: .* +.*:14: Error: .* +GAS LISTING .* + + + 1 [ ]* .text + 2 [ ]*# All the following should be illegal for x86-64 + 3 [ ]*calll \*%eax # 32-bit data size not allowed + 4 [ ]*calll \*\(%ax\) # 32-bit data size not allowed + 5 [ ]*calll \*\(%eax\) # 32-bit data size not allowed + 6 [ ]*calll \*\(%r8\) # 32-bit data size not allowed + 7 [ ]*calll \*\(%rax\) # 32-bit data size not allowed + 8 [ ]*callq \*\(%ax\) # 32-bit data size not allowed + 9 [ ]*callw \*\(%ax\) # no 16-bit addressing + 10 [ ]*foo:[ ]*jcxz foo # No prefix exists to select CX as a counter + 11 [ ]*popl %eax # can\'t have 32-bit stack operands + 12 [ ]*pushl %eax # can\'t have 32-bit stack operands + 13 [ ]*pushfl # can\'t have 32-bit stack operands + 14 [ ]*popfl # can\'t have 32-bit stack operands diff --git a/gas/testsuite/gas/i386/x86-64-inval.s b/gas/testsuite/gas/i386/x86-64-inval.s new file mode 100644 index 00000000000..be532d52a13 --- /dev/null +++ b/gas/testsuite/gas/i386/x86-64-inval.s @@ -0,0 +1,14 @@ + .text +# All the following should be illegal for x86-64 + calll *%eax # 32-bit data size not allowed + calll *(%ax) # 32-bit data size not allowed + calll *(%eax) # 32-bit data size not allowed + calll *(%r8) # 32-bit data size not allowed + calll *(%rax) # 32-bit data size not allowed + callq *(%ax) # 32-bit data size not allowed + callw *(%ax) # no 16-bit addressing +foo: jcxz foo # No prefix exists to select CX as a counter + popl %eax # can't have 32-bit stack operands + pushl %eax # can't have 32-bit stack operands + pushfl # can't have 32-bit stack operands + popfl # can't have 32-bit stack operands diff --git a/gas/testsuite/gas/mmix/weak1.d b/gas/testsuite/gas/mmix/weak1.d new file mode 100644 index 00000000000..d0696e0c3dc --- /dev/null +++ b/gas/testsuite/gas/mmix/weak1.d @@ -0,0 +1,23 @@ +#as: -x +#objdump: -str + +# Relaxation thought a weak symbol was within reach. + +.*: file format elf64-mmix + +SYMBOL TABLE: +0+ l d \.text 0+ +0+ l d \.data 0+ +0+ l d \.bss 0+ +0+ w \.text 0+ foo +0+4 g \.text 0+ main + +RELOCATION RECORDS FOR \[\.text\]: +OFFSET TYPE VALUE +0+18 R_MMIX_64 foo +0+4 R_MMIX_PUSHJ foo + +Contents of section \.text: + 0000 f8010000 f20f0000 fd000000 fd000000 .* + 0010 fd000000 fd000000 00000000 00000000 .* +Contents of section \.data: diff --git a/gas/testsuite/gas/mmix/weak1.s b/gas/testsuite/gas/mmix/weak1.s new file mode 100644 index 00000000000..f5dbefb3d99 --- /dev/null +++ b/gas/testsuite/gas/mmix/weak1.s @@ -0,0 +1,7 @@ + .weak foo +foo: + POP 1,0 + .global main +main: + PUSHJ $15,foo + .quad foo