aboutsummaryrefslogtreecommitdiff
path: root/gcc/config.gcc
diff options
context:
space:
mode:
authorIain Sandoe <iain@sandoe.co.uk>2021-11-13 12:39:09 +0000
committerIain Sandoe <iain@sandoe.co.uk>2021-12-02 19:44:44 +0000
commit22a982409323feb203401d345488a5a9c18e6733 (patch)
treed1b59ebd2620f197c94fa2a5d00817dc007700f1 /gcc/config.gcc
parent2835977f8460ea59e7d3c877453fa358b31f9a7f (diff)
downloadgcc-22a982409323feb203401d345488a5a9c18e6733.zip
gcc-22a982409323feb203401d345488a5a9c18e6733.tar.gz
gcc-22a982409323feb203401d345488a5a9c18e6733.tar.bz2
Darwin: Rewrite host PCH support [PR 55610].
We need to revise the PCH memory allocation scheme to enable support for PIE on aarch64. The rewrite uses a similar scheme to the one used on Linux. We attempt to identify VM segments for each arch/OS version that are always available to the compiler (note this is not general, it only needs to work for the cc1* exes). If we cannot find the preferred segment we fall back to allowing the kernel to supply one - this is more likely to fail when the PCH read-in occurs (but that is trapped). In doing this we obviate the need to unmap any part of the compiler __DATA segment - thus fixing PR 55610. Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> gcc/ChangeLog: PR target/55610 * config/host-darwin.c (TRY_EMPTY_VM_SPACE, SAFE_ALLOC_SIZE): New. (darwin_gt_pch_get_address): Rewrite to use nominated memory segments rather than part of the compiler __DATA segment. (darwin_gt_pch_use_address): Likewise.
Diffstat (limited to 'gcc/config.gcc')
0 files changed, 0 insertions, 0 deletions