Skip to content

[GR-74988] Base-relative code pointers and PIE by default.#13468

Merged
graalvmbot merged 4 commits into
masterfrom
ph/GR-74988
May 5, 2026
Merged

[GR-74988] Base-relative code pointers and PIE by default.#13468
graalvmbot merged 4 commits into
masterfrom
ph/GR-74988

Conversation

@graalvmbot

Copy link
Copy Markdown
Collaborator
  • Default to building position-independent executables (PIE). They have security advantages and are enabled by default in the toolchains of many Linux OSes, but not all. Even then, their software packages typically use PIE. macOS and Windows toolchains have turned on PIE for some time already.
  • Enable RelativeCodePointers by default. For PIE and shared libraries, this substantially reduces the number of relocations and therefore image size and memory usage (and improves sharing between processes). This comes at the cost of a dedicated code base register and extra address arithmetic, which turns out to be near-negligible.

@oracle-contributor-agreement oracle-contributor-agreement Bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label May 5, 2026
@graalvmbot graalvmbot closed this May 5, 2026
@graalvmbot graalvmbot merged commit 5ff674a into master May 5, 2026
3 checks passed
@graalvmbot graalvmbot deleted the ph/GR-74988 branch May 5, 2026 20:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

OCA Verified All contributors have signed the Oracle Contributor Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants