Skip to content

Commit ae36223

Browse files
authored
Merge pull request #317 from asb/relax-note
Add note ensuring to emit relocations in the presence of relaxation
2 parents 442ae19 + ad21ffd commit ae36223

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

riscv-elf.adoc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1001,6 +1001,11 @@ rather than to instruct the linker how to apply a relocation.
10011001
The linker should only perform such relaxations when a R_RISCV_RELAX relocation
10021002
is at the same position as a candidate relocation.
10031003

1004+
As this transformation may delete bytes (and thus invalidate references that
1005+
are commonly resolved at compile-time, such as intra-function jumps), code
1006+
generators must in general ensure that relocations are always emitted when
1007+
relaxation is enabled.
1008+
10041009
[bibliography]
10051010
== References
10061011

0 commit comments

Comments
 (0)