This is the mail archive of the
binutils-cvs@sourceware.org
mailing list for the binutils project.
src/gold ChangeLog layout.cc output.cc output. ...
- From: ian at sourceware dot org
- To: binutils-cvs at sourceware dot org
- Date: 13 Aug 2008 07:37:46 -0000
- Subject: src/gold ChangeLog layout.cc output.cc output. ...
CVSROOT: /cvs/src
Module name: src
Changes by: ian@sourceware.org 2008-08-13 07:37:46
Modified files:
gold : ChangeLog layout.cc output.cc output.h
script-c.h script-sections.cc script-sections.h
script.cc script.h yyscript.y
gold/testsuite : Makefile.am Makefile.in relro_test.cc
Added files:
gold/testsuite : relro_script_test.t
Log message:
* layout.cc (Layout::attach_allocated_section_to_segment): Don't
set tls_segment_ or relro_segment_.
(Layout::make_output_segment): Set tls_segment_ and relro_segment_
when appropriate.
* output.h (Output_section::clear_is_relro): New function.
* output.cc (Output_segment::add_output_section): Handle SHF_TLS
sections specially even when output_data_ is empty.
(Output_segment::maximum_alignment): When first section is relro,
only force alignment for PT_LOAD segments.
* script.cc (script_data_segment_align): New function.
(script_data_segment_relro_end): New function.
* script-c.h (script_data_segment_align): Declare.
(script_data_segment_relro_end): Declare.
* script-sections.h (class Script_sections): Declare
data_segment_align and data_segment_relro_end. Add fields
segment_align_index_ and saw_relro_end_.
* script-sections.cc (class Sections_element): Add set_is_relro
virtual function. Add new bool* parameter to place_orphan_here.
Add get_output_section virtual function.
(class Output_section_definition): Add set_is_relro. Add new
bool* parameter to place_orphan_here. Add get_output_section.
Add is_relro_ field.
(Output_section_definition::Output_section_definition): Initialize
evaluated_address_, evaluated_load_address, evaluated_addralign_,
and is_relro_ fields.
(Output_section_definition::place_orphan_here): Add is_relro
parameter.
(Output_section_definition::set_section_addresses): Set relro for
output section.
(Output_section_definition::alternate_constraint): Likewise.
(class Orphan_output_section): Add new bool* parameter to
place_orphan_here. Add get_output_section.
(Orphan_output_section::place_orphan_here): Add is_relro
parameter.
(Script_sections::Script_sections): Initialize
data_segment_align_index_ and saw_relro_end_.
(Script_sections::data_segment_align): New function.
(Script_sections::data_segment_relro_end): New function.
(Script_sections::place_orphan): Set or clear is_relro.
(Script_sections::set_section_addresses): Force alignment of first
TLS section.
* yyscript.y (exp): Call script_data_segment_align and
script_data_segment_relro_end.
* testsuite/relro_script_test.t: New file.
* testsuite/relro_test.cc (using_script): Declare.
(t1, t2): Test using_script.
* testsuite/Makefile.am (check_PROGRAMS): Add relro_script_test.
(relro_script_test_SOURCES): Define.
(relro_script_test_DEPENDENCIES): Define.
(relro_script_test_LDFLAGS): Define.
(relro_script_test_LDADD): Define.
(relro_script_test.so): New target.
* testsuite/Makefile.in: Rebuild.
Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/ChangeLog.diff?cvsroot=src&r1=1.127&r2=1.128
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/layout.cc.diff?cvsroot=src&r1=1.111&r2=1.112
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/output.cc.diff?cvsroot=src&r1=1.82&r2=1.83
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/output.h.diff?cvsroot=src&r1=1.74&r2=1.75
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/script-c.h.diff?cvsroot=src&r1=1.11&r2=1.12
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/script-sections.cc.diff?cvsroot=src&r1=1.16&r2=1.17
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/script-sections.h.diff?cvsroot=src&r1=1.6&r2=1.7
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/script.cc.diff?cvsroot=src&r1=1.46&r2=1.47
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/script.h.diff?cvsroot=src&r1=1.20&r2=1.21
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/yyscript.y.diff?cvsroot=src&r1=1.15&r2=1.16
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/testsuite/relro_script_test.t.diff?cvsroot=src&r1=NONE&r2=1.1
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/testsuite/Makefile.am.diff?cvsroot=src&r1=1.74&r2=1.75
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/testsuite/Makefile.in.diff?cvsroot=src&r1=1.79&r2=1.80
http://sourceware.org/cgi-bin/cvsweb.cgi/src/gold/testsuite/relro_test.cc.diff?cvsroot=src&r1=1.2&r2=1.3