This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC] .fill does not accept forward labels


On Mon, 9 Oct 2017, Andreas Krebbel wrote:

> diff --git a/gas/testsuite/gas/all/fill-1.d b/gas/testsuite/gas/all/fill-1.d
> new file mode 100644
> index 0000000..80b8d0a
> --- /dev/null
> +++ b/gas/testsuite/gas/all/fill-1.d
> @@ -0,0 +1,7 @@
> +#objdump: -s
> +#name: fill test with forward labels
> +
> +.*: +file format .*
> +
> +Contents of section .data:
> + [^ ]* (0a0a0d0d 0b0b0c0c) .*

 Please verify it suitably; offhand I smell endianness related problems 
with this pattern, but there can be other peculiarities with some targets.  

 Also what's the purpose of the parentheses?

> diff --git a/gas/testsuite/gas/all/fill-1.s b/gas/testsuite/gas/all/fill-1.s
> index e72cbf1..3d27e51 100644
> --- a/gas/testsuite/gas/all/fill-1.s
> +++ b/gas/testsuite/gas/all/fill-1.s
> @@ -1,5 +1,7 @@
> -       .text
> -       .fill (2f-1f), 1, 0x90
> +       .data
> +       .word 0x0a0a
> +       .fill (2f-1f), 1, 0x0d
>  1:
> -        .word 42
> +       .word 0x0b0b
>  2:
> +       .word 0x0c0c

 If verifying actual output, then I suggest using `dc.w' instead.  With 
MIPS targets for example `.word' will produce 32-bit quantities.

  Maciej


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]