This is an archive of the discontinued LLVM Phabricator instance.

[libc] Fix allocator inclusion
ClosedPublic

Authored by michaelrj on Feb 11 2022, 1:24 PM.

Details

Summary

Previously, allocator functions were only available if they were included
from scudo or by using the system libc headers (i.e. by turning off the
full build). This patch changes the logic to include the prototypes for
the allocator functitons in all cases, which allows the linker to link
in the system's allocator.

Diff Detail

Event Timeline

michaelrj created this revision.Feb 11 2022, 1:24 PM
michaelrj requested review of this revision.Feb 11 2022, 1:24 PM
abrachet accepted this revision.Feb 11 2022, 1:28 PM

Does something similar need to happen to the arm entrypoint file?

This revision is now accepted and ready to land.Feb 11 2022, 1:28 PM
sivachandra accepted this revision.Feb 11 2022, 1:33 PM

+1 @abrachet's suggestion about updating aarch64 list.

michaelrj updated this revision to Diff 408038.Feb 11 2022, 1:37 PM

add allocator functions + strdup to aarch64 entrypoints list

This revision was automatically updated to reflect the committed changes.