5.12 PC-relative addressing

armasm syntax assembly and GNU syntax assembly provide different methods for performing PC-relative addressing.

armasm syntax

armasm syntax assembly provides the symbol {pc} to let you specify an address relative to the current instruction.

For example:

ADRP x0, {pc}

GNU syntax

GNU syntax assembly does not support the {pc} symbol. Instead, it uses the special dot "." character, as follows:

ADRP x0, .
Non-ConfidentialPDF file icon PDF version100068_0609_00_en
Copyright © 2014–2017 Arm Limited (or its affiliates). All rights reserved.