[PATCH] aarch64: Fix the documentation on :pg_hi21:

Marcus Shawcroft marcus.shawcroft@arm.com
Mon Jun 2 13:45:00 GMT 2014


On 29/05/14 18:58, Martin Storsjo wrote:
> The syntax described, including a leading '#', was not supported
> in practice. (For :lo12: it is optional.)
> ---
> Removed the # from the declaration of :lo12: as well - the
> '#' isn't a part of the :lo12: prefix itself but is part of how
> the symbol is used in the instruction.
> ---
>   gas/doc/c-aarch64.texi | 10 +++++-----
>   1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/gas/doc/c-aarch64.texi b/gas/doc/c-aarch64.texi
> index cce4f61..3d84123 100644
> --- a/gas/doc/c-aarch64.texi
> +++ b/gas/doc/c-aarch64.texi
> @@ -186,24 +186,24 @@ For example to load the 48-bit absolute address of @var{foo} into x0:
>   @cindex ADRP, ADD, LDR/STR group relocations, AArch64
>   Relocations for @samp{ADRP}, and @samp{ADD}, @samp{LDR} or @samp{STR}
>   instructions can be generated by prefixing the label with
> -@samp{#:pg_hi21:} and @samp{#:lo12:} respectively.
> +@samp{:pg_hi21:} and @samp{:lo12:} respectively.
>
>   For example to use 33-bit (+/-4GB) pc-relative addressing to
>   load the address of @var{foo} into x0:
>
>   @smallexample
> -        adrp x0, #:pg_hi21:foo
> +        adrp x0, :pg_hi21:foo
>           add  x0, x0, #:lo12:foo
>   @end smallexample
>
>   Or to load the value of @var{foo} into x0:
>
>   @smallexample
> -        adrp x0, #:pg_hi21:foo
> +        adrp x0, :pg_hi21:foo
>           ldr  x0, [x0, #:lo12:foo]
>   @end smallexample
>
> -Note that @samp{#:pg_hi21:} is optional.
> +Note that @samp{:pg_hi21:} is optional.
>
>   @smallexample
>           adrp x0, foo
> @@ -212,7 +212,7 @@ Note that @samp{#:pg_hi21:} is optional.
>   is equivalent to
>
>   @smallexample
> -        adrp x0, #:pg_hi21:foo
> +        adrp x0, :pg_hi21:foo
>   @end smallexample
>
>   @node AArch64 Floating Point
>

OK with an appropriate ChangeLog entry.
/Marcus



More information about the Binutils mailing list