gold/
* configure.ac (MERGE_CONSTANTS_FLAG): New check. * configure: Regenerate. * Makefile.in: Regenerate. * testsuite/merge_string_literals_1.c: Renamed to have .cc suffix. * testsuite/merge_string_literals_2.c: Likewise. * testsuite/Makefile.am (merge_string_literals_1.o, merge_string_literals_2.o): Update deps. (AM_CFLAGS, AM_CXXFLAGS): Use $(MERGE_CONSTANTS_FLAG) in place of literal -fmerge-constants. * testsuite/Makefile.in: Regenerate.
This commit is contained in:
parent
43819297ce
commit
2b64b5511a
8 changed files with 101 additions and 45 deletions
|
@ -1,5 +1,16 @@
|
|||
2013-10-11 Roland McGrath <mcgrathr@google.com>
|
||||
|
||||
* configure.ac (MERGE_CONSTANTS_FLAG): New check.
|
||||
* configure: Regenerate.
|
||||
* Makefile.in: Regenerate.
|
||||
* testsuite/merge_string_literals_1.c: Renamed to have .cc suffix.
|
||||
* testsuite/merge_string_literals_2.c: Likewise.
|
||||
* testsuite/Makefile.am
|
||||
(merge_string_literals_1.o, merge_string_literals_2.o): Update deps.
|
||||
(AM_CFLAGS, AM_CXXFLAGS): Use $(MERGE_CONSTANTS_FLAG) in place of
|
||||
literal -fmerge-constants.
|
||||
* testsuite/Makefile.in: Regenerate.
|
||||
|
||||
* i386.cc (Target_i386): Remove unused member dynbss_.
|
||||
* arm.cc (Target_arm): Likewise.
|
||||
* powerpc.cc (Target_powerpc): Likewise.
|
||||
|
@ -336,23 +347,23 @@
|
|||
|
||||
2013-05-21 Cary Coutant <ccoutant@google.com>
|
||||
|
||||
* object.cc (Sized_relobj_file::get_symbol_location_info): Set
|
||||
type of enclosing symbol.
|
||||
(Relocate_info::location): Check symbol type when describing symbol.
|
||||
* object.h (Symbol_location_info): Remove unused line_number;
|
||||
add enclosing_symbol_type.
|
||||
* testsuite/debug_msg.sh: Adjust expected output.
|
||||
* object.cc (Sized_relobj_file::get_symbol_location_info): Set
|
||||
type of enclosing symbol.
|
||||
(Relocate_info::location): Check symbol type when describing symbol.
|
||||
* object.h (Symbol_location_info): Remove unused line_number;
|
||||
add enclosing_symbol_type.
|
||||
* testsuite/debug_msg.sh: Adjust expected output.
|
||||
|
||||
2013-05-13 Cary Coutant <ccoutant@google.com>
|
||||
|
||||
* configure.ac: Export DEFAULT_TARGET.
|
||||
* configure: Regenerate.
|
||||
* Makefile.in: Regenerate.
|
||||
* testsuite/Makefile.am: Add .EXPORT_ALL_VARIABLES.
|
||||
* testsuite/Makefile.in: Regenerate.
|
||||
* testsuite/debug_msg.sh: Delete duplicate tests.
|
||||
Don't check undef_int error message match for powerpc where the
|
||||
source file and line number aren't available.
|
||||
* configure.ac: Export DEFAULT_TARGET.
|
||||
* configure: Regenerate.
|
||||
* Makefile.in: Regenerate.
|
||||
* testsuite/Makefile.am: Add .EXPORT_ALL_VARIABLES.
|
||||
* testsuite/Makefile.in: Regenerate.
|
||||
* testsuite/debug_msg.sh: Delete duplicate tests.
|
||||
Don't check undef_int error message match for powerpc where the
|
||||
source file and line number aren't available.
|
||||
|
||||
2013-05-10 Roland McGrath <mcgrathr@google.com>
|
||||
|
||||
|
|
|
@ -319,6 +319,7 @@ LN_S = @LN_S@
|
|||
LTLIBOBJS = @LTLIBOBJS@
|
||||
MAINT = @MAINT@
|
||||
MAKEINFO = @MAKEINFO@
|
||||
MERGE_CONSTANTS_FLAG = @MERGE_CONSTANTS_FLAG@
|
||||
MKDIR_P = @MKDIR_P@
|
||||
MKINSTALLDIRS = @MKINSTALLDIRS@
|
||||
MSGFMT = @MSGFMT@
|
||||
|
|
30
gold/configure
vendored
30
gold/configure
vendored
|
@ -622,6 +622,7 @@ STATIC_TLS_FALSE
|
|||
STATIC_TLS_TRUE
|
||||
TLS_FALSE
|
||||
TLS_TRUE
|
||||
MERGE_CONSTANTS_FLAG
|
||||
MCMODEL_MEDIUM_FALSE
|
||||
MCMODEL_MEDIUM_TRUE
|
||||
FN_PTRS_IN_SO_WITHOUT_PIC_FALSE
|
||||
|
@ -6339,6 +6340,35 @@ else
|
|||
fi
|
||||
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fmerge-constants" >&5
|
||||
$as_echo_n "checking whether $CC supports -fmerge-constants... " >&6; }
|
||||
if test "${gold_cv_merge_constants+set}" = set; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
|
||||
save_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS -fmerge-constants"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
const char *s = "foo";
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
have_merge_constants=yes
|
||||
else
|
||||
have_merge_constants=no
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
CFLAGS="$save_CFLAGS"
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_merge_constants" >&5
|
||||
$as_echo "$gold_cv_merge_constants" >&6; }
|
||||
|
||||
if test "$gold_cv_merge_constants" = yes; then :
|
||||
MERGE_CONSTANTS_FLAG=-fmerge-constants
|
||||
else
|
||||
MERGE_CONSTANTS_FLAG=
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread support" >&5
|
||||
$as_echo_n "checking for thread support... " >&6; }
|
||||
if test "${gold_cv_c_thread+set}" = set; then :
|
||||
|
|
|
@ -338,6 +338,19 @@ dnl Whether we can test -mcmodel=medium.
|
|||
AM_CONDITIONAL(MCMODEL_MEDIUM,
|
||||
[test "$target_cpu" = "x86_64" -a "$have_mcmodel_medium" = "yes" -a "$gold_cv_prog_gcc41" = "yes"])
|
||||
|
||||
AC_CACHE_CHECK([whether $CC supports -fmerge-constants],
|
||||
[gold_cv_merge_constants], [
|
||||
save_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS -fmerge-constants"
|
||||
AC_COMPILE_IFELSE([const char *s = "foo";],
|
||||
[have_merge_constants=yes],
|
||||
[have_merge_constants=no])
|
||||
CFLAGS="$save_CFLAGS"])
|
||||
AC_SUBST([MERGE_CONSTANTS_FLAG])
|
||||
AS_IF([test "$gold_cv_merge_constants" = yes],
|
||||
[MERGE_CONSTANTS_FLAG=-fmerge-constants],
|
||||
[MERGE_CONSTANTS_FLAG=])
|
||||
|
||||
dnl Test for __thread support.
|
||||
AC_CACHE_CHECK([for thread support], [gold_cv_c_thread],
|
||||
[AC_COMPILE_IFELSE([__thread int i = 1;],
|
||||
|
|
|
@ -8,10 +8,10 @@
|
|||
AUTOMAKE_OPTIONS = foreign -Wno-portability
|
||||
|
||||
# The two_file_test tests -fmerge-constants, so we simply always turn
|
||||
# it on. This may need to be controlled by a configure option
|
||||
# eventually.
|
||||
AM_CFLAGS = $(WARN_CFLAGS) $(LFS_CFLAGS) -fmerge-constants
|
||||
AM_CXXFLAGS = $(WARN_CXXFLAGS) $(LFS_CFLAGS) -fmerge-constants
|
||||
# it on. For compilers that do not support the command-line option,
|
||||
# we assume they just always emit SHF_MERGE sections unconditionally.
|
||||
AM_CFLAGS = $(WARN_CFLAGS) $(LFS_CFLAGS) $(MERGE_CONSTANTS_FLAG)
|
||||
AM_CXXFLAGS = $(WARN_CXXFLAGS) $(LFS_CFLAGS) $(MERGE_CONSTANTS_FLAG)
|
||||
|
||||
AM_CPPFLAGS = \
|
||||
-I$(srcdir) -I$(srcdir)/.. -I$(srcdir)/../../include \
|
||||
|
@ -337,9 +337,9 @@ large_symbol_alignment_LDADD =
|
|||
check_SCRIPTS += merge_string_literals.sh
|
||||
check_DATA += merge_string_literals.stdout
|
||||
MOSTLYCLEANFILES += merge_string_literals
|
||||
merge_string_literals_1.o: merge_string_literals_1.c
|
||||
merge_string_literals_1.o: merge_string_literals_1.cc
|
||||
$(CXXCOMPILE) -O2 -c -fPIC -g -o $@ $<
|
||||
merge_string_literals_2.o: merge_string_literals_2.c
|
||||
merge_string_literals_2.o: merge_string_literals_2.cc
|
||||
$(CXXCOMPILE) -O2 -c -fPIC -g -o $@ $<
|
||||
merge_string_literals: merge_string_literals_1.o merge_string_literals_2.o gcctestdir/ld
|
||||
$(CXXLINK) -Bgcctestdir/ merge_string_literals_1.o merge_string_literals_2.o -O2 -shared -nostdlib
|
||||
|
|
|
@ -1964,6 +1964,7 @@ LN_S = @LN_S@
|
|||
LTLIBOBJS = @LTLIBOBJS@
|
||||
MAINT = @MAINT@
|
||||
MAKEINFO = @MAKEINFO@
|
||||
MERGE_CONSTANTS_FLAG = @MERGE_CONSTANTS_FLAG@
|
||||
MKDIR_P = @MKDIR_P@
|
||||
MKINSTALLDIRS = @MKINSTALLDIRS@
|
||||
MSGFMT = @MSGFMT@
|
||||
|
@ -2055,10 +2056,10 @@ top_srcdir = @top_srcdir@
|
|||
AUTOMAKE_OPTIONS = foreign -Wno-portability
|
||||
|
||||
# The two_file_test tests -fmerge-constants, so we simply always turn
|
||||
# it on. This may need to be controlled by a configure option
|
||||
# eventually.
|
||||
AM_CFLAGS = $(WARN_CFLAGS) $(LFS_CFLAGS) -fmerge-constants
|
||||
AM_CXXFLAGS = $(WARN_CXXFLAGS) $(LFS_CFLAGS) -fmerge-constants
|
||||
# it on. For compilers that do not support the command-line option,
|
||||
# we assume they just always emit SHF_MERGE sections unconditionally.
|
||||
AM_CFLAGS = $(WARN_CFLAGS) $(LFS_CFLAGS) $(MERGE_CONSTANTS_FLAG)
|
||||
AM_CXXFLAGS = $(WARN_CXXFLAGS) $(LFS_CFLAGS) $(MERGE_CONSTANTS_FLAG)
|
||||
AM_CPPFLAGS = \
|
||||
-I$(srcdir) -I$(srcdir)/.. -I$(srcdir)/../../include \
|
||||
-I$(srcdir)/../../elfcpp -I.. \
|
||||
|
@ -4513,9 +4514,9 @@ uninstall-am:
|
|||
@GCC_TRUE@@NATIVE_LINKER_TRUE@ $(CXXLINK) -Bgcctestdir/ -Wl,--icf=all icf_sht_rel_addend_test_1.o icf_sht_rel_addend_test_2.o
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@icf_sht_rel_addend_test.stdout: icf_sht_rel_addend_test
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@ $(TEST_NM) icf_sht_rel_addend_test > icf_sht_rel_addend_test.stdout
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@merge_string_literals_1.o: merge_string_literals_1.c
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@merge_string_literals_1.o: merge_string_literals_1.cc
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@ $(CXXCOMPILE) -O2 -c -fPIC -g -o $@ $<
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@merge_string_literals_2.o: merge_string_literals_2.c
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@merge_string_literals_2.o: merge_string_literals_2.cc
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@ $(CXXCOMPILE) -O2 -c -fPIC -g -o $@ $<
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@merge_string_literals: merge_string_literals_1.o merge_string_literals_2.o gcctestdir/ld
|
||||
@GCC_TRUE@@NATIVE_LINKER_TRUE@ $(CXXLINK) -Bgcctestdir/ merge_string_literals_1.o merge_string_literals_2.o -O2 -shared -nostdlib
|
||||
|
|
Loading…
Reference in a new issue