This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Hi, I have added linker relaxation support for bit manipulation insns like following, band, bclr, biand, bild, bior, bist, bixor, bld, bnot, bor, bset, bst, btst, bxor. Please find attached a patch written for binutils snapshot dated 28 Dec 03 which adds relaxation support for above mentioned bit manipulation insns along with a patch for ChangeLog. Relaxation support is added for ELF as well as for COFF file formats. Also please find attached testcode, object dump of testcode for COFF and ELF formats. I hope this testcode can be directly included in ld-testsuite. Thanks to Nick Clifton for his valuable guidance. Regards, Anil Paranjpe -----Original Message----- From: Nick Clifton [mailto:nickc@redhat.com] Sent: Monday, December 15, 2003 9:37 PM To: Anil Paranjape Cc: binutils@sources.redhat.com Subject: Re: Regarding Bitwise relaxation for H8/300 Hi Anil, > Above objdump clearly shows that "bset #0x6,@0x120:32" insn can be > relaxed to "bset #0x6,@0x120:16" likewise "mov.b r2l,@0x120:16" is > relaxed by linker from insn "mov.b r2l,@0x120:32". > > I would like to add relaxation support for bitwise insn like bset, > bclr etc . Can anyone guide me on this ? What you need to do is to download the latest binutils sources from the CVS repository. (See the binutils web page for information on how to do this). The build yourself a version of the linker targeted at the h8300-elf using these sources and verify that it works. Next take a look at the source file bfd/elf32-h8300.c and find the function elf32_h8_relax_section(). This is the function where you will need to add the support for relaxing the BSET instruction. Use the code that is already there as a guide for what you need to do. When you think you have things working, and have tested the patched linker and found that it works, have a look at the directory ld/testsuite/ld-h8300. Try adding a test case here to check that the new relaxation works, and continues to work with future version of the linker. When you are happy that everything is ready, please do consider contributing it back to the FSF. You will need a copyright assignment in place to do this - so that we can accept the code. If you are interested I can send you the email form that starts this process rolling. If you have questions or encounter problems, please do post them to this mailing list. Cheers Nick
Attachment:
bitwise_relaxation.patch
Description: bitwise_relaxation.patch
Attachment:
relax-4.d
Description: relax-4.d
Attachment:
relax-4.s
Description: relax-4.s
Attachment:
relax-4.sh
Description: relax-4.sh
Attachment:
relax-4-coff.d
Description: relax-4-coff.d
Attachment:
chnagelog.patch
Description: chnagelog.patch
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |