Page MenuHomeFreeBSD

[PowerPC] Only move linker sets to .data on ELFv1
ClosedPublic

Authored by bdragon on Dec 13 2019, 4:31 PM.
Referenced Files
F87253636: D22796.id65595.diff
Sun, Jun 30, 9:12 PM
Unknown Object (File)
May 2 2024, 10:59 PM
Unknown Object (File)
Apr 29 2024, 9:16 AM
Unknown Object (File)
Apr 29 2024, 9:01 AM
Unknown Object (File)
Apr 29 2024, 9:00 AM
Unknown Object (File)
Apr 29 2024, 7:49 AM
Unknown Object (File)
Apr 29 2024, 7:28 AM
Unknown Object (File)
Mar 1 2024, 7:26 PM
Subscribers

Details

Summary

In r268055, powerpc64 was special cased regarding linker sets to not mark the function pointer as 'const'.

This appears to have been done to ensure the compiler generates the function descriptors correctly. When non-const, the function descriptors will end up in the .data.rel.local section, and the linker set symbols will get relocations pointing to them there.

Since function pointers on ELFv2 are "just" pointers like other platforms, we can leave them const like they are on every other platform.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

I trust you've tested this with at least a buildkernel and boot? What's the result?

This revision is now accepted and ready to land.Dec 17 2019, 1:41 AM

Yeah, been running with it for over a month.

This revision was automatically updated to reflect the committed changes.