This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
Use linker script to split text section ??
- From: Jer Yu Hsu <zysheu at sslab dot cs dot nthu dot edu dot tw>
- To: binutils at sourceware dot org
- Date: Fri, 02 Dec 2005 14:27:59 +0800
- Subject: Use linker script to split text section ??
In linker script , I can control the input sections to output sections
mapping.
If I want one output section split to many subsections , how can I do it ?
ex: output section : .text => (split to subsections) .text_1 + .text_2 +
.text_3 + ....
Another question, if i want to insert some null code (nop) in .text
section , how can i do it ?
ex: .text (128K) => 32K code + 2K nop + 32K code + 2K nop+ 32K code + 2K
nop+ 32K code+ 2K nop ( 128K + 2K x 4 )
every 32K code insett 2K null code .
If I want to do these , should I need to modify the linker's source code
or linker script can help i do it ?
Thanks .