This is an archive of the discontinued LLVM Phabricator instance.

[instrprof] Use __{start,stop}_SECNAME on PS4 too.
ClosedPublic

Authored by silvas on Feb 26 2016, 9:25 PM.

Details

Summary

The PS4 linker seems to handle this fine.

Hi David, it seems that indeed most ELF linkers support
__{start,stop}_SECNAME, as our proprietary linker does as well.

This follows the pattern of r250679 w.r.t. the testing.

Maggie, Phillip, Paul: I've tested this with the PS4 SDK 3.5 toolchain
prerelease and it seems to work fine.

Diff Detail

Event Timeline

silvas updated this revision to Diff 49282.Feb 26 2016, 9:25 PM
silvas retitled this revision from to [instrprof] Use __{start,stop}_SECNAME on PS4 too..
silvas updated this object.
silvas added a reviewer: davidxl.

Adding some more subscribers.

davidxl accepted this revision.Feb 26 2016, 9:34 PM
davidxl edited edge metadata.

This one looks fine. There is a compiler-rt part too.

This revision is now accepted and ready to land.Feb 26 2016, 9:34 PM
This revision was automatically updated to reflect the committed changes.

Thanks David. r262112.

This one looks fine. There is a compiler-rt part too.

Curiously PS4 defines FreeBSD and we we were actually already taking the linker magic #ifdef. I actually ran into this somewhat accidentally when using an upstream compiler-rt for PS4. I actually encountered link errors for missing __llvm_profile_register_function et al. which gave me the motivation to look closer. In the end this change seemed like the natural thing to do since it was a win-win for reducing our private patches and also getting the improved startup time.