-
Notifications
You must be signed in to change notification settings - Fork 183
Closed
Milestone
Description
Review comment come from @anderslindgren-iar and Anders Berg(IAR) https://lists.riscv.org/g/tech-toolchain-runtime/message/344
global offset table (GOT)
Anders: Where is the specification for GOT (how can one find it)?
# Load value from a local symbol
0: auipc a0, %pcrel_hi(symbol)
lw a0, %pcrel_lo(0b)(a0)
# Store value to a local symbol
1: auipc a0, %pcrel_hi(symbol)
sw a1, %pcrel_lo(1b)(a0)
# Calculate address of a local symbol
2: auipc a0, %pcrel_hi(symbol)
addi a0, a0, %pcrel_lo(2b)
# Calculate address of non-local symbol
3: auipc a0, %got_pcrel_hi(symbol)
l[w|d] a0, a0, %pcrel_lo(3b)
Anders: The example is pointless if one cannot find the specification for GOT.
Should it not be an additional case of how to read a non-local symbol?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels