diff options
author | Hans-Peter Nilsson <hp@axis.com> | 2002-02-01 08:24:03 +0000 |
---|---|---|
committer | Hans-Peter Nilsson <hp@axis.com> | 2002-02-01 08:24:03 +0000 |
commit | 48fa4a5def1116273c2c2a236939e96eb9b6231a (patch) | |
tree | b8597630be4f09f870fede949598daddae5d1d15 /ld/scripttempl | |
parent | 930b4cb2c2da2be8643a1e79fe09fe7328544d32 (diff) | |
download | fsf-binutils-gdb-48fa4a5def1116273c2c2a236939e96eb9b6231a.zip fsf-binutils-gdb-48fa4a5def1116273c2c2a236939e96eb9b6231a.tar.gz fsf-binutils-gdb-48fa4a5def1116273c2c2a236939e96eb9b6231a.tar.bz2 |
Support on-demand global register allocation from
R_MMIX_BASE_PLUS_OFFSET relocs.
* emultempl/mmix-elfnmmo.em (mmix_after_allocation): Rename from
mmix_set_reg_section_vma. Call
_bfd_mmix_finalize_linker_allocated_gregs.
(mmix_before_allocation): New function.
(LDEMUL_AFTER_ALLOCATION): Set to mmix_after_allocation.
(LDEMUL_BEFORE_ALLOCATION): Define to mmix_before_allocation.
* scripttempl/mmo.sc (.text): Mark .init, .fini as KEEP.
(.MMIX.reg_contents): Add .MMIX.reg_contents.linker_allocated
before .MMIX.reg_contents.
* emultempl/mmo.em (gldmmo_before_allocation): Define to default.
(mmo_after_open): New function.
(LDEMUL_AFTER_OPEN): Define to mmo_after_open.
* emulparams/elf64mmix.sh (OTHER_SECTIONS): Tweak formatting. Add
.MMIX.reg_contents.linker_allocated before .MMIX.reg_contents.
Diffstat (limited to 'ld/scripttempl')
-rw-r--r-- | ld/scripttempl/mmo.sc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ld/scripttempl/mmo.sc b/ld/scripttempl/mmo.sc index 5b9ef85..72e8b49 100644 --- a/ld/scripttempl/mmo.sc +++ b/ld/scripttempl/mmo.sc @@ -16,12 +16,12 @@ SECTIONS /* FIXME: Move .init, .fini, .ctors and .dtors to their own sections. */ ${RELOCATING+ PROVIDE (_init_start = .);} ${RELOCATING+ PROVIDE (_init = .);} - ${RELOCATING+ *(.init)} + ${RELOCATING+ KEEP (*(.init))} ${RELOCATING+ PROVIDE (_init_end = .);} ${RELOCATING+ PROVIDE (_fini_start = .);} ${RELOCATING+ PROVIDE (_fini = .);} - ${RELOCATING+ *(.fini)} + ${RELOCATING+ KEEP (*(.fini))} ${RELOCATING+ PROVIDE (_fini_end = .);} /* FIXME: Align ctors, dtors, ehframe. */ @@ -115,6 +115,7 @@ SECTIONS { /* Note that this section always has a fixed VMA - that of its first register * 8. */ + *(.MMIX.reg_contents.linker_allocated); *(.MMIX.reg_contents); } |