Skip to content

Commit 104b7dc

Browse files
authored
TLSDESC Relax Relocation Clarification (#475)
Unlike all other relaxation sequences, TLSDESC relaxations only require a R_RISCV_RELAX on their first relocation. Clarify this fact in the text.
1 parent 1f2ecf4 commit 104b7dc

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

riscv-elf.adoc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1920,7 +1920,10 @@ Relaxation result:
19201920

19211921
Target Relocation:: R_RISCV_TLSDESC_HI20, R_RISCV_TLSDESC_LOAD_LO12, R_RISCV_TLSDESC_ADD_LO12, R_RISCV_TLSDESC_CALL
19221922

1923-
Description:: This relaxation can relax a sequence loading the address of a thread-local symbol reference into a GOT load instruction.
1923+
Description::
1924+
1925+
This relaxation can relax a sequence loading the address of a thread-local symbol reference into a GOT load instruction.
1926+
Unlike most other relaxations, this only requires a `R_RISCV_RELAX` relocation at the same location as the `R_RISCV_TLSDESC_HI20` relocation.
19241927

19251928
Condition::
19261929
- Linker output is an executable.
@@ -1957,7 +1960,10 @@ Relaxation result:
19571960

19581961
Target Relocation:: R_RISCV_TLSDESC_HI20, R_RISCV_TLSDESC_LOAD_LO12, R_RISCV_TLSDESC_ADD_LO12, R_RISCV_TLSDESC_CALL
19591962

1960-
Description:: This relaxation can relax a sequence loading the address of a thread-local symbol reference into a thread-pointer-relative instruction sequence.
1963+
Description::
1964+
1965+
This relaxation can relax a sequence loading the address of a thread-local symbol reference into a thread-pointer-relative instruction sequence.
1966+
Unlike most other relaxations, this only requires a `R_RISCV_RELAX` relocation at the same location as the `R_RISCV_TLSDESC_HI20` relocation.
19611967

19621968
Condition::
19631969

0 commit comments

Comments
 (0)