[all-commits] [llvm/llvm-project] 07d0a4: [ELF][RISCV] Make .sdata and .sbss closer
Fangrui Song via All-commits
all-commits at lists.llvm.org
Tue Mar 7 10:37:17 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 07d0a4fb537f15d68385c0598d3b0dbf9e99763d
https://github.com/llvm/llvm-project/commit/07d0a4fb537f15d68385c0598d3b0dbf9e99763d
Author: Fangrui Song <i at maskray.me>
Date: 2023-03-07 (Tue, 07 Mar 2023)
Changed paths:
M lld/ELF/Writer.cpp
R lld/test/ELF/riscv-gp-no-sdata.s
A lld/test/ELF/riscv-section-layout.s
Log Message:
-----------
[ELF][RISCV] Make .sdata and .sbss closer
GNU ld's internal linker scripts for RISC-V place .sdata and .sbss close.
This makes GP relaxation more profitable.
While here, when .sbss is present, set `__bss_start` to the start of
.sbss instead of .bss, to match GNU ld.
Note: GNU ld's internal linker scripts have symbol assignments and input
section descriptions which are not relevant for modern systems. We only
add things that make sense.
Reviewed By: craig.topper
Differential Revision: https://reviews.llvm.org/D145118
More information about the All-commits
mailing list