This is the mail archive of the binutils@sourceware.org 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]

Patch to fix bug in ICF.


Hi,

   Doug reported a bug in ICF on ARM while processing merge sections.
ICF currently does not handle addends correctly while processing
relocations to merge sections on ARM. I have tested ICF merge section
handling  for i386 and x86_64 but not the corner cases on other back
ends. So, here is a patch to turn-off the inlining of merge sections
in ICF for all back-ends, except for i386 and x86_64. Anybody who is
interested in turning this on should first make sure ICF handles this
adequately.

	* target.h (Target::can_icf_inline_merge_sections): New virtual
	function.
	* x86_64.cc (Target__x86_64::can_icf_inline_merge_sections): New
	virtual function.
	* i386.cc (Target_i386::can_icf_inline_merge_sections): New
	virtual function.
	* icf.cc (get_section_contents): Inline merge sections only when
	target allows it.


Is this ok to submit ?

Thanks,
-Sri.

Attachment: icf_merge_sections_patch.txt
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]